Makena Preston

Answered

2022-07-19

i have this differential equation and actually i am not sure if i have solved it right with Euler's improved method :

${z}^{\u2033}={f}_{z}-{C}_{z}\ast |{z}^{\prime}|\ast {z}^{\prime}$

${z}^{\prime}=u$

${u}^{\prime}={z}^{\u2033}={f}_{z}-{C}_{z}\ast |u|\ast u$

Improved Euler Method :

${K}_{1}=fz-Cz\ast |{u}_{n}|\ast {u}_{n}$

${K}_{2}=fz-({C}_{z}\ast |{u}_{n}+h\ast {K}_{1}|)\ast ({u}_{n}+h\ast {K}_{1})$

so we get :

${z}_{n+1}=zn+h\ast {u}_{n}$

${u}_{n+1}={u}_{n}+\frac{h}{2}\ast ({K}_{1}+h\ast {K}_{2})$

Is this right ?

P.S (fz , Cz are just variables with numbers not function inputs)

${z}^{\u2033}={f}_{z}-{C}_{z}\ast |{z}^{\prime}|\ast {z}^{\prime}$

${z}^{\prime}=u$

${u}^{\prime}={z}^{\u2033}={f}_{z}-{C}_{z}\ast |u|\ast u$

Improved Euler Method :

${K}_{1}=fz-Cz\ast |{u}_{n}|\ast {u}_{n}$

${K}_{2}=fz-({C}_{z}\ast |{u}_{n}+h\ast {K}_{1}|)\ast ({u}_{n}+h\ast {K}_{1})$

so we get :

${z}_{n+1}=zn+h\ast {u}_{n}$

${u}_{n+1}={u}_{n}+\frac{h}{2}\ast ({K}_{1}+h\ast {K}_{2})$

Is this right ?

P.S (fz , Cz are just variables with numbers not function inputs)

Answer & Explanation

Trace House

Expert

2022-07-20Added 7 answers

There are several small errors that would sum up to a more grossly incorrect output. As a system with multiple components, you need to compute the intermediary slopes at all stages for all components, that is, additionally for the slopes in $z$ direction

$\begin{array}{rl}{L}_{1}& =u\\ {L}_{2}& =u+h{K}_{1}\end{array}$

Then the equations for the step are

$\begin{array}{rl}{u}_{+1}& =u+\frac{h}{2}({K}_{1}+{K}_{2})\\ {z}_{+1}& =z+\frac{h}{2}({L}_{1}+{L}_{2})=z+hu+\frac{{h}^{2}}{2}{K}_{1}\end{array}$

$\begin{array}{rl}{L}_{1}& =u\\ {L}_{2}& =u+h{K}_{1}\end{array}$

Then the equations for the step are

$\begin{array}{rl}{u}_{+1}& =u+\frac{h}{2}({K}_{1}+{K}_{2})\\ {z}_{+1}& =z+\frac{h}{2}({L}_{1}+{L}_{2})=z+hu+\frac{{h}^{2}}{2}{K}_{1}\end{array}$

Bruno Thompson

Expert

2022-07-21Added 9 answers

Thanks alot for the comprehensive response

Most Popular Questions