Appendix A KdV Solitons via Inverse Scattering by G. E. Sarty The inverse scattering method for finding soliton solutions of the KdV equa­ tion as presented in Section 4.2 can be automated with the symbolic manipula­ tion program Mathematica (and probably by other such programs as well). At the end of this appendix is a Mathematica routine that will generate n-soliton solutions for the KdV equation Ut - 6UUx + Uxxx = 0 subject to the initial condition of U(x, t = 0) = -n(n + 1)sech2(x). To use the program (assuming you have purchased Mathematica), type the code as given into a file called "invskat.m". Then start up Mathematica and type «invskat .m. This loads the soliton generation code. Then to generate, say, a 2-soliton solution type soliton [2] ; or soli ton [3] for a 3-soliton solu­ tion, etc. The solution is then returned as the function u[x_. tJ. The code 277 278 Appendix A. KdV Solitons via Inverse Scattering has been tested for up to 6 solitons and no attempt has been made to simplify the answer to any extentj it is given in terms of exponential functions. The program of Appendix B simplifies answers in terms of hyperbolic trigonometric functions which gives a neater looking final result. The logic of the program follows that given in Chapter 4 and comments in the code explain the steps followed. We give a brief elaboration here of the steps. First we must use the result that the eigenfunctions of the linear Schrodinger equation at t = 0 for the initial data under our consideration are the associated Legendre functions in the variable e = tanh(z). Symbolically, we write the associated Legendre functions as p;:'(e) where n is the number of solitons sought and 1 ~ m ~ n. (In the code, LegendreP[n.m.Tanh[x]] is P;:'(tanh(z)).) It is known that 1 [pm(e)]2 ~ = .!. (n + m)! 1-1 n 1 - e2 m (n - m)! and this is used to normalize the eigenfunction <Pm(z) = P;:'(tanh(z)) to <Pm(z) = (~~-:)t <pm(z) (which is Phi [m.x] in the code). Next, Cm (0) is calculated as Co [m] in the program. Since Mathematica has trouble doing infinite limits for complicated expressions involving hyperbolic trigonometric functions, some substitutions are done that mimic the calculation as it would be done manually. With Cm(O) in hand, Cm(t), written as Cm[m. t] in the code, can be easily calculated by a formula in Theorem 4.2. Now the kernel function B(e, t), written as B[y_. tJ, can be determined using the fact that R(k, t) = O. The program is now ready to solve the Gelfand­ Levitan equation for K(z, Yj t) using the method of separation of variables. That is, we assume that n K(z,Yjt) = L Lm(z,t)e-k ",11 m=l where K(z,Yjt) is K[x_.y_.tJ and Lm(z,t) is L[m] at this point in the pro­ gram. Note that km = m in our case. The expression for K(z, Yj t) is sub­ stituted into the Gelfand-Levitan equation ( GL in the code). Terms involving e-k ",11 for 1 ~ m ~ n are separated out. That being done, the coefficient functions Lm(z,t) and hence K(z,Yjt) can be solved for algebraically. Finally, the solution is calculated as {) U(z, t) = -2 {)z K(z, Zj t). The symbolic program written in Mathematica is given below: 279 ( ....................................................................... .) (. .) (. • IIVSKAT." -- A "athematica soliton generator. This •• ) (.. package contains subroutines that generate n-soliton solutions •• ) (.. ~or the KdV equation: •• ) (. .) (. • U - 6 U U + U = 0 •• ) (. • t x xxx •• ) (. ..) (. • subject to the initial condition •• ) (. • 2 •• ) (. • U(x,t=O) = -n(n+1) sech [x]. • .) (. ..) (. • The inverse scattering method and the Gel~and-Levitan •• ) (. • equation is used. • .) (. • Programmed by: •• ) (. • G. Sarty, July 1992 •• ) (. ..) ( ........................................................................ ) invskat: : usage = "The package invskat.m returns n soli ton solutions to the standard KdV equation subject to the initial condition U(x,t=O) = -n(n+1) sech[x]·2 using the inverse scattering method. For more in~ormation, type '?soliton." soliton: :usage = "soliton[n] will return an n soliton solution to the standard KdV equation where n is an integer." sOliton[n_Integer] := Block[{m,Phi,Co,Cm,B,K,L,GL,y,eqn,k}, I~[ n <= 0, Return["Use a positive integer."] ]; (. define normalized eigen~unctions: .) Do[ Phi[m,x] = (-1)·m Sqrt[ m(n-m)!/(n+m)! ] LegendreP[n,m,Tanh[x]]; Phi[m,x] = Factor[Phi[m,x]]; Phi[m,x] = Phi[m,x] II. {(1 - u_) (1 + u_) -> (1 - u·2), (-1 + u_) (1 + u_) -> - (1 - u·2), (1 - u_)·k_ (1 + u_)·k_ -> (1 - u·2)·k, (-1 + u_)·k_ (1 + u_)·k_ -> - (1 - u·2)·k}; Phi[m,x] Phi[m,x] II. {(1 - Tanh[x_]·2) -> Sech[x]·2, (-1 + Tanh[x_]·2) -> -Sech[x]·2, (1 - Tanh[x_]·2)·(k_/2) -> Sech[x]·k, (-1 + Tanh[x_]·2)·(k_/2) -> -Sech[x]·k, (1 - Tanh[x_]·2)·k_ -> Sech[x]·(2 k), (-1 + Tanh[x_]·2)·k_ -> -Sech[x]·(2 k)}; Phi[m,x] = PowerExpand[Phi[m,x]], {m,1,n,1}] ; (. de~ine Cm(O) .) Do[ Co[m] Phi[m,x] E·(m x); Co[m] Co[m] II. Sech[x] -> 2/(E·x + E·(-x»; Co[m] Co[m] II. Tanh[x] -> 1; Co[m] = ExpandAII[Co[m]]; 280 Appendix A. KdV Solitons via Inverse Scattering top = lumerator[Co[m]]/E-(m x); bot • ExpandAll[Denominator[Co[.]]/E-(m x)]; Co[m] = top/bot; Co[m] • Limit[ Co[m] , x -> In£inity], {m,l,n,H] ; Do[ Cm[m,t] = Co[m] E-(4 m-3 t), {m,l,n,H] ; (. de£ine B(y,t) .) Do[ B[y_,t_] := Sum[Cm[m,t]-2 E-(-m y), {m,l,n}], {m,l,n,H] ; (. using separation of variables, define l(x,y;t) .) (. substitute into the Gelfand-Levitan equation .) (. first solving the integral of B[y+z,t] l[x,z,t] from x to in£inity, .) (. vrt z: .) in£int = ExpandA11[B[y+z,t] l[x,z,t]] II. E-(b_ + c_ z) -> -E-(b + c x) / c; GL = l[x,y,t] + B[x+y,t] + infint; (. pullout E-(-km y) terms: .) GL = ExpandA11[GL]; GL = ExpandAll[E-«n+l) y) GL]; Do[ GL = GL II. {E-(h_ + m y) -> y[m] E-h, E-(m y) -> y[m]}, {m,l,n,H] ; Do[ eqn[m] = GL; Do[ I£[k == m,eqn[m]=eqn[m] II. y[k] -> l,eqn[m]=eqn[m] II. y[k] -> 0], {k,l,n,H] , {m,l,n ,H]; (. solve for L[m] .) system = {eqn[l] == O}; vars = {L[1]}; Do[ system = Append [system , eqn[m] == 0]; vars = Append[vars, L[m]] , {m,2,n,l}] ; soln = Solve[system,vars]; (. use L[m] to reconstruct l[x,x,t] .) Do[ l[m] = Together[Expand[Part[Part[Part[soln,l],m],2]]], {m,l,n,H]; 281 k[x_,t_] := Together[Expand[Sum[l[mJ E-(-m x), {m,1,n}]]]; (. finally, calculate the solution, u, of the initial value problem .) Return[u[x_,t_] = Together[Expand[-2 D[k[x,t] ,x]]]] ] Appendix B KdV Solitons via Backlund Transform by G. E. Sarty B.1 Backlund Transform Program Biicklund transform and the nonlinear superposition principle were described in section 4.4. In this subsection, we describe how to use a symbolic computer code to implement the nonlinear superposition principle automatically to find multiple soliton solutions of the initial value problems for the KdV equation. The code is written in Mathematica and given in the later part of this subsec­ tion. Specifically, the code has been designed to calculate soliton solutions to the KdV equation using the initial condition U(z, t = 0) = -n(n+ 1) sech 2 (z). The results of 2-,3-, 4-, 5-, 6-, and 7-soltion solutions computed from this code are presented in sections B.2, B.3, B.4, B.5, B.6 and B.7 respectively. The computer program essentially has two parts. One part is a set of routines that enables specific hyperbolic trigonometric function simplifications to be done. This set of routines is called "hyppac.m" . The other part calculates 283 284 Appendix B. KdV Solitons via Backlund Transform the soliton solutions. These two parts have been put into a package called "solipac.m". It can be used by copying the code into a file called "solipac.m" and entering «solipac.m at the Mathematica prompt. Typing soliton[N] will cause the program to generate an N -soliton solution. One may like to test the code by typing in soliton[l] or soliton[2] to generate 1- and 2-soliton solutions. These calculations take only a few seconds on any workstation. If you desire only to calculate an expression for the soliton ladder, type ladder [N] . After the ladder calculation is completed, if one want to see the cor­ responding soltion, simply type finish. For instance, the command ladder [2] generates a 2-soliton ladder. Then the command finish will generate a 2- soliton solution. The program has been tested up to 7 solitons (the 7-soliton solution took about a week's worth of CPU time on a SUN Sparcstation 1+ (1991)). The hyperbolic function routines are pretty much self-explanatory with the locally defined hyperbolic functions being designated with small first letters (e.g. sinh, cosh) to avoid confusion with Mathematica's definitions (Sinh, Cosh, etc.). The soliton calculation itself proceeds by calculation of the the func­ tions Wen) via the nonlinear superposition principle derived using the Backlund transform in section 4.4.
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages51 Page
-
File Size-