The term transform usually refers to a mathematical operation that takes a given function and returns a new function. The transformation is sometimes done by means of a sum formula. Examples include the transform and the discrete-time Fourier transform. Transforms are frequently used to change a complicated problem into a simpler one. The simpler problem is then solved, usually using elementary algebraic means. The solution to the simpler problem is taken over to the original problem using the inverse transform. A standard example is the use of the transform to solve a difference or recurrence equation.
This package implements the transform. The transform of a function of the integer-valued variable is the function defined by . The package DiscreteMath`RSolve`
is automatically loaded.
This loads the package.
The transform and its inverse.
This evaluates a
In:= ZTransform[Sin[n], n, z]
The functions you are transforming can contain symbolic quantities.
In:= ZTransform[n^3 a^n, n, z]
Here is the inverse
transform of the previous result.
In:= InverseZTransform[%, z, n] // Together
ZTransform knows the standard properties of the transform such as linearity and the behavior of differences. The superscript (0,0,1) means the first derivative with respect to the third variable.
In:= ZTransform[f[n] - f[n-1] + -n^2 g[n], n, z]
ZTransform recognizes the Kronecker delta function KroneckerDelta and the discrete unit step function DiscreteStep. These functions are discussed in the section on the DiscreteMath`KroneckerDelta` package.
Here is a transform of an expression involving a delta function.
In:= ZTransform[Sin[n] KroneckerDelta[n - 7], n, z]
The inverse transforms of many standard functions include delta functions.
In:= InverseZTransform[ArcTan[1/z], z, n]
The convention is to make the assumptions about parameters necessary for the transform to exist. However, if the form the transform takes depends on the assumptions made, then the transform will return unevaluated.
In:= ZTransform[DiscreteStep[n - b], n, z]
Assumptions about parameters can be made by defining Positive, Negative, Sign, or IntegerQ for a parameter. This is the transform for a step on the positive real axis.
In:= b /: Positive[b] = True;
b /: IntegerQ[b] = True;
ZTransform[DiscreteStep[n - b], n, z]
Here the step is on the negative real axis, outside the summation limits of the
In:= c /: Sign[c] = 1;
c /: IntegerQ[c] = True;
ZTransform[DiscreteStep[n + c], n, z]