# Transient Attitude Motion of TNS-0#2 Nanosatellite during Atmosphere Re-Entry
## 3 Attitude Motion Reconstruction Technique
### TNS-0#2 Attitude Motion Equations  
Consider the motion of a satellite with hysteresis rods and a permanent magnet, taking into account both gravitational and aerodynamic torques. Assume that the satellite is a rigid body moving along a circular orbit around the Earth. The geomagnetic field model is IGRF [18]. The parallelogram model is used to describe the effect of the hysteresis in rods [19]. The following reference frames are used in the paper. \(OX_{O}Y_{O}Z_{O}\) is the orbital reference frame with the origin placed in the satellite center of mass. The axis \(OZ_{O}\) is directed along the satellite radius-vector from the Earth center. \(OY_{O}\) is perpendicular to the orbital plane, and axis \(OX_{O}\) complements these axes. \(OXY\) is the body-fixed reference frame, and its axes are directed as shown in Figure 2.  
The attitude motion is described using the Euler equations and kinematic relations based on the quaternion. The satellite state vector consists of the absolute angular velocity vector \(\mathbf{\Omega}\) and the attitude quaternion \(\Lambda=(\mathbf{q},q_{0})\). Here \(\mathbf{q}\) is the vector part of the quaternion and \(q_{0}\) is the scalar part. Additionally, the direction cosines matrix \(\mathbf{A}\) is used for the torques formulation and for the attitude representation. The dynamical motion equations are as follows:  
\[\mathbf{J}\dot{\mathbf{\Omega}}+\mathbf{\Omega}\times\mathbf{J}\mathbf{\Omega }=\mathbf{M}_{mag}+\mathbf{M}_{grav}+\mathbf{M}_{hyst}+\mathbf{M}_{aero}\]  
Figure 2: Center of mass location, permanent magnet, magnetometer and Sun sensors positions in the satellite body. where \(\mathbf{J}\) is the inertia tensor, \(\mathbf{M}_{mag}\), \(\mathbf{M}_{grav}\), \(\mathbf{M}_{hyst}\), and \(\mathbf{M}_{zero}\) are the magnetic torque caused by the permanent magnet, gravitational torque, magnetic torque due to the hysteresis rods, and aerodynamic torque, respectively. The gravitational torque is  
\[\mathbf{M}_{grav}=3\omega_{0}^{2}(\mathbf{A}\mathbf{e}_{3})\times\mathbf{J}( \mathbf{A}\mathbf{e}_{3})\]  
where \(\mathbf{e}_{3}=\left[ \begin{array}{ccc}0&0&1\end{array} \right]^{T}\) is a local vertical vector written in the orbital reference frame, and \(\omega_{0}\) is the orbital angular velocity vector \(\omega_{0}=\left[ \begin{array}{ccc}0&\omega_{0}&0\end{array} \right]^{T}\). The torque due to the permanent magnet is as follows:  
\[\mathbf{M}_{mag}=\mathbf{m}\times\mathbf{B}\]  
where \(\mathbf{m}\) is the dipole moment of the permanent magnet, \(\mathbf{B}\) is the geomagnetic induction vector. The torque caused by the hysteresis rods is  
\[\mathbf{M}_{hyst}=\mathbf{m}_{hyst}\times\mathbf{B}\]  
where \(\mathbf{m}_{hyst}\) is the resulting dipole magnetic moment of all the rods. The dipole moment of one rod is  
\[\mathbf{m}_{hyst}^{k}=\mu_{k}V_{k}H_{0}W\mathbf{e}_{k}/\mu_{0}\]  
where \(\mu_{k}\) is the relative magnetic permeability of the k-th rod, \(V_{k}\) is its volume, \(H_{0}\) is the mean magnitude of the geomagnetic \(\mathbf{H}\)-field in the current point of the orbit, \(W(H_{\tau})\) is a dimensionless function describing the dependence of the induction of the rod related to \(H_{0}\) according to the parallelogram hysteresis model, \(\mu_{0}\) is the magnetic constant, and \(H_{\tau}=\mathbf{H}\mathbf{e}_{k}\), \(\mathbf{e}_{k}\) is the unit vector directed along the rod in the body reference frame. The aerodynamic torque is  
\[\mathbf{M}_{zero}=-\sum\mathbf{d}\times\mathbf{f}_{a}.\]  
Vector \(\mathbf{d}\) determines the position of the satellite centre of mass relative to the centre of pressure, and \(\mathbf{f}_{a}\) is the aerodynamic drag force acting on the side in the body-fixed reference frame. The sum over all sides facing the incoming flow is performed. Dynamic equations are supplemented with kinematic relations. The attitude quaternion is used in the numerical simulation. Its kinematic equation is as follows:  
\[\dot{\Lambda}=\frac{1}{2}\mathbf{C}\Lambda\]  
\[\mathbf{C}=\left[