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.

Undefined value found in the equation residual vector

Please login with a confirmed email address before reporting spam

Hi

I am trying to simulate a simple nanometal pair structure but I am unexpectedly getting the following error mainly at the coordinates near the pml layers

-------------------------------------------------------
Undefined value found in the equation residual vector.
There are 1360 degrees of freedom giving NaN/Inf in the vector for the variable mod1.relE10
-------------------------------------------------------

Apparently 'NaN/Inf' is due to working with very large numbers but I dont know how to fix them. The problem for this instability is not linked to the mesh size which I have tried to correct using different mesh sizes. Also I increased the PML thickness but it didnt work.

I have attached my mph file. Can anyone help please.

Amin

2 Replies Last Post 22 janv. 2011, 08:21 UTC−5
Ivar KJELBERG COMSOL Multiphysics(r) fan, retired, former "Senior Expert" at CSEM SA (CH)

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago 22 janv. 2011, 07:55 UTC−5
Hi

first (but it's probably not your true issue) how do you expect your field lines to be square or round (at infinity) ?

It's often easier (also for COMSOL) to use a round infinite element/ PML region and declare it cylindrical /spherical, and next, as IMPORTANT to place the origine at the centre of the figure. Because when you get it to converge, you will see modes patterns that I do not expect are truely physical for an infinite space

Then if I take your model in my 4.1, and reset it delete the solver and rerun it it works OK, for me the conclusion is find out with your rep how to update to v4.1 and apply latest patch.

Then I defined a Parameter
lamb=c_cont/4E14[Hz]

whcih is the wavelength, and I defined a variable

MeshPerLambda = lambda/h

and made a plot of my new variable. there I see that the mesh density is at least 27 elements per wavelength, which is fine enough with a good security factor, as you should have, in my view, at least 5 elements per wavelength perdiode.

--
Good luck
Ivar
Hi first (but it's probably not your true issue) how do you expect your field lines to be square or round (at infinity) ? It's often easier (also for COMSOL) to use a round infinite element/ PML region and declare it cylindrical /spherical, and next, as IMPORTANT to place the origine at the centre of the figure. Because when you get it to converge, you will see modes patterns that I do not expect are truely physical for an infinite space Then if I take your model in my 4.1, and reset it delete the solver and rerun it it works OK, for me the conclusion is find out with your rep how to update to v4.1 and apply latest patch. Then I defined a Parameter lamb=c_cont/4E14[Hz] whcih is the wavelength, and I defined a variable MeshPerLambda = lambda/h and made a plot of my new variable. there I see that the mesh density is at least 27 elements per wavelength, which is fine enough with a good security factor, as you should have, in my view, at least 5 elements per wavelength perdiode. -- Good luck Ivar


Please login with a confirmed email address before reporting spam

Posted: 1 decade ago 22 janv. 2011, 08:21 UTC−5
Thanks,
Thanks,

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.