I am to optimize utility given the utility function $$ u(c,l):=c-\frac{\eta}{\eta+1}(24-l)^{\frac{\eta+1}{\eta}},$$
where $c$ represents consumption and $l$ represents leisure. The budget constraint given: $pc+wl=24w$; $p$ represents the price of consumption and $w$ represents hourly wage. I have found the optimal amount of leisure, but I can’t find the optimal amount of consumption for the life of me. I have found the optimal amount of leisure, $l^*$, as follows:
I have written it as a Lagrangian maximization problem: $$ L(c,l,\lambda)=c-\frac{\eta}{\eta+1}(24-l)^{(\eta+1)/\eta} - \lambda(pc+wl-24w) $$
and found the following: $$ \frac{\partial (U)}{\partial(l)}=-\lambda w+ (24-l)^{1/\eta}=0 $$
Solving for $\lambda$: $$ \lambda = \frac{(24-l)^{1/\eta}}{w} $$ and $$ \frac{\partial (U)}{\partial(c)}=-\lambda p+1=0 $$
Solving for $\lambda$: $$ \lambda = 1/p$$
I then set $\lambda$ equal to $\lambda$ and solved the equation for $l$: $$ \frac{(24-l)^{1/\eta}}{w} = 1/p $$ $$ l^*= 24-\left(\frac{w}{p}\right)^{\eta} $$
I have concluded that this is the optimal amount of leisure, however, I can’t find the optimal amount of consumption, as $c$ of course vanishes unless you find the partial derivative with respect to $\lambda$; this, however, of course doesn’t yield an equation containing $\lambda$, so I can’t isolate $\lambda$ and find $c^*$ how I found $l^*$. Any help would be much appreciated :)
So far so good. Next you make the derivative of $\mathcal L(c,l,\lambda)$ w.r.t $\lambda$, which is just the constraint.
$$\frac{\partial\mathcal L(c,l,\lambda)}{\partial \lambda}=24w-pc-wl=0$$
In combination with $l^*= 24-\left(\frac{w}{p}\right)^{\eta}$ we obtain
$$24w-pc-w\cdot \left(24-\left(\frac{w}{p}\right)^{\eta} \right)=0$$
It remains to solve the equation for $c$. I don´t think that you need the next steps. So I hide them and you can compare them with your own steps at the end.