Docking Manoeuvre Control for CubeSats

Rendezvous and docking missions of small satellites are opening new scenarios to accomplish unprecedented in-obit operations. These missions impose to win the new technical challenges that enable the possibility to successfully perform complex and safety–critical manoeuvres. The disturbance forces and torques due to the hostile space environment, the uncertainties introduced by the onboard technologies and the safety constraints and reliability requirements lead to select advanced control systems. The paper proposes a control strategy based on Model Predictive Control for trajectory control and Sliding Mode Control for attitude control of the chaser in last meters before the docking. The control performances are verified in a dedicated simulation environment in which a non-linear six Degrees of Freedom and coupled dynamics, uncertainties on sensors and actuators responses are included. A set of 300 Monte Carlo Simulation with this Non-Linear system are carried out, demonstrating the capabilities of the proposed control system to achieve the final docking point with the required accuracy.


Introduction
Rendezvous and docking (RVD) between spacecraft are very attractive operations which enable a large set of space missions. Beyond the spacecraft periodic cargo and crewed mission to ISS, a wide range of relevant missions can be performed such 1 3 between Target and Chaser. In [18], the authors study controllers based on Linear Quadratic Regulator (LQR) and Proportional Derivative (PD) Control, verifying the performance and robustness of the solutions without considering other parameters such as time and control effort. In [19], the authors use the same control laws of [18] and present a comparative analysis between different guidance trajectories for important parameters such as time, fuel consumption, minimum absolute distance, and the maximum radial distance from the target without highlighting the optimality of the results. Adaptive control laws for spacecraft rendezvous and docking under measurement uncertainty, such as aggregation of sensor calibration parameters, systematic bias, or some stochastic disturbances, are proposed in [20]. In [21], authors show an optimized state dependent Model Predictive Control (MPC) that integrates a pulse width pulse frequency modulation model: the results highlight a good accuracy for the reaching the final state minimizing the control efforts and approaching time. Ventura at al. [22] proposes a guidance scheme for autonomous docking where the trajectory components of the controlled spacecraft are imposed by using polynomial functions determined through optimization processes. From the manoeuvre's strategies point of view, the authors in [23] give a complete overview of the manoeuvre and control capabilities for the capture of a non-rotating and of a rotating target, using a MPC but limiting the study to planar manoeuvres. One of the key points for MPC controller is the ability to handle constraints on state vector and control vectors: [24] presents a strategy for spacecraft rendezvous control based on linear quadratic MPC with dynamically reconfigurable constraints. In [25], authors present a MPC focused on the tracking based capability for a chaser involved in the capture of a non-cooperative spacecraft discussing advantages and criticalities of this approach through analysis of the time and the control efforts required to achieve the mating point. Mammarella et al. [26] propose and validate on a test-bench a sampling-based stochastic model predictive control (SMPC) algorithm for discrete-time linear systems subject to both parametric uncertainties and additive disturbances.
In the small satellite's context, few papers address the control problem for the final approach and mating phases of rendezvous. Bowen et al. [27] presents the determination and control strategy for CPOD mission, but no further details are provided on the adopted techniques. Pirat et al. [28] present an H-infinity controller taking care the robust stability and performance through mu-synthesis. Stesina in [29] reports a solution based on a tracking MPC without including the attitude control.
The present paper presents a control strategy that maintain de-coupled the rotational and translational dynamics based on the MPC and Sliding Mode Control techniques, in order to optimize the final position and attitude of the chaser limiting the fuel consumption and the time to perform the capture. After the problem definition in Sect. 2, the design of the controller and the tuning of its parameters is proposed in Sect. 3. Section 4 reports and discusses the results of simulations for different initial conditions and uncertainties on the spacecraft parameters. Section 5 concludes the paper with final remarks and the future perspectives of the work.

Problem formulation
The objective is the control of the relative position and attitude between the target and chaser. The problem formulation is based on the definition of the adopted reference frames and assumptions on the motion conditions and the spacecraft features.

Reference frames
Four reference frames are defined in order to formulate the problem (Fig. 1).
• The ECEF (Earth-centered Earth-fixed) frame ( R I ) is considered a quasi-inertial frame for the mission and it has origin O I in the centre of the Earth, x I in the equatorial plane, pointing toward the mean of the vernal equinox; z I is normal to the equatorial plane and pointing north, y I is in the equatorial plane, such that z I = x I × y I . •   • The Target Body frame ( R t ) has origin O t in the Target centre of mass, the directions of the axes are along the main inertia axes of the Target and z t = x t × y t forming a right-handed system. • The Chaser Body frame ( R c ) has origin O c in the Chaser centre of mass, the directions of the axes are along the main inertia axes of the Chaser and z c = x c × y c forming a right-handed system.

Assumptions
The problem formation is based on a set of assumptions on the motion conditions:

Assumption 1 (Last Hold Point orbit conditions)
The control starts in the final hold point (HP) at 50-meters of distance between chaser and target and Chaser mechanism is already aligned with the docking port when moves from the HP. This assumption allows us to consider guidance strategies based on straight-line approaches. The achievement of this final hold point depends on the previous mission phases; an example is provided in [8].

Assumption 2 (Last hold Point attitude conditions)
The target reaches any orientation in space but it maintains this orientation for the entire duration of the manoeuvre. This allows defining a fixed desired attitude that the chaser has in the HP and shall maintain for the entire duration of the manoeuvres. Other assumptions derive from the spacecraft configuration.

Assumption 3 (Chaser and Target mass properties)
Target and chaser are 12U Cube-Sats (20 cm × 20 cm × 30 cm) whose mass (m) is 20 kg and the inertia (expressed in the respective body frame) is diagonal I cx = I tx = 0.133, I cy = I ty = 0.216, I cz = I tz = 0.216. In general, the two CubeSats should have a different architecture and different onboard instruments because the Target should only maintain the attitude without orbit control, while the chaser shall determine and change its orbit and needs of specific sensors and actuators dedicated to this purpose. However, the perfect similarity of the two spacecraft can be justified by reliable considerations: both the Cube-Sats have the complete attitude and orbit control systems enabling the possibility to exchange the role of target and chaser in case of anomaly for the orbit control of the regular chaser.

Assumption 4 (Location of the docking port and docking mechanism)
Due to the small dimensions of the satellites and considering a fixed distance of the docking port with respect to O c along X c axis and fixed distance of the docking mechanism with respect to O t along X t axis, it is assumed that the docking port and the docking mechanism are located in coincidence of O t and O c , respectively.

Assumption 5 (Rotational Dynamics of Chaser and Target)
The Target body axes are aligned with the orbital frame (i.e. R t ≡ R o ). It means that if the Chaser controller is 1 3 The Journal of the Astronautical Sciences (2022) 69:312-334 able to control the attitude reaching and maintaining the Chaser body axes aligned with the orbital frame (i.e. R c ≡ R o ), Target and Chaser have the attitude.

Control design
The goal of the controller is to reach the soft docking performance described in Table 1 guaranteeing efficiency and safety conditions. More specifically, the goal is to control the Chaser attitude and angular velocity and the relative position and velocity between the Chaser and Target, according to the strategies defined for any phase (see Sect. 4.1). The controlled state variables are: the attitude (q c ) and the angular velocity (ω oc ) between the Chaser Body Frame ( R c ) and orbital frame ( R o ) and the relative position (x,y,z) and velocity (V x , V y , V z ) between the Chaser CoM (O c ) and the Target CoM (O t ).
The control design and assessment phases are articulated in two steps: the design is based on a linearized spacecraft model, while the verification is led through a more complex and nonlinear model of rotational and translational dynamics of the chaser including disturbances and uncertainties.
The control design foresees the de-coupling of the rotational and translational dynamics, that allows us to select different techniques to control the attitude and the relative trajectory between Chaser and Target.
A Model Predictive Controller (MPC) is designed for the control of the Chaser trajectory. The advantages of this technique for the rendezvous and docking problem are: 1) the possibility to constrain the input, the state and output imposing boundaries whose violation is prevented and 2) the capability to jointly define an optimal guidance strategy and the feedback command allowing the spacecraft to follow this strategy, 3) constraints or penalties on fuel consumption, time to capture and safety conditions of the manoeuvre can be introduced. 4) MPC can drive some variables to their optimal set points (i.e., the relative position can be optimized to meet the soft docking requirements) while others can be held within imposed ranges (i.e. the velocity can be regulated with specific profiles). The prediction of the future states leads to the definition of an optimal trajectory. For the MPC design in this research, a reference tracking optimization criterion is introduced in order to assign a higher importance to the capability of the controller to track the desired values.

3
A Sliding Mode Controller is designed for the control of the Chaser attitude. The advantages of this approach applied to the presented rendezvous and docking problem are: 1) capability to efficiently deal with nonlinear dynamics and 2) robustness versus modelling uncertainties.

Model predictive control law
In this section, we present a general formulation of Model Predictive Control (MPC), suitable for nonlinear and linear systems [29]. Consider a dynamic system described by the following state equation: where x ∈ ℝ n x is the state, u ∈ ℝ n u is the command input and f ∶ ℝ n x +n u → ℝ n x is a function characterizing the system dynamics. Assume that the state is measured in real-time, with a sampling time T s , according to x(t k ), t k = T s k, k = 0, 1, … Suppose that the system state x is required to track a desired reference signal r . The state and input variables may be subject to constraints and it may be of interest to have a suitable trade-off between performance and command effort. MPC is a suitable approach to solve such a control problem [30].
MPC is based on two key operations: prediction and optimization. At each time t = t k , the system state is predicted over the time interval [t, t + T p ] , where T p ≥ T s is called the prediction horizon. The prediction is obtained by integration of the system Eq. (1). For any ∈ [t, t + T p ] , the predicted state x( ) is a function of the "initial" state x(t) and the input signal: where u(t ∶ ) denotes the input signal in the interval [t, ] . The basic idea of MPC is to look, at each time t = t k , for an input signal u * (t ∶ ) such that the prediction x( , x(t), u * (t ∶ )) has the desired behavior in the time interval [t, t + T p ] . The concept of desired behavior is formalized by defining the objective function is the predicted tracking error, r( ) ∈ ℝ n x is the reference to track and ‖ ⋅ ‖ * is a weighted vector norm. For a generic vector x and a positive definite weight matrix Q , this norm is defined as follows: In most cases, diagonal weight matrices are used since the non-diagonal terms are in general difficult to manage/interpret and their utilization usually does not yield relevant advantages.
The Journal of the Astronautical Sciences (2022) 69:312-334 The input signal u * (t ∶ t + T p ) is chosen as one minimizing the objective function J u(t ∶ t + T p ) . In particular, at each time t = t k , for ∈ [t, t + T p ] , the following optimization problem is solved: The fist constraint in this problem ensures that the predicted state is consistent with the system Eq. (1). The set X c accounts for possible constraints that may hold for the state trajectory (e.g., obstacles, barriers, etc.). The set U c accounts for input constraints (e.g., input saturation).
The MPC feedback command is obtained by solving the optimization problem at each sampling time t = t k , according to a so-called receding horizon strategy: (2); -apply to the system only the first input value: • Repeat the two steps above for t = t k+1 , t k+2 , … Note that the optimization problem in Eqs. (2) is in general non-convex. Moreover, the decision variable u(⋅) is a signal and optimizing a function with respect to a signal is in general a difficult task. To overcome this problem, a suitable parametrization of the input signal u is taken. In particular, the prediction interval , where the i 's are called the nodes. Then, u is assumed constant on each sub-interval, so that the optimization problem reduces to a finite-dimension problem, which is solved using an efficient numerical optimization algorithm.

MPC for trajectory control
The assumptions of small initial relative position and short maneuver time allow us to use the well-known Hill-Clohessy-Wiltshire model, describing the motion of a spacecraft (called the Chaser) relative to a nominal point traveling in a circular orbit (called the Target orbit). This model is described by the following equations: where x c , y c , z c are the relative Chaser positions, m c is its mass, Ω is the angular frequency of the Target orbit, and F cx , F cy and F cz are the external forces applied to the Chaser.
Equations (3) can be represented in the form of the state equation (1) as follows: where x = ( x c , y c , z c , ̇x c , ̇y c ,̇z c ) is the state vector, constituted by the three components of the Chaser position and velocity with respect to R t , u=(F cx ,F cy ,F cz ) is the force vector, and The MPC control law is obtained by solving, at each sampling time, the optimization problem in Eqs. (2), according to the receding horizon strategy described in the above section. In the optimization problem, the model function is f (x, u) = Ax + Bu . The input constraint set U c is defined by the following inequalities: where F cmax is the vector of the maximum thruster forces and the inequalities are element-wise. The state constraints depend on the approach corridor represented by the cone originated from the mating point and with a half cone angle of . Considering the assumptions made in Sect. 2, the cone is univocally defined for the straightline maneuver, and it is generated from the docking point and it is centered in the docking axis, the X c axis. Therefore, the state constraint set is defined by the following inequalities: where a xy , a xz , b xy and b xz represent the corridor limits, and and are the angles between the docking axis and R t axes. These angles are assumed constant for the entire prediction horizon. Figure 2 refers to the specific case (considered in this paper) of V-bar approach, where phi and theta are equal to 180 deg.
Note that the set U c is convex. If the chaser initial conditions are inside the cone, also the set X c is convex. Hence, with f (x, u) = Ax + Bu , the optimization problem of Eqs. (2) becomes convex, which implies that every local solution of this problem is a global solution. Another implication is that convex algorithms can be used for its solution, which are characterized by a high numerical efficiency and strong convergence properties. In this paper, an algorithm based on quadratic programming is adopted, suitably modified for the considered application.
As discussed in the above section, it is convenient to parametrize the input signal by dividing the prediction interval into sub-intervals and assuming u constant on each sub-interval. In this paper, a single sub-interval is assumed for simplicity ( 1 = 0, 2 = T p ). Larger numbers of sub-intervals were considered in preliminary simulation sessions, but no relevant improvements were observed.

Sliding mode control
In this section, we present a standard formulation of Sliding Mode Control (SMC), that is particularly suitable for mechanical systems. Consider a dynamic system described by the following state equations: where p, v ∈ ℝ n p , x = (p, v) ∈ ℝ n x is the state and u ∈ ℝ n u is the command input; f ∶ ℝ n x → ℝ n p and g ∶ ℝ n x → ℝ n p are two functions characterizing the system dynamics. Note that many mechanical systems can be written in the form (5), with p being a position vector and v a velocity vector. Suppose that the system state x = (p, v) is required to track a desired reference signal r = (p r , v r ) . SMC is a suitable approach to solve this tracking problem. SMC is based on the concept of sliding surface, that is a surface S(t) in the state domain, defined as

Fig. 2 Safety cone definition
where the tracking errors p ≐ p r − p and ṽ ≐ v r − v have been introduced, and k 2 > 0 . A fundamental property of S(t) is that, if the motion of the system state occurs on this surface, then the tracking errors converge to zero [29]. Based on the sliding surface, the following SMC law is defined: where k 1 > 0 . It can be proven that this law is able to bring the system state to the sliding surface and, once there, to keep the state on it [29]. In summary, with this law, the following properties hold: It must be noted that the term with the sign in the control law may cause a phenomenon called chattering (high frequency oscillations around the sliding surface). To avoid this problem, a sigmoid function like the hyperbolic tangent can be used instead: tanh( ) ≃ sign( ) , where is a design parameter determining the sigmoid slope.

Sliding mode controller for attitude control
Considering the Assumption 5, it is possible to design the attitude control using the absolute rotational dynamics of the Chaser, as in [25], instead the relative dynamics Target/Chaser. A standard model is adopted for the chaser attitude motion. In particular, the attitude state equations are obtained using the quaternion kinematic equation and the Euler dynamic equation: where is the chaser quaternion (rotation from the ECEF to the Chaser Body frame), is the chaser angular speed vector, J is the chaser inertia matrix, × denotes the cross product and The goal is to have the state vector x = ( , ) tracking a reference vector ( r , r ) . In order to define a proper SMC law accomplishing this task, we define the angular velocity tracking error as ∼ ≐ r − and the quaternion tracking error as ̇v r − f (x) + k 2ṽ + k 1 sign( (x, t))

3
The Journal of the Astronautical Sciences (2022) 69:312-334 ∼ ≐ * ⊗ r , where * is the conjugate of and ⊗ denotes the quaternion product. A suitable sliding surface function is where q is the imaginary part of ∼ . The SMC law for the system (7) is given by where q 0 is the real part of ∼ . See [30] for a detailed derivation of this control law.

Simulation architecture
The designed controllers are verified using a detailed model and a simulation architecture built in the Matlab/Simulink© environment (Fig. 3). This architecture includes models for disturbance torques (i.e. all the torques due to aerodynamic drag, the solar pressure, gravitational gradient, residual magnetic dipole, and the sloshing of the fuel in the tank) and the disturbance force due to the aerodynamics. The emulation of the attitude and position sensing and estimation is obtained from

Cubesat constraints and initial conditions
In the simulation sessions, the parameters representative of a CubeSat are reported in Table 2: the inertia matrix is diagonal and the mass is compliant with a 12U and an uncertainties of the 10% is added for both the parameters. The maximum controlled forces and torques are limited by the small satellite technology, i.e., the maximum thrust of a miniaturized propulsion system, that guarantees a 3DoF control, and the maximum torque generated by a set of reaction wheels. Table 3 reports the initial conditions with uncertainties angular velocity and attitude, and relative velocity and position.
The satellites travel in a circular orbit with an altitude of 500 km. The controllers sampling time is 0.1 s.
Upper and lower bounds are referred to input values, according to the physical limitations of the propulsion system: the thrusters are able to provide a maximum force equal to 0.035 N. Since the internal model considered in the MPC formulation is based on Clohessy-Wiltshire-Hill equations, whose right hand side (corresponding to the control action) is dimensionally a product between the force produced by thrusters and the mass of the chaser, the following equalities hold:  By adopting the usual trial & error approach, the choice of a smaller prediction horizon T p resulted in a better overall performance and in a slower response of the system. This latter consequence should not be considered a drawback because a slower response of system reduces the overshoots that could not be tolerated in the docking phases. Moreover, a smaller prediction horizon means a reduced computational time. A higher prediction horizon leads to a better performance in terms of final state achievement, at the expense of a larger the complexity of the optimization problem.
The Q matrix has higher values on the lateral position with respect to the approach axis in order to limit or eliminate the overshoots, while lower values are selected for relative position and velocity of the chaser along the approach axis, in order to slow down the response of the system along the approach axis.
A high value is selected for the terminal weight only on the velocity along the approach axis, corresponding to the last diagonal element of the P matrix, in order to meet the requirement on the approach velocity at the end of the simulating sequence.
The R matrix values are close to zero in order to drive the MPC algorithm towards the optimization of states and to exploit all the available actuation, which is a key element in this phase of the manoeuvre. Table 4 reports the main parameters of MPC tuning.
In the state constraints (4), the parameters are = and = 24 , while the constraint on the input u min and u max are −0.7 N and + 0.7 N along each axis.
Referring to the Sliding Mode Control law, discussed in Sect. 3.2, k 1 and k 2 are tuning parameters, respectively aimed at weighting tracking performance and at minimizing the disturbance action on the spacecraft attitude. The tuned values of the SMC are reported in Table 5.   These parameter values were chosen through a "trail & error" procedure using the simulation environment described in Sect. 4.1. The main criterion for the selection of these values was to minimise the misalignment of the thrusters with respect to the main body axes in a sufficiently short time compared to the entire duration of the manoeuvre (resulting in less than 10 seconds).

Simulation results
A robustness analysis was performed by introducing an uncertainty-based setup, in a Monte Carlo simulations framework. All simulations resulted successful, meeting all requirements in Table 1. In order to avoid dwelling on every single set of simulation, however, only the worst-case scenario is analysed here, i.e. the 30 last simulations with the highest amplitude of uncertainties (Table 6).
This set of Monte Carlo simulations shows how the control strategy is proven effective also in the most uncertain condition expected. In Figs. 4 and 5, it is shown how trajectory never exceeds the upper and lower bounds of 2 meters and −2 meters. Due to the high amount of uncertainties, however, a significantly oscillating behaviour is observed in relative position: in such conditions a straight-line trajectory cannot be guaranteed, by means of the discussed control strategy.
Despite the not negligible amplitude and frequency of oscillations, on both z and y axes, the acceptance cone constraint is always satisfied.
As plotted in Figs. 6 and 7, in very close proximity with the target, the previously outlined oscillations do not affect the behaviour of the system, nor the outcome of the RVD procedure which is brought to completion in compliance with requirements, for each developed simulation.
In Fig. 8, the relative velocity time response is shown: this parameter never exceeds the upper bound of 0.8 m/s in any of the performed simulations. The transient is completely expired after 260 s of simulation. The elements of the response reaching the peak value of 0.8 m/s are, for each simulated manoeuvre, referred to the velocity along the approach axis. The contribution of v x is the most relevant, as it is related to position along x-axis, which must be driven from 50 to 0 m to the target. Figure 9 shows that the initial deviation on the desired angular velocity (i.e. 0 rad/s around each axis) is quickly recovered in less than 8 seconds (Fig. 10), limiting the orientation error towards the docking port.
In Fig. 11, the results of the attitude behaviour are outlined: there is no perturbation, along the simulating sequence, apart from a small overshoot at the beginning, due to the disturbing torques slightly affecting rotational dynamics. Every undesired deviation from the reference values is recovered after only 6 seconds (Fig. 12).

3
The Journal of the Astronautical Sciences (2022) 69:312-334   Figure 13 shows, by means of a histogram, the simulation time, in order to evaluate how heavily the uncertain initial conditions can affect the duration of the manoeuvre. Even though the selected control strategy does not directly include time as a variable of the optimization problem, the duration of simulations is mostly kept in the neighbourhood of 580 seconds, with few exceptions in which the manoeuvre lasts even less. This parameter is in line with the time   requirements of a RVD manoeuvre in its final phases. Eight different cases are analysed, as regards MPC tuning, to varying of R matrix parameters. In each case, slightly different results are obtained; for each scenario, those results are compared, as follows, with the problem requirements, in order to verify if the orbit control strategy is effective.  Rendezvous and docking between two nanosatellites is challenging because an high accuracy is required due to the low dimensions of the spacecraft and the current miniaturized technology has lower performance compared with that available for bigger satellites. Advanced control systems can help to improve the confidence level in the accomplishment of the docking manoeuvre.
The paper assesses the capabilities of a Model Predictive Controller and a Sliding Mode Controller to control the chaser trajectory and attitude, respectively. Both the controllers provide an excellent capability to lead the chaser to achieve the docking port with the required accuracy in terms of final position, final attitude, approaching velocity and angular velocity. Using a nonlinear model for simulations and varying the initial state conditions and the mass properties of the chaser, 300 Monte Carlo runs have been performed demonstrating that a final position lower than 0,02 m is achieved, the approaching velocity is lower than 5 mm/s, the relative attitude between chaser and target is lower than 0,1 deg. Moreover, the achieved results show that a relevant margin exists between the performance and the required  values ensuring the capability of the system to work properly in presence of all the uncertainties.
In the future, the proposed solution will be extended considering that the docking port and the docking mechanism frames are not coincident with the body frames of target and chaser, respectively and studies on the collision avoidance manoeuvres will be conducted in order to evaluate the ability of the controller to react in case of off-nominal conditions.
Funding Open access funding provided by Politecnico di Torino within the CRUI-CARE Agreement.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http:// creat iveco mmons. org/ licen ses/ by/4. 0/.