Discussion ClosedThis discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one,click here.

How can I define and where can I apply a variable function in space and time?

Marianna Di Pietrantonio

Please login with a confirmed email address before reporting spam

Hello everyone, I have a problem and hope that someone can help me. I have attached a video and an image. The video shows (in blue) the trend of the y-component of the magnetic field traveling on a tape of HTS (in orange).

In Matlab, I reproduced this trend, and the function for By is "waveform = A * sin(2pix/lambda - 2pift) + DC_offset" with A = 0.68 [T], f = 12 Hz, lambda = 42 mm, DC_offset = 0.68 [T], mu_0 = 1.2510^-6 [H/m].

I would like to reproduce this phenomenon in Comsol, so I defined a 2D geometry (shown in the image) that consists of a tape of 92 mm modeled as a line and an external square space defined as air; the shape of this space is not important. I need to use the magnetic field physics in Comsol. I tried applying this function directly as an external magnetic field on the tape, but Comsol does not allow it. So my question is: How can I define and where can I apply the "waveform" function, variable with space and time, which synthesizes By so that it directly affects the tape and therefore reproduces something similar reported in the video?

Thanks in advance for any advice.

Marianna



7 Replies Last Post 2024年1月25日 GMT+1 11:52
Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月24日 GMT+1 17:26

Hi Marianna,

I'm not sure what error that you got, but in principle, such a function should be possible to enter into a time-dependent simulation wheretis predefined as the time variable. You would enter it asA*sin(2*pi*x/lambda-2*pi*f*t)+DC_offset(where the constant values are defined as parameters). You can contact COMSOL Support if you want additional assistance.

Best regards,

Magnus

Hi Marianna, I'm not sure what error that you got, but in principle, such a function should be possible to enter into a time-dependent simulation where `t` is predefined as the time variable. You would enter it as `A*sin(2*pi*x/lambda-2*pi*f*t)+DC_offset` (where the constant values are defined as parameters). You can contact COMSOL Support if you want additional assistance. Best regards, Magnus

Marianna Di Pietrantonio

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月24日 GMT+1 17:59

Hi Magnus,

Can you confirm that the way I defined the Comsol waveform function takes into account both the spatial variable x and the temporal variable t?

The problem is that I can't apply this function, as a magnetic field, directly on the tape line. The external magnetic field condition in mf physics is only applicable at the boundary of the geometry but I need to impose in this trend of By on my line.

Thanks for your time.

Marianna

Hi Magnus, Can you confirm that the way I defined the Comsol waveform function takes into account both the spatial variable x and the temporal variable t? The problem is that I can't apply this function, as a magnetic field, directly on the tape line. The external magnetic field condition in mf physics is only applicable at the boundary of the geometry but I need to impose in this trend of By on my line. Thanks for your time. Marianna

Edgar J. Kaiser Certified Consultant

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月24日 GMT+1 18:25
Updated: 7 months ago 2024年1月24日 GMT+1 18:35

Hi Marianna,

this may be a case for a pointwise constraint: The constraint expression mf.By - yourFunction may do the trick.

Cheers Edgar

-------------------
Edgar J. Kaiser
emPhys Physical Technology
www.emphys.com
Hi Marianna, this may be a case for a pointwise constraint: The constraint expression mf.By - yourFunction may do the trick. Cheers Edgar

Marianna Di Pietrantonio

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月24日 GMT+1 18:39

Hi Edgar, first of all thank you very much! Sorry but I didn't understand exactly what you mean, can you give me more information?

Best, Marianna

Hi Edgar, first of all thank you very much! Sorry but I didn't understand exactly what you mean, can you give me more information? Best, Marianna

Edgar J. Kaiser Certified Consultant

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月24日 GMT+1 18:48

Here is a small model I used to test it. Look into the pointwise constraint. Here the expression is mf.By - 1, which forces a By component of 1 T on the line. Replace the '1' by your function and the space and time dependent values of the function should be forced on the line.

-------------------
Edgar J. Kaiser
emPhys Physical Technology
www.emphys.com
Here is a small model I used to test it. Look into the pointwise constraint. Here the expression is mf.By - 1, which forces a By component of 1 T on the line. Replace the '1' by your function and the space and time dependent values of the function should be forced on the line.


Marianna Di Pietrantonio

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月24日 GMT+1 18:59

Thanks so much Edgar this is just what I needed to complete my model! You have been very kind.

Best regards, Marianna

Thanks so much Edgar this is just what I needed to complete my model! You have been very kind. Best regards, Marianna

Edgar J. Kaiser Certified Consultant

Please login with a confirmed email address before reporting spam

Posted: 7 months ago 2024年1月25日 GMT+1 11:52

Thank you for the feedback. I am happy I could help.

-------------------
Edgar J. Kaiser
emPhys Physical Technology
www.emphys.com
Thank you for the feedback. I am happy I could help.

Note that while COMSOL employees may participate in the discussion forum, COMSOL®software users who are on-subscription should submit their questions via theSupport Centerfor a more comprehensive response from the Technical Support team.

Baidu
map