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.

## 3D waveguide, compute electromagnetic field

Posted Jul 11, 2010, 11:54 AM EDT RF & Microwave Engineering, Studies & Solvers Version 4.0a, Version 4.1 13 Replies

In solver sequences created automatically by COMSOL 4 there is two study step, the first is Boundary mode analysis, the second is Frequency domain.

Problem:

The first study step compute rightly the field at boundary of waveguide, the eigenvalue is almost the same of that in 2D model, the second study step doesn't finish, there is an error. First appears a window:

"The following feature has encountered a problem:

Feature: Stationary 1 (sol1/s1)

Error: Undefined value found."

In the tab Error 1 there is:

"Undefined value found.

- Detail: Undefined value found in the equation residual vector.

There are 1 degrees of freedom giving NaN/Inf in the vector for the variable mod1.emw.S1x

at coordinates: (0,0,0), ...

There are 1 degrees of freedom giving NaN/Inf in the vector for the variable mod1.emw.S2x

at coordinates: (0,0,0), ..."

Where is the problem? Is there another method to solve my (I think and hope) simple problem (view the electromagnetic field in the entire 3D structure)?

Thanks in advance.

And sorry for my bad English.

The boundary mode analysis is necessary (I think) for simulating the field in the waveguide, each port is a numeric type port then I have to add boundary mode analysis to know the field at boundary of the waveguide.

I hope that this information are useful for other users.

The problem is that I have to add two boundary mode analysis, one for each port. Then there are three study in the solver sequence node (two for boundary mode analysis and one for Frequency domain).

The boundary mode analysis is necessary (I think) for simulating the field in the waveguide, each port is a numeric type port then I have to add boundary mode analysis to know the field at boundary of the waveguide.

I hope that this information are useful for other users.

Hello Ciccio,

I having some trouble in putting a 3D model of a simple step-index fiber working... I tried adding the study 'Boundary Mode Analysis' and 'Frequency Domain', but I can't get it working. The only thing that appears after simulation is the following error:

" Undefined value found.

- Detail: Undefined value found in the equation residual vector.

There are 1 degrees of freedom giving NaN/Inf in the vector for the variable mod1.emw.S1x

at coordinates: (0,0,0), ... "

I really don't understand this error code... I was hoping you could help out with this problem. I would appreciate it.

Thank you for your time.

Best Regards,

Steven R. Carneiro

Assuming that fields are not blowing up inside, you apparently missed to set something up. It would be easier for people if you share your model file as well.

If you can, I would recommend you to have a look at "waveguide adapter" tutorial in model library. It is basically the same thing, launching an eigen mode in the waveguide.

All the best

Failed to evaluate variable.

- Variable: mod1.emw.tEmodez

- Geometry: 1

- Boundary: 10

Failed to evaluate variable.

- Variable: mod1.emw.Jsportz

- Defined as: ((mod1.tEz-(2*mod1.emw.tEmodez))/mod1.emw.etaRef)

Failed to evaluate expression.

- Expression: d((mod1.emw.iomega*mu0_const*(-mod1.emw.Jsportx*test(mod1.tEx)-mod1.emw.Jsporty*test(mod1.tEy)-mod1.emw.Jsportz*test(mod1.tEz)))*(dvol),{test@2})

Attachments:

I am having a similar problem in boundary mode analysis and frequency domain analysis in a 3D RF waveguide. Does any one know on how to resolve the following issues I am facing at the moment in Comsol 4.1-

1. When you add boundary mode analysis for two ports, they ask for desired number of modes and search for modes around. Well I know from 2D modal analysis, you can include any number of modes but how to include the search for mode around field as I am just looking for the fundamental mode (I know that you can include the mode index parameter where you are interested as in 2D mode solver but it gives an error in 3 D analysis).

2. Is it possible to solve for TM/TE fundamental mode via boundary mode analysis and then launch the mode at the input port.

Thanks

Roney

I’ve the same problem. Does anyone get the solutions? I’ve tried to look at "waveguide adapter" tutorial in model library , but it’s not help. There’re still errors. The errors are

" Undefined value found.

- Detail: Undefined value found in the equation residual vector.

There are 1 degrees of freedom giving NaN/Inf in the vector for the variable mod1.emw.S1x

at coordinates: (0,0,0), ... "

It would be a very helpful if anyone can help or get the solutions for these errors

Thank you in advance

In the branc study, you have to add two boundary mode analysis, and set correctly the field Port name.

To choose one particular mode in multimodal waveguide, you have to create two stuy, in one add two boundary mode analysis, in the second stydy add only a frequency domain. Create default solver in the second study and set in the dependent varibales the right parameter to choose the solution that you found out in the first stydy.

Sorry for my bad English

I have the same problem while I have done what you have said.

Could you please share your structure, which has solved? or send it to my email (ahaje092@uottawa.ca)

Thank you in advance,

Akram

I have the same problem.

Could you please send your structure to me if you have solved it?

my email:

ahaje092@uottawa.ca

Thank you in advance,

Akram

Hi Ciccio,

I have the same problem while I have done what you have said.

Could you please share your structure, which has solved? or send it to my email (ahaje092@uottawa.ca)

Thank you in advance,

Akram

Did you get the required file? I am really stuck into this problem.

Can you help me, please?

I don't know if COMSOL (in my case version 3.5a, for the 4.3 or something like that there is an example of a dielectric slab waveguide with 2 Boundary Mode Analysis) has problems with the fact that just one of the BMA can be the ruling application.

I set one port to excitation and the other not. But it gives me problems anyway

I had a similar problem. To do an S-parameter analysis with more than one port, you must use as many Boundary Mode Analysis as the ports. Go to the User's Guide of the RF module, pages 59-62.

You have to go to the Initial Value page of the Solver Manager and select current solution from the area "Variables not solved for ..."

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

- KNOWLEDGE BASE Should I use the RMS, the peak, or the instantaneous value to specify sources for electromagnetic fields?
- BLOG Guide to Frequency Domain Wave Electromagnetics Modeling
- FORUM how to compute electromagnetic force for the AC/DC electromagnet
- BLOG Quick Intro to Modeling RF and Microwave Heating
- FORUM Simulation of thermoelectric model (problem of compute)