|
From: Andy R. <an...@ne...> - 2001-08-28 22:34:57
|
Jon S. Berndt wrote:
> 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?
It's not using the body frame. It's using the body "basis". That is,
it takes a single value expressed in a useful coordinate system and
transforms it into another where it gets interpreted. This is
perfectly fine. It's not applying that value to compute more changes
in the frame.
That is, it computes a pilot acceleration to find out what direction
the poor soul is being pushed -- the instantaneous transformation of a
global acceleration vector to a coordinate basis that "just happens"
to coincide with the body frame. It does NOT assume that the pilot
(had he jumped out the window) would have actually accelerated in that
way.
See the difference? I'm not trying to use F=ma, or any other
Newtonian gadgets. I just want a force (gravity) in one basis
("local") translated to a force in another (body). Because the force
is interpreted instantaneously, it's valid in all reference frames
(instantaneously, there's no such thing as an accelerated frame). The
prohibition isn't against the USE of different coordinate systems,
it's against the ASSUMPTION that Newtonian mechanics will hold in them
to predict the future.
Or here's another way to look at it: a "reference frame" isn't the
same thing as a vector transformation. It's the whole world, from the
start of time to the end of time (or at least the whole model, from
the start of the sim to program termination). There is a vector
transformation for every instant of time in the "frame".
Yes, it's complicated (and the awful McFarland conventions certainly
aren't helping). I'm a poor teacher, and email is a poor medium for
this sort of thing. Really, the best I can do is hand you code that
produces correct results and hope that everybody figures it out.
That's not the same thing as saying "just trust me" -- I
wholeheartedly agree that you should grok everything that goes into
the sim. I'm just out of ideas for how to explain it. Like I said
originally, the patch is a hack.
Andy
--
Andrew J. Ross NextBus Information Systems
Senior Software Engineer Emeryville, CA
an...@ne... http://www.nextbus.com
(510)420-3126 Why Wait?
|