Example 3.5 The method described for example 3.4 can be used to solve boundary value problems. Consider the boundary value problem given by the Airy differential equation: (3.16) The procedure for solving this boundary value problem is the same as that of section 3.1.2 except that instead of the exponential matrix, the matrizant must be used. > restart: > with(linalg):with(plots): Warning, the protected names norm and trace have been redefined and unprotected Warning, the name changecoords has been redefined > N:=2; > nvars:=6; > Eq:=diff(y(x),x$2)=x*y(x); > A:=matrix(2,2,[0,1,x,0]); > Y0:=matrix(N,1,[1,c[1]]); > id:=Matrix(N,N,shape=identity); > X1:=matrix(N,N);X2:=matrix(N,N); > X1:=map(int,subs(x=x1,evalm(A)),x1=0..x); > mat := evalm(id + X1) ; > for i from 2 to nvars do S:=evalm( subs(x=x1,evalm(A))&*subs(x=x1,evalm(X1)) ):X2:= map(int,S,x1=0..x):mat := evalm(mat +X2) : X1:=evalm(X2):od : > evalm(mat) ; > sol:=evalm(mat&*Y0); > y:=sol[1,1]; > dydx:=sol[2,1]; Now the unknown constant c1 is solved by using the boundary condition at x = 1. > bc2:=subs(x=1,dydx)=0; > c[1]:=solve(bc2,c[1]); > y:=eval(y); Readers can verify this series solution with the series solution obtained by using Maple's 'dsolve' command.