Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: How to set coefficients of 'fittype' global?
Replies: 0  

Advanced Search

Back to Topic List Back to Topic List  
Atul Tiwari

Posts: 1
Registered: 1/20/14
How to set coefficients of 'fittype' global?
Posted: Jan 20, 2014 2:01 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Hello..
I am working on curve fitting. I have an equation to fit.

ft = fittype(@(Hs1,Hs2,s1,s2,m1,m2,x)(2*m1/pi)*atan(((x+Hs1)/Hs1).*tan((s1*pi)/2))+(2*m2/pi)*atan(((x+Hs2)/Hs2).*tan((s2*pi)/2)));

I have designed a GUI for fitting. This GUI contains six radio buttons, and six edit texts.
When a particular radio button is ON, it shows that the value of it's corresponding Coefficient is fixed and the coefficient has become a constant. It means Now it is a constant. So when again executing fitting equation there will be five coefficients of unknown value and one constant.

For this purpose i want to pass the coefficients as global so that using other functions.
How can I do this?



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.