- Joined
- Feb 2, 2012
- Messages
- 1,667
- Reaction score
- 105
- Points
- 78
I am not really entirely sure I understand the program flow applied here, but from your description of the problem it seems that there is an inherent numerical instability somewhere.
One possible cause of the problem you describe could arise if you recalculate the touchdown points according to the rotation matrix for your vessel you retrieve from Orbiter. Note that due to the compressibility of the touchdown points, the touchdown points you define in the code do not coincide exactly with the surface in the vessel frame, but will end up slightly below the surface. And if the mass distribution is not exactly symmetrical with respect to the arrangement of the touchdown points (which it will never be in practice), then this will also result in a small tilt (i.e. some touchdown points more compressed than others.)
If you now recompute the touchdown points according to the vessel rotation matrix to place them exactly back onto the surface (i.e. undoing the compression), Orbiter will then reapply the touchdown point compression, including the resulting tilt. If you do this repeatedly, the touchdown points will be displaced further and further, until the rocket topples over. Is it possible that this is what happens?
Thank you very much for your reply!
Unfortunately that's not the cause but you pointed me in the direction of managing touchdown points and mass distribution. Now I'm experimenting with it. Mass is considered anyway concentrated in the baricenter, which is the origin 0,0,0 in local vessel frame, right?
Just to be clear I can say now that there were two separate issues (i thought they were totally the same, but it's not true):
The liftoff instability issue, which can be solved with what said above, if so, that was probably my fault, sorry to have bothered you.
But now after a lot of testing I can say that there is another sure issue, which is that the old methods of SetTouchdownPoints(VECTOR3 Pt1, VECTOR3 Pt2, VECTOR3 Pt3) simply doesn't work anymore.
If you use it the vehicles simply doesn't use the points you provided. When callig clbkSetStateEx it seems to forget the touchdown points specified and try to use something like the old method and that's related on the issue of the picture I posted yesterday.