<s>[INST] Help with a differential equation? 
I'm confused about what the question is asking. I solved the following equations:
$$y'' + 4y = 0 \implies y = c_1\cos2x + c_2\sin2x$$
$$y'' + 4y = \sin x \implies y= c_3\cos2x + c_4\sin2x + \frac{\sin x}{3}$$
Using the given initial values, the coefficients for the second solution (the one that's the solution for the equation with $\sin x$ on the RHS) can be solved for. I don't understand how or why you would be able to solve for the coefficients for the first solution though ($c_1$ and $c_2$). The given value is outside of the domain of the first function, hence it doesn't say anything about it so it can't be used to solve for the coefficients.
How can $c_1$ and $c_2$ be solved for?
 [/INST] You are asked to find a solution where $y$ and $y^\prime$ are continuous at $\frac{\pi}{2}$.  Now in the region up to $\frac{\pi}{2}$ the solution is dictated by the initial conditions (at $x=0$) giving $c_3 = 1$ and $2 c_4 + \frac{1}{3} = 2$ (that is, $c_4 = \frac{5}{6}$.
$$
y = 1 \cdot \cos (2x) + \frac{5}{6} \sin (2x) + \frac{1}{3} \sin x
$$
Now we can find the value and first derivative at $\frac{\pi}{2}$:
$$
y(\frac{\pi}{2}) = -1 + \frac{5}{6} (0) + \frac{1}{3} = -\frac{2}{3}
$$
$$
y^\prime = 0 - \frac{5}{3} + 0 = - \frac{5}{3}
$$
So $c_1$ and $c_2$ are determined by the need for the limit of the solution having a value of $-\frac{2}{3}$ and a first derivative of  $-\frac{5}{3}$ as $x\rightarrow \frac{\pi}{2}^+$.  Thre is nothing fancy about the limit, it is just the value in this case. So,
$$
-c_1 + 0 = -\frac{2}{3}
$$ and
$$
0 - 2 c_2 = -\frac{5}{3}
$$
Thus $c_1 = \frac{2}{3}$ and $c_2 = \frac{5}{6}$
</s>