Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Fitting an equation to a set of multiple equations.

Status
Not open for further replies.

cannibol_90

Member level 5
Member level 5
Joined
Jun 20, 2009
Messages
83
Helped
5
Reputation
10
Reaction score
5
Trophy points
1,288
Visit site
Activity points
2,066
Hi,

I need to know how can I get a single equation for a given set of equations.

For e.g.:- I have,

Y1=0.106X1+0.103, for a1=1mm
Y2=0.092X2-0.03, for a2=0.5mm
Y3=0.028X3+0.078, for a3=2mm

Now I need a single equation for Y which can include 'a', say;

Y=pX+qa+r or something like that. Is it possible? Is there any software in order to achieve this?

Please help me!
 

OK, in general you have a linear equation whose coefficient are function of a variable "a", that is:

Y=m(a)*x+n(a)

so you want to determine the funtions m(a) and n(a)

from your data we have (ordered by increasing value of "a"):

m(a): m(0.5)=0.092, m(1)=0.106, m(2)=0.028
n(a): n(0.5)=-0.03, n(1)=0.103, n(2)=0.078

we can see that "m" and "n" arent' linear with respect to the variable "a", so you can't have an expression like that you showed (I mean: Y=pX+qa+r) unless you can accept very large errors.

You can instead use a quadratic model; that is m(a)=hm*a^2+km*a+qm and n(a)=hn*a^2+kn*a+qn. This because it's always possible to fit a parabola given 3 points.

numerically you have to solve (with respect to h,k and q) the two linear systems of equations:

0.092 =0.25*hm+0.5*km+qm
0.106=hm+km+qm
0.028=4*hm+2*km+qm

-0.03 =0.25*hn+0.5*kn+qn
0.103=hn+kn+qn
0.078=4*hn+2*kn+qn

Then Y=m(a)*x+n(a) will be:

Y=(hm*a^2+km*a+qm)*x+hn*a^2+kn*a+qn

NOTE: this last will be exact only in the three point (a=0.5, 1 and 2 mm)
 
  • Like
Reactions: cannibol_90

    V

    Points: 2
    Helpful Answer Positive Rating

    cannibol_90

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top