0
$\begingroup$

I just wanted to doublecheck answers for my sanity's sake (exam next week)

problem statement

recurrence relation, solve it

$y[n+1]= 35 + y[n]*0.5$

according to my teacher it will be such that the input sequence must be causal, so that we have re-arranged form such as

$y[n+1]- y[n]*0.5= 35u[n]$ ,where $y[0]=20$, and causal input

My understanding is that we should go as follows

  1. get $X(z)$
  2. find what is $Y(z)$
  3. then we can maybe do inverse Z-transform to get the y[k] output sequence in explicit form sequence
  4. typically the most difficult phase seems to be the inverse Z transform so it can be tricky, but we have a table, and our teacher taught us to either use
    1. z-table
    2. long division
    3. partial fraction expansion and z-table

enter image description here

Firstly, Z-transform both sides

$Z(y[n+1])-0.5Z(y[n])=35*Z(u[n])$

according to the z-table we receive

$z*Y(z)-z*y[0]-0.5*Y(z)=35*\frac{z}{z-1}$

combine terms and re-factor and emplace y[0]=20

$Y(z)(z-0.5)=35*\frac{z}{z-1}+z*20$

$Y(z)=35*\frac{z}{(z-1)(z-0.5)}+20*\frac{z}{z-0.5}$

We designate R(z) for the purposes of partial fraction expansion, because it is not found in the z-table

$R(z)=\frac{z}{(z-1)(z-0.5)}$

however the rightsided term is found directly in the z-table $Z^{-1}(20*\frac{z}{z-0.5}) = 20* (0.5^k)$

start partial fraction expansions $R(z)/z = \frac{1}{(z-1)(z-0.5)}=\frac{a}{(z-1)}+\frac{b}{(z-0.5)}$, then we find that, $a=2,b=-2$

$R(z)=2*\frac{z}{(z-1)}-2*\frac{z}{(z-0.5)}$

$Y(z)=35*(2*\frac{z}{z-1}-2*\frac{z}{z-0.5})+20*(\frac{z}{z-0.5})$

apply inverse Z transform

$y[k]=20*(0.5)^k+70*u[k]-70*0.5^k$

$y[k]=u[k]*(70-50*0.5^k)$

tabulating some results

  • k=-1; y[-1]=0
  • k=0; y[0]= 20
  • k=1; y1= 45
  • k=2; y[2]= 115/2
$\endgroup$
0
$\begingroup$

With such simple recursions it's often easiest (and instructive) to actually go through the recursion and find a pattern. With $y[0]=20$ and using $c=35$ we get

$$\begin{align}y[1]&=c+\frac{y[0]}{2}\\y[2]&=c+\frac{c}{2}+\frac{y[0]}{4}\\y[3]&=c+\frac{c}{2}+\frac{c}{4}+\frac{y[0]}{8}\\\vdots\end{align}$$

So we can conclude

$$\begin{align}y[n]&=c\left[1+\frac12+\frac14+\ldots+\left(\frac12\right)^{n-1}\right]+y[0]\left(\frac12\right)^n\\&=c\sum_{k=0}^{n-1}\left(\frac12\right)^k+y[0]\left(\frac12\right)^n\\&=c\cdot\frac{1-\left(\frac12\right)^{n}}{1-\frac12}+y[0]\left(\frac12\right)^n\\&=2c+\big(y[0]-2c\big)\left(\frac12\right)^n,\qquad n>0\end{align}$$

which is the same expression you obtained.

$\endgroup$
  • $\begingroup$ I dont think that is the right approach. I think you made mistake where you assumed y[0]=35. I think I said in the beginning that y[0]=20. Anyway, I inputted the recurrence relation into my casio calculator recursive mode (that mode can also calculate newton-raphson and other recursive relations) It seems that you can easily compute the values recursively with computer. I got: k=0, y[0]=20; k=1, y[1]=45; k=2, y[2]=57,5 etc. etc. The problem apparently wants to have explicit defined sequence $\endgroup$ – Late347 Nov 18 '18 at 16:21
  • $\begingroup$ @Late347: yes, I missed the line in your equation where $y[0]=20$ was specified. I'll update my answer. $\endgroup$ – Matt L. Nov 18 '18 at 16:28
  • $\begingroup$ I used excel to compute recursive relation / recurrence relation, so this problem was funny because the answer is "known" so you can recursively compute always results, but explicit formula was apparently desired... $\endgroup$ – Late347 Nov 18 '18 at 16:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.