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
 All Forums
 Origin Forum
 Origin Forum
 Additional extract from user defined fit function.

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
cheolmin park Posted - 09/10/2020 : 09:33:51 AM
Origin Ver.originlab 2019 and Service Release (Select Help-->About Origin):
Operating System: window 10 pro
Hello. Dear friends.
I fitted by origin C in user defined fitting.
In the fit function, additionally, I want to extract real and imaginary value into worksheet coulomb;
Do you know how to do it?
((( Importantly, the fit data is numerically merged of real and imaginary. So the y value cannot separated.)))
----------------------------------------------------------------------
void _nlsMycomplexFitFunction(
// Fit Parameter(s):
double a1, double a2, double a3,
// Independent Variable(s):
double x,
// Dependent Variable(s):
double& y)
{
double real;
double imaginary;
complex result=0;
:
:

real=result.m_re; //<---- this
imaginary=result.m_im; //<-----this

y=real+imaginary;
// End of editable part
}
1   L A T E S T    R E P L I E S    (Newest First)
AmandaLu Posted - 09/11/2020 : 02:43:56 AM
Hi,

To fit a complex function, you will need to put real and imaginary values into two columns, and the outputs are also in two columns. Please refer to this tutorial:

https://www.originlab.com/doc/Tutorials/Fitting-ComplexFunc

Thanks,
Amanda
OriginLab Technical Service

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000