Find the constant $c$ which solves the following problem: $$-u''=c\quad \text{in}\quad(a,b)$$ $$u'(a)=-1 \quad u'(b)=1$$
One way to solve this is considering the cases when $c>0$ and $c<0$ and writing the solution in terms of $\cos$ , $\sin$ . But that method is not giving the value of $c$