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 for Programming
 Forum for Origin C
 Fitting the linear combination data
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

funfine

USA
Posts

Posted - 07/28/2007 :  11:33:53 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
I have edited the messege to make it more clear. Hopefully, this is less misleading.

Origin Version (Select Help-->About Origin): Origin Pro 7.5 SR5
Operating System: WinXP Home Edition

Hi everyone,

I have met a problem. I need to fit the data with linear combination. The case is like this. I have two columns of data, one called ColA, one ColB. I need to fit a new dataset (a*ColA+ b*ColB) with Function1, where a and b is also variable fitting parameter. I need to do this with Function2 too. . Anybody knows how to do this? I appreciate any idea. Thanks.

Ying


Edited by - funfine on 07/28/2007 2:21:39 PM

Mike Buess

USA
3037 Posts

Posted - 07/28/2007 :  1:27:39 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Ying,

I think you mean to simultaneously fit one column to Function A and the other column to Function B. If that is correct you must create a new function which is a linear combination of both functions...

y = mu*FuncA(x) + (1-mu)*FuncB(x)
http://www.originlab.com/www/helponlin/origin/Defining_a_New_Function.htm

Then on the Select Dataset tab check the Fit Multiple Datasets option and select both columns as dependent variables.
http://www.originlab.com/www/helponlin/origin/Selecting_the_Data_Sets.htm

When you start the fitting session you'll see a duplicate set of parameters for each column, i.e., mu_1, w_1, xc_1, mu_2, w_2, xc_2. For the column that fits to FuncA set mu_# = 1 and initialize the remaining parameters for that column. For the column that fits to FuncB set mu_# = 0 and initialize the rest.
http://www.originlab.com/www/helponlin/origin/The_Fitting_Session_Concept.htm

If FuncA and FuncB happen to be Lorentz and Gauss you can use Origin's built-in PseudVoigt2 function.

Mike Buess
Origin WebRing Member
Go to Top of Page

funfine

USA
Posts

Posted - 07/28/2007 :  1:45:24 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi Mike,

Thanks for the timely reply. But I am deep sorry for the misunderstanding. What I meant is, let's say, I have two columns data, one called ColA, one ColB. I need to fit a new dataset (a*ColA+ b*ColB) with FunctionA, where a and b is also variable fitting parameter. I need to do this with FunctionB too. Thanks for your great help.

Ying
Go to Top of Page

Mike Buess

USA
3037 Posts

Posted - 07/29/2007 :  10:23:06 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
So you want to change the data even as you are performing the fit? I don't see how you could do that. Best I can suggest is to create col(C)= a*col(A) + b*col(B), fit to funcA or funcB, save params and then repeat with new a & b.

Mike Buess
Origin WebRing Member
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