conlaw.tex 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353
  1. \documentclass[12pt]{article}
  2. %Sets size of page and margins
  3. \textheight 21cm
  4. \textwidth 15cm
  5. \title{Manual for CONLAW versions 1,2,3,4}
  6. \author{Thomas Wolf \\
  7. Department of Mathematics \\
  8. Brock University \\
  9. St.Catharines \\
  10. Ontario, Canada L2S 3A1 \\
  11. twolf@brocku.ca}
  12. \begin{document}
  13. \maketitle
  14. \section{Purpose}
  15. The procedures {\tt CONLAW1, CONLAW2, CONLAW3, CONLAW4}
  16. try to find conservation laws
  17. for a given single/system of differential equation(s) (ODEs or PDEs)
  18. \begin{equation}
  19. u^{\alpha}_J = w^{\alpha}(x,u^{\beta},...,u^{\beta}_K,...) \label{a1}
  20. \end{equation}
  21. {\tt CONLAW1} tries to find the conserved current $P^i$ by solving
  22. \begin{equation}
  23. \mbox{Div}\;\,P = 0 \;\;\; \mbox{modulo}\;\; (\ref{a1})
  24. \label{a2}
  25. \end{equation}
  26. directly. {\tt CONLAW3} tries to find $P^i$ and the characteristic
  27. functions (integrating factors) $Q^{\nu}$ by solving
  28. \begin{equation}
  29. \mbox{Div}\,P = \sum_{\nu} Q^{\nu}\cdot (u^{\nu}_J - w^{\nu}) \label{a3}
  30. \end{equation}
  31. identically in all $u$-derivatives.
  32. Applying the Euler operator (variational derivative) for each $u^{\nu}$
  33. on (\ref{a3}) gives a zero left hand side and therefore
  34. conditions involving only $Q^{\nu}$. {\tt CONLAW4} tries to solve these
  35. conditions identically in all $u$-derivatives and to compute $P^i$
  36. afterwards. {\tt CONLAW2}
  37. does substitutions based on (\ref{a1}) before solving these
  38. conditions on $Q^{\nu}$
  39. and therefore computes adjoined symmetries. These are
  40. completed, if possible, to conservation laws by computing $P^i$ from
  41. the $Q^{\nu}$.
  42. All four procedures have the same syntax. They have two parameters,
  43. both are lists. The first parameter specifies the equations (\ref{a1}),
  44. the second specifies the computation to be done. One can either specify an
  45. ansatz for $P^i, Q^{\nu}$ or investigate a general situation, only specifying
  46. the order of the characteristic functions or the conserved current. For a
  47. more detailed description see the file {\tt conca.tex}.
  48. The file {\tt CONLAW0.RED} contains subroutines used in all four versions.
  49. \section{The Syntax}
  50. The procedures {\tt CONLAWi} $\;\;$ i=1,2,3,4 are called through \\
  51. {\tt CONLAWi({\it problem,runmode}); } \\
  52. where i=1,2,3,4. Both parameters {\it problem, runmode} are lists.
  53. The first specifies the DEs to be investigated: \\
  54. {\it problem} ... \{{\it equations, ulist, xlist}\}
  55. \begin{tabbing}
  56. \hspace{0.5cm}
  57. {\it equations}\= ... \= list of equations,
  58. each has the form {\tt df(ui,..)=...} where \\
  59. \> \> the LHS (left hand side) {\tt df(ui,..)} is selected such that \\
  60. \> \> - The RHS (right h.s.) of an equations must not include \\
  61. \> \>$\;\;$ the derivative on the LHS nor a derivative of it. \\
  62. \> \> - The LHS of any equation should not occur in any other\\
  63. \> \>$\;\;$ equation nor any derivative of the LHS. \\
  64. \> \> If CONLAW3 or CONLAW4 are run where no substitutions\\
  65. \> \> are made then the LHS of equations can be {\tt df(ui,..)**n=...}\\
  66. \> \> where {\tt n} is a number. No difference is made between\\
  67. \> \> equations and constraints. \\
  68. \hspace{0.5cm}
  69. {\it ulist} \> ... \> list of function names, which can be chosen freely \\
  70. \> \> the number of functions and equations need not
  71. be equal \\
  72. \hspace{0.5cm}
  73. {\it xlist} \> ... \> list of variable names, which can be chosen freely
  74. \end{tabbing}
  75. The second parameter specifies the calculation to be done. \\
  76. {\it runmode} ... \{{\it minord, maxord, expl, flist, inequ}\}
  77. \begin{tabbing}
  78. \hspace{0.5cm}
  79. {\it minord} \= ... \= the minimum of the highest order of
  80. derivatives of u \\
  81. \> \> - in {\tt p\_t} for CONLAW1 where {\tt t} is the first variable in\\
  82. \> \> \ \ {\tt xlist} and \\
  83. \> \> - in {\tt q\_j} for CONLAW2,CONLAW3,CONLAW4 \\
  84. \hspace{0.5cm}
  85. {\it maxord} \> ... \> the maximum of the highest order of
  86. derivatives of u \\
  87. \> \> - in {\tt p\_i} for CONLAW1 where {\tt t} is the first variable in\\
  88. \> \> \ \ {\tt xlist} and \\
  89. \> \> - in {\tt q\_j} for CONLAW2,CONLAW3,CONLAW4 \\
  90. \hspace{0.5cm}
  91. {\it expl} \> ... \> (t/nil) whether or not the charac.\
  92. functions {\tt q\_i} or conserved \\
  93. \> \> current may depend explicitly on
  94. the variables of xlist \\
  95. \hspace{0.5cm}
  96. {\it flist} \> ... \> a list of unknown functions in any ansatz for
  97. {\tt p\_i,q\_j}, \\
  98. \> \> also all parameters and parametric functions in
  99. the equation \\
  100. \> \> that are to be calculated such that
  101. conservation laws exist,\\
  102. \> \> if there are no such unknown functions then
  103. {\it flist} is the \\
  104. \> \> empty list: \verb+{}+ \\
  105. \hspace{0.5cm}
  106. {\it inequ} \> ... \> a list of expressions non of which
  107. may be identically \\
  108. \> \> zero for the conservation
  109. law to be found, if there is no such \\
  110. \> \> expression
  111. then {\it inequ} is an empty list: \verb+{}+
  112. \end{tabbing}
  113. The procedures {\tt CONLAWi} return a list of conservation laws
  114. \verb+ {+$C_1,C_2,\ldots$\verb+}+, if no
  115. non-trivial conservation law is found they return the empty list \verb+{}+.
  116. Each $C_i$ representing a conservation law
  117. has the form \verb+ {{+$P^1,P^2,\ldots$\verb+},{+$Q^1,Q^2,\ldots$\verb+}}+.
  118. An ansatz for a conservation law can be formulated by specifying one
  119. or more of the components $P^i$ for {\tt CONLAW1}, one or more of the
  120. functions $Q^{\mu}$ for {\tt CONLAW2, CONLAW4} or one or more of
  121. $P^i, Q^{\mu}$ for {\tt CONLAW3}. The $P^i$ are input as {\tt p\_i} where
  122. {\tt i} in {\tt p\_i} stands for a variable name, and the $Q^{\mu}$ are
  123. input as {\tt q\_i} where {\tt i} stands for an index - the number of the
  124. equation in the input list {\it equations} with which {\tt q\_i} is
  125. multiplied.
  126. There is a restriction in the structure of all the expressions for
  127. {\tt p\_i, q\_j} that are specified: they must be homogeneous linear
  128. in the
  129. unknown functions or constants which appear in these expressions.
  130. The reason for this restriction is not
  131. for CRACK to be able to solve the resulting overdetermined system but for
  132. {\tt CONLAWi} to be able afterwards to extract the individual conservation
  133. laws from the general solution of the determining conditions.
  134. All such unknown functions and constants must be
  135. listed in {\it flist} (see above). The dependencies of such functions
  136. must be defined before calling {\tt CONLAWi}. This is done with the
  137. command {\tt DEPEND}, e.g. {\tt DEPEND f,t,x,u\$ } to specify $f$ as a
  138. function of $t,x,u$. If one wants to have $f$ as a function of derivatives
  139. of $u(t,x)$, say $f$ depending on $u_{txx}$, then one can {\it not} write \\
  140. \verb+ DEPEND f,df(u,t,x,2)$ + \\
  141. but instead \\
  142. \verb+ DEPEND f,u!`1!`2!`2$ + \\
  143. if {\it xlist} has been specified as \verb+ {t,x}+, because {\tt t} is the
  144. first variable and {\tt x} is the second variable in {\it xlist} and {\tt u}
  145. is differentiated ones wrt.\ {\tt t} and two times wrt.\ {x} we therefore get
  146. \verb+ u!`1!`2!`2+. The character {\tt !} is the exempt character to allow
  147. special characters like ` to occur in an identifier name.
  148. It is possible to add extra conditions like PDEs for $P^i, Q^{\mu}$ as a list
  149. {\tt cl\_condi} of expressions that shall vanish. \hspace{6pt}
  150. \noindent Remarks:
  151. \begin{itemize}
  152. \item The input to {\tt CONLAW1, CONLAW2, CONLAW3, CONLAW4} is the
  153. same apart from:
  154. \begin{itemize}
  155. \item an ansatz for $Q^{\nu}$ is ignored in {\tt CONLAW1}
  156. \item an ansatz for $P^i$ is ignored in {\tt CONLAW2, CONLAW4}
  157. \item the meaning of mindensord, maxdensord is different in {\tt CONLAW1}
  158. on one hand and {\tt CONLAW2,CONLAW3,CONLAW4} on the other (see above).
  159. \end{itemize}
  160. \item
  161. It matters how the differential equations are input, i.e. which
  162. derivatives are eliminated. For example, the Korteweg - de Vries
  163. equation if input in the form $u_{xxx}=-uu_x-u_t$ instead of
  164. $u_t=-uu_x-u_{xxx}$
  165. in {\tt CONLAW1} and choosing {\tt maxdensord}=1 then
  166. $P^i$ will be of at most first order, Div $P$ of second order and $u_{xxx}$
  167. will not be substituted and no non-trival conservation laws can be found.
  168. This does not mean that one will not find low order conservation laws at
  169. all with the substitution $u_{xxx}$ one only has to go to
  170. {\tt maxdensord}=2 with longer computations as a consequence compared to the
  171. input $u_t=-uu_x-u_{xxx}$ where {\tt maxdensord}=0 is enough to find
  172. non-trivial conservation laws.
  173. \item The drawback of using $u_t=\ldots$ compared with $u_{xxx}=\ldots$
  174. is that when seeking all conservation laws up to some order
  175. then one has to investigate a higher order ansatz, because with each
  176. substitution $u_t=-u_{xxx}+\ldots$ the order increases by 2.
  177. For example, if all conservation laws of order up to two in $Q^{\nu}$
  178. are to be determined then in order to include a $u_{tt}$-dependence the
  179. dependence of $Q^{\nu}$ on $u_x$ up to $u_{6x}$ has to be considered.
  180. \item Although for any equivalence class of conserved currents $P^i$
  181. differing only by a curl, there exist characteristic functions $Q^{\mu}$,
  182. this need not be true for any particular $P^i$.
  183. Therefore one cannot specify a known density $P^i$ for {\tt CONLAW3}
  184. and hope to calculate the remaining $P^j$ and the corresponding $Q^{\mu}$
  185. with {\tt CONLAW3}. What one
  186. can do is to use {\tt CONLAW1} to calculate the remaining components
  187. $P^j$ and from this a trivial conserved
  188. density $R$ and characteristic functions $Q^{\nu}$ are computed such that
  189. \[ \mbox{Div}\,(P-R) = \sum_{\nu} Q^{\nu}\cdot (u^{\nu}_J - w^{\nu}). \]
  190. \item The $Q^{\mu}$ are uniquely determined only modulo $\Delta=0$.
  191. If one makes an ansatz for $Q^{\mu}$ then this freedom should be removed
  192. by having
  193. the $Q^{\mu}$ independent of the LHS's of the equations and independent of
  194. derivatives of the LHS's of them. If the $Q^{\mu}$ were allowed to depend on
  195. anything, then (\ref{a3}) could simply be solved for one $Q^{\nu}$ in terms of
  196. arbitrary $P^j$ and other arbitrary $Q^{\rho}$, giving $Q^{\nu}$ that are
  197. singular for solutions of the differential equations as the expression
  198. of the differential equation would appear in the denominator of $Q^{\nu}$.
  199. \item Any ansatz for $P^i,Q^{\nu}$ should
  200. as well be independent of the LHS's of the equations (\ref{a1}) and
  201. independent of derivatives of the LHS's of (\ref{a1}).
  202. \item If in equation (\ref{a3}) the right hand side is of order $m$ then
  203. from the conserved current $P^i$ a trivial conserved current can be
  204. subtracted such that the remaining conserved current is at most of order $m$.
  205. If the right hand side is linear in the highest derivatives of order
  206. $m$ then subtraction of a trivial conserved current can even achieve a
  207. conserved current of order $m-1$. The relevance of this result is that
  208. if the right hand side is known to be linear in the highest derivatives
  209. then for $P^i$ an ansatz of order $m-1$ is only necessary. To take
  210. advantage of this relation
  211. if the right hand side is known to be linear in the highest
  212. derivatives, a flag {\tt quasilin\_rhs} can be set to {\tt t} (see
  213. below).
  214. \end{itemize}
  215. \section{Flags, parameters}
  216. \verb+ LISP (PRINT_:= NIL/0/1/ ...)$+ \\
  217. \verb+print_=nil+ suppresses all CRACK output, for \verb+print_=n+
  218. ($n$ an integer)
  219. {\tt CRACK} prints only equations with at most $n$ factors in its terms.
  220. %\verb+ LISP (LOGOPRINT_:=t/nil)$+ \\
  221. %to print/not print a logo at the start of {\tt CONLAWi}
  222. \verb+ CRACKHELP()$+ \\
  223. to show other flags controling the solution of the overdetermined PDE-system,
  224. \verb+ OFF BATCH_MODE$+ \\
  225. to solve the system of conditions with {\tt CRACK} interactively.
  226. \verb+ LISP(QUASILIN_RHS:=T)$+ \\
  227. reduces in the ansatz for $P^i$ the order to $m-1$ if the order of the
  228. right hand side is $m$. This can be used to speed up computations if
  229. the right hand side is known to be linear in the highest derivatives
  230. (see the note above).
  231. \section{Requirements}
  232. {\tt REDUCE 3.6} and
  233. the files {\tt CRACK.RED, CONLAW0.RED}, one of the files
  234. {\tt CONLAW1.RED, CONLAW2.RED, CONLAW3.RED, CONLAW4.RED} depending which
  235. program should be used and all files {\tt CR*.RED} which
  236. are read in from {\tt CRACK.RED}.
  237. One either has to read in files with \\
  238. \verb+ IN "crack.red","conlaw0.red","conlaw1.red"$+ \\
  239. \noindent (and appropriate paths) or compile them before with
  240. \begin{verbatim}
  241. FASLOUT "crack"$
  242. IN "crack"$
  243. FASLEND$
  244. FASLOUT "conlaw0"$
  245. IN "conlaw0.red"$
  246. FASLEND$
  247. FASLOUT "conlaw1"$
  248. IN "conlaw1.red"$
  249. FASLEND$
  250. BYE$
  251. \end{verbatim}
  252. and load them afterwards with \verb+ LOAD crack,conlaw0,conlaw1$+ \\
  253. \verb+conlaw2, conlaw3, conlaw4+ are treated like {\tt conlaw1}.
  254. \section{Examples}
  255. Below a {\tt CRACK}-procedure {\tt nodepnd} is used to clean up
  256. after each run and delete all dependencies of each
  257. function in the list of functions in the argument of {\tt nodepnd}.
  258. More details concerning these examples are given when running
  259. the file {\tt conlaw.tst}.
  260. \verb+ lisp(print_:=nil); + to suppress output from CRACK
  261. \begin{itemize}
  262. \item a single PDE:
  263. \begin{verbatim}
  264. depend u,x,t$
  265. conlaw1({{df(u,t)=-u*df(u,x)-df(u,x,3)}, {u}, {t,x}},
  266. {0, 1, t, {}, {}})$
  267. nodepnd {u}$
  268. \end{verbatim}
  269. \item a system of equations:
  270. \begin{verbatim}
  271. depend u,x,t$
  272. depend v,x,t$
  273. conlaw1({{df(u,t)=df(u,x,3)+6*u*df(u,x)+2*v*df(v,x),
  274. df(v,t)=2*df(u,x)*v+2*u*df(v,x) },
  275. {u,v}, {t,x}},
  276. {0, 1, t, {}, {}})$
  277. nodepnd {u,v}$
  278. \end{verbatim}
  279. \item a system of equations with ansatz:
  280. \begin{verbatim}
  281. depend u,x,t$
  282. depend v,x,t$
  283. depend r,t,x,u,v,u!`2,v!`2$
  284. q_1:=r*df(u,x,2)$
  285. conlaw2({{df(u,t)=df(v,x),
  286. df(v,t)=df(u,x) }, {u,v}, {t,x}},
  287. {2, 2, t, {r}, {r}})$
  288. nodepnd {u,v,r}$
  289. \end{verbatim}
  290. \item for the
  291. determination of parameters, such that conservation laws exist:
  292. \begin{verbatim}
  293. depend u,x,t;
  294. conlaw1({{df(u,t)=-df(u,x,5)-a*u**2*df(u,x)
  295. -b*df(u,x)*df(u,x,2)-c*u*df(u,x,3)},
  296. {u}, {t,x}},
  297. {0, 1, t, {a,b,c}, {}});
  298. nodepnd {u};
  299. \end{verbatim}
  300. \item for first integrals of an ODE-system including the determination of
  301. parameter values s,b,r such that conservation laws exist:
  302. \begin{verbatim}
  303. depend {x,y,z},t;
  304. depend a1,x,t;
  305. depend a2,y,t;
  306. depend a3,z,t;
  307. p_t:=a1+a2+a3;
  308. conlaw2({{df(x,t) = - s*x + s*y,
  309. df(y,t) = x*z + r*x - y,
  310. df(z,t) = x*y - b*z},
  311. {x,y,z},{t}
  312. },
  313. {0,0,t,{a1,a2,a3,s,r,b},{}});
  314. nodepnd {x,y,z,a1,a2,a3};
  315. \end{verbatim}
  316. \end{itemize}
  317. \end{document}