Your verbal problem description in which you call L and ouput, but in fact you know what it is, somewhat confuses me, but in anycase going from your equations I think I see what you are trying to do.
Besides the details of how to get extract the variables from what is returned by ode23, I think you have some more fundamental issues.
You are solving for dh/dt , but you want h. If you want h then you should set up a system of two first order ode's
So for example defining y1 = h, y2 = dh/dt
dydt = fun(t,y)
dydt = [y(2)
Note that you can also use two left hand argument to ode23 and get the answers returned as y and t rather than in a structure if you prefer.
The additional arguments can be sent using the anonymous function as you did before as long as they are in the local workspace when you call ode23.
Sorry I see now that @Starstrider has been giving you additional ideas while I was writing this answer, but maybe this is helpful too.