The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Fitting multiple Voigt lines
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

andrew.o.wright@thermofis

5 Posts

Posted - 10/06/2010 :  2:55:32 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
I have a spectrum with 4 overlapped Voigt lines. I don't trust the multiple peak fit feature because I find it generates non-correct parameters, even if the resulting fit curve otherwise looks okay. I can't get in and tweak or fix parameters independently to refit.

On the other hand, I am having trouble generating a User-defined multiple Voigt routine because I don't know how to handle the "t" variable in the integral.

Any suggestions would be appreciated.

larry_lan

China
Posts

Posted - 10/07/2010 :  11:02:15 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
quote:
I have a spectrum with 4 overlapped Voigt lines. I don't trust the multiple peak fit feature because I find it generates non-correct parameters, even if the resulting fit curve otherwise looks okay.


I happens when the fitting model is complicated, or the function is over-parameterized. To overcome it, you can:

1. Fix one or several parameters on Parameters tab.

2. Tweak the chi-square tolerance on Settings tab, Advance page, Fit Control branch

quote:
I can't get in and tweak or fix parameters independently to refit.


Please give more detail on what you did and what you saw.

quote:
On the other hand, I am having trouble generating a User-defined multiple Voigt routine because I don't know how to handle the "t" variable in the integral.


Voigt is a special fitting function because it include integration in the function body, so, you cannot simply duplicate and then modify it. If you want to call this function, you can use the nlf_FunName() notation. For example, you can define a "two voigo peak" function like:

Independent Variables: x
Dependent Variables: y
Parameter Names: y0, xc1, A1, wG1, wL1, xc2, A2, wG2, wL2
Function Body: y = nlf_voigt(x, y0, xc1, A1, wG1, wL1) + nlf_voigt(x, y0, xc2, A2, wG2, wL2);


Hope that helps.

Thanks
Larry
OriginLab Technical Services

Edited by - larry_lan on 10/07/2010 11:03:23 PM
Go to Top of Page

andrew.o.wright@thermofis

5 Posts

Posted - 10/12/2010 :  08:35:42 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello Larry,

Thanks for the help.

I have tried to attach a screen image JPEG showing the multiple peak fitting dialog, where I can't find or tweak the fitting parameters, but the file size is 250 kB which is too big.

Per your suggestion, I wrote up the following function:
y = nlf_Voigt(x, y0, xc1, wL1, wG1, A1)+nlf_Voigt(x, y0, xc2, wL2, wG2, A2)+nlf_Voigt(x, y0, xc3, wL3, wG3, A3)
+nlf_Voigt(x, y0, xc4, wL4, wG4, A4)

It compiles okay, but the evaluate feature generates a message "y = -- (y0 = -- invalid)" that I don't know the meaning for. Also, I find I cannot enter bounds or linear constraints, which are important as I am generating negative numbers in the fit for wL and wG terms which have no physical meaning. When I click on the appropriate boxes (single left click, double left click, right click), there is no response.

Btw, the dataset I am fitting has 1500 points. Peak FWHM are 30 to 40 points.
Go to Top of Page

easwar

USA
1964 Posts

Posted - 10/12/2010 :  09:36:02 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Andrew,

The Multiple Peak Fitting dialog is a simplified dialog that does not offer any controls on parameters etc. It was intended for quickly fitting peak data.

You should instead use the NLFit dialog accessible from the Analysis->Fitting->Nonlinear Curve Fit menu item. Then in that dialog you can set the number of replicas in the Advanced section. Once you do that Origin will try auto detect your peaks, but you can then also further control the parameter values and bounds etc using the Parameters tab.

If you have OriginPro you can also fit your multi-peak data with the Peak Analyzer, and that has options to remove or fit baseline along with fitting peaks.

For your need of just fitting multiple voigt peaks you should not be making a new function by repeating the function call, this would just be slower and less efficient, so instead use one of the methods from above.

If you need further help please send your data/opj to tech support.

Easwar
OriginLab
Go to Top of Page

andrew.o.wright@thermofis

5 Posts

Posted - 10/13/2010 :  10:00:09 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thank you, Easwar.
Go to Top of Page

nanak

4 Posts

Posted - 04/07/2014 :  04:59:16 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Easwar,
I am mailing this with a problem relevant to this link: I am trying to fit two Voigt functions using the NLcurve fit option. However, I can choose only one Voigt - the Replica option in the Advanced section is not active. Any help in this regard is appreciated. I have OriginPro 8 SRO and Origin 6.1.

Thanks

Nanak
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000