# What is the math behind Magnetorquers?

I'm trying to better understand the mathematics behind how torque rods work. I know that even if you have 3 axis of magnetic torquers, in effect there is only 2 axis of control, and I'm trying to figure out how all of this works exactly. Specifically, let's assume the following hypothetical situation:

I have a location of a satellite in LEO, and the magnetic field vector for said satellite. I have magnetorquers on the satellite of a known strength, and I'm trying to determine how much control authority I have in various directions. How much control authority do I have, given a magnetic field in body coordinates, and 3 equal strength magnetorquers in orthogonal vectors lined up with the body axis?

A set of three orthogonally aligned torque rods wired up so they can generate a magnetic dipole field of either sign (i.e. flip the North and South poles) can generate a magnetic field of arbitrary orientation (up to the maximum vector sum of the dipole moment of each rod individually).

This artificial field interacts with the Earth's magnetic field to produce a net external torque on the vehicle that will tend to line up the fields. Mathematically, the torque is provided in the direction of:

$\mathbf{\tau}=\mathbf{\mu}\times\mathbf{B}$, where $\tau$ is the torque on the satellite, $\mathbf{B}$ is the ambient magnetic field, and $\mu$ is the magnetic field of the satellite

This torque only has two degrees of freedom, i.e. instantaneously the torque rods will tend to align the vehicle and Earth fields, with no control of the rotation of the vehicle around its magnetic poles. (see below for proof)

However, remember that the magnetic field lines around the Earth are themselves a dipole field, which is a toroidal shape.

This means as the spacecraft orbits the Earth it encounters a diversity of Earth magnetic field orientations and in general the time-averaged effect of this field diversity enables full 3-axis control.

That said, the field is weak, so the actual torque produced by torque rods is very small. It's completely unsuitable for agile spacecraft (e.g. imagers), for which attitude control effectors like reaction wheels or control moment gyros are typically used. Torque rods are used to desaturate these effectors which accumulate momentum due to disturbance torques like atmospheric drag, and to de-spin satellites (e.g. due to tip-off rates at launch vehicle separation).

### Proof of the ineffectiveness of torque rods in the absence of magnetic field diversity

Torque rods rely on the change in direction of the Earth's magnetic field, which is especially problematic in equatorial orbits because (to first order) the field has a constant inertial direction. Equating the control torque with the rigid-body rotational equations of motion:

$$\mathbf{\mu}\times\mathbf{B}=\mathbf{\tau}=\mathbf{I\alpha+\omega}\times\mathbf{I\omega}$$

where $\mathbf{I}$ is the moment of inertia tensor, $\mathbf{\omega}$ is the vector body rates, and $\mathbf{\alpha}$ is the vector of body accelerations (i.e. $\dot{\omega}$), all in an arbitrary inertial reference frame. Moment of inertia matrices are always real and symmetric and can thus be decomposed / rotated into a principle reference frame.

$$\mathbf{\mu}\times\mathbf{B}=\mathbf{Q\Lambda Q}^{-1}\mathbf{\alpha}+\mathbf{\omega}\times\mathbf{Q\Lambda Q}^{-1}\mathbf{\omega}$$ $$\mathbf{RQ\Lambda}^{-1}\mathbf{Q}^{-1}(\mathbf{\mu}\times\mathbf{B})=\mathbf{R\alpha}+\mathbf{RQ}(\mathbf{\Lambda}^{-1}\mathbf{Q}^{-1}\mathbf{\omega}\times\mathbf{Q}^{-1}\mathbf{\omega})$$ $$\mathbf{R\mu'}\times\mathbf{RB'}=\mathbf{R\alpha}$$ $$\mathbf{\mu''}\times[0, 0, Bz]=\mathbf{\alpha'}$$

where $\mathbf{\mu}$ and $\mathbf{B}$ are rotated into the principle axes and the matrix math has shown there is no gyroscopic coupling between the axes of rotation in the principle frame because the $\mathbf{\omega}\times\mathbf{I\omega}$ term cancels. (We could have started at this step by choosing the principle reference frame to start, but many seem comforted by starting with the full EOM.) We've additionally rotated by $\mathbf{R}$, selected so that the Earth's magnetic field only acts in the z-axis.

The vector $\mathbf{\mu}$ is our torque rod control input, which we may point in any direction by combining the effect of three orthogonal rods. This means the double rotation of $\mathbf{\mu}$ to $\mathbf{\mu''}$ has to be accounted for by the control system, but has no bearing on controllability. We can now expand the cross product and show despite the ability to point $\mathbf{\mu}$ in an arbitrary direction, the resultant acceleration (in the frame where the z-axis is aligned to magnetic North) has the form $[kx, kz, 0]$, which shows we can only control the angular accelerations about the x- and y-axes, but never z.

From the initial equation $\mathbf{\mu}\times\mathbf{B}$ we know a toque cannot be generated in the direction of $\mathbf{B}$; thus, any initial angular momentum in that direction is uncontrollable, but spacecraft kinematics can be counterintuitive, so sometimes the math is helpful.

• "...so sometimes the math is helpful." That's a bit of an understatement. Indeed! Math is very frequently helpful in spaceflight.
– uhoh
Oct 9, 2016 at 0:22

Basically, most magnetorquers function something like bar magnets that can be dialed to select how powerful, and what direction, they pull in. The math behind them turns out to be really simple. $\mathbf{\tau}=\mathbf{\mu}\times\mathbf{B}$, where $\tau$ is the torque on the satellite, $\mathbf{B}$ is the ambient magnetic field, and $\mu$ is the magnetic field of the satellite. Usually, there are 3 axis of magnetorquers, which means that $\mu$ can effectively be set to anything within a certain range, although the torque will be applied differently depending on exactly where the magnetorquer is placed. The full analysis will be easier to apply by measuring one magnetorquer at a time, but I'm going to assume that their torque lines up with the rotational vectors reasonably well, allowing for all of them to be handled.

Essentially, what happens when you turn on the magnetorquer is that there is a torque applied to move the spacecraft to line up with the magnetic field vector. Like a compass needle, the magnet will line up with the north pole of the magnet lining up to the south magnetic field. Without resistance, it will overshoot the pole, making it difficult to exactly line up on an axis.

Furthermore, one must consider that there are in effect only 2 axis of rotation. If you are lined up perfectly with the magnetic field, you cannot control your rotation about the field. There is always one axis that you cannot rotate about, although you might be able to mitigate it with some effort.