- #1
shakeel001
- 7
- 0
I need to convert quaternion (q) to a form that is suitable to show changing attitude of a Satellite. like new x,y,z vectors of a satellite.I don't know the math of quaternions. I am getting updated state using rung -kutta 4 method where state vector x=[q(1:4) wx wy wz a(1:3) b(1:3)].I can convert quaternion to euler angles but don't know further how to convert these to x,y,z of a satellite(updated) which will tell x,y,z position of a satellite after its state vector(x) was updated.
the sequence of operations I am doing are
% Simulation data
% Spacecraft data
% Gyro data
% Sensor data.
% Control system initialization
% Generate the orbit
% el = [a,i,W,w,e,M]. The spacecraft is in geostationary orbit
% Initial conditions at equinox
% Sun and Earth vectors
% Run the simulation
I shall be very grateful to all for help in this regards
Thanks again in advance for your time and efforts
the sequence of operations I am doing are
% Simulation data
% Spacecraft data
% Gyro data
% Sensor data.
% Control system initialization
% Generate the orbit
% el = [a,i,W,w,e,M]. The spacecraft is in geostationary orbit
% Initial conditions at equinox
% Sun and Earth vectors
% Run the simulation
here I am using RK4 for solving differential equation which is giving me an updated state vector x
% Attitude Determinationhere I am getting q
% Plot resultsI shall be very grateful to all for help in this regards
Thanks again in advance for your time and efforts