Problem with substitution in a difference equation

jwxie
Messages
278
Reaction score
0

Homework Statement


Verify that the response of the system governed by the 1st order different equation
y(k)=bu(k)+ay(k-1)

is given by this solution
y(k)=\frac{b}{1+a}\left [ (-1)^{k}+a^{k+1} \right ]
for u(k) = (-1)^k


The Attempt at a Solution



The solution said we can verify this by substitution. I didn't get how we jump to the second step

(sub)
\frac{b}{1+a}\left [ (-1)^{k}+a^{k+1} \right ]-\frac{ab}{1+a}\left [ (-1)^{k}+a^{k} \right ]

2nd step
\frac{b(-1)^{k}[1+a]}{(1+a)}+\frac{ba^{k}(a-a)}{1+a}

How did we get the top (1+a) in the first term, and the (a-a) in the second term?
Thank you.
 
Physics news on Phys.org
There has to be an error.
Was the first step supposed to be y(k)-ay(k-1)? This would either have been
\frac{b}{1+a}[(-1)^k+a^{k+1}] + \frac{ab}{1+a}[(-1)^{k}+a^{k}]

or

\frac{b}{1+a}[(-1)^k+a^{k+1}] - \frac{ab}{1+a}[(-1)^{k-1}+a^{k}].

(Notice the power of the second (-1) term.)
 
Hi Thompson, yes the first step is indeed to rewrite the difference equation in the standard form, which is y(k) - ay(k-1)
Thanks.
 
Unsure if this proof is correct

I completed this proof in the attachment but can someone please check my working

The aim was to show that the height of P above floor after the crate is tilted is h(cosb+2sinb)

From the rectangles you can work out
Length of OP=h√5
sin(a)=1/√5
cos(a)=2/√5

therefore
height=h√5.sin(a+b)
=h√5.(sinacosb+cosasinb)
=h√5.(1/√5cosb+2/√5sinb)
=h(cosb+2sinb)
 

Attachments

  • Trig.jpg
    Trig.jpg
    4.9 KB · Views: 428


Yes, that's perfectly correct!:smile:

But why did you open a new thread for this?
(I'm merging the two threads.)
 
Hmmm.. excuse me? What is this proof all about?
LOOOL
how is this relevant to my difference equation problem?
 
anyone? still haven't figure it out yet. Thanks, and sorry for the bump.
 
Darn it! The first expression I posted had an error! It should be

<br /> \frac{b}{1+a}[(-1)^k+a^{k+1}] + \frac{ab}{1+a}[(-1)^{k}-a^{k}]<br />

Sorry about that. I'm new to doing math via computer, and usually make silly errors.


These two threads were apparently merged by mistake- okay, so let's take the first form of y(k)-a(yk-1) that I posted
<br /> \frac{b}{1+a}[(-1)^k+a^{k+1}] + \frac{ab}{1+a}[(-1)^{k}-a^{k}]<br />

multiply out the terms in the numerators..

<br /> \frac{b(-1)^k +ba^{k+1}}{1+a} + \frac{ab(-1)^{k}-ba^{k+1}}{1+a}<br />

then simply group the terms appropriately. In the reduced form you posted (the second step) they got

<br /> \frac{b(-1)^{k}[1+a]}{(1+a)}+\frac{ba^{k}(a-a)}{1+a}<br />

from grouping terms immediately instead of expanding the numerators, but you can do it either way.
 
It's also important for you to see where

<br /> <br /> \frac{b}{1+a}[(-1)^k+a^{k+1}] + \frac{ab}{1+a}[(-1)^{k}-a^{k}]<br /> <br />

comes from.

<br /> y(k)-ay(k-1)=\frac{b}{1+a}[(-1)^k+a^{k+1}] - \frac{ab}{1+a}[(-1)^{k-1}+a^{k}]

= \frac{b}{1+a}[(-1)^k+a^{k+1}] - \frac{ab}{1+a}[\frac{(-1)^{k}}{(-1)}-(-a^{k})]

= \frac{b}{1+a}[(-1)^k+a^{k+1}] -(-1)\frac{ab}{1+a}[(-1)^{k}+(-a^{k})]<br />

Does that make sense?
 
  • #10
hey JThompson, thank you very much. Your explanations are very clear. Thanks!
 
Back
Top