3
$\begingroup$

I have to solve this boundary value problem for

$$ y''(x) -x \ y(x) = 0 \\ y(a) = y_a \\ y(b)=y_b $$

for some $y_a$ and $y_b$. I have to use the Shooting method with Runge–Kutta 4.

So far I have

$$ z_1(x)=y(x) \\ z_2(x)=y'(x) $$ from which I get: $$ z_1'(x)=z_2(x) \\ z_2'(x)=x\ z_1(x) $$

And this is where it stops. What am I missing to have a full system of equations that I'll solve with Rk4? And how do I get the parameter $\alpha$ that I will have to tune?

Sorry if the question isn't well formed, but I am still quite lost here. I have looked at some other questions about shooting method but the answers just confuse me even more (it may be just because of the late hour), so a simple answer or a hint would be nice.

Thank you.

$\endgroup$
3
$\begingroup$

You have converted the problem into a system of two differential equations.

Now you need to set it up as a Initial Value Problem (IVP). This means you need to specify the initial values for $z_1(a)$ and $z_2(a)$. We know that $z_1(a) = y_a$, but we need to `guess' $z_2(a)$. This guess is your parameter $\alpha$.

The shooting method involves repeatedly solving this IVP problem (using RK4) over the interval $[a, b]$ with different values of $\alpha$. You then compare the computed value of $z_1(b)$ against $y_b$.

The aim is to find the value of $\alpha$ that gives the result $z_1(b) = y_b$ to the required accuracy.

A simple (but not efficient) way to do this is to find two values of $\alpha$ that bracket the value $y_b$ and then use the bisection method to refine the approximation.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.