If I have a system response or the primitive equation , how can i find its difference equation by mathematica?


h[n] = b0 a^n u[n] + b1 a^n-1 u[n-1]
H[z] = b0 + b1 z^-1 / (1- a z^-1), |z| > |a|


y[n] - a y[n-1] = b0 x[n] + b1 x[n-1]
  • $\begingroup$ Welcome to Mathematica.SE! I hope you will become a regular contributor. To get started, 1) take the introductory tour now, 2) when you see good questions and answers, vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge, $\endgroup$
    – Dunlop
    Mar 1 at 5:09
  • $\begingroup$ 3) remember to accept the answer, if any, that solves your problem, by clicking the checkmark sign, and 4) give help too, by answering questions in your areas of expertise. $\endgroup$
    – Dunlop
    Mar 1 at 5:09
  • $\begingroup$ Please try to be a bit clearer in your example. This will help others in understanding and solving your problem $\endgroup$
    – Dunlop
    Mar 1 at 5:10

1 Answer 1


There is an undocumented internal function that does this.

tfm = TransferFunctionModel[(b0 + b1 z^-1)/(1 - a z^-1), 1/z, SamplingPeriod -> 1];

Control`DEqns`ioEqnsForm[tfm][[1, 1]]

enter image description here


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.