franko / regress-pro

Spectroscopic Ellipsometry and Reflectometry data analysis
http://franko.github.io/regress-pro/
GNU Lesser General Public License v2.1
21 stars 6 forks source link

wrong formula for epsilon_r in disp-tauc-lorentz.c #5

Open urbachjp opened 4 years ago

urbachjp commented 4 years ago

deleted

franko commented 4 years ago

Hi,

I see you have deleted your comment but just in case, I think the formula in my implementation include the correction. In this page you may found the formula I have used:

https://franko.github.io/regress-pro/models.html#tauc-lorentz-model

In addition, in the "dev" branch I compute the Tauc Lorentz dispersion and its Jacobian using C++ code generate by sympy. The sympy code for the Tauc Lorentz is there:

https://github.com/franko/regress-pro/blob/dev/doc/tauc_lorentz.py

urbachjp commented 4 years ago

Hello Francesco,

thanks for the feedback and the additional information.

I was somewhat too fast with my comment because I was referring to the formula as given by Horiba for eps_r (https://www.horiba.com/fileadmin/uploads/Scientific/Downloads/OpticalSchool_CN/TN/ellipsometer/Tauc-Lorentz_Dispersion_Formula.pdf).

I realized a little bit later that yes indeed your implementation is correct as it is identical to the erratum of the Jellison&Modine paper.

If you don’t mind I have (for the moment) two questions:

1) I do not understand how I can fit multiple spectra of the same sample e.g. taken under different incident angles in spectrocopic ellipsometry. To me it seems that even when loading multiple spectra (via Edit -> Dataset) the fit will only consider the spectra loaded via Spectra –-> Load Spectra

2) If I have a Bruggeman EMA model with 2 components both described by a Tauc-Lorentz model, is it possible to fit also some of the TL parameters of one component in addition to the fraction. My problem is, that I do have measurment data for only one of the two components of the mixture

Best regards

JP


Dr. Jan-Peter Urbach

PLASUS GmbH

Lechstraße 9 D-86415 Mering Germany

Tel.: +49 (0)8233 73 53 78-0

Fax: +49 (0)8233 73 53 78-9

E-Mail: mailto:urbach@plasus.de urbach@plasus.de Internet: http://www.plasus.de/ www.plasus.de


PLASUS GmbH Amtsgericht Augsburg HRB 29314

Geschäftsführer: Dr.-Ing. Thomas Schütte

VAT-No.: DE 815 541 716

Von: Francesco [mailto:notifications@github.com] Gesendet: Dienstag, 8. September 2020 21:20 An: franko/regress-pro regress-pro@noreply.github.com Cc: urbachjp urbach@plasus.de; Author author@noreply.github.com Betreff: Re: [franko/regress-pro] wrong formula for epsilon_r in disp-tauc-lorentz.c (#5)

Hi,

I see you have deleted your comment but just in case, I think the formula in my implementation include the correction. In this page you may found the formula I have used:

https://franko.github.io/regress-pro/models.html#tauc-lorentz-model

In addition, in the "dev" branch I compute the Tauc Lorentz dispersion and its Jacobian using C++ code generate by sympy. The sympy code for the Tauc Lorentz is there:

https://github.com/franko/regress-pro/blob/dev/doc/tauc_lorentz.py

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/franko/regress-pro/issues/5#issuecomment-689084159 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AQ5JTYBXDGHZNVGQINMRKGDSEZ7XFANCNFSM4Q72DNPA .

franko commented 4 years ago

1) I do not understand how I can fit multiple spectra of the same sample e.g. taken under different incident angles in spectrocopic ellipsometry. To me it seems that even when loading multiple spectra (via Edit -> Dataset) the fit will only consider the spectra loaded via Spectra –-> Load Spectra

Well, the fit of multiple spectra at once is not documented and a little bit more difficult to use. Basically you need to create a special recipe by checking "Enable multi-sample" and you work by defining a table with you datasets, a list of spectra with some optional known values. Then you can run the recipe but it doesn't work in interactive mode. In the multi-sample recipe you have two lists of fitting parameters, those that are linked to that same value for all the spectra (common parameters) and those that can have different values for each sample. By using the dataset table you can also impose different fixed values for each of the spectra.

2) If I have a Bruggeman EMA model with 2 components both described by a Tauc-Lorentz model, is it possible to fit also some of the TL parameters of one component in addition to the fraction. My problem is, that I do have measurment data for only one of the two components of the mixture

That would be nice to have but this feature is not implemented in Regress Pro.

urbachjp commented 4 years ago

Thanks for your explanation regarding the multi-fit feature.

I tried to run the recipe „Oxide Nit Multi Sample Optimization.rcp“ from the exampe/multifit directory of RegressPro, as it seems to me that this an application of the multi-fit approach.

After loading the recipe, I try to start the fit via Fitting -> Run Multiple fit, however I get the error message

And the below copied output in the Fit Output window.

What am I doing wrong?

Best regards

Jan-Peter

output in the Fit Output window:

COMMON / Nosc:0 : 74

COMMON / En:0 : 8

COMMON / Eg:0 : 0.4

COMMON / Phi:0 : 0

SAMPLE(00)/ T1 : 4220

SAMPLE(00)/ T2 : 890

SAMPLE(01)/ T1 : 2910

SAMPLE(01)/ T2 : 890

SAMPLE(02)/ T1 : 3530

SAMPLE(02)/ T2 : 890

SAMPLE(03)/ T1 : 3280

SAMPLE(03)/ T2 : 890

SAMPLE(04)/ T1 : 2500

SAMPLE(04)/ T2 : 890

Residual Chi Square by sample:

ChiSq(00): 898.727

ChiSq(01): 2188.16

ChiSq(02): 2312.47

ChiSq(03): 1779.42

ChiSq(04): 1483.18

Seed used: 74.00000 8.00000 0.40000 0.00000 4220.00000 890.00000 2910.00000 890.00000 3530.00000 890.00000 3280.00000 890.00000 2500.00000 890.00000

Nb of iterations to converge: 1


Dr. Jan-Peter Urbach

PLASUS GmbH

Lechstraße 9 D-86415 Mering Germany

Tel.: +49 (0)8233 73 53 78-0

Fax: +49 (0)8233 73 53 78-9

E-Mail: mailto:urbach@plasus.de urbach@plasus.de Internet: http://www.plasus.de/ www.plasus.de


PLASUS GmbH Amtsgericht Augsburg HRB 29314

Geschäftsführer: Dr.-Ing. Thomas Schütte

VAT-No.: DE 815 541 716

Von: Francesco [mailto:notifications@github.com] Gesendet: Mittwoch, 9. September 2020 19:32 An: franko/regress-pro regress-pro@noreply.github.com Cc: urbachjp urbach@plasus.de; Author author@noreply.github.com Betreff: Re: [franko/regress-pro] wrong formula for epsilon_r in disp-tauc-lorentz.c (#5)

  1. I do not understand how I can fit multiple spectra of the same sample e.g. taken under different incident angles in spectrocopic ellipsometry. To me it seems that even when loading multiple spectra (via Edit -> Dataset) the fit will only consider the spectra loaded via Spectra –-> Load Spectra

Well, the fit of multiple spectra at once is not documented and a little bit more difficult to use. Basically you need to create a special recipe by checking "Enable multi-sample" and you work by defining a table with you datasets, a list of spectra with some optional known values. Then you can run the recipe but it doesn't work in interactive mode. In the multi-sample recipe you have two lists of fitting parameters, those that are linked to that same value for all the spectra (common parameters) and those that can have different values for each sample. By using the dataset table you can also impose different fixed values for each of the spectra.

  1. If I have a Bruggeman EMA model with 2 components both described by a Tauc-Lorentz model, is it possible to fit also some of the TL parameters of one component in addition to the fraction. My problem is, that I do have measurment data for only one of the two components of the mixture

That would be nice to have but this feature is not implemented in Regress Pro.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/franko/regress-pro/issues/5#issuecomment-689710423 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AQ5JTYH7YU5ZEMQGGP7TNB3SE63XNANCNFSM4Q72DNPA .

franko commented 4 years ago

Sorry the multi-fit is buggy in some of the later release. Yet you should be able to make it work by:

The run Fit -> "Run Multiple Fit"

urbachjp commented 4 years ago

Hello Francesco,

thanks for your support. I was able to get the multifit feature running in the v2.0.2.

Regards

Jan-PEter


Dr. Jan-Peter Urbach

PLASUS GmbH

Lechstraße 9 D-86415 Mering Germany

Tel.: +49 (0)8233 73 53 78-0

Fax: +49 (0)8233 73 53 78-9

E-Mail: mailto:urbach@plasus.de urbach@plasus.de Internet: http://www.plasus.de/ www.plasus.de


PLASUS GmbH Amtsgericht Augsburg HRB 29314

Geschäftsführer: Dr.-Ing. Thomas Schütte

VAT-No.: DE 815 541 716

Von: Francesco [mailto:notifications@github.com] Gesendet: Freitag, 11. September 2020 23:10 An: franko/regress-pro regress-pro@noreply.github.com Cc: urbachjp urbach@plasus.de; Author author@noreply.github.com Betreff: Re: [franko/regress-pro] wrong formula for epsilon_r in disp-tauc-lorentz.c (#5)

Sorry the multi-fit is buggy in some of the later release. Yet you should be able to make it work by:

The run Fit -> "Run Multiple Fit"

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/franko/regress-pro/issues/5#issuecomment-691313273 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AQ5JTYBBWLIVFIAZRBPFP33SFKG2VANCNFSM4Q72DNPA . https://github.com/notifications/beacon/AQ5JTYFXH2GW4Z5SJPF7HSDSFKG2VA5CNFSM4Q72DNPKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOFE2JU6I.gif

franko commented 4 years ago

If you are using Regress Pro for some real applications I may provide some support to fix some bugs or develop some new features you may need.

Otherwise I no longer actively develop Regress Pro because I am no longer in the field of thin film metrology.

ZheruQiu commented 4 years ago

If you are using Regress Pro for some real applications I may provide some support to fix some bugs or develop some new features you may need.

Otherwise I no longer actively develop Regress Pro because I am no longer in the field of thin film metrology.

Thank you very much for developing this software and I found it useful for my research. I wonder is it possible to add the feature of fitting for parameters of individual components in the Bruggeman model? It looks like you are using a quite complex ODE based method to iteratively compute the mixture epsilon of more than 2 materials. I'm not an expert in the field of thin film metrics, I can't really understand it (without references), but I can imagine that it can be difficult to compute the Jacobian. However, implementing the 2 component problem with closed form solution can be already very helpful for me. By the way, do you think it's a good idea to introduce a depolarization coefficient like in some commercial software? (like https://www.lugosi.info.hu/wp-content/uploads/2018/11/SEA_Users_Reference_Manual.pdf , page 71) Besides, I hope you can add the support for import of semilab ellipsometers. I attached an example (the proper file extension is .pae) and I think it can be quite straightforward to implement with a slight adaption of load_vase_spectrum sopraexample.pae.txt

franko commented 4 years ago

For the ODE method I am using for the Bruggeman model here some explications I published on the web:

https://gsl-shell.blogspot.com/2016/09/compute-dielectrict-constant-for.html

The real problem was not computing the Jacobian but the determination of the actual solution of the Bruggeman equation. Once the solution is found the Jacobian is simple to compute. An alternative approach could have been to use a complex coefficients polynomial solver.

The feature of fitting the parameter of individual Bruggeman component is feasible I think without any big difficulty but it needs a non trivial amount of work to be integrated in the software.

As for the depolarization coefficient I didn't know that it had a use in the Bruggeman model. In general Regress Pro don't implement depolarization but I know it is useful in some cases.

I will see to implement the loading of the data from semilab ellipsometers but I cannot give a commitment.

Otherwise I am interest to have a little bit more context about your requests. The Semilab software seems to be good, why you don't just use the software they provides ? You are working in the industry or are you doing academic research ?

ZheruQiu commented 4 years ago

For the ODE method I am using for the Bruggeman model here some explications I published on the web:

https://gsl-shell.blogspot.com/2016/09/compute-dielectrict-constant-for.html

The real problem was not computing the Jacobian but the determination of the actual solution of the Bruggeman equation. Once the solution is found the Jacobian is simple to compute. An alternative approach could have been to use a complex coefficients polynomial solver.

The feature of fitting the parameter of individual Bruggeman component is feasible I think without any big difficulty but it needs a non trivial amount of work to be integrated in the software.

Thank you very much for the fast reply and pointing me to the explanation of your quite elegant solution. Now I understand the story with it.

For other people arrived here in the future, here are some more references: [1] Vadim A. Markel, "Introduction to the Maxwell Garnett approximation: tutorial," J. Opt. Soc. Am. A 33, 1244-1256 (2016) [2] Roger Jansson, Hans Arwin,"Selection of the physically correct solution in the n-media Bruggeman effective medium approximation", Optics Communications, Volume 106, Issues 4–6, 1994,

It looks like your code can already support variable number of fit parameters, like for HO model. From my naive understanding, we can just wrap the inner fit variables in the disp-bruggeman as we are keeping the reference to the bema_component s, we can dynamically gather the list of all inner variables and combine them when requested, calculate the solution and Jacobian for all the variables with chain rule. I wonder what's the obstacle to integrate it to the software?

As for the depolarization coefficient I didn't know that it had a use in the Bruggeman model. In general Regress Pro don't implement depolarization but I know it is useful in some cases.

I will see to implement the loading of the data from semilab ellipsometers but I cannot give a commitment.

Otherwise I am interest to have a little bit more context about your requests. The Semilab software seems to be good, why you don't just use the software they provides ? You are working in the industry or are you doing academic research ?

I'm doing academic research, but the problem with the Semilab software is

  1. It's locked to the computer in the cleanroom with a Superpro hardware dongle (which I can easily bypass but I want to remain legal), for some personal reason I don't feel comfortable for staying there for too long time.
  2. Just prefer to do my research with FOSS (at least vendor neutral) tools.
  3. It's getting old and they abandoned it and/or our facility no longer have access to updates since 2013.

BTW: if I want to fork, which branch should I start with? Can the dev branch produce a working build? (better if on Windows)

franko commented 4 years ago

Thank you very much for the fast reply and pointing me to the explanation of your quite elegant solution. Now I understand the story with it.

For other people arrived here in the future, here are some more references: [1] Vadim A. Markel, "Introduction to the Maxwell Garnett approximation: tutorial," J. Opt. Soc. Am. A 33, 1244-1256 (2016) [2] Roger Jansson, Hans Arwin,"Selection of the physically correct solution in the n-media Bruggeman effective medium approximation", Optics Communications, Volume 106, Issues 4–6, 1994,

Cool, thank you for the references, I all have a look to [2] maybe, sounds they solved the same problem I had.

It looks like your code can already support variable number of fit parameters, like for HO model. From my naive understanding, we can just wrap the inner fit variables in the disp-bruggeman as we are keeping the reference to the bema_component s, we can dynamically gather the list of all inner variables and combine them when requested, calculate the solution and Jacobian for all the variables with chain rule. I wonder what's the obstacle to integrate it to the software?

You are right in your analysis and there are no obstacles, it just needs some work to be implemented. For the Bruggeman you can keep the fractions are the first parameters then add in order the parameters of each components.

I'm doing academic research, but the problem with the Semilab software is

1. It's locked to the computer in the cleanroom with a Superpro hardware dongle (which I can easily bypass but I want to remain legal), for some personal reason I don't feel comfortable for staying there for too long time.

2. Just prefer to do my research with FOSS (at least vendor neutral) tools.

3. It's getting old and they abandoned it and/or our facility no longer have access to updates since 2013.

Nice to hear. I too, I strongly dislike locked down proprietary softwares. In many case they could publish them as free software without suffering any business loss but their views are too restricted to understand.

BTW: if I want to fork, which branch should I start with? Can the dev branch produce a working build? (better if on Windows)

If you want to work on Regress Pro that's really cool and I will be probably able to help you. The branch you should use is definitely "dev". The only gotcha is that in this branch the multi-sample fitting has a few bugs but it shouldn't be a real problem and it can be fixed. The "dev" branch works and compiles on both Linux and Windows.