Skip to main content

Exercises 19.6 Homework

1.

(Theoretical) Rewrite the second-order equation \(y'' + yy' - ty^3 = e^{-t}\) as a system of two first-order equations.

2.

Use the midpoint method (19.4.3) with step size \(h=0.01\) to solve the autonomous system

\begin{align*} y_1' \amp = y_2\\ y_2' \amp = -y_1 - y_2^3 \end{align*}

with initial condition \(y(0) = \begin{pmatrix}1 \\ 1\end{pmatrix}\) on the interval \([0, 50]\text{.}\) Display both time series plot and phase plot side by side, for example

subplot(1, 2, 1)
plot(t, y)
subplot(1, 2, 2)
plot(y(1,:), y(2,:))

How would you describe the long-term behaviour of this solution?