Note: This discussion is about an older version of the COMSOL Multiphysics® software. The information provided may be out of date.
Discussion Closed This 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.
frequency-dependent material - with coupled physics
Posted Nov 7, 2012, 3:06 a.m. EST RF & Microwave Engineering, Materials Version 4.3 6 Replies
Please login with a confirmed email address before reporting spam
In the RF module, I have two EMW physics (emw1, emw2) with user-defined frequencies, f1 and f2, which are fully coupled and solved simultaneously in the frequency domain. So for example, f1=1e14[Hz], f2=2e14[Hz], then emw1.freq=f1 and emw2.freq=f2.
I also define an analytic function for the relative permittivity dependent on frequency, epsr(fx), so epsr(emw1.freq) is not equal to epsr(emw2.freq).
I would like to define a new material, with the relative permittivity being "epsr(fx)". I would like fx, the input to epsr(), to be dependent on the current physics, i.e. the physics that's calling the material rather, as I have two.
One option for me would be to define the relative permittivity in the physics, overriding the material definition, by choosing Model->EMW1->Wave Equation->Electric Displacement Field->Relative permittivity and changing it from "From material" to "User defined", then defining it with my function, "epsr(f1)", and the same for EMW2 with "epsr(f2)". However, it seems intuitive that I should be able to go to the Model->Materials and in my material define the relative permittivity to be something like "epsr(activeemw.freq)" or in the essence of "epsr( if_being_called_from_emw1_then_emw1.f1, else if_being_called_from_emw2_then_emw2.f2 )".
Has anyone ever faced this problem?
Thanks
Please login with a confirmed email address before reporting spam
To my understanding, this means I must find the way to refer to the "currently active physics" in the material. Any suggestions?
Please login with a confirmed email address before reporting spam
I find it also strange if you observe 2 distinct e_r's, I wonder if it could come from some mixing of other parameters with two identical physics.
In such cases I sometimes define my material parameters locally, under the physics, to be sure I know which one is used where, but so far I have not encountered your issue there.
When nothing else works you have "support" too that could help, as they are really the only ones knowing what is going on "under the hood ;)
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
The set-up you described can be done in Comsol, but you must be careful in picking the right frequency.
I'll start from the beginning: I assume you have selected Equation Form: Frequency Domain and Frequency: User Defined in the Electromagnetic Waves physics nodes, since that is the only way you can solve two coupled physics with two different frequencies. In this case you have:
- a global variable freq, defined by the solver, containing the frequency you wrote in the solver.
- two global variables emw.freq and emw2.freq with the user-defined frequencies, different from each other and (potentially) from freq.
To create a material that can be applied to both physics and use the correct frequency, you need to use model inputs. Model inputs are physical quantities that a material can use as input for its functions, and are automatically matched to the context where the material is used. Practical instructions:
- Create a material in the Materials node and apply it to the domains.
- Go in the Basic subnode of the material. This contains all the material properties definitions.
- From the Output Properties list, select the properties you want to specify ("Relative permittivity" in your case), then press the plus button. They will be added to the table.
- From the Model Inputs list, select Frequency, and click plus. It will be added to the second table, with variable name "freq". Note that this "freq" has nothing to do with the global variable freq I discussed before, this is just a local variable that you can use in the expressions in this material node.
- In the first table, write an expression for epsilonr using freq (I guess "epsr(freq)" in your case).
- Last, go in each physics' Wave Equation feature, expand the Model Inputs section and check that the frequency used is taken from the equation form (it should say something like "Frequency (emw/EquationForm)" and "Frequency (emw2/EquationForm)" ).
What just happened is this: each Wave Equation required a material property (epsilonr) from the material. The material notified back the Wave Equation features that a model input "frequency" is necessary, and the most appropriate frequency was picked from the context, i.e. the one specified in the respective parent nodes.
At first this Model Input machinery might seem complex, but the idea is pretty simple and very flexible: choose the input physical quantity in the material, and the features will pick the best one from the context.
--
Andrea Ferrario
Electromagnetics Group
COMSOL AB
Please login with a confirmed email address before reporting spam
Thanks for the prompt reply. Your solution worked wonderfully!
Roy
Please login with a confirmed email address before reporting spam
Learned someting too ;)
--
Haveing fun Comsoling
Ivar
Please login with a confirmed email address before reporting spam
Hi Roy,
The set-up you described can be done in Comsol, but you must be careful in picking the right frequency.
I'll start from the beginning: I assume you have selected Equation Form: Frequency Domain and Frequency: User Defined in the Electromagnetic Waves physics nodes, since that is the only way you can solve two coupled physics with two different frequencies. In this case you have:
- a global variable freq, defined by the solver, containing the frequency you wrote in the solver.
- two global variables emw.freq and emw2.freq with the user-defined frequencies, different from each other and (potentially) from freq.
To create a material that can be applied to both physics and use the correct frequency, you need to use model inputs. Model inputs are physical quantities that a material can use as input for its functions, and are automatically matched to the context where the material is used. Practical instructions:
- Create a material in the Materials node and apply it to the domains.
- Go in the Basic subnode of the material. This contains all the material properties definitions.
- From the Output Properties list, select the properties you want to specify ("Relative permittivity" in your case), then press the plus button. They will be added to the table.
- From the Model Inputs list, select Frequency, and click plus. It will be added to the second table, with variable name "freq". Note that this "freq" has nothing to do with the global variable freq I discussed before, this is just a local variable that you can use in the expressions in this material node.
- In the first table, write an expression for epsilonr using freq (I guess "epsr(freq)" in your case).
- Last, go in each physics' Wave Equation feature, expand the Model Inputs section and check that the frequency used is taken from the equation form (it should say something like "Frequency (emw/EquationForm)" and "Frequency (emw2/EquationForm)" ).
What just happened is this: each Wave Equation required a material property (epsilonr) from the material. The material notified back the Wave Equation features that a model input "frequency" is necessary, and the most appropriate frequency was picked from the context, i.e. the one specified in the respective parent nodes.
At first this Model Input machinery might seem complex, but the idea is pretty simple and very flexible: choose the input physical quantity in the material, and the features will pick the best one from the context.
--
Andrea Ferrario
Electromagnetics Group
COMSOL AB
Hi
I am struggling with similar problem. I have a .dat file which contains three column.col 1 is for frequency col 2 is for epsilon_single prime and col 3 is for epsilon_double prime....
1)how can i assign col 1 as frequency variable in comsol?
2)how can i assign col 2 and col 3 as the input of complex permittivity in a material's permittivity parameter as (epsilon_prime-j*epsilon_double prime)
Thanks in advance.
Saimoom
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- FORUM How to change geometry from one physics to another in coupled physics
- FORUM External Material Model COUPLED with other physics
- KNOWLEDGE BASE Understanding the Fully Coupled vs. Segregated approach and Direct vs. Iterative Linear Solvers
- BLOG Which Study Type Should I Use for My Electrothermal Analysis?
- FORUM Coupled Physics