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
 Fast Method for fast multiple fit?
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

FloTor

29 Posts

Posted - 11/29/2012 :  12:04:40 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. and Service Release (Select Help-->About Origin): 8.6.0 64bit
Operating System: Win7

I have several data sets containing extremly similar peaks (carrier and two sidebands). I want to fit lorentzians to all of them and finally I need a list wich contains the distance between the two sidebands with fitting errors.
What is the fastest way to achive this?

Thank you very much!

Hideo Fujii

USA
1582 Posts

Posted - 11/29/2012 :  2:39:48 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi FloTor,

> I have several data sets containing extremly similar peaks (carrier and two sidebands).

My understanding is that each your data set contains three Lorentzian peaks, and these peaks
have very similar positions across data sets, right?

> I need a list wich contains the distance between the two sidebands with fitting errors.

If above holds, one possible way is to define a user-defined function which contains
three Lorentzian terms e.g.,:

y=y0+nlf_lorentz(x,0,xc1,w1,A1)+nlf_lorentz(x,0,xc2,w2,A2)+nlf_lorentz(x,0,xc3,w3,A3)

where you can give specific positions (xc1,2,3) and areas(A1,2,3) as initial values.
You can define a derived parameter such as:

dist=xc3-xc1

for the distance between peak1 and peak3.
Furthermore, you may also want to put effective constraints e.g. to force the peaks separated.

xc2-xc1>3;
xc3-xc2>3;



Here, you can get the derived parameter dist's estimation and the error in the report sheet.

Once you make sure that this fitting function works okay, you can asve the NLFit settings
as a dialog theme (you probably want to save the parameter values and constraints by
selecting "Theme Settings" flyout before saving the theme.)
For the new data set, you can just run NLFit applying this theme to perform.

Hope this is your case.

--Hideo Fujii
OriginLab

Edited by - Hideo Fujii on 11/29/2012 3:06:23 PM
Go to Top of Page

easwar

USA
1964 Posts

Posted - 11/30/2012 :  2:09:08 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi FloTor,

If your data has no baseline (or constant baseline), you can simply use the Replica feature in NLFit to fit multiple peaks to a given dataset:
http://www.originlab.com/www/helponline/Origin/en/UserGuide/Fitting_Multiple_Peaks_with_Replicas.html

If you have a baseline that needs correction, then you need the Peak analyzer to fit multiple peaks along with baseline, and this feature is available in OriginPro
http://www.originlab.com/www/helponline/Origin/en/Category/Peak_Analyzer.html

In either case, once you perform the fit to one dataset, you can do the following:
1> Add another sheet to your workbook and copy the peak position, error etc values from the report sheet table, and then paste-link these values into the new sheet - thereby creating a custom summary report for the fit. Add additional column to compute the distance by using set values dialog for column formula. Copy-pasting the summary table from the report may be the most helpful.
2> Save the book as analysis template, and then perform batch processing on all data files

This will then given you a table of all peak positions and the calculated values such as distance, for each file.

You can refer to this tutorial:
http://www.originlab.com/www/helponline/Origin/en/mergedProjects/Tutorial/Category/Batch_Processing_%28Tutorials%29.html
and contact tech support with your files if you need further help.

Easwar
OriginLab
Go to Top of Page

FloTor

29 Posts

Posted - 12/04/2012 :  06:33:56 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi guys,

acutally both answers are very useful. I will try them out now. If any problems occur, I will ask again :)

thank you very much!
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