zero, one :: Num a => [a]
zero = 0 : zero
one  = 1 : zero
For ordinary numeric coefficients such as Rational, zero == zero does not terminate, while zero == one is False. The former comparison never finds a differing coefficient or reaches two empty lists; the latter rejects the unequal first coefficients immediately. Equality of denoted formal power series is mathematical equality of all coefficients, whereas this executable list comparison is a potentially nonterminating procedure.
Addition and subtraction of formal power series are coefficientwise:
plus, minus :: Num a => [a] -> [a] -> [a]
plus  = zipWith (+)
minus = zipWith (-)
Here every valid input is an infinite coefficient list. If finite polynomial coefficient lists were admitted, they would need zero-padding before these definitions: ordinary list zip otherwise truncates to the shorter length.
The coefficient index supplies the multiplier for a formal derivative and the divisor for a zero-constant formal integral:
deriv :: Num a => [a] -> [a]
deriv as = zipWith (*) (map fromInteger [1..]) (tail as)

integral :: Fractional a => [a] -> [a]
integral as = 0 : zipWith (/) as (map fromInteger [1..])
Using fromInteger makes the index stream unbounded before conversion to the coefficient type. The formal derivative drops the original constant coefficient; the formal integral prepends its chosen zero constant. With exact Rational coefficients these are exact algebraic operations. Analytic convergence is unnecessary for operations on formal power series over a characteristic-zero field.
The derivative relations and initial values give , , and . Integrating from zero yields and . Thus use mutually recursive lazy lists:
sinx, cosx :: Fractional a => [a]
sinx = integral cosx
cosx = minus one (integral sinx)
Both heads are available immediately, and later coefficients depend on earlier coefficients of the other stream. The resulting formal power series are and . Their zero coefficients and alternating signs follow directly from the coupled recurrence relations, providing a coefficientwise proof without assumptions about analytic convergence.
Power series Created 2026-09-24 Updated 2026-10-14
A power series combines a sequence of coefficients with monomials in the displacement from a fixed centre:
The variable , centre , and coefficients can be real numbers or complex numbers. Its degree- partial sum is a polynomial, so a convergent power series can turn a complicated function into increasingly accurate finite calculations. Convergence, and the error after stopping, are essential parts of that claim.
The geometric series supplies the simplest computed example:
At , stopping after degree ten gives , differing from the exact value by . At , the same degree gives only about instead of . The same formula has very different practical accuracy at different points; the geometric power-series remainder quantifies it.
The structure is useful beyond numerical evaluation. Within its radius of convergence, termwise differentiation of a power series turns a question about a derivative into a question about coefficients. A Taylor series chooses when it represents the function locally. A formal power series instead uses the coefficients algebraically, without asserting numerical convergence; the existing generating function examples use that distinction to encode counting problems.
Let be a complete discrete valuation ring of residue characteristic of a field , with maximal ideal , and let be a one-dimensional formal group law over . Its multiplication series is . If , the invertible morphism criterion for formal group laws constructs its inverse with coefficients in . Both formal power series converge on , since their coefficients are integral and the powers of an element of tend to zero. Their compositions are the identity there. Thus multiplication by is bijective, including when and is odd. Every finite-order element of consequently has order of a group element equal to a prime power with prime .
q-series Created 2026-10-20 Updated 2026-11-05
A q-series is a series in a parameter , treated either as a formal power series or as an analytic series, often for . Its coefficients can encode a sequence, while identities involving infinite products record choices of parts in integer partitions.
For example,
where counts integer partitions of . Expanding each factor as a geometric series chooses the number of parts of size . Formally, each coefficient uses only finitely many factors. This product is a basic link between combinatorics, number theory, and modular forms.
A rational generating function is a formal power series equal to a quotient of two polynomials, with denominator nonzero at the origin. Multiplying by the denominator shows that its coefficients eventually satisfy a linear recurrence with constant coefficients.
Reciprocal of a power series Created 2026-10-20 Updated 2026-10-25
If has , its reciprocal has a unique formal power series . Equating coefficients in the Cauchy product gives the displayed recurrence relation. In particular,
For a convergent power series, continuity and give a neighborhood without zeros, where the reciprocal is analytic and this series converges. Its radius need not equal the original radius: zeros of can introduce closer reciprocal singularities.
Let be a commutative unital ring and with a unit. Set . The coefficient of in gives . At every degree , the coefficient is plus an expression involving only ; choose to cancel that expression. This gives a unique right compositional inverse of a formal power series.
Similarly, the coefficient of in is plus previously fixed terms, so the same recursion gives a left inverse . Composition of zero-constant-term formal power series is associative, since every coefficient involves finitely many terms. Therefore , proving .
Roots-of-unity filter Created 2026-10-20 Updated 2026-11-05
Let be a primitive th root of unity. The finite geometric series gives
Consequently, for a polynomial , the expression keeps exactly the terms whose exponents are congruent to modulo . This is orthogonality of characters for a cyclic group in concrete form.
For , the even and odd parts are and . Taking extracts sums of binomial coefficients in chosen residue classes. The same calculation works for formal power series coefficient by coefficient over a coefficient field containing and .
At an unramified irregular singular point with distinct leading eigenvalues, a sectorial fundamental solution is a fundamental matrix whose entries are holomorphic functions asymptotic to a prescribed formal matrix on a sector of the logarithm cover. For competing cubic exponentials, the usual construction uses six overlapping sectors with basic angle . A formal power series need not converge, and two sectorial realizations may differ by exponentially small terms across a sector boundary.
Series reversion Created 2026-09-29 Updated 2026-11-05
Series reversion constructs the power series for a local inverse function. If with , substitute into the original power series and compare coefficients. The linear coefficient determines ; each later coefficient enters linearly after the earlier ones are known. This also defines reversion of a formal power series, independently of convergence.
For example, gives
Substitution makes the coefficients of and cancel. The exact local inverse verifies the calculation. The general coefficients through cubic order are derived under cubic series reversion.
For an analytic function with nonzero derivative, the inverse function theorem supplies an analytic local inverse, so the reverted series converges sufficiently near the base point. If the linear coefficient vanishes, an ordinary inverse power series may fail: instead needs a choice of square-root branch and a fractional scale.
Put and . A free resolution has countably many generators and relations . Applying the Hom functor with coefficients in gives on sequence products. This is surjective: for prescribed use , a well-defined formal power series. Therefore the degree-one Ext functor vanishes. But , since every image is infinitely divisible by . A nonzero projective module has a nonzero coordinate map into , so is not projective. Its displayed resolution proves that its projective dimension is exactly one. The finite-generation hypothesis in top Ext detects finite projective dimension is essential.