MATLAB Answers

Coorindate transforms to a satellite reference frame

83 views (last 30 days)
KatherineS
KatherineS on 29 Jul 2019
Answered: Meysam Mahooti on 12 Mar 2020
Hi,
I have a matrix in target coordinates, but I need to put this matrix into coordinates for a satllite. The unit vectors are given below (target to Earth Centered Earth Fixed) and then the satellite is just offset from ECEF by its orbit height. How do I transform the original matrix into satellite coordinates?
Thank you in advance for your help
a = longVal;
b = latVal;
Re = 6371; %km
Rgeo = 35786 + Re; %km
%--------------------------------------------------------------------------
%Target in satellite coordinates
%--------------------------------------------------------------------------
target_ECEF = [-sin(a) cos(a) 0; -sin(b)*cos(a) -sin(b)*sin(a) cos(b); ...
cos(b)*cos(a) cos(b)*sin(a) sin(b)];

  3 Comments

Joel Handy
Joel Handy on 29 Jul 2019
Dependig on your application, the first thing you need to do is look into geodetic versus geocentric coordinates. There will be inaccuracies in your code due to the oblateness of the earth.
What do you mean, "transform the original matrix into satellite coordinates." It looks like you have computed a target frame to ECEF transformation matrix. These arent coordinates. They are instructions for converting coordinates from one reference frame to another.
Did you really want to convert your lat and lon values to ECEF cartesian coordinates and then convert to coordinates in a spacecraft frame?
KatherineS
KatherineS on 29 Jul 2019
For the purposes of this simulation I am assuming a spherical Earth.
I have a 64 x 64 matrix with a target 'hill' in it, however this is currently in the coordinates of the Earth. This needs to be transformed into the coordinates of the satellite.
The 3x3 matrix shown is the unit vectors for the target coordinate system in terms of the satellite frame
Joel Handy
Joel Handy on 29 Jul 2019
So you have already applied target_ECEFand have a 64x64 matrix of cartesian position vectors in the ECEF frame? Essentially a 64x64x3 matrix. Is that accurate?
You need to create ECEF vectors from your satellite to your grid points, by subtracting the satellite position from each point. Then you need to transform these vectors into spacecraft coordinates. How you come up with that direction cosine matrix though depends on the definition of your satellite frame. Do you know the definition of this frame?

Sign in to comment.

Answers (2)

Jim Riggs
Jim Riggs on 29 Jul 2019
Edited: Jim Riggs on 29 Jul 2019
In order to answer this question, we need a good definition of the coordinate frames involved. The only way to do this is to draw a good diagram. Your description of the problem state that "the sattelite is just offset from the ECEF by it's orbit height". This, to me, implies that the satellite reference frame remains aligned with the ECEF frame, because an "offset" is typically a linear displacement. (An angular displacement is a "rotation"). If this is the case, then the basis vectors are the same for both the ECEF and the satellite reference frame, and a vector in ECEF is converted to satellite coordinates simply by adding (or subtracting) the offset vector.
However, if the satellite does, in fact, rotate (as I suspect it might) and one axis remains pointed "down", then the satellite reference frame might be described by a "North-East-Down" (NED) coordinate frame. In this case the Z-axis is selected as the "down" direction, and the x-axis remains pointing north at all times. In order to rotate a vector from ECEF to NED, you would apply the transformations, based on the lattitude and the longitude, per the equations below.
If you want some other axis (say the x-axis) pointing "down", then you would need to derive the appropriate transformation for this. Is this close to what you are looking for? (The attached paper shows the derivation of these equations. This may, or may not be of help to you)

  0 Comments

Sign in to comment.



Translated by