|
From: Tony P. <ap...@ea...> - 2001-08-29 12:48:39
|
On Tuesday 28 August 2001 02:34 pm, you wrote: > > vUVWdot = mVel*vPQR + vForces/Mass; > > + > > + // Body-frame acceleration is similar, but it includes gravity > > + // too, and does NOT include the mVel*PQR fictitious force (which > > + // is an artifact of the accelerated reference frame used here). > > + // Note that the gravity vector is the Z unit vector times the > > + // "local to body" matrix. > > + vBodyAccel = vForces/Mass; > > + vBodyAccel(1) -= 32.1 * State->GetTl2b(1, 3); > > + vBodyAccel(2) -= 32.1 * State->GetTl2b(2, 3); > > + vBodyAccel(3) -= 32.1 * State->GetTl2b(3, 3); > > > > vNcg = vUVWdot*INVGRAVITY; > > Another thing that is suspicious here, to me. vBodyAccel gives an > acceleration vector in body axes. You are adding the effects of gravity in > body frame. This would be correct, except that now vForces includes > gravity, as mentioned in the previous email. Also, you wrote: "it uses > F=ma to calculate the acceleration relative to the _earth_ frame". This is > not what you are doing, above. You are calculating, here, the accels in > body frame. I do not see them being transformed to inertial, or "earth" > frame, anywhere. But, I may be missing something, here. Can you explain > this misunderstanding? Gravity is already there, at least in the current code. Check out FGInertial::Run() > > Jon > > _______________________________________________ > Flightgear-devel mailing list > Fli...@li... > http://lists.sourceforge.net/lists/listinfo/flightgear-devel -- Tony Peden ap...@ea... We all know Linux is great ... it does infinite loops in 5 seconds. -- attributed to Linus Torvalds |