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.

Some problems of Bandgap Analysis of Photonic Crystal (ver 3.5)

Please login with a confirmed email address before reporting spam

Hello All,

I am trying to run the built-in model of Bandgap Analysis in ver 3.5. But I got some problem:

Error: 6170
Failed to evaluate variable.
- Variable: lambda
- Global scope
Failed to evaluate expression.
- Expression: imag(lambda)
Failed to evaluate expression.
- Expression: -imag(lambda)/(2*pi)

Am I supposed to give some initial value of lambda somewhere?

By the way, way the ver4.0 does not provide this model? Does it still support this calculation for 4.0?

Thank you!!
Xing

7 Replies Last Post Apr 24, 2013, 3:37 a.m. EDT
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 Dec 13, 2010, 4:30 p.m. EST
Hi

normally "lambda" is defined by COMSOL when you do an eigvenvalue or eigenfrequency solveing, except if you have redefined it yourself, in which case there might be a variable naming conflict

I believe the bandgp example appears again in 4.1

--
Good luck
Ivar
Hi normally "lambda" is defined by COMSOL when you do an eigvenvalue or eigenfrequency solveing, except if you have redefined it yourself, in which case there might be a variable naming conflict I believe the bandgp example appears again in 4.1 -- Good luck Ivar

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Dec 13, 2010, 5:24 p.m. EST
Dear Ivar,

Many thanks for your rapid reply!!
I agree that lambda itself is an unknown and should be determined in eigenvalue or eigenfrequency solvers. However, when I run the example, comsol immediately tells me the failure of lambda evaluation. I think there might be some problems there, because I just simply open it and run without revising anything.

Can you tell me how should i do regarding this example model or kindly check if there is any problem in this model?

I also install 4.0a and 4.1, but i did not obtain a similar example model in these two versions. Do you have any updated one?

I very appreciate your help!!!!!!!!


Best,

Xing
Dear Ivar, Many thanks for your rapid reply!! I agree that lambda itself is an unknown and should be determined in eigenvalue or eigenfrequency solvers. However, when I run the example, comsol immediately tells me the failure of lambda evaluation. I think there might be some problems there, because I just simply open it and run without revising anything. Can you tell me how should i do regarding this example model or kindly check if there is any problem in this model? I also install 4.0a and 4.1, but i did not obtain a similar example model in these two versions. Do you have any updated one? I very appreciate your help!!!!!!!! Best, Xing

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 Dec 14, 2010, 2:54 a.m. EST
Hi

no I have nothing more than the latest patch for 4.1 from the Comsol site, I know they are working hard to update and verify all models and that with the major v4 changes in the soft they need still some months to get all models back ;)

--
Good luck
Ivar
Hi no I have nothing more than the latest patch for 4.1 from the Comsol site, I know they are working hard to update and verify all models and that with the major v4 changes in the soft they need still some months to get all models back ;) -- Good luck Ivar

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Dec 14, 2010, 10:36 a.m. EST
Dear Ivar,

I very appreciate your reply, especially your response regarding the examples in the new versions!!

But, can you provide me more advise for the error code:

Error: 6170
Failed to evaluate variable.
- Variable: lambda
- Global scope
Failed to evaluate expression.
- Expression: imag(lambda)
Failed to evaluate expression.
- Expression: -imag(lambda)/(2*pi)

It seems that comsol encounters some problem with evaluating lambda. How can I do to fix this problem??

Thank you!!

Best,

Xing
Dear Ivar, I very appreciate your reply, especially your response regarding the examples in the new versions!! But, can you provide me more advise for the error code: Error: 6170 Failed to evaluate variable. - Variable: lambda - Global scope Failed to evaluate expression. - Expression: imag(lambda) Failed to evaluate expression. - Expression: -imag(lambda)/(2*pi) It seems that comsol encounters some problem with evaluating lambda. How can I do to fix this problem?? Thank you!! Best, Xing

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Dec 14, 2010, 11:04 a.m. EST
The model works perfectly fine, just that you need to follow it through the complete sequence mentioned in tutorial.

It won't work, however, if you just open it from model library and click compute button. The reason being that it needs initial field distribution and frequency value out of eigen frequency analysis to proceed with parametric solver. Once the result of parametric solver is computed, initial values of eigen frequency analysis are no longer available. Hence you get that error message.

Hope this helps.
The model works perfectly fine, just that you need to follow it through the complete sequence mentioned in tutorial. It won't work, however, if you just open it from model library and click compute button. The reason being that it needs initial field distribution and frequency value out of eigen frequency analysis to proceed with parametric solver. Once the result of parametric solver is computed, initial values of eigen frequency analysis are no longer available. Hence you get that error message. Hope this helps.

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Dec 14, 2010, 3:31 p.m. EST
Dear All,

Thank you very much for all of your help!!

I eventually figure it out!! Shakeeb is right, once you obtained the results, you cannot run it. So, in the example model, we cannot execute directly, since the results have been there. But, if you click "Re-do," everything goes well!!

Thank you!!

Best,

Xing
Dear All, Thank you very much for all of your help!! I eventually figure it out!! Shakeeb is right, once you obtained the results, you cannot run it. So, in the example model, we cannot execute directly, since the results have been there. But, if you click "Re-do," everything goes well!! Thank you!! Best, Xing

Radwanul Hasan Siddique

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Apr 24, 2013, 3:37 a.m. EDT
Hello guys,

I want to calculate the photonic bandgap of 1D or 2D PhC. Does anyone has any model or example for this kind of problem?

I really do appreciate your help.

Thank you in advance.
Hello guys, I want to calculate the photonic bandgap of 1D or 2D PhC. Does anyone has any model or example for this kind of problem? I really do appreciate your help. Thank you in advance.

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.