I have given the following differential equation:
$x'= - y$ and $y' = x$
How can I solve them?
Thanks for helping! Greetings
I have given the following differential equation:
$x'= - y$ and $y' = x$
How can I solve them?
Thanks for helping! Greetings
If you differentiate $y'$, you have: $$y'' = -y$$ Which has the solutions: $$y=C_1 \cos(t) + C_2 \sin(t),$$
Introduce the complex dependent variable $z=x+iy,$ then your ode is $$z'=iz,$$ where $'$ is again the differentiation w.r.t. the independent variable $t$.
The characteristic polinomial is $P(\lambda)=\lambda-i,$ so the general solution is $$z(t)=\alpha.e^{it},$$ for an arbitrary $\alpha\in\mathbb{C}$.
P.S. : By the way your original system is the Hamilton equation for the harmonic oscillator $$H(x,y)=\tfrac{1}{2}(x^2+y^2).$$
Let $\displaystyle X(t)= \binom{x(t)}{y(t)}$ so
$$ X' = \left( \begin{array}{ccc} 0 & -1 \\ 1 & 0 \\ \end{array} \right)X .$$
This has solution $$ X(t)= \exp\biggr( \left( \begin{array}{ccc} 0 & -t \\ t & 0 \\ \end{array} \right) \biggr) X(0)= \left( \begin{array}{ccc} 0 & e^{-t} \\ e^t & 0 \\ \end{array} \right)\binom{x(0)}{y(0)}$$
so $$ x(t) = y(0) e^{-t} \ \ \text{ and } \ \ y(t) = x(0) e^{t} . $$