0

The original ODE I had was $4f‴+ff″+2(f′)²=0$ with $f(0)=α,f′(0)=β$

Now I want to use Composite Trapezoidal Rule for this integral : $$ ∫(f-α)(f′)²dη = 1 \qquad \text{from}\,\, 0 \,\,\text{to}\,\, ∞ $$ Please help me to find the value of $α$. It would be very nice if anyone help me with the MATLAB code specially how to define the function for this problem.

V. Vancak
  • 16,444

1 Answers1

0

Why use the trapezoidal method, when you can package all into the ODE solver? Use

[ f0', f1', f2', g', h' ] = [ f1, f2, -0.25*(f0*f2+2f1^2), f1^2, f*f1^2 ]

and solve for boundary conditions

f0(0)=a, f1(0)=b, f2(0)=c, g(0)=0, h(0)=0

and at the other end the asymptotic conditions and equations

f1(N)=0, f2(N)=0, a*g(N)-h(N)=0

for some large upper interval end N.

Lutz Lehmann
  • 126,666
  • But i don't know the value of a and b. is this problem solvable through trapezoidal method ? – Md. Taj Uddin Raju Mar 22 '16 at 18:52
  • That is why you solve a boundary value problem. You have 3 unknown at time $0$ that get propagated to time $N$ and 3 equations to satisfy at time $N$. So you have to solve a non-linear 3×3 system, where the computation of the function values includes the integration of the ODE. – Lutz Lehmann Mar 22 '16 at 18:56