Algorithmic Arithmetics with DD-Finite Functions Implementation and - - PowerPoint PPT Presentation

algorithmic arithmetics with dd finite functions
SMART_READER_LITE
LIVE PREVIEW

Algorithmic Arithmetics with DD-Finite Functions Implementation and - - PowerPoint PPT Presentation

D-finite functions DD-finite functions Implementation Conclusions Algorithmic Arithmetics with DD-Finite Functions Implementation and Issues Antonio Jimnez-Pastor, Veronika Pillwein ISSAC (July 2018) Algorithmic Arithmetics with DD-Finite


slide-1
SLIDE 1

D-finite functions DD-finite functions Implementation Conclusions

Algorithmic Arithmetics with DD-Finite Functions

Implementation and Issues

Antonio Jiménez-Pastor, Veronika Pillwein

ISSAC (July 2018)

Algorithmic Arithmetics with DD-Finite Functions

slide-2
SLIDE 2

D-finite functions DD-finite functions Implementation Conclusions

Outline

1 D-finite functions 2 DD-finite functions 3 Implementation of closure properties 4 Conclusions

Algorithmic Arithmetics with DD-Finite Functions

slide-3
SLIDE 3

D-finite functions DD-finite functions Implementation Conclusions

Notation

Throughout this talk we consider: K: a computable field K[[x]]: ring of formal power series over K. Given a field F: VF(f ) = f , f ′, f ′′, ...F.

Algorithmic Arithmetics with DD-Finite Functions

slide-4
SLIDE 4

D-finite functions DD-finite functions Implementation Conclusions

D-finite functions

Definition Let f ∈ K[[x]]. We say that f is D-finite (or holonomic) if there exist d ∈ N and polynomials p0(x), ..., pd(x) such that: pd(x)f (d)(x) + ... + p0(x)f (x) = 0. We say that d is the order of f .

Algorithmic Arithmetics with DD-Finite Functions

slide-5
SLIDE 5

D-finite functions DD-finite functions Implementation Conclusions

Non-D-finite examples

There are power series that are not D-finite: Double exponential: f (x) = eex. Tangent: tan(x) = sin(x)

cos(x).

Gamma function: f (x) = Γ(x + 1). Partition Generating Function: f (x) =

n≥0 p(n)xn.

Algorithmic Arithmetics with DD-Finite Functions

slide-6
SLIDE 6

D-finite functions DD-finite functions Implementation Conclusions

DD-finite Functions

Definition Let f ∈ K[[x]]. We say that f is D-finite if there exist d ∈ N and polynomials p0(x), ..., pd(x) such that: pd(x)f (d)(x) + ... + p0(x)f (x) = 0.

Algorithmic Arithmetics with DD-Finite Functions

slide-7
SLIDE 7

D-finite functions DD-finite functions Implementation Conclusions

DD-finite Functions

Definition Let f ∈ K[[x]]. We say that f is DD-finite if there exist d ∈ N and D-finite elements r0(x), ..., rd(x) such that: rd(x)f (d)(x) + ... + r0(x)f (x) = 0.

Algorithmic Arithmetics with DD-Finite Functions

slide-8
SLIDE 8

D-finite functions DD-finite functions Implementation Conclusions

Examples

The set is bigger than the D-finite functions: f is D-finite ⇒ f is DD-finite, f (x) = eex ⇒ f ′(x) − exf (x) = 0, f (x) = tan(x) ⇒ cos(x)2f ′′(x) − 2f (x) = 0, f (x) = e

x

0 Jn(t)dt

⇒ f ′(x) − Jn(x)f (x) = 0

Algorithmic Arithmetics with DD-Finite Functions

slide-9
SLIDE 9

D-finite functions DD-finite functions Implementation Conclusions

Differentially Definable Functions

Definition Let f ∈ K[[x]]. We say that f is DD-finite if there exist d ∈ N and D-finite elements r0(x), ..., rd(x) such that: rd(x)f (d)(x) + ... + r0(x)f (x) = 0.

Algorithmic Arithmetics with DD-Finite Functions

slide-10
SLIDE 10

D-finite functions DD-finite functions Implementation Conclusions

Differentially Definable Functions

Definition Let f ∈ K[[x]] and R ⊂ K[[x]] a ring. We say that f is differentially definable over R if there exist d ∈ N and elements in R r0(x), ..., rd(x) such that: rd(x)f (d)(x) + ... + r0(x)f (x) = 0. D(R): differentially definable functions over R.

Algorithmic Arithmetics with DD-Finite Functions

slide-11
SLIDE 11

D-finite functions DD-finite functions Implementation Conclusions

Characterization Theorem

The following are equivalent: f (x) ∈ D(R). There are elements r0(x), ..., rd(x) ∈ R and g(x) ∈ D(R) such: rd(x)f (d)(x) + ... + r0(x)f (x) = g(x).

Algorithmic Arithmetics with DD-Finite Functions

slide-12
SLIDE 12

D-finite functions DD-finite functions Implementation Conclusions

Characterization Theorem

The following are equivalent: f (x) ∈ D(R). There are elements r0(x), ..., rd(x) ∈ R and g(x) ∈ D(R) such: rd(x)f (d)(x) + ... + r0(x)f (x) = g(x). Let F be the field of fractions of R: dim(VF(f )) < ∞

Algorithmic Arithmetics with DD-Finite Functions

slide-13
SLIDE 13

D-finite functions DD-finite functions Implementation Conclusions

Closure properties

f (x), g(x) ∈ D(R) of order d1, d2. F the field of fractions of R. a(x) algebraic over F of degree p. Property Is in D(R) Order bound Addition (f + g) d1 + d2 Product (fg) d1d2 Differentiation f ′ d1 Integration

f

d1 + 1 Be Algebraic a(x) p

Algorithmic Arithmetics with DD-Finite Functions

slide-14
SLIDE 14

D-finite functions DD-finite functions Implementation Conclusions

Closure properties

f (x), g(x) ∈ D(R) of order d1, d2. F the field of fractions of R. a(x) algebraic over F of degree p. Property Is in D(R) Order bound Addition (f + g) d1 + d2 Product (fg) d1d2 Differentiation f ′ d1 Integration

f

d1 + 1 Be Algebraic a(x) p − → Proof by direct formula − → Proof by linear algebra

Algorithmic Arithmetics with DD-Finite Functions

slide-15
SLIDE 15

D-finite functions DD-finite functions Implementation Conclusions

Vector spaces

Let R ⊂ K[[x]], F its field of fractions and VF(f ) the F-vector space spanned by f and its derivatives. The Characterization theorem provides f (x) ∈ D(R) ⇔ dim(VF(f )) < ∞

Algorithmic Arithmetics with DD-Finite Functions

slide-16
SLIDE 16

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0

Algorithmic Arithmetics with DD-Finite Functions

slide-17
SLIDE 17

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

1 Compute W ⊂ K[[x]] such that dim(W ) < ∞ and

VF(h) ⊂ W .

Algorithmic Arithmetics with DD-Finite Functions

slide-18
SLIDE 18

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

1 Compute W ⊂ K[[x]] such that dim(W ) < ∞ and

VF(h) ⊂ W .

2 Compute generators Φ = {φ1, ..., φn} of W .

Algorithmic Arithmetics with DD-Finite Functions

slide-19
SLIDE 19

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

1 Compute W ⊂ K[[x]] such that dim(W ) < ∞ and

VF(h) ⊂ W .

2 Compute generators Φ = {φ1, ..., φn} of W . 3 For i = 0, ..., n, compute vectors vi ∈ F n such that:

h(i)(x) = n

j=0 vijφj.

Algorithmic Arithmetics with DD-Finite Functions

slide-20
SLIDE 20

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

4 Set up the ansatz:

α0h(x) + ... + αnh(n) = 0.

Algorithmic Arithmetics with DD-Finite Functions

slide-21
SLIDE 21

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

4 Set up the ansatz:

α0h(x) + ... + αnh(n) = 0.

5 Solve the induced F-linear system for the variables αk.

Algorithmic Arithmetics with DD-Finite Functions

slide-22
SLIDE 22

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

4 Set up the ansatz:

α0h(x) + ... + αnh(n) = 0.

5 Solve the induced F-linear system for the variables αk. 6 Return A = αn∂n + ... + α1∂ + α0.

Algorithmic Arithmetics with DD-Finite Functions

slide-23
SLIDE 23

D-finite functions DD-finite functions Implementation Conclusions

The ansatz method

Specifications Input: A power series h(x) (f (x) + g(x), f (x)g(x) or a(x)) Output: An operator A ∈ R[∂] such that Ah = 0 Method

1 Compute W ⊂ K[[x]] such that dim(W ) < ∞ and

VF(h) ⊂ W .

2 Compute generators Φ = {φ1, ..., φn} of W . 3 For i = 0, ..., n, compute vectors vi ∈ F n such that:

h(i)(x) = n

j=0 vijφj.

Algorithmic Arithmetics with DD-Finite Functions

slide-24
SLIDE 24

D-finite functions DD-finite functions Implementation Conclusions

Derivation matrices

Let V be an F-vector space with derivation ∂ and Φ be n generators of V . Derivation matrix M ∈ F n×n is a derivation matrix w.r.t Φ if ∂

  

α1 . . . αn

   = M   

α1 . . . αn

   +   

α′

1

. . . α′

n

  

Algorithmic Arithmetics with DD-Finite Functions

slide-25
SLIDE 25

D-finite functions DD-finite functions Implementation Conclusions

Derivation matrices

Let V be an F-vector space with derivation ∂ and Φ be n generators of V . Derivation matrix M ∈ F n×n is a derivation matrix w.r.t Φ if ∂

  

α1 . . . αn

   = M   

α1 . . . αn

   +   

α′

1

. . . α′

n

  

Example: a derivation matrix in VF(f ) is the companion matrix Cf .

Algorithmic Arithmetics with DD-Finite Functions

slide-26
SLIDE 26

D-finite functions DD-finite functions Implementation Conclusions

Addition

Let f , g ∈ D(R) of orders d1 and d2 respectively. Consider h = f + g

Algorithmic Arithmetics with DD-Finite Functions

slide-27
SLIDE 27

D-finite functions DD-finite functions Implementation Conclusions

Addition

Let f , g ∈ D(R) of orders d1 and d2 respectively. Consider h = f + g Computing the space W+ and the generators Φ+ The proof of the closure property addition shows: W+ = V (f ) ⊕ V (g), hence the generators of W+ are the union of the generators of V (f ) and V (g): Φ+ = {f , f ′, ..., f (d1−1), g, g′, ..., g(d2−1)}

Algorithmic Arithmetics with DD-Finite Functions

slide-28
SLIDE 28

D-finite functions DD-finite functions Implementation Conclusions

Addition

Let f , g ∈ D(R) of orders d1 and d2 respectively. Consider h = f + g Computing the derivation matrix M+ w.r.t Φ+ M+ = Cf ⊕ Cg. Computing the initial vector v0 w.r.t Φ+ As we have h = f + g, the initial vector is: v0 = ed1,1 ⊕ ed2,1,

Algorithmic Arithmetics with DD-Finite Functions

slide-29
SLIDE 29

D-finite functions DD-finite functions Implementation Conclusions

Product

Let f , g ∈ D(R) of orders d1 and d2 respectively. Consider h = fg

Algorithmic Arithmetics with DD-Finite Functions

slide-30
SLIDE 30

D-finite functions DD-finite functions Implementation Conclusions

Product

Let f , g ∈ D(R) of orders d1 and d2 respectively. Consider h = fg Computing the space W∗ and the generators Φ∗ The proof of the closure property product shows: W = V (f ) ⊗ V (g). Hence the generators of W∗ are the tensor product of the generators of V (f ) and V (g): Φ = { fg, f ′g, ..., f (d1−1)g, fg′, f ′g′, ..., f (d1−1)g′, . . ., . . ., ... , . . ., fg(d2−1), f ′g(d2−1), ..., f (d1−1)g(d2−1)}

Algorithmic Arithmetics with DD-Finite Functions

slide-31
SLIDE 31

D-finite functions DD-finite functions Implementation Conclusions

Product

Let f , g ∈ D(R) of orders d1 and d2 respectively. Consider h = fg Computing the derivation matrix M∗ w.r.t Φ∗ M∗ = Cf ⊗ Id2 + Id1 ⊗ Cg. Computing the initial vector v0 w.r.t Φ∗ As we have h = fg, the initial vector is: v0 = ed1,1 ⊗ ed2,1 = (1, 0, 0, 0...),

Algorithmic Arithmetics with DD-Finite Functions

slide-32
SLIDE 32

D-finite functions DD-finite functions Implementation Conclusions

Coefficient growth

In the case R = D(K[x]), computing closure properties means computing D-finite closure properties on the coefficient level. Each sum possibly increases the order of the equation. Each product possibly increases the order of the equation. Each derivative possibly increases the order of the equation.

Algorithmic Arithmetics with DD-Finite Functions

slide-33
SLIDE 33

D-finite functions DD-finite functions Implementation Conclusions

Coefficient growth

In the case R = D(K[x]), computing closure properties means computing D-finite closure properties on the coefficient level. Each sum possibly increases the order of the equation. Each product possibly increases the order of the equation. Each derivative possibly increases the order of the equation. In practice: huge coefficient growth

Algorithmic Arithmetics with DD-Finite Functions

slide-34
SLIDE 34

D-finite functions DD-finite functions Implementation Conclusions

Lazy computations

Solution: skip computations until the end.

1 The coefficients of the original equations are converted to new

variables. In the end, apply closure properties

Algorithmic Arithmetics with DD-Finite Functions

slide-35
SLIDE 35

D-finite functions DD-finite functions Implementation Conclusions

Lazy computations

Solution: skip computations until the end.

1 The coefficients of the original equations are converted to new

variables.

2 Each derivative (requires closure properties) is transformed

into new variables. In the end, apply closure properties

Algorithmic Arithmetics with DD-Finite Functions

slide-36
SLIDE 36

D-finite functions DD-finite functions Implementation Conclusions

Lazy computations

Solution: skip computations until the end.

1 The coefficients of the original equations are converted to new

variables.

2 Each derivative (requires closure properties) is transformed

into new variables.

3 While solving the linear systems, some pivots need to be

chosen. In the end, apply closure properties

Algorithmic Arithmetics with DD-Finite Functions

slide-37
SLIDE 37

D-finite functions DD-finite functions Implementation Conclusions

Lazy computations

Solution: skip computations until the end.

1 The coefficients of the original equations are converted to new

variables.

2 Each derivative (requires closure properties) is transformed

into new variables.

3 While solving the linear systems, some pivots need to be

chosen.

A zero checking (applying closure properties) for choosing pivot.

In the end, apply closure properties

Algorithmic Arithmetics with DD-Finite Functions

slide-38
SLIDE 38

D-finite functions DD-finite functions Implementation Conclusions

Lazy computations

Solution: skip computations until the end.

1 The coefficients of the original equations are converted to new

variables.

2 Each derivative (requires closure properties) is transformed

into new variables.

3 While solving the linear systems, some pivots need to be

chosen.

A zero checking (applying closure properties) for choosing pivot. Each zero found is an algebraic relation: simplify the system.

In the end, apply closure properties

Algorithmic Arithmetics with DD-Finite Functions

slide-39
SLIDE 39

D-finite functions DD-finite functions Implementation Conclusions

Lazy computations

Solution: skip computations until the end.

1 The coefficients of the original equations are converted to new

variables.

2 Each derivative (requires closure properties) is transformed

into new variables.

3 While solving the linear systems, some pivots need to be

chosen.

A zero checking (applying closure properties) for choosing pivot. Each zero found is an algebraic relation: simplify the system.

In the end, apply closure properties

Algorithmic Arithmetics with DD-Finite Functions

slide-40
SLIDE 40

D-finite functions DD-finite functions Implementation Conclusions

Conclusions

Achievements Extended the framework of D-finite to a wider class of computable functions Implemented closure properties for DD-finite Code available for SAGE

Algorithmic Arithmetics with DD-Finite Functions

slide-41
SLIDE 41

D-finite functions DD-finite functions Implementation Conclusions

Conclusions

Future work Improve performance of the current code Study analytic properties of DD-finite functions Study combinatorial properties of DD-finite functions Study the analogue of DD-finite functions in sequences Generalize to other types of operators (q-holonomic). Multivariate case

Algorithmic Arithmetics with DD-Finite Functions

slide-42
SLIDE 42

D-finite functions DD-finite functions Implementation Conclusions

Thank you!

Contact webpage: https://www.dk-compmath.jku.at/people/antonio https://www.risc.jku.at/home/ajpastor SAGE code: http://git.risc.jku.at/gitweb/?p=ajpastor/diff_ defined_functions.git

Algorithmic Arithmetics with DD-Finite Functions