Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

linearization of non-linear systems

Status
Not open for further replies.

PG1995

Active Member
Hi

Could you please help me with these queries? Thanks a lot.

Regards
PG
 

Attachments

  • lcs_linearization.jpg
    lcs_linearization.jpg
    623.7 KB · Views: 408
Q1: The assumption is that y is linear for both x1 and x2 for small deviations of either around some point. It is literally the slope of the curve at that point with respect to x1 and x2. Partial derivatives work because x1 and x2 are independent of one another.

Q2: Just think about it. It isn't as complicated as it might seem.
 
[LATEX]\frac{\partial f^2}{dy dx} = \frac{\partial \frac{\partial f}{dx}}{dy}[/LATEX]
 
Hi

Could you please help me with these queries? Thanks a lot.

Regards
PG

For Q1, the text is actually being imprecise in that formula, those partial derivatives are supposed to be evaluated at the operating point. This is usually indicated with a vertical bar and some kind of notation that indicates that the DC operating point value (the variable with the overbar) is substituted in. You see this done correctly for the K1, K2 etc.

For Q2, there can be cases where there are no differential equations. This is true of linear systems also. However, things are more interesting when there are differential equations and for nonlinear state-space systems there are of course differential equations, but the nonlinear state space form generally has first order differential equations of the form below, where n is the number of states, m is the number of outputs and k is the number of inputs.

State Equations
dx1/dt=f1(x1,x2 ..., u1, u2 ... uk, t)
dx2/dt=f2(x1,x2 ..., u1, u2 ... uk, t)
dx3/dt=f3(x1,x2 ..., u1, u2 ... uk, t)
.
.
.
dxn/dt=fn(x1,x2 ..., u1, u2 ... uk, t)

Output Equations
y1=g1(x1,x2 ..., u1, u2 ... uk, t)
y2=g2(x1,x2 ..., u1, u2 ... uk, t)
y3=g3(x1,x2 ..., u1, u2 ... uk, t)
.
.
.
ym=gm(x1,x2 ..., u1, u2 ... uk, t)

You see here that f1,f2 ... fn and g1, g2 .... gn are nonlinear functions that must be linearized to allow a matrix formulation in linear form. Those matrices then become Jacobian matrices, since they are made of partial derivatives.
 
Last edited:
Thank you, moffy, MrAl, Steve.

@Steve: I'm still not done with the Q2 and need to clarify it further but I think it's better to clear the confusion about Q1 first. I have tried to rephrase the Q1 here. Please guide me with it. Thanks.

Regards
PG
 

Attachments

  • lcs_linearization1.jpg
    lcs_linearization1.jpg
    544.9 KB · Views: 389
When you do a Taylor expansion in more than one dimension, you need the cross terms too. That's just how the theory works out.
 
Thank you.

When you do a Taylor expansion in more than one dimension, you need the cross terms too. That's just how the theory works out.

And this was the point I was missing and was causing all the confusion. I juts found that my formulae book also lists the formula.

Regards
PG
 

Attachments

  • lcs_taylor_two_variables.jpg
    lcs_taylor_two_variables.jpg
    69.9 KB · Views: 346
Last edited:
Here is another rendition which makes it much clearer:

[LATEX]\mathrm{f}\left( x+a,y+b\right) =\mathrm{f}\left( x,y\right)+\frac{E_1}{1!}+\frac{E_2}{2!} +\frac{E_3}{3!}+...+\frac{E_n}{n!}+R_n[/LATEX]

where

[LATEX]E_n=\,D_n\, * f(x,y)\,,[/LATEX]

[LATEX]D_n={\left(a\,\frac{d}{dx}+ b\, \frac{d}{dy}\right) }^{n}[/LATEX] symbolically,

and [LATEX]R_n[/LATEX] is the remainder or error term,

so we expand [LATEX]D_n[/LATEX] with [LATEX]n=2[/LATEX] as:

[LATEX]D_2={a}^{2}\,\frac{{d}^{2}}{{dx}^{2}}+2\,a\,b\,\frac{{d}^{2}}{dx\,dy}+{b}^{2}\,\frac{{d}^{2}}{{dy}^{2}}[/LATEX]

and so:

[LATEX]E_2={a}^{2}\,\frac{{d}^{2}f(x,y)}{{dx}^{2}}+2\,a\,b\,\frac{{d}^{2}f(x,y)}{dx\,dy}+{b}^{2}\,\frac{{d}^{2}f(x,y)}{{dy}^{2}}[/LATEX]
 
Last edited:
Thank you, MrAl.

I think it's the first or second time I see you using Latex and that's nice!

Regards
PG
 
Hello again,

Yes it's cool i guess, but it takes a lot longer to post that's what i dont like about it. And the Latex editor is broken again apparently.

I should have added that the f(x,y) functions in the right side go to f(0,0) at x=0 and y=0 and the Dn changes a little. I guess adding the error term calculation couldnt hurt either, but i'll wait and see if the Latex editor gets up and running again first.
 
MrAl said:
Yes it's cool i guess, but it takes a lot longer to post that's what i dont like about it.

I agree with you. Using Latex here is such a pain and that's the reason I use my own editor to write math stuff and then post the screenshot.

Regards
PG
 
Hi

The following is your reply to the Q2 from post #1.

For Q2, there can be cases where there are no differential equations. This is true of linear systems also. However, things are more interesting when there are differential equations and for nonlinear state-space systems there are of course differential equations, but the nonlinear state space form generally has first order differential equations of the form below, where n is the number of states, m is the number of outputs and k is the number of inputs.

State Equations
dx1/dt=f1(x1,x2 ..., u1, u2 ... uk, t)
dx2/dt=f2(x1,x2 ..., u1, u2 ... uk, t)
dx3/dt=f3(x1,x2 ..., u1, u2 ... uk, t)
.
.
.
dxn/dt=fn(x1,x2 ..., u1, u2 ... uk, t)

Output Equations
y1=g1(x1,x2 ..., u1, u2 ... uk, t)
y2=g2(x1,x2 ..., u1, u2 ... uk, t)
y3=g3(x1,x2 ..., u1, u2 ... uk, t)
.
.
.
ym=gm(x1,x2 ..., u1, u2 ... uk, t)

You see here that f1,f2 ... fn and g1, g2 .... gn are nonlinear functions that must be linearized to allow a matrix formulation in linear form. Those matrices then become Jacobian matrices, since they are made of partial derivatives.

All the state equations are of first order. The derivative terms such as as x1(dot), x2(dot), etc. appear on the left and on the right side of equality sign we have an expression which is completely algebraic and involve no derivative terms. In case I'm utterly wrong then please correct me.

You said, "You see here that f1,f2 ... fn and g1, g2 .... gn are nonlinear functions that must be linearized to allow a matrix formulation in linear form". Sorry but I can't get how they are non-linear. For example, f1 is going to be non-linear if it's of the form, say, f1=(x1)(x2)+x3 (type #1). But if it's of the form f1=x1+x2+x3 (type #2) then I don't think it's non-linear because degree of each individual variable is one. As you are saying that f1 is non-linear then what makes you say that f1 is of form type #1 and not of type #2? Perhaps, a non-linear system always give rise to f1, f2, etc. of the form type #1. For instance, specific functions using eqs. 3-17 and 3-18, f1=x2, f2=(-k/m)x1 - (b/m)x2 + (1/m)u, are linear because they belong to a system which is linear. Please guide me. Thank you.

Regards
PG

Useful links:
1: degree of a polynomial
 

Attachments

  • lcs_state_space_differential_eqs.jpg
    lcs_state_space_differential_eqs.jpg
    108.8 KB · Views: 348
  • lcs_degree.jpg
    lcs_degree.jpg
    61.4 KB · Views: 352
Last edited:
All the state equations are of first order. The derivative terms such as as x1(dot), x2(dot), etc. appear on the left and on the right side of equality sign we have an expression which is completely algebraic and involve no derivative terms. In case I'm utterly wrong then please correct me.

You are correct. State space equations are always a formulation of coupled first order differential equations. The derivative is set equal to functions of the states, inputs and sometimes explicitly time itself. This is true of both nonlinear and linear state space equations.

You said, "You see here that f1,f2 ... fn and g1, g2 .... gn are nonlinear functions that must be linearized to allow a matrix formulation in linear form". Sorry but I can't get how they are non-linear. For example, f1 is going to be non-linear if it's of the form, say, f1=(x1)(x2)+x3 (type #1). But if it's of the form f1=x1+x2+x3 (type #2) then I don't think it's non- linear because degree of each individual variable is one. As you are saying that f1 is non-linear then what makes you say that f1 is of form type #1 and not of type #2? Perhaps, a non-linear system always give rise to f1, f2, etc. of the form type #1. For instance, specific functions using eqs. 3-17 and 3-18, f1=x2, f2=(-k/m)x1 - (b/m)x2 + (1/m)u, are linear because they represent a system which is linear. Please guide me. Thank you.

OK, this is just a wording issue. Of course you can have special cases where some of the functions f1, f2... or g1, g2 ... etc. are linear. In such cases, you don't need to linearize the equations because they are already linear. However, the process of linearization does not care if they are linear or nonlinear. It works in both cases. It's just that if you linearize something that is linear, you get the same thing back again, which then allows you to prove the equation is linear.

In the special case where all functions are linear, then you already have a linear state space system and there is no need to linearize the equations. However, your original question was specifically about nonlinear systems, so I didn't think to clarify this point.
 
Thank you.

OK, this is just a wording issue. Of course you can have special cases where some of the functions f1, f2... or g1, g2 ... etc. are linear. In such cases, you don't need to linearize the equations because they are already linear. However, the process of linearization does not care if they are linear or nonlinear. It works in both cases. It's just that if you linearize something that is linear, you get the same thing back again, which then allows you to prove the equation is linear.

In the special case where all functions are linear, then you already have a linear state space system and there is no need to linearize the equations. However, your original question was specifically about nonlinear systems, so I didn't think to clarify this point.

So, I gather that for a non-linear system the functions f1, f2... or g1, g2 ... etc. could be of both types, i.e. f=(x1)(x2)+x3 (type #1) and f=x1+x2+x3 (type #2). But still linearization could be performed on all f's and g's because only those f's and g's will be affected which are not linear.

Regards
PG
 
Thank you.



So, I gather that for a non-linear system the functions f1, f2... or g1, g2 ... etc. could be of both types, i.e. f=(x1)(x2)+x3 (type #1) and f=x1+x2+x3 (type #2). But still linearization could be performed on all f's and g's because only those f's and g's will be affected which are not linear.

Regards
PG

Yes, that's correct. Type #1 would be any linear formula and Type #2 would be any "linearizable" nonlinear function. There are some devices and processes that are not linearizable. A good example is a switching event. However, it is sometimes possible to implement an averaging operation first and then to linearize the averaged system. Eventually, you will encounter this if you study DC/DC converters and switching power systems in general.

I can't stress enough that this subject/material will not be fully understood and will be quickly forgotten if you don't work out practical examples.
 
Thank you.

Yes, that's correct. Type #1 would be any linear formula and Type #2 would be any "linearizable" nonlinear function.

I thought I just confirm it. As I wrote it in my post Type #1 was f=(x1)(x2)+x3, and Type #2 was f=x1+x2+x3. So, I will say Type #2 is any linear formula and so on. So, don't you have them in reverse order? Please let me know. Thanks.

I can't stress enough that this subject/material will not be fully understood and will be quickly forgotten if you don't work out practical examples.

Your point is well taken. Actually I was thinking this too that I'm getting into too much theory without having any concrete example at hand and as you also advised that this way any material is not well understood and easily forgotten, and moreover I believe this way, for you or anyone else, it's really hard to guide especially when the person seeking help and guidance is not physically present in front of you.

Regards
PG
 
I thought I just confirm it. As I wrote it in my post Type #1 was f=(x1)(x2)+x3, and Type #2 was f=x1+x2+x3. So, I will say Type #2 is any linear formula and so on. So, don't you have them in reverse order? Please let me know.

Yes, of course, I swapped them by accident. You have it correct.




Your point is well taken. Actually I was thinking this too that I'm getting into too much theory without having any concrete example
That's one of the benefits of working on real problems. Undergraduate study gives the tools, but real work (grad work can be real work too, contrary to popular opinion) is the real venue for learning.

One advantage I had in school is that I did practical work on my own from age 14 to 18, so when i got to engineering study at college, I had so many questions and applications in mind. However, one problem I have now is that if I try to learn something completely new, I'm very bored by the examples given in the books I read. I'm not motivated to study hypothetical and simplified problems after working on so many real world problems. Hence, my approach, now that I'm older, is to just learn many new things in a cursory way, and then keep them in the back of my mind. Then, if a real applciation of that theory comes up in my work, then I master it. Invariably, mastering is hard if you don't have an application and so very easy when you do have an application.


I believe this way, for you or anyone else, it's really hard to guide especially when the person seeking help and guidance is not physically present in front of you.

Sometimes it is very hard, and in those cases I usually make a comment like "this would be easier standing at a blackboard". Other times the material is well suited to this format, and it is no problem at all.
 
Hi

Could you please help me with this query? Thank you.

Regards
PG

Helpful link(s):
1: **broken link removed**
 

Attachments

  • linear_nonlinear.jpg
    linear_nonlinear.jpg
    95.6 KB · Views: 350
Last edited by a moderator:
Good observation. You are correct that any offset from a linear function y=mx becomes y=mx+b and is a nonlinear system. This is a tricky point that many people never understand. The terms "linear" and "line" do not imply the same things. A line function is only linear when the y-intercept (b offset) is zero.

Don't ever forget this.

A place where this matters is with OPAMP circuits. Everyone knows that when your OPAMP output hits the supply rails, you have a nonlinear response, but if the output is in range, you typically have a linear system. However, this assumes the signals and the OPAMPs are referenced to ground. But, if the OPAM is being referenced to a voltage reference, then the circuit is not linear any more. Many people have fallen into that trap.
 
Thank you, Steve.

Let's get this straight first. In mathematics, f(x)=ax+b is a linear function where "b" could be any real number but in signal theory a linear system always has b=0. I hope I have it correct.

I understand that the definitions of a linear system aren't applicable to the case f(x)=ax+b where b≠0 but I'm still confused about it. You are quite correct in saying that it's a trap and I have already fallen into this trap and hit my face on a box full of rotten tomatoes! :(

However, this assumes the signals and the OPAMPs are referenced to ground. But, if the OPAM is being referenced to a voltage reference, then the circuit is not linear any more.

What you say above is critical here. Could you please elaborate on it a little using some signal?

What physical system can the function f(x)=ax+b represent? The function f(x)=ax could represent an ohmic resistor circuit.

Thanks very much.

Regards
PG
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top