I am writing an iPhone app that requires for a vector defined in a body fixed frame to be converted to a vector in a global frame. I know the value of a vector with reference to the body fixed frame and I know that this vector is normal to the global xy plane (It is the acceleration due to gravity vector). Given a vector with reference to the body fixed frame, how might I convert this to the global frame?
In other words,
g = < x1 , y1 , z1 > with reference to the body fixed frame
g = < 0 , 0 , z2 > with reference to the global frame
v = < x2 , y2 , z2 > with reference to the body fixed frame
v = ??? with reference to the global frame
I would appreciate if anyone could tell me what formula to use or point me in the direction of what I need to research. I have done many a google search, but I haven't come across anything useful yet.
Thanks in advance.
You don't have enough information. You need to know how the body moves in the global frame. Just as an example: suppose the body is stationary in the global frame. Then g in the global and local frame are identical, and say the velocity of an outside object moving a constant speed along x is v=(v,0,0) in both frames. But if the body is falling with a velocity v1, the velocity of the outside object is (v,0,0) in the global frame and (v,0,v1) in the body frame. Look up motion in non-inertial frames for the general case. One quick search yielded http://www.dartmouth.edu/~phys44/lectures/Chap_6.pdf