# Message Boards

Answer
(Unmark)

GROUPS:

4

# Simplify 3rd order ODE to v''' + Z v = F a general formula

Posted 3 months ago

A third-order linear ordinary differential equation in general has the form u'''+au''+bu'+cu=f u=u[t] a,b,c,f t v'''+Zv=F v'' v' w''[t]= 2 p
Deriving the formula A general third-order linear ordinary differential equation has the form u'''[t]+a[t]u''[t]+b[t]u'[t]+c[t]u[t]=f[t] ( 1 ) The equation is currently written in terms of u[t] v[t] u[t]=A[t]v[ϕ[t]] ( 2 ) Effectively, this change of variables replaces t ϕ A[t] A 3 (ϕ') 3 d 3 dϕ 2 (ϕ') 2 (ϕ') 2 d 2 dϕ dv dϕ ( 3 ) That is how the ODE is written in terms of the variables v ϕ d dϕ ϕ ' A ϕ A ϕ 2 d 2 dϕ dv dϕ aA 2 k 2 k ( 4 ) Here, k≡ϕ'[t] dϕ/dt A 2 k a+3 A' A k' k t ∫ t 1 dt 1 ∼ A[t] A= 1 1 3 t ∫ t 1 dt 1 1 k ( 5 ) Plugging this in to the second equation in (4), we get 3 2 k' k k'' k 1 3 2 a w[t]≡ 1 k[t] ( 6 ) The equation 3 2 k' k k'' k 1 3 2 a w w''[t]= 2 p ( 7 ) Where 2 p 2 a[t] 12 a'[t]-b 4 w[t]≡1 k[t] k k= 1 2 w w[t]≡1 k[t] k!=0 k[t]≡ϕ'[t] ϕ[t] k!=0 ϕ t ϕ 1 A[t] A[t]=Exp- 1 3 t ∫ t 1 dt 1 2 w ( 8 ) Making 1 A k[t]≡ϕ'[t] ϕ[t] k[t]=1/ 2 w ϕ[t]= t ∫ dt 1 2 w t 1 ( 9 ) And this is it! The problem is solved. If we substitute u[t]=A[t]v[ϕ[t]] A ϕ v'' v' 3 d 3 dϕ ( 10 ) Where Z F Z[ϕ]≡ 1 54 6 w 3 a[t] ′ a ′ b ′′ a 6 w A[t] ( 11 )
Code used to do the calculations
Computer implementation The function below executes the algorithm described above. It first computes 2 p w[t] ϕ,A,Z,F w A,ϕ,Z ϕ,A,Z,F w In[]:= ClearAll[findϕAZF];findϕAZF[a_Function, b_Function, c_Function, f_Function] := Block t, p2, w, possiblew, wIndicator, Aval , p2 = 2 a[t] 12 a'[t] - b[t] 4 1 3 2 w[t] 1 2 w[t] 1 54 6 w[t] 3 a[t] ′ a ′ b ′′ a 6 w[t] Aval In[]:= ClearAll[getZFform];getZFform[{ϕ -> ϕval_, A -> Aval_, Z -> Zval_, F -> Fval_}] := Block[{texpr}, texpr = Solve[ϕval == ϕ, t]; Which[ SameQ[Head[texpr], Solve], Return[$Failed], Length[texpr] >= 1, texpr = texpr[[1, 1, 2]]; u[t] == Aval v[ϕ], t == texpr, Z -> Zval /. t -> texpr, F -> Fval /. t -> texpr ]]; Here is how to use this method: 1 .Get the ODE to the form u'''[t]+a[t]u''[t]+b[t]u'[t]+c[t]u[t]=f[t] a[t],b[t],c[t],f[t] 2 .Run findϕAZF to find ϕ[t],A[t],Z[t],F[t] 3 .The expressions for ϕ[t],A[t],Z[t],F[t] 4 .Run getZFform to find Z F ϕ Simple! Of course, this isn’t going to work with each and every ODE. Often, the program is unable to find ϕ[t] ϕ[t] t[ϕ]
Simple example: u'''+u''+u'+u=Log[6+ 2 t The equation is very simple, which makes it a great initial example to show that the formula works. On practice we could just solve it explicitly without bothering to get it to the v'''+Zv=F a=b=c=1 f[t]=Log[6+ 2 t In[]:= findϕAZF[1&,1&,1&,Function[t,Log[6+ 2 t Out[]= ϕ 6 Sint 6 2 1 t 6 1 2 t 6 -t/3 2 1 t 6 2 t 6 20 27 6 1 t 6 2 t 6 t/3 2 t 4 1 t 6 2 t 6 Step 3: The choice of constants 1 2 1 2 In[]:= %/.{C[1]1,C[2]0} Out[]= ϕ 6 Tant 6 -t/3 2 Cos t 6 20 27 6 Cos t 6 t/3 4 Cos t 6 2 t Step 4: Run getZFform: In[]:= getZFform[%] Out[]= u[t] -t/3 2 Cos t 6 t 6 ϕ 6 1 1 20 27 6 CosArcTan ϕ 6 1 1 2 3 ϕ 6 1 4 CosArcTan ϕ 6 1 2 ϕ 6 1 1 The expression contains an arbitrary constant 1 t[ϕ] 1 In[]:= %/.C[1]->0 Out[]= u[t] -t/3 2 Cos t 6 6 ArcTanϕ 6 20 27 3 2 ϕ 6 2 3 ϕ 6 2 ArcTan ϕ 6 2 2 ϕ 6 So, the ODE can be written as 3 d 3 dϕ 160 3 (6+ 2 ϕ 2 3 ϕ 6 2 ArcTan ϕ 6 2 (6+ 2 ϕ If we now substitute u[t]=A[t]v[ϕ] u'''[t]+u''[t]+u'[t]+u[t]=Log[6+ 2 t In[]:= Simplifyu'''[t]+u''[t]+u'[t]+u[t]/.u->Function[t,A[t]v[ϕ[t]]]/.ϕFunctiont, 6 Tant 6 -t/3 2 Cos t 6 160 3 (6+ 2 ϕ 2 3 ϕ 6 2 ArcTan ϕ 6 2 (6+ 2 ϕ Out[]= Log[6+ 2 t Notice that the result only makes sense for -π/2<t<π/2 ϕ= 6 Tant 6 t=±π/2
A more complicated example: u'''+tu''+u'+u=Sin[t] The ODE u'''+tu''+u'+u=Sin[t] ϕ[t] In[]:= findϕAZF[#&,1&,1&,Function[t,Sin[t]]] Out[]= ϕ 2 2 1 2 t 1/4 3 1 1 2 t 1/4 3 - 2 t 6 2 2 1 2 t 1/4 3 1 1 2 t 1/4 3 1 27 3 t 6 2 1 2 t 1/4 3 1 1 2 t 1/4 3 2 t 6 4 2 1 2 t 1/4 3 1 1 2 t 1/4 3 The integral can be evaluated approximately using methods such as Taylor series or numerically; for simplicity, the example will go with the latter option. Choose 1 2 In[]:= %/.{C[1]->1,C[2]->0} Out[]= ϕ 2 ParabolicCylinderD- 1 2 t 1/4 3 - 2 t 6 2 ParabolicCylinderD- 1 2 t 1/4 3 1 27 3 t 6 ParabolicCylinderD- 1 2 t 1/4 3 2 t 6 4 ParabolicCylinderD- 1 2 t 1/4 3 Now, the equation can be written as 3 d 3 dϕ 1 27 3 t 6 ParabolicCylinderD- 1 2 t[ϕ] 1/4 3 2 t 6 4 ParabolicCylinderD- 1 2 t 1/4 3 The function ϕ[t] t[ϕ] ϕ= 1 2 ParabolicCylinderD- 1 2 t |