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.

Access to function n_interp

Please login with a confirmed email address before reporting spam

Hi everyone

When I Add a new Material from the library (e.g. Pd or Cu), then I can see its real and refractive indexes, n and k respectively.

They function n which is a function of the wavelength is calculated automatically using a local table. The function is called n_interp for the real part.

Now when I want to use the refractive index in an expression (e.g. as an expression under "derived values") I don't know how to access this function.

I would like to write an expression like

n_interp_Pd(lambda) / n_interp_Cu(lambda)

But as the refractive index of Cu is calculated similarly and the interpolation function of Cu is also just called n_interp, I don't know how to access these two functions.

I solved the problem creating two interpolation functions under "global definitions" where I copied the local tables from Pd and from Cu and called them n_Cu and n_Pd. Now I can access these functions.

But I think this step is unnecessary since these functions are exact copies of already existing functions...

Does somebody know how to avoid this additional step?

Best regards

Gabriel

2 Replies Last Post Jul 11, 2017, 6:07 a.m. EDT

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Oct 21, 2016, 8:38 a.m. EDT
Aaah now I found it:

When you would insert an expression, just hit the + sign (insert expression) and go to

Model/Definitions/Material functions

There you find all the interpolation functions.
Aaah now I found it: When you would insert an expression, just hit the + sign (insert expression) and go to Model/Definitions/Material functions There you find all the interpolation functions.

Please login with a confirmed email address before reporting spam

Posted: 7 years ago Jul 11, 2017, 6:07 a.m. EDT
Updated: 7 years ago Jul 11, 2017, 6:07 a.m. EDT
Can you explain for me more detail about how we can access to function n_interp. Thank you !
Can you explain for me more detail about how we can access to function n_interp. Thank you !

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.