ZTransform[expr,n,z]
gives the Z transform of expr.
ZTransform[expr,{n1,…,nm},{z1,…,zm}]
gives the multidimensional Z transform of expr.
ZTransform
ZTransform[expr,n,z]
gives the Z transform of expr.
ZTransform[expr,{n1,…,nm},{z1,…,zm}]
gives the multidimensional Z transform of expr.
Details and Options
- The Z transform for a discrete function
is given by
. - The multidimensional Z transform is given by
. - The following options can be given:
-
Assumptions $Assumptions assumptions to make about parameters GenerateConditions False whether to generate answers that involve conditions on parameters Method Automatic method to use VerifyConvergence True whether to verify convergence - In TraditionalForm, ZTransform is output using .
Examples
open all close allBasic Examples (3)
ZTransform[n ^ 2 2 ^ (-n), n, z]InverseZTransform[%, z, n]Transform a multivariate sequence:
ZTransform[a ^ n m ^ 3, {n, m}, {u, v}]InverseZTransform[%, {u, v}, {n, m}]Transform a symbolic sequence:
ZTransform[f[n + 1], n, z]Scope (25)
Basic Uses (7)
Transform a univariate sequence:
ZTransform[a ^ n, n, z]Transform a multivariate sequence:
ZTransform[a ^ (n + m), {n, m}, {z, w}]F = ZTransform[n (n + 1)(-1 / 2) ^ n, n, z]Plot the magnitude using Plot3D, ContourPlot, or DensityPlot:
Block[{z = u + I v}, Table[plot[Abs[F], {u, -2, 2}, {v, -2, 2}], {plot, {Plot3D, ContourPlot, DensityPlot}}]]Block[{z = u + I v}, Table[plot[Arg[F], {u, -2, 2}, {v, -2, 2}], {plot, {Plot3D, ContourPlot, DensityPlot}}]]Generate conditions for the region of convergence:
ZTransform[a ^ n, n, z, GenerateConditions -> True]With[{z = u + I v}, RegionPlot[Abs[z] > 1 / 2, {u, -1, 1}, {v, -1, 1}]]Evaluate the transform at a point:
F = ZTransform[Sin[n 2Pi / 3](2 / 3) ^ n, n, Exp[I ω]]LogPlot[Abs[F] ^ 2, {ω, 0, 2π}, Ticks -> {{0, π, 2π}, Automatic}]Plot[Arg[F], {ω, 0, 2π}, Ticks -> {{0, π, 2π}, Automatic}]Plot both the spectrum and the plot phase using color:
LogPlot[Abs[F] ^ 2, {ω, 0, 2π}, Ticks -> {{0, π, 2π}, Automatic}, ColorFunction -> Function[ω, Evaluate@Hue[Arg[F] / (2Pi) + 1 / 2]], ColorFunctionScaling -> False, Filling -> Axis]Plot the spectrum in the complex plane using ParametricPlot3D:
ParametricPlot3D[{Cos[ω], Sin[ω], Log[10, Abs[F] ^ 2]}, {ω, 0, 2π}, BoxRatios -> {1, 1, 1}]ZTransform will use several properties including linearity:
ZTransform[a f[n] + b g[n], n, z]{ZTransform[f[n + 1], n, z], ZTransform[f[n - 1], n, z]}Multiplication by exponentials:
{ZTransform[a ^ n f[n], n, z], ZTransform[b ^ (-n)f[n], n, z]}ZTransform[Exp[I ω n]f[n], n, z]Multiplication by polynomials:
{ZTransform[ n f[n], n, z], ZTransform[n(n + 1) f[n], n, z]}ZTransform[Conjugate[f[n]], n, z]ZTransform automatically threads over lists:
ZTransform[{a ^ n, b ^ n}, n, z]ZTransform[{{a ^ n, b ^ n}, {n, n ^ 2}}, n, z]ZTransform[a ^ n == f[n], n, z]ZTransform[f[n] -> a ^ n, n, z]TraditionalForm typesetting:
ZTransform[f[n], n, z]//TraditionalFormSpecial Sequences (13)
{ZTransform[DiscreteDelta[n], n, z], ZTransform[DiscreteDelta[n - 5], n, z]}Table[DiscretePlot[f, {n, -10, 10}, PlotStyle -> PointSize[Medium]], {f, {DiscreteDelta[n], DiscreteDelta[n - 5]}}]{ZTransform[UnitStep[n], n, z], ZTransform[UnitStep[n - 3], n, z]}Table[DiscretePlot[f, {n, -10, 10}], {f, {UnitStep[n], UnitStep[n - 3]}}]{ZTransform[n UnitStep[n], n, z], ZTransform[(n - 3)UnitStep[n - 3], n, z]}Table[DiscretePlot[f, {n, -10, 10}], {f, {n UnitStep[n], (n - 3)UnitStep[n - 3]}}]Polynomials result in rational transforms:
{ZTransform[n, n, z], ZTransform[n ^ 2, n, z]}ZTransform[Pochhammer[n, Range[0, 3]], n, z]ZTransform[FactorialPower[n, Range[0, 3]], n, z]ZTransform[a ^ n, n, z]{ZTransform[n a ^ n, n, z], ZTransform[n ^ 2 a ^ n, n, z]}Table[DiscretePlot[f, {n, 0, 40}], {f, {n (10 / 12) ^ n, n ^ 2 (10 / 12) ^ n}}]Factorial exponential polynomials:
ZTransform[Pochhammer[n, Range[0, 3]] a ^ n, n, z]ZTransform[FactorialPower[n, Range[0, 3]] a ^ n, n, z]{ZTransform[Sin[ω n + ϕ], n, z], ZTransform[Cos[ω n + ϕ], n, z]}Table[DiscretePlot[f, {n, -20, 20}], {f, {Sin[2π / 10 n], Cos[2π / 10 n]}}]Trigonometric, exponential and polynomial:
{ZTransform[(5 / 6) ^ n Sin[ω n], n, z], ZTransform[n (5 / 6) ^ n Sin[ω n], n, z]}Table[DiscretePlot[f, {n, 0, 20}], {f, {(5 / 6) ^ n Sin[2π / 10 n], n (5 / 6) ^ n Sin[2π / 10 n]}}]Combinations of the previous input will also generate rational transforms:
ZTransform[n ^ 2 a ^ n + b ^ n Sin[ω n] UnitStep[n + 20], n, z]DiscretePlot[n ^ 2 (5 / 6) ^ n + (11 / 12) ^ n 20Sin[2Pi / 10 n]UnitStep[n - 20], {n, 0, 50}]Different ways of expressing piecewise defined signals:
ZTransform[n (UnitStep[n] - UnitStep[n - 6]) + a ^ n UnitStep[n - 6], n, z]ZTransform[Piecewise[{{n, n ≤ 5}, {a ^ n, True}}], n, z]Simplify[%% - %]ZTransform[1 / (n + 1), n, z]ZTransform[(n^2 + n + 1) / (n + 1) ^ 2, n, z]//SimplifyZTransform[FactorialPower[n, -2], n, z]//SimplifyRational exponential functions:
ZTransform[a ^ n / (n + 1) ^ 2, n, z]ZTransform[a ^ n FactorialPower[n, -2], n, z]//SimplifyHypergeometric term sequences:
ZTransform[1 / n!, n, z]The DiscreteRatio is rational for all hypergeometric term sequences:
DiscreteRatio[1 / n!, n]Many functions give hypergeometric terms:
hl = {a ^ n, n!, Gamma[n], Pochhammer[a, n], FactorialPower[a, n], Binomial[n, a], Binomial[b, n], CatalanNumber[n]};DiscreteRatio[hl, n]Any products are hypergeometric terms:
DiscreteRatio[Times@@RandomChoice[hl, 3], n]Transforms of hypergeometric terms:
ZTransform[(2^-2 + n/Gamma[(1/2) + n]), n, z]ZTransform[n / Binomial[2n, n], n, z]ZTransform[CatalanNumber[n] / Binomial[2n, n], n, z]ZTransform[(FactorialPower[a1, n]/FactorialPower[b1, n]FactorialPower[b2, n]), n, z]ZTransform[LegendreP[n, a], n, z]A holonomic sequence is defined by a linear difference equation:
DifferenceRootReduce[LegendreP[n, a], n]Many special function are holonomic sequences in their index:
ZTransform[ChebyshevT[n, x], n, z]ZTransform[ChebyshevU[2n, x] ^ 2, n, z]ZTransform[BernoulliB[n] / n!, n, z]ZTransform[EulerE[n] / n!, n, z]ZTransform[Mod[n, 3], n, z]ZTransform[Exp[n 2π I / 7], n, z]ZTransform[a^n + m, {n, m}, {u, v}]ZTransform[n ^ 2 m ^ 3, {n, m}, {u, v}]ZTransform[a^n + mn ^ 2 m ^ 3, {n, m}, {u, v}]ZTransform[Sin[n + m]a ^ n, {n, m}, {u, v}]ZTransform[m / (n + 1), {n, m}, {u, v}]Multivariate periodic sequences:
ZTransform[Mod[n + m, 3], {n, m}, {u, v}]DiscretePlot3D[Mod[n + m, 3], {n, 0, 12}, {m, 0, 12}]Special Operators (5)
ZTransform[a f[n] + b g[n], n, z]ZTransform[f[n + 1], n, z]There are several relations to the InverseZTransform:
ZTransform[InverseZTransform[F[z], z, n], n, z]ZTransform[InverseZTransform[F[z], z, n + 1], n, z]ZTransform[n InverseZTransform[F[z], z, n], n, z]ZTransform[n ^ 2 InverseZTransform[F[z], z, n], n, z]ZTransform[a ^ n InverseZTransform[F[z], z, n], n, z]ZTransform[n a ^ n InverseZTransform[F[z], z, n], n, z]ZTransform[DifferenceDelta[f[n], n], n, z]ZTransform[DiscreteShift[f[n], n], n, z]ZTransform[Sum[f[m], {m, 0, n}], n, z]ZTransform[Sum[f[m], {m, a, n}], n, z, Assumptions -> a > 0 && a∈Integers]ZTransform[Integrate[f[x, n], {x, a, b}], n, z]Options (4)
Assumptions (1)
Without assumptions, typically a general formula will be produced:
ZTransform[FactorialPower[n, k], n, z]Use Assumptions to obtain the expression on a given range:
ZTransform[FactorialPower[n, k], n, z, Assumptions -> (k∈Integers && k > 0)]GenerateConditions (1)
Set GenerateConditions to True to get the region of convergence:
ZTransform[a ^ n, n, z, GenerateConditions -> True]Method (1)
VerifyConvergence (1)
By default, convergence testing is performed:
ZTransform[(n + 1)!, n, z]Setting VerifyConvergence->False will avoid the verification step:
ZTransform[(n + 1)!, n, z, VerifyConvergence -> False]Applications (1)
ZTransform[y[n + 2] + 2 y[n + 1] - 3 y[n] == 0, n, z]Solve[% /. {y[0] -> 0, y[1] -> 2}, ZTransform[y[n], n, z]]InverseZTransform[ZTransform[y[n], n, z] /. First[%], z, n]RSolve[{y[n + 2] + 2 y[n + 1] - 3 y[n] == 0, y[0] == 0, y[1] == 2}, y[n], n]Properties & Relations (6)
ZTransform is closely related to GeneratingFunction:
{GeneratingFunction[n, n, z], ZTransform[n, n, 1 / z]}//SimplifyExponentialGeneratingFunction:
{ExponentialGeneratingFunction[n, n, z], ZTransform[n / n!, n, 1 / z]}{FourierSequenceTransform[n UnitStep[n], n, ω], ZTransform[n, n, Exp[-I * ω]]}//SimplifyUse InverseZTransform to get the sequence from its transform:
InverseZTransform[ZTransform[f[n], n, z], z, n]ZTransform[InverseZTransform[F[z], z, n], n, z]ZTransform[a ^ n, n, z]InverseZTransform[%, z, n]ZTransform effectively computes an infinite sum:
ZTransform[n ^ 2, n, z]Sum[n ^ 2 z ^ (-n), {n, 0, Infinity}]ZTransform[a f[n] + b g[n], n, z]ZTransform[f[n + 2], n, z]ZTransform[Sum[f[k]g[k - n], {k, 0, n}], n, z]ZTransform[n f[n], n, z]ZTransform[(n ^ 2 + 1)2 ^ (-n), n, z]Limit[(n ^ 2 + 1)2 ^ (-n), n -> 0] == Limit[%, z -> Infinity]ZTransform[(n ^ 2 + 1)2 ^ (-n), n, z]Limit[(n ^ 2 + 1)2 ^ (-n), n -> Infinity] == Limit[%, z -> 0]Possible Issues (1)
A ZTransform may not converge for all values of parameters:
{Sum[2 ^ n 1 ^ (-n), {n, 0, ∞}], ZTransform[2 ^ n, n, 1]}ZTransform[a ^ n, n, z]Use GenerateConditions to get the region of convergence:
ZTransform[a ^ n, n, z, GenerateConditions -> True]Neat Examples (1)
Create a gallery of Z transforms:
flist = {{UnitStep[n], n, z}, {E ^ (-α n), n, z}, {Sin[α n], n, z}, {n ^ 3 + 3n + 1, n, z}, {n ^ k, n, z}, {ChebyshevU[n, x], n, z}, {a ^ n Cos[Pi n], n, z}, {(m + 1)(n - m), {m, n}, {u, v}}, {a ^ n m ^ 3, {m, n}, {u, v}}};Grid[Prepend[{#[[1]], ZTransform@@#}& /@ flist, {f, "Z-Transform"}], IconizedObject[«Grid options»]]//TraditionalFormTech Notes
Related Guides
Related Links
History
Introduced in 1999 (4.0) | Updated in 2008 (7.0)
Text
Wolfram Research (1999), ZTransform, Wolfram Language function, https://reference.wolfram.com/language/ref/ZTransform.html (updated 2008).
CMS
Wolfram Language. 1999. "ZTransform." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2008. https://reference.wolfram.com/language/ref/ZTransform.html.
APA
Wolfram Language. (1999). ZTransform. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/ZTransform.html
BibTeX
@misc{reference.wolfram_2026_ztransform, author="Wolfram Research", title="{ZTransform}", year="2008", howpublished="\url{https://reference.wolfram.com/language/ref/ZTransform.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_ztransform, organization={Wolfram Research}, title={ZTransform}, year={2008}, url={https://reference.wolfram.com/language/ref/ZTransform.html}, note=[Accessed: 12-June-2026]}