Answer
See below
Work Step by Step
Given
$m_1\frac{d^2x}{dt^2}=-k_1x+k_2(y-x)\\
m_2\frac{d^2y}{dt^2}=-k_2(y-x)$
We introduce new variables $x_1$ and $x_2$ defined by
$x_1=x\\
x_2=\frac{dx}{dt}\\
x_3=y\\
x_4=\frac{dy}{dt}$
Since $x(0)=\alpha_1\\
x'(0)=\alpha_2\\
y(0)=\alpha_3\\
y'(0)=\alpha_4$
Then the given differential equation can be replaced by the first-order system
$m_1\frac{dx_2}{dt}=-k_1x_1+k_2(x_3-x_1)\\
m_2\frac{dx_4}{dt}=-k_2(x_3-x_1) \\
x_2=\frac{dx_1}{dt}\\
x_4=\frac{dx_3}{dt}$