So this is my problem:
I want to maximize the final mass of an ascending rocket into an orbit by controlling the trajectory over a thrust vector control variable a(t). So I need an Optimization Toolbox that returns me the optimal function a(t), but the objective function I want to minimize is m(t). And I couldn't find anything about this anywhere. I tried for example fmincon, but fmincon only returns a scalar.
Do you have any ideas?