$m$ is mass of spacecraft, F is trust force, $\varphi$ is angle between trust vector and horizontal plane, $\gamma$ is gravitational acceleration
Given state variables as: $$ \begin{align} x_1&=x & x_2&=y & x_3&=\dot{x} & x_4&=\dot{y} & u_1&=\frac{F}{m} & u_2&=\varphi \end{align} $$
SC starts from $(0,0)$ at $t=0$ and reaches to altitude $H$ with horizontal velocity $V$ at that altitude.
I have 3 questions to solve:
a) Solve the lagrange multipliers and write down the following expressions by obtaining $\tan(u_2)$ as a function of $t$ and $\dot{x}$ vector wrt $u_1$ & $u_2$
$$ \begin{align} \frac{\partial x_1^*}{\partial u_2^*}&=\frac{x_3^*}{K cos^2(u_2^*)} & \frac{\partial x_2^*}{\partial u_2^*}&=\frac{x_4^*}{K cos^2(u_2^*)}\\ \frac{\partial x_3^*}{\partial u_2^*}&=\frac{u_1^*}{K cos(u_2)} & \frac{\partial x_4^*}{\partial u_2^*}&=\frac{u_1^* sin(u_2^*)-\gamma}{K cos^2(u_2^*)} \end{align} $$ where $K=\frac{d Tanu_2}{d t}=Constant$
My Solution is:
$$ \begin{align} \frac{d}{dt}\tan (u_2^*)=K \quad \Rightarrow \quad \tan (u_2^*)=Kt \quad \Rightarrow \quad t=\frac{\tan (u_2^*)}{K} \end{align}4$$
$$ \begin{align} x_1=\int \dot{x_1} dt=x_3 t \quad \Rightarrow \quad x_1=\frac{x_3}{K} \tan (u_2^*) \quad \Rightarrow \quad \frac{\partial x_1^*}{\partial u_2^*}=\frac{x_3^*}{K \cos^2(u_2^*)} \end{align} $$
and so on... Is that correct?
b) Solve the differential equations(which were found before as initial conditions, cost function, hamiltonian, lagrange multipliers) if $u_1=\frac{F}{m}=U=constant$ and $u_2(0)$ and $u_2(t_f)$ are free;
I don't know what to do if control is free to choose at initially and finally.
where if state $x(t_f)$ is free its variation $\delta x_f$ cannot be $0$. Thus, corresponding lagrange multiplier $p^*$ should be $0$
But I don't know what "control is free" means.
