This paper was converted on www.awesomepapers.org from LaTeX by an anonymous user.
Want to know more? Visit the Converter page.

Graph-Based Convexification of Nested Signal Temporal Logic Constraints for Trajectory Optimization

Thomas Claudet Corresponding author: [email protected] ISAE-SUPAERO, 10 Av. E. Belin, 31400 Toulouse, France IRT Saint-Exupéry, 3 Rue Tarfaya, 31400 Toulouse, France Davide Martire ISAE-SUPAERO, 10 Av. E. Belin, 31400 Toulouse, France Damiana Losa Thales Alenia Space, 5 All. des Gabians, 06150 Cannes, France IRT Saint-Exupéry, 3 Rue Tarfaya, 31400 Toulouse, France Francesco Sanfedino ISAE-SUPAERO, 10 Av. E. Belin, 31400 Toulouse, France Daniel Alazard ISAE-SUPAERO, 10 Av. E. Belin, 31400 Toulouse, France
Abstract

Optimizing high-level mission planning constraints is traditionally solved in exponential time and requires to split the problem into several ones, making the connections between them a convoluted task. This paper aims at generalizing recent works on the convexification of Signal Temporal Logic (STL) constraints converting them into linear approximations. Graphs are employed to build general linguistic semantics based on key words (such as Not, And, Or, Eventually, Always), and super-operators (e.g., Until, Implies, If and Only If) based on already defined ones. Numerical validations demonstrate the performance of the proposed approach on two practical use-cases of satellite optimal guidance using a modified Successive Convexification scheme.

1 Introduction

The widespread approach for optimizing high-level mission planning scenarios generally involves parallel or distributed frameworks requiring to split the problem into several segments, often failing in finding global optimal solutions [YYW+19]. Tasks requiring fast generations may opt for fewer segments and more lenient splitting tolerances in their planning, hence trading for precision. On the other hand, highly accurate trajectories involve increased subproblems with tighter splitting tolerances, leading to longer planning times [WBT21]. In any case, tuning of hyper-parameters (number of segments, tolerance) is an inherent limitation which has to be differently approached from one problem to another. By treating the trajectory as a whole, this issue is alleviated, but at the cost of even larger computational efforts. Generally solved using Mixed-Integer Linear Programming (MILP) or related NP-hard techniques [Ric05], these methods suffer from poor scaling capabilities and their integration into agile autonomous systems with low computational capabilities today still remains out of reach.

Another way of looking at high-level mission planning is from the perspective of logic operators. Derived from the linear temporal logic (LTL) theory [Pnu77], logical operators such as And, Or, Eventually, Always, Until provide a formal language to express complex temporal constraints and objectives in optimization models. In [DM10], Signal Temporal Logic (STL) was introduced as a derivative of LTL to guide simulation-based verification of complex nonlinear and hybrid systems against temporal properties. STL was later extended from verification to optimization to fit within a robust Model Predictive Control (MPC) scheme [RDM+14]. Although enabling more intuitive problem-solving approaches, its underlying MILP baseline showed incompressible limits to its applicability for fast, responsive autonomous systems.

To remedy this, in 2022, Y. Mao, B. Açıkmeşe, et al. [MAGC22] were the first to apply STL to convex optimization [BV04], specifically to the Successive Convexification (SCvx) scheme introduced in [MSA16], and benefit from all its fast and global convergence properties to a local optimum provided convexity assumptions. Signal Temporal Logic was also infused into Machine Learning and Deep Learning [MGFS20], [VCDJS17] as well as reinforcement learning [PDN21]. Furthermore, [LAP23] computed the quantitative semantics of STL formulas using computation graphs and perform backpropagation for neural networks using off-the-shelf automatic differentiation tools. However, supervised and reinforcement learning, and especially applied to trajectory optimization, are black boxes requiring enormous amount of realistic data, which makes them problem dependant, training intensive and has no certification for safety critical missions.

For the present study, inherited from the foundations laid down in [MAGC22] and [LAP23], the aim is to bridge the gap between graph-based Signal Temporal Logic and convexification for optimization problem solving. By accompanying the reader through several examples, arbitrarily complex graphs of STL constraints are being discretized and linearized to fit the convex framework. New super-structure of operators are introduced while numerical simulations show the effectiveness of the proposed approach within a modified Successive Convexification scheme. The layout of this work goes as follows:

  • Section 2 presents the STL grammar and its convexification basics;

  • Section 3 focuses on each basic logical operator individually;

  • Section 4 presents operator nesting and proposes a convexification process based on graphs;

  • Section 5 presents new operators which can be derived from existing ones, therefore creating super-operators and getting closer to real-world operations;

  • Section 6 presents simulation results of optimization problems containing real-world operating constraints;

  • Section 7 finally draws conclusions on this work.

2 STL Grammar and Convexification

This section presents the STL grammar (see also [MAGC22]) and the associated convexification process in the context of a general convex optimization problem of type:

minimize𝒖k=1NJ(𝒙k,𝒖k),\underset{\bm{u}}{\mathrm{minimize}}\sum_{k=1}^{N}J\left(\bm{x}_{k},\bm{u}_{k}\right), (1)

subject to the discrete dynamics:

𝒙k+1=𝒇(𝒙k,𝒖k),k=1,2,,N1,\begin{matrix}\bm{x}_{k+1}=\bm{f}\left(\bm{x}_{k},\bm{u}_{k}\right),&k=1,2,\dotso,N-1,\end{matrix} (2)

as well as STL type constraints being introduced in the present work. Additional convex constraints of inequality and equality types can also be implemented in the general vector format:

{𝒈(𝒙k,𝒖k)𝟎𝒉(𝒙k,𝒖k)=𝟎,k=1,2,,N.\left\{\begin{array}[]{ll}\bm{g}(\bm{x}_{k},\bm{u}_{k})\leq\bm{0}\\ \bm{h}(\bm{x}_{k},\bm{u}_{k})=\bm{0}\end{array}\right.,k=1,2,\dotso,N. (3)

2.1 STL Grammar

Signal Temporal Logic uses a specific grammar that is being recalled in this section. The following notations are functional to the STL grammar:

  • 𝒙k\bm{x}_{k} and 𝒖k\bm{u}_{k}: state and control vectors at time instance kk;

  • φ\varphi or ψ\psi: examples of STL predicates found throughout the paper (always expressed in terms of inequality, an equality being a double inequality);

  • μ\mu: generic function of the state and control vectors;

  • πμ\pi^{\mu}: Boolean predicate whose truth value is determined by the sign of the evaluation of μ\mu (i.e. πμ=1μ>0\pi^{\mu}=1\iff\mu>0, 0 otherwise).

Examples of STL formula could be a function expressing the command variable greater than a certain value or expressing the distance between two objects lower than a threshold value. Table 1 presents mathematical key words used in the sequel of this paper and STL operators as building blocks of logical constraints.

Table 1: Mathematical key words and STL operators.
Mathematical Symbol Meaning
Negation ¬\neg
There exists \exists
For all \forall
Implies \implies
If and Only If \iff
Satisfies \models
Is Equivalent \equiv
STL Operator Symbol
And \wedge
Or \lor
Eventually \diamond
Always \Box
Exclusive Or \oplus
Until 𝒰\mathcal{U}

The formal semantics of predicates φ\varphi or/and ψ\psi with respect to a trajectory ξ\xi are defined as follows:

  • A trajectory ξ\xi at time tkt_{k}, denoted (ξ,tk)(\xi,t_{k}) satisfies a predicate πμ\pi^{\mu} if and only if the associated function μ\mu at time kk is positive:

    (ξ,tk)πμμ(𝒙k,𝒖k)>0.(\xi,t_{k})\models\pi^{\mu}\iff\mu(\bm{x}_{k},\bm{u}_{k})>0. (4)
  • A trajectory ξ\xi at time tkt_{k} satisfies the negation of a predicate φ\varphi if and only if the opposite trajectory satisfies φ\varphi:

    (ξ,tk)¬φ¬(ξ,tk)φ.(\xi,t_{k})\models\neg\varphi\iff\neg(\xi,t_{k})\models\varphi. (5)
  • A trajectory ξ\xi at time tkt_{k} satisfies the conjunction φψ\varphi\wedge\psi (respectively disjunction φψ\varphi\lor\psi) if and only if the signal ξ\xi at time tkt_{k} satisfies the STL predicates φ\varphi and ψ\psi (respectively φ\varphi or ψ\psi):

    (ξ,tk)φψ(ξ,tk)φ(ξ,tk)ψ,(\xi,t_{k})\models\varphi\wedge\psi\iff(\xi,t_{k})\models\varphi\wedge(\xi,t_{k})\models\psi, (6)
    (ξ,tk)φψ(ξ,tk)φ(ξ,tk)ψ.(\xi,t_{k})\models\varphi\lor\psi\iff(\xi,t_{k})\models\varphi\lor(\xi,t_{k})\models\psi. (7)
  • A trajectory ξ\xi satisfies Eventually (\diamond) φ\varphi between time aa and bb if and only if there exists at least one time in that interval [a,b][a,b] where the predicate φ\varphi is satisfied:

    ξ[a,b]φtk[a,b],(ξ,tk)φ.\xi\models\diamond_{[a,b]}\varphi\iff\exists t_{k}\in[a,b],(\xi,t_{k})\models\varphi. (8)
  • A trajectory ξ\xi satisfies Always (\Box) φ\varphi between time aa and bb if and only if the predicate φ\varphi is satisfied for each time between the interval [a,b][a,b]:

    ξ[a,b]φtk[a,b],(ξ,tk)φ.\xi\models\Box_{[a,b]}\varphi\iff\forall t_{k}\in[a,b],(\xi,t_{k})\models\varphi. (9)

2.1.1 STL Margin Measure

In the above STL Eqs. (4) to (9), the result is a Boolean: either the property is True, or False. In order to gain more insight, a margin function is introduced to better classify an STL expression. The margin function ρ\rho defines the truth of the STL formula as shown in Fig. 1. This margin function is computed using minimum and maximum functions for the STL operators introduced in Table 1 and used in Eqs. (4) to (9).

Let us consider a practical example to better illustrate the interest of the margin function ρ\rho. By denoting the position of an autonomous system as 𝒓\bm{r}, the condition 𝒓(t)d\lVert\bm{r}(t)\rVert\geq d states that at time tt the system remains at a distance greater than a certain value dd from an obstacle located at the reference frame’s origin. In that case, defining a margin function such that ρ(t)=𝒓(t)d\rho(t)=\lVert\bm{r}(t)\rVert-d, the security condition is satisfied at time t if and only if ρ\rho is positive at tt. STL formulas (4) to (9) can be expressed as follows, in terms of margin semantics using margin functions.

The complete robust semantics for Eq. (4) is given by:

ρkπμ=μ(𝒙k,𝒖k).\rho^{\pi^{\mu}}_{k}=\mu(\bm{x}_{k},\bm{u}_{k}). (10)

Margin function for the negation of a property ψ\psi of the Eq. (5) is given by:

ρk¬ψ=ρkψ.\rho^{\neg\psi}_{k}=-\rho^{\psi}_{k}. (11)

Margin function of Eq. (6) as conjunction satisfies the following minimum property in terms of margin functions of φ\varphi and ψ\psi:

ρkφψ=min(ρkφ,ρkψ).\rho^{\varphi\wedge\psi}_{k}=\min(\rho^{\varphi}_{k},\rho^{\psi}_{k}). (12)

Instead, margin function of Eq. (7) as disjunction satisfies the following maximum property in terms or margin functions of φ\varphi and ψ\psi:

ρkφψ=max(ρkφ,ρkψ).\rho^{\varphi\lor\psi}_{k}=\max(\rho^{\varphi}_{k},\rho^{\psi}_{k}). (13)

Margin function of Eq. (8) (involving constraint Eventually (\diamond) φ\varphi True between time aa and bb) is positive when the maximum of the constraint margin function is positive in the interval:

ρ[a,b]φ=maxk[a,b]ρkφ.\rho^{\diamond_{[a,b]}\varphi}=\max\limits_{k\in[a,b]}\rho^{\varphi}_{k}. (14)

Margin function of Eq. (9) (involving constraint Always (\Box) φ\varphi True between time aa and bb) is positive when the minimum of the constraint margin function is positive in the interval:

ρ[a,b]φ=mink[a,b]ρkφ.\rho^{\square_{[a,b]}{\varphi}}=\min\limits_{k\in{[a,b]}}\rho^{\varphi}_{k}. (15)
Refer to caption
Figure 1: The margin function. When the area is blue (respectively pink) the constraint is True (respectively False).

2.2 STL Convexification

The convexification process is made of three steps. First, discretization to make the problem suitable for numerical evaluations and implementation on computers. Then, the second step is linearization to approximate nonlinear functions and work with convenient linear methods. Finally, the third step is to concatenate the linearizations into a linear system of equations, being a suitable input for optimization problem solvers. This section discusses these three steps in greater details.

2.2.1 Discretization

As it was seen in Section 2.1.1, the margin of the operators are functions of time and derived from minmin and maxmax functions. So, to model this in the discrete world, new variables (scalars), denoted as STL-variables, representing the margin (which is a scalar) evaluated at each time step, are introduced:

𝜶=[α1αN].\bm{\alpha}=\left[\begin{array}[]{c}\alpha_{1}\\ \vdots\\ \alpha_{N}\end{array}\right]. (16)

The STL-variable vector augments the state vector of the optimization variables:

𝒙=[𝒙1𝒙N],\bm{x}=\left[\begin{array}[]{c}\bm{x}_{1}\\ \vdots\\ \bm{x}_{N}\end{array}\right], (17)

to give:

𝒛=[𝒙𝜶].\bm{z}=\left[\begin{array}[]{c}\bm{x}\\ \hline\cr\bm{\alpha}\end{array}\right]. (18)

The goal is to replicate the behavior of the max or min functions over time intervals [a,b][a,b]. The extremum is initialized at the first value of the interval and propagates through it. The obtained value at the end of the interval is kept until the end. It follows:

{αk=ρkaφαk+1=χ(αk,ρk+1φ)αk=αkbk=1,,kak=ka,,kb1k=kb+1,,N,\left\{\begin{matrix}\begin{array}[]{ll}\alpha_{k}=\rho^{\varphi}_{k_{a}}\\ \alpha_{k+1}=\chi(\alpha_{k},\rho^{\varphi}_{k+1})\\ \alpha_{k}=\alpha_{k_{b}}\end{array}&\begin{array}[]{ll}\forall k=1,\dots,k_{a}\\ \forall k=k_{a},\dots,k_{b}-1\\ \forall k=k_{b}+1,\dots,N\end{array}\end{matrix}\right., (19)

where χ\chi is a general function representing the margin, e.g., functions minmin or maxmax.

Between times aa and bb, the STL-variable vector 𝜶\bm{\alpha} is now defined as a sequence of scalar variables (αk)(ka:kb)(\alpha_{k})_{(k_{a}:k_{b})} following the discrete dynamics:

αk+1=χ(αk,ρk+1φ).\alpha_{k+1}=\chi(\alpha_{k},\rho^{\varphi}_{k+1}). (20)

The margin function, in turn, depends on the dynamics of the system under control:

ρk+1φ=ρk+1φ(𝒙k+1).\rho^{\varphi}_{k+1}=\rho^{\varphi}_{k+1}\left(\bm{x}_{k+1}\right). (21)

2.2.2 Linearization

Now, the STL-variables are defined over the whole time horizon to follow the continuous definition of the margin function. In particular, the functions minmin and maxmax are not linear as function of the other STL-variables, not even differentiable (indeed the maximum and minimum function have sharp edges at the flips). Function ρφ\rho^{\varphi} is in general not linear as well (e.g. when asking for a distance between an object and an obstacle being greater that a threshold, the norm function is involved). These kinds of functions are not straightforwardly implementable in a standard convex optimization algorithm. A linearization step is then performed to cope with this framework.

Let us assume that function χ\chi is differentiable. In that case, it would be desired to consider the STL-variables appearing linearly to build a linear system of equations. Using the chain rule (derivation of function composition), the approximation to the first order of the Taylor expansion leads:

αk+1=χ(αk,ρk+1φ)χ(α¯k,ρ¯k+1φ)+χαk|α¯k,ρ¯k+1φ(αkα¯k)+χρk+1φ|α¯k,ρ¯k+1φρk+1φ𝒙k+1|𝒙¯k+1(𝒙k+1𝒙¯k+1),\alpha_{k+1}=\chi(\alpha_{k},\rho^{\varphi}_{k+1})\approx\chi(\bar{\alpha}_{k},\bar{\rho}^{\varphi}_{k+1})+\left.\frac{\partial\chi}{\partial\alpha_{k}}\right|_{\bar{\alpha}_{k},\bar{\rho}^{\varphi}_{k+1}}(\alpha_{k}-\bar{\alpha}_{k})+\left.\frac{\partial\chi}{\partial\rho^{\varphi}_{k+1}}\right|_{\bar{\alpha}_{k},\bar{\rho}^{\varphi}_{k+1}}\left.\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}_{k+1}}\right|_{\bar{\bm{x}}_{k+1}}(\bm{x}_{k+1}-\bar{\bm{x}}_{k+1}), (22)

where the notation x¯j\bar{x}_{j} for any general variable xx represents the reference of xx at time jj (e.g. either of the initialization or the last optimal iteration). Introducing the zero order term:

R(α¯k,𝒙¯k+1)=χ(α¯k,ρ¯k+1φ)χαk|α¯k,ρ¯k+1φα¯kχρk+1φ|α¯k,ρ¯k+1φρk+1φ𝒙k+1|𝒙¯k+1𝒙¯k+1,R(\bar{\alpha}_{k},\bar{\bm{x}}_{k+1})=\chi(\bar{\alpha}_{k},\bar{\rho}^{\varphi}_{k+1})-\left.\frac{\partial\chi}{\partial\alpha_{k}}\right|_{\bar{\alpha}_{k},\bar{\rho}^{\varphi}_{k+1}}\bar{\alpha}_{k}-\left.\frac{\partial\chi}{\partial\rho^{\varphi}_{k+1}}\right|_{\bar{\alpha}_{k},\bar{\rho}^{\varphi}_{k+1}}\left.\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}_{k+1}}\right|_{\bar{\bm{x}}_{k+1}}\bar{\bm{x}}_{k+1}, (23)

Dropping the reference notation for the gradients in the following part of the paper, for the sake of conciseness, one finally gets:

αk+1=R(α¯k,𝒙¯k+1)+χαkαk+χρk+1φρk+1φ𝒙k+1𝒙k+1.\alpha_{k+1}=R(\bar{\alpha}_{k},\bar{\bm{x}}_{k+1})+\frac{\partial\chi}{\partial\alpha_{k}}\alpha_{k}+\frac{\partial\chi}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}_{k+1}}\bm{x}_{k+1}. (24)

Equation (24) is now linear in the STL-variables 𝜶\bm{\alpha} and in the dynamic state variables 𝒛\bm{z}. Function χ\chi, when equal to minmin or maxmax, is not differentiable. However, as proposed in [MAGC22], it can be approximated with smoothed functions (sminsmin and smaxsmax for minmin and maxmax respectively). Function sminsmin and smaxsmax are defined as follows (see also Fig. 2 depicting an example):

smin(a,b,κ)={bagmin(a,b,κ)ifififabκabκab[κ,,κ],smin(a,b,\kappa)=\left\{\begin{matrix}\begin{array}[]{ll}b\\ a\\ g_{min}(a,b,\kappa)\end{array}&\begin{array}[]{ll}\mathrm{if}\\ \mathrm{if}\\ \mathrm{if}\end{array}&\begin{array}[]{ll}a-b\geq\kappa\\ a-b\leq-\kappa\\ a-b\in[-\kappa,\dots,\kappa]\end{array}\end{matrix}\right., (25)

where gming_{min} is the smoothing function:

gmin(a,b,κ)=a(1h)+hbκh(1h),withh=12+ab2κ,\begin{matrix}g_{min}(a,b,\kappa)=a(1-h)+hb-\kappa h(1-h),&\mathrm{with}&h=\frac{1}{2}+\frac{a-b}{2\kappa}\end{matrix}, (26)

dependent on its smoothing gain κ\kappa.

As stated in Eq. (24), partial derivatives of the margin functions are essential to define the STL-variable dynamics:

smina(a,b,κ)={011hifififabκabκab[κ,,κ],\frac{\partial smin}{\partial a}(a,b,\kappa)=\left\{\begin{matrix}\begin{array}[]{ll}0\\ 1\\ 1-h\end{array}&\begin{array}[]{ll}\mathrm{if}\\ \mathrm{if}\\ \mathrm{if}\end{array}&\begin{array}[]{ll}a-b\geq\kappa\\ a-b\leq-\kappa\\ a-b\in[-\kappa,\dots,\kappa]\end{array}\end{matrix}\right., (27)
sminb(a,b,κ)={10hifififabκabκab[κ,,κ].\frac{\partial smin}{\partial b}(a,b,\kappa)=\left\{\begin{matrix}\begin{array}[]{ll}1\\ 0\\ h\end{array}&\begin{array}[]{ll}\mathrm{if}\\ \mathrm{if}\\ \mathrm{if}\end{array}&\begin{array}[]{ll}a-b\geq\kappa\\ a-b\leq-\kappa\\ a-b\in[-\kappa,\dots,\kappa]\end{array}\end{matrix}\right.. (28)

Caution has to be taken by the reader since sminsmaxsmin\neq-smax. Indeed, function smaxsmax is defined as:

smax(a,b,κ)={bagmax(a,b,κ)ifififbaκbaκba[κ,,κ],smax(a,b,\kappa)=\left\{\begin{matrix}\begin{array}[]{ll}b\\ a\\ g_{max}(a,b,\kappa)\end{array}&\begin{array}[]{ll}\mathrm{if}\\ \mathrm{if}\\ \mathrm{if}\end{array}&\begin{array}[]{ll}b-a\geq\kappa\\ b-a\leq-\kappa\\ b-a\in[-\kappa,\dots,\kappa]\end{array}\end{matrix}\right., (29)

where gmaxg_{max} is the smoothing function:

gmax(a,b,κ)=b(1h)+ha+κh(1h),withh=12+ab2κ,\begin{matrix}g_{max}(a,b,\kappa)=b(1-h)+ha+\kappa h(1-h),&\mathrm{with}&h=\frac{1}{2}+\frac{a-b}{2\kappa}\end{matrix}, (30)

dependent on its smoothing gain κ\kappa.

Partial derivatives of the margin function smaxsmax are the following:

smina(a,b,κ)={01hifififbaκbaκba[κ,,κ],\frac{\partial smin}{\partial a}(a,b,\kappa)=\left\{\begin{matrix}\begin{array}[]{ll}0\\ 1\\ h\end{array}&\begin{array}[]{ll}\mathrm{if}\\ \mathrm{if}\\ \mathrm{if}\end{array}&\begin{array}[]{ll}b-a\geq\kappa\\ b-a\leq-\kappa\\ b-a\in[-\kappa,\dots,\kappa]\end{array}\end{matrix}\right., (31)
sminb(a,b,κ)={101hifififbaκbaκba[κ,,κ].\frac{\partial smin}{\partial b}(a,b,\kappa)=\left\{\begin{matrix}\begin{array}[]{ll}1\\ 0\\ 1-h\end{array}&\begin{array}[]{ll}\mathrm{if}\\ \mathrm{if}\\ \mathrm{if}\end{array}&\begin{array}[]{ll}b-a\geq\kappa\\ b-a\leq-\kappa\\ b-a\in[-\kappa,\dots,\kappa]\end{array}\end{matrix}\right.. (32)

These partial derivatives will allow to implement the derivatives of χ={min,max}\chi=\{min,max\} with respect to its variables as seen in (24).

In cases where the margin functions might not be differentiable at certain points (e.g., the norm function is not differentiable at 0), a null gradient can, for instance, be automatically introduced when performing the computation at these singular points. Of course, the smaller the κ\kappa, the better the approximation (in practice, not thinking about differentiability, κ=0\kappa=0 seemed of no concern in this work). Maybe some edge cases could be found in highly nonlinear settings, but with a usual step size, the vicinity of the flips is rarely, not to say never, encountered in practical applications. The takeaway is probably that that there is a parameter which can smoothen the dynamics if needed. In the following, the κ\kappa input of χ\chi will be omitted for conciseness.

Refer to caption
Figure 2: The smoothed margin function with respect to time. The green (respectively blue) line represents the evolution of ρφ\rho^{\varphi} (respectively ρψ\rho^{\psi}). The red dashed lines represent different smoothing parameters when using the smaxsmax function.

2.2.3 Convex Framework

After discretizing and linearizing the robust semantics of the STL-formulas, the final step is to transform the STL-variable dynamics equations into a convex matrix form of type 𝑨𝒛=𝒃\bm{Az}=\bm{b}, where:

  • 𝑨\bm{A} is defined as the state-transition matrix;

  • 𝒛\bm{z} is the augmented optimization vector composed of the state optimization variable vector 𝒙\bm{x} and of the STL-variable vector 𝜶\bm{\alpha});

  • 𝒃\bm{b} is the vector independent on the optimization variables.

To define these three convex framework elements on the basis of the discrete and linearized dynamics of Eqs (19) and (24), the following mathematical notation are used:

  • 𝑰K\bm{I}_{K} is an identity square matrix of size KK;

  • 𝟎K\bm{0}_{K} is a column vector of length KK with all its elements equal to 0;

  • 𝟎K1,K2\bm{0}_{K_{1},K_{2}} is a zero matrix with K1K_{1} rows and K2K_{2} columns;

  • 𝟏K\bm{1}_{K} is a column vector of length KK with all its elements equal to 1;

  • diag([u1um])K\mathrm{diag}\left(\left[\begin{matrix}u_{1}\dots u_{m}\end{matrix}\right]\right)_{K} is a diagonal concatenation of KK blocks, each equal to the row vector [u1um]\left[\begin{matrix}u_{1}\dots u_{m}\end{matrix}\right];

  • diag([f(v1k),f(vmk)])K1:K2\mathrm{diag}\left(\left[f(v_{1k}),\dots f(v_{mk})\right]\right)_{K_{1}:K_{2}} is a diagonal concatenation of K2K1+1K_{2}-K_{1}+1 blocks, equal to [f(v1k),f(vmk)]\left[f(v_{1k}),\dots f(v_{mk})\right] for k=K1,,K2k=K_{1},\dots,K_{2}.

Compact convex formulation 𝑨𝒛=𝒃\bm{Az}=\bm{b} is based on the following definitions:

  1. 1.

    For matrix 𝑨\bm{A}:

    𝑨=[𝟎ka,ka𝟎ka,kbka𝟎ka,Nkb𝑰ka𝟎ka,kbka𝟎ka,Nkb𝟎kbka,ka𝑨𝟐𝟐𝟎kbka,Nkb𝟎kbka,ka𝑨𝟐𝟓𝟎kbka,Nkb𝟎Nkb,ka𝟎Nkb,kbka𝟎Nkb,Nkb𝟎Nkb,ka𝟎Nkb,kbka𝑨𝟑𝟔],\bm{A}=\left[\begin{array}[]{ccc|ccc}\bm{0}_{k_{a},k_{a}}&\bm{0}_{k_{a},k_{b}-k_{a}}&\bm{0}_{k_{a},N-k_{b}}&\bm{I}_{k_{a}}&\bm{0}_{k_{a},k_{b}-k_{a}}&\bm{0}_{k_{a},N-k_{b}}\\ \bm{0}_{k_{b}-k_{a},k_{a}}&\bm{A_{22}}&\bm{0}_{k_{b}-k_{a},N-k_{b}}&\bm{0}_{k_{b}-k_{a},k_{a}}&\bm{A_{25}}&\bm{0}_{k_{b}-k_{a},N-k_{b}}\\ \bm{0}_{N-k_{b},k_{a}}&\bm{0}_{N-k_{b},k_{b}-k_{a}}&\bm{0}_{N-k_{b},N-k_{b}}&\bm{0}_{N-k_{b},k_{a}}&\bm{0}_{N-k_{b},k_{b}-k_{a}}&\bm{A_{36}}\end{array}\right], (33)

    with:

    𝑨𝟐𝟐=diag([χρk+1φρk+1φ𝒙k+1φ])ka:kb1,\bm{A_{22}}=\mathrm{diag}\left(\left[\frac{\partial\chi}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\right]\right)_{k_{a}:k_{b}-1}, (34)
    𝑨𝟐𝟓=diag([χαk1])ka:kb1,\bm{A_{25}}=\mathrm{diag}\left(\left[\begin{matrix}\frac{\partial\chi}{\partial\alpha_{k}}&-1\end{matrix}\right]\right)_{k_{a}:k_{b}-1}, (35)
    𝑨𝟑𝟔=diag([11])Nkb.\bm{A_{36}}=\mathrm{diag}\left(\left[\begin{matrix}1&-1\end{matrix}\right]\right)_{N-k_{b}}. (36)
  2. 2.

    For vector 𝒛\bm{z}:

    𝒛=[𝒙φ𝜶].\bm{z}=\left[\begin{array}[]{c}\bm{x}^{\varphi}\\ \hline\cr\bm{\alpha}\end{array}\right]. (37)
  3. 3.

    For vector 𝒃\bm{b}:

    𝒃=[ρ¯kaφ𝟏kadiag([R(α¯k,𝒙¯k+1φ)])ka:kb1𝟏kbka𝟎Nkb].\bm{b}=\begin{bmatrix}\bar{\rho}^{\varphi}_{k_{a}}\bm{1}_{k_{a}}\\ -\mathrm{diag}\left(\left[R(\bar{\alpha}_{k},\bar{\bm{x}}^{\varphi}_{k+1})\right]\right)_{k_{a}:k_{b}-1}\bm{1}_{k_{b}-k_{a}}\\ \bm{0}_{N-k_{b}}\end{bmatrix}. (38)

This linear system of equations can then be concatenated with the other physical dynamics linear constraints to obtain an augmented optimization problem, which will then be fed to the convex optimization solver (e.g., second-order cone, semi-definite).

Finally, it remains a very last constraint, which is actually the most natural and important. Let us recall that the STL constraint will be satisfied if and only if the margin function is positive. This can be enforced by asking the last time step of the STL variable to be positive:

αN0.\alpha_{N}\geq 0. (39)

Note that all the constraints are made to specifically arrive to this one.

3 Isolated STL Operators

This section presents the STL operators one by one as introduced in [MAGC22]. In Section 4, nesting of these STL operators considered as building blocks will be presented. This paper introduces the classification of the four main operators And, Or, Eventually, Always as operators of type Bridge Operator or Flow.

  • An operator is of Bridge type when it connects two inputs and generates only one output. And and Or are examples of Bridge operators.

  • An operator is of Flow type when it is connected to a single input and generates a single output. Eventually and Always are examples of Flow operators.

3.1 Bridge Operators

3.1.1 And

Let φ\varphi and ψ\psi, be two predicates. The conjunction operator between φ\varphi and ψ\psi is shown in Fig. 3, represented by a graph.

Refer to caption
Figure 3: Graph of the And operator.

In terms of robust STL semantics, the margin function of the conjunction operator can be expressed as a minimum function:

min(ρφ,ρψ).min(\rho^{\varphi},\rho^{\psi}). (40)

The discretization gives

αk+1=min(ρk+1φ,ρk+1ψ),k=0,1,,N1.\alpha_{k+1}=min(\rho^{\varphi}_{k+1},\rho^{\psi}_{k+1}),\;\;\;\forall k=0,1,\dots,N-1. (41)

Defining as 𝒙φ\bm{x}^{\varphi} (respectively 𝒙ψ\bm{x}^{\psi}) the state variable vector used to write predicate φ\varphi (respectively ψ\psi), the linearization provides:

αk+1=R(𝒙¯k+1φ,𝒙¯k+1ψ)+sminρk+1φρk+1φ𝒙k+1φ𝒙k+1φ+sminρk+1ψρk+1ψ𝒙k+1ψ𝒙k+1ψ.\alpha_{k+1}=R(\bar{\bm{x}}^{\varphi}_{k+1},\bar{\bm{x}}^{\psi}_{k+1})+\frac{\partial smin}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\;\bm{x}^{\varphi}_{k+1}+\frac{\partial smin}{\partial\rho^{\psi}_{k+1}}\frac{\partial\rho^{\psi}_{k+1}}{\partial\bm{x}^{\psi}_{k+1}}\bm{x}^{\psi}_{k+1}. (42)

In general, the states considered by the two margin functions are completely different. For instance, one could use the positions, while the other one the attitude. In that case, they would have to be positioned differently in the STL matrix 𝑨\bm{A}, easily made with an automated routine.

The terms of the compact convex formulation 𝑨𝒛=𝒃\bm{Az}=\bm{b} becomes:

  1. 1.

    For matrix 𝑨\bm{A}:

    𝑨=[diag([sminρk+1φρk+1φ𝒙k+1φ])0:N1diag([sminρk+1ψρk+1ψ𝒙k+1ψ])0:N1𝑰N],\bm{A}=\begin{bmatrix}\begin{array}[]{c|c|c}\mathrm{diag}\left(\left[\frac{\partial smin}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\right]\right)_{0:N-1}&\mathrm{diag}\left(\left[\frac{\partial smin}{\partial\rho^{\psi}_{k+1}}\frac{\partial\rho^{\psi}_{k+1}}{\partial\bm{x}^{\psi}_{k+1}}\right]\right)_{0:N-1}&-\bm{I}_{N}\end{array}\end{bmatrix}, (43)
  2. 2.

    For vector 𝒛\bm{z}:

    𝒛=[𝒙φ𝒙ψ𝜶],\bm{z}=\left[\begin{array}[]{c}\bm{x}^{\varphi}\\ \hline\cr\bm{x}^{\psi}\\ \hline\cr\bm{\alpha}\end{array}\right], (44)
  3. 3.

    For vector 𝒃\bm{b}:

    𝒃=diag([R(𝒙¯k+1φ,𝒙¯k+1ψ)])0:N1𝟏N.\bm{b}=-\mathrm{diag}\left(\left[R(\bar{\bm{x}}^{\varphi}_{k+1},\bar{\bm{x}}^{\psi}_{k+1})\right]\right)_{0:N-1}\bm{1}_{N}. (45)

Taking the analogy with electric circuits, the system would look like Fig. 4:

Refer to caption
Figure 4: Electronic circuit of the And operator.

3.1.2 Or

Let φ\varphi and ψ\psi, be two predicates. The disjunction operator between φ\varphi and ψ\psi is shown in Fig. 3, represented by a graph.

Refer to caption
Figure 5: Graph of the Or operator.

In terms of robust STL semantics, the margin function of the disjunction operator can be expressed as a maximum function:

max(ρφ,ρψ).max(\rho^{\varphi},\rho^{\psi}). (46)

The discretization gives:

αk+1=max(ρk+1φ,ρk+1ψ),k=0,1,,N1.\alpha_{k+1}=max(\rho^{\varphi}_{k+1},\rho^{\psi}_{k+1}),\;\;\;\forall k=0,1,\dots,N-1. (47)

Defining as 𝒙φ\bm{x}^{\varphi} (respectively 𝒙ψ\bm{x}^{\psi}) the state variable vector used to write predicate φ\varphi (respectively ψ\psi), the linearization provides:

αk+1=R(𝒙¯k+1φ,𝒙¯k+1ψ)+smaxρk+1φρk+1φ𝒙k+1φ𝒙k+1φ+smaxρk+1ψρk+1ψ𝒙k+1ψ𝒙k+1ψ.\alpha_{k+1}=R(\bar{\bm{x}}^{\varphi}_{k+1},\bar{\bm{x}}^{\psi}_{k+1})+\frac{\partial smax}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\;\bm{x}^{\varphi}_{k+1}+\frac{\partial smax}{\partial\rho^{\psi}_{k+1}}\frac{\partial\rho^{\psi}_{k+1}}{\partial\bm{x}^{\psi}_{k+1}}\bm{x}^{\psi}_{k+1}. (48)

In general, the states considered by the two margin functions are completely different. For instance, one could use the positions, while the other one the attitude. In that case, they would have to be positioned differently in the STL matrix 𝑨\bm{A}, easily made with an automated routine.

The terms of the compact convex formulation 𝑨𝒛=𝒃\bm{Az}=\bm{b} becomes:

  1. 1.

    For matrix 𝑨\bm{A}:

    𝑨=[diag([smaxρk+1φρk+1φ𝒙k+1φ])0:N1diag([smaxρk+1ψρk+1ψ𝒙k+1ψ])0:N1𝑰N],\bm{A}=\begin{bmatrix}\begin{array}[]{c|c|c}\mathrm{diag}\left(\left[\frac{\partial smax}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\right]\right)_{0:N-1}&\mathrm{diag}\left(\left[\frac{\partial smax}{\partial\rho^{\psi}_{k+1}}\frac{\partial\rho^{\psi}_{k+1}}{\partial\bm{x}^{\psi}_{k+1}}\right]\right)_{0:N-1}&-\bm{I}_{N}\end{array}\end{bmatrix}, (49)
  2. 2.

    For vector 𝒛\bm{z}:

    𝒛=[𝒙φ𝒙ψ𝜶],\bm{z}=\left[\begin{array}[]{c}\bm{x}^{\varphi}\\ \hline\cr\bm{x}^{\psi}\\ \hline\cr\bm{\alpha}\end{array}\right], (50)
  3. 3.

    For vector 𝒃\bm{b}:

    𝒃=diag([R(𝒙¯k+1φ,𝒙¯k+1ψ)])0:N1𝟏N.\bm{b}=-\mathrm{diag}\left(\left[R(\bar{\bm{x}}^{\varphi}_{k+1},\bar{\bm{x}}^{\psi}_{k+1})\right]\right)_{0:N-1}\bm{1}_{N}. (51)

Taking the analogy with electric circuits, the system would look like Fig. 6:

Refer to caption
Figure 6: Electronic circuit of the Or operator.

3.2 Flow Operators

3.2.1 Always

The Always operator is an operator of flow type, it asks for a property to always be True inside of a time window, which can cover the whole simulation. The Always operator is shown in Fig. 7 represented by a graph.

Refer to caption
Figure 7: Graph of the Always operator.

In terms of robust STL semantics, the margin function of this operator can be seen as a recurrent conjunction active at each time step of the time window. The discretization of this operator gives:

{αk=ρkaφαk+1=min(αk,ρk+1φ)αk=αkbk=1,,kak=ka,,kb1k=kb+1,,N,\left\{\begin{matrix}\begin{array}[]{ll}\alpha_{k}=\rho^{\varphi}_{k_{a}}\\ \alpha_{k+1}=\min(\alpha_{k},\rho^{\varphi}_{k+1})\\ \alpha_{k}=\alpha_{k_{b}}\end{array}&\begin{array}[]{ll}\forall k=1,\dots,k_{a}\\ \forall k=k_{a},\dots,k_{b}-1\\ \forall k=k_{b}+1,\dots,N\end{array}\end{matrix}\right., (52)

The terms of the compact convex formulation 𝑨𝒛=𝒃\bm{Az}=\bm{b} have the same expression as the ones in Eqs (33)-(38) with:

𝑨𝟐𝟐=diag([sminρk+1φρk+1φ𝒙k+1φ])ka:kb1,\bm{A_{22}}=\mathrm{diag}\left(\left[\frac{\partial smin}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\right]\right)_{k_{a}:k_{b}-1}, (53)
𝑨𝟐𝟓=diag([sminαk1])ka:kb1.\bm{A_{25}}=\mathrm{diag}\left(\left[\begin{matrix}\frac{\partial smin}{\partial\alpha_{k}}&-1\end{matrix}\right]\right)_{k_{a}:k_{b}-1}. (54)

Taking the analogy with electric circuits, the system would look like Fig. 8.

Refer to caption
Figure 8: Electronic circuitry of the Always operator.

3.2.2 Eventually

The Eventually operator is an operator of flow type, it asks for a property to be True at least once inside of a time window, which can cover the whole simulation. The Eventually operator is shown in Fig. 9 represented by a graph.

Refer to caption
Figure 9: Graph of the Eventually operator.

In terms of robust STL semantics, the margin function of this operator can be seen as a recurrent disjunction active at each time step of the time window. The discretization of this operator gives:

{αk=ρkaφαk+1=max(αk,ρk+1φ)αk=αkbk=1,,kak=ka,,kb1k=kb+1,,N.\left\{\begin{matrix}\begin{array}[]{ll}\alpha_{k}=\rho^{\varphi}_{k_{a}}\\ \alpha_{k+1}=\max(\alpha_{k},\rho^{\varphi}_{k+1})\\ \alpha_{k}=\alpha_{k_{b}}\end{array}&\begin{array}[]{ll}\forall k=1,\dots,k_{a}\\ \forall k=k_{a},\dots,k_{b}-1\\ \forall k=k_{b}+1,\dots,N\end{array}\end{matrix}\right.. (55)

The terms of the compact convex formulation 𝑨𝒛=𝒃\bm{Az}=\bm{b} have the same expression of Eqs (33)-(38) with:

𝑨𝟐𝟐=diag([smaxρk+1φρk+1φ𝒙k+1φ])ka:kb1,\bm{A_{22}}=\mathrm{diag}\left(\left[\frac{\partial smax}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}^{\varphi}_{k+1}}\right]\right)_{k_{a}:k_{b}-1}, (56)
𝑨𝟐𝟓=diag([smaxαk1])ka:kb1.\bm{A_{25}}=\mathrm{diag}\left(\left[\begin{matrix}\frac{\partial smax}{\partial\alpha_{k}}&-1\end{matrix}\right]\right)_{k_{a}:k_{b}-1}. (57)

Taking the analogy with electric circuits, the system would look like Fig. 10.

Refer to caption
Figure 10: Electronic circuitry of the Eventually operator.

4 Nested STL Operators

Nested (i.e., concatenated) STL operators can be used to express complex constraints. This section presents a method to deal with nested STL operators based on graphs. In a graph representing a complex logic expression, the roots (i.e., the first generation parents) are all the predicates of the expression. The top node of the graph (i.e., the youngest child) must be an operator of Flow type (e.g., Always or Eventually). This means that, for example, at the very top of the graph, a Bridge expression as φψ\varphi\lor\psi is not accepted. To be more precise, a Bridge operator always has to be attached to a Flow operator above it (e.g., to form (φψ))\Box(\varphi\lor\psi)). This allows to obtain a unequivocal output that does not lead to misunderstandings.

Following this logic, it is possible for each operator to only look at one child down the tree and there is a general formulation to connect them to the rest of the tree.

In the following, the naming conventions of STL variables follows the order of the Greek alphabet the higher in the tree the operator is.

4.1 Nested Flow Operators

A Flow type operator is, by definition, connected to a single input. This is the case for the operator with STL variable vector 𝜷\bm{\beta} in Fig. 11. The input Flow type operator can either be the output of another STL operator (e.g., \Box or \diamond), or a simple predicate (e.g., φ\varphi).

Refer to caption
(a)
Refer to caption
(b)
Figure 11: General graphs for the Flow operators. (a) Connection to another STL variable. (b) Direct connection to a predicate. The clouds in blue and yellow represent the rest of the graph. 𝒮\mathcal{S} is the STL variable space while Φ\Phi represents the root predicate space.

The equations governing the transition at the Flow operator level are the following for the case represented in Fig. 11(a) and 11(b) respectively:

βk+1=χβkβk+χαk+1αk+1+R(β¯k,α¯k+1)if𝒫β𝒮,\begin{matrix}\beta_{k+1}=\frac{\partial\chi}{\partial\beta_{k}}\beta_{k}+\frac{\partial\chi}{\partial\alpha_{k+1}}\alpha_{k+1}+R(\bar{\beta}_{k},\bar{\alpha}_{k+1})&\text{if}&\mathcal{P^{\beta}}\in\mathcal{S},\end{matrix} (58)
βk+1=χβkβk+χρk+1φρk+1φ𝒙k+1𝒙k+1+R(β¯k,𝒙¯k+1)if𝒫βΦ.\begin{matrix}\beta_{k+1}=\frac{\partial\chi}{\partial\beta_{k}}\beta_{k}+\frac{\partial\chi}{\partial\rho^{\varphi}_{k+1}}\frac{\partial\rho^{\varphi}_{k+1}}{\partial\bm{x}_{k+1}}\bm{x}_{k+1}+R(\bar{\beta}_{k},\bar{\bm{x}}_{k+1})&\text{if}&\mathcal{P^{\beta}}\in\Phi.\end{matrix} (59)

In the above expressions

  • 𝒫β\mathcal{P}^{\beta} is the space of the parent node associated to STL variable 𝜷\bm{\beta};

  • 𝒮\mathcal{S} is the space of all the STL variables of all the STL complex expressions;

  • Φ\Phi is the root predicate space.

For instance, if the Flow operator is connected to an STL expression (e.g., (φψ)\Box(\varphi\wedge\psi)) as in Fig. 11(a), then 𝒫β𝒮\mathcal{P}^{\beta}\in\mathcal{S}. On the other hand, if the flow is directly linked to the predicate φ\varphi as in Fig. 11(b), then 𝒫βΦ\mathcal{P}^{\beta}\in\Phi. In cases where the time windows do not cover the whole simulations, the three cases as shown in Eq. (52) or (55) are being used. They are not written again for conciseness.

4.2 Nested Bridge Operators

General graphs containing a Bridge type operator with STL variable vector 𝜸\bm{\gamma} are show in Fig. 12.

Refer to caption
(a)
Refer to caption
(b)
Refer to caption
(c)
Refer to caption
(d)
Figure 12: General graphs for the Bridge operators. (a) Connection to two STL variables. (b) Connection to an STL variable on the left and a predicate on the right. (c) Connection to a predicate on the left and an STL variable on the right. (d) Direct connection to two predicates. The clouds in blue and yellow represent the rest of the graph. 𝒮\mathcal{S} is the STL variable space while Φ\Phi represents the root predicate space.

The equations governing the transition at the Bridge operator level are the following for the four cases represented in Fig. 12:

γk=χαkαk+χβkβk+R(α¯k,β¯k)if(𝒫γ𝒮)(𝒫γ𝒮),\begin{matrix}\gamma_{k}=\frac{\partial\chi}{\partial\alpha_{k}}\alpha_{k}+\frac{\partial\chi}{\partial\beta_{k}}\beta_{k}+R(\bar{\alpha}_{k},\bar{\beta}_{k})&\text{if}&(\mathcal{P^{\gamma}_{\mathcal{L}}}\in\mathcal{S})\wedge(\mathcal{P^{\gamma}_{\mathcal{R}}}\in\mathcal{S}),\\ \end{matrix} (60)
γk=χαkαk+χρkρk𝒙k𝒙k+R(α¯k,𝒙¯k)if(𝒫γ𝒮)(𝒫γΦ),\begin{matrix}\gamma_{k}=\frac{\partial\chi}{\partial\alpha_{k}}\alpha_{k}+\frac{\partial\chi}{\partial\rho^{\mathcal{R}}_{k}}\frac{\partial\rho^{\mathcal{R}}_{k}}{\partial\bm{x}_{\mathcal{R}_{k}}}\bm{x}_{\mathcal{R}_{k}}+R(\bar{\alpha}_{k},\bar{\bm{x}}_{\mathcal{R}_{k}})&\text{if}&(\mathcal{P^{\gamma}_{\mathcal{L}}}\in\mathcal{S})\wedge(\mathcal{P^{\gamma}_{\mathcal{R}}}\in\Phi)\end{matrix}, (61)
γk=χρkρk𝒙k𝒙k+χβkβk+R(𝒙¯k,β¯k)if(𝒫γΦ)(𝒫γ𝒮),\begin{matrix}\gamma_{k}=\frac{\partial\chi}{\partial\rho^{\mathcal{L}}_{k}}\frac{\partial\rho^{\mathcal{L}}_{k}}{\partial\bm{x}_{\mathcal{L}_{k}}}\bm{x}_{\mathcal{L}_{k}}+\frac{\partial\chi}{\partial\beta_{k}}\beta_{k}+R(\bar{\bm{x}}_{\mathcal{L}_{k}},\bar{\beta}_{k})&\text{if}&(\mathcal{P^{\gamma}_{\mathcal{L}}}\in\Phi)\wedge(\mathcal{P^{\gamma}_{\mathcal{R}}}\in\mathcal{S})\end{matrix}, (62)
γk=χρkρk𝒙k𝒙k+χρkρk𝒙k𝒙k+R(𝒙¯k,𝒙¯k)if(𝒫γΦ)(𝒫γΦ).\begin{matrix}\gamma_{k}=\frac{\partial\chi}{\partial\rho^{\mathcal{L}}_{k}}\frac{\partial\rho^{\mathcal{L}}_{k}}{\partial\bm{x}_{\mathcal{L}_{k}}}\bm{x}_{\mathcal{L}_{k}}+\frac{\partial\chi}{\partial\rho^{\mathcal{R}}_{k}}\frac{\partial\rho^{\mathcal{R}}_{k}}{\partial\bm{x}_{\mathcal{R}_{k}}}\bm{x}_{\mathcal{R}_{k}}+R(\bar{\bm{x}}_{\mathcal{L}_{k}},\bar{\bm{x}}_{\mathcal{R}_{k}})&\text{if}&(\mathcal{P^{\gamma}_{\mathcal{L}}}\in\Phi)\wedge(\mathcal{P^{\gamma}_{\mathcal{R}}}\in\Phi)\end{matrix}. (63)

In the above expressions

  • 𝒫γ\mathcal{P^{\gamma}_{\mathcal{L}}} (respectively 𝒫γ\mathcal{P^{\gamma}_{\mathcal{R}}}) is the space of the left (respectively right) parent node associated to STL variable 𝜸\bm{\gamma};

  • 𝒙\bm{x}_{\mathcal{L}} (respectively 𝒙\bm{x}_{\mathcal{R}}) is the state vector of the left (respectively right) predicate;

  • ρ\rho^{\mathcal{L}} (respectively ρ\rho^{\mathcal{R}}) is the margin function of the left (respectively right) STL expression.

4.3 General Nesting

4.3.1 Backward Propagation

A very important aspect of general nesting is how the margin function is transmitted from each operator to the next one above it. In the previous section, when dealing with a single operator, a forward propagation of the STL variables was performed (i.e., αk+1=χ(αk,ρk+1φ))\alpha_{k+1}=\chi(\alpha_{k},\rho^{\varphi}_{k+1})). In the general case, with nesting operators, backward propagation plays a major role in preventing loss of information. To visualize the concept, let us consider the following nesting example:

𝛽(𝛼φ),\underset{\beta}{\diamond}(\underset{\alpha}{\Box}\varphi), (64)

represented in Fig. 13, where the notations α\alpha and β\beta are the STL variables associated to their respective operators. To illustrate the concept, let assume that the example result is True during the last two time steps, i.e., margin function ρφ\rho^{\varphi} is eventually always positive for these steps. As always, the STL variable at the last time step must be positive. One notices that the backward propagation of the margins preserves the Boolean conclusion (i.e., the property is True), information being lost at the first negative value in case of forward propagating due to the nesting of minmin and maxmax functions.

Another more complex nesting will be presented in Sec. 4.3.2 to build up intuition before presenting the general rules in Sec. 4.3.3.

Refer to caption
(a)
Refer to caption
(b)
Figure 13: Nesting operator example of Eq. (64). (a) Only forward propagating case. (b) First backward propagating case.

4.3.2 Until Operator

Until operator, represented with notation φ𝒰ψ\varphi\mathcal{U}\psi, and as presented in [MAGC22], is an operator that checks if a predicate φ\varphi is always True when another predicate ψ\psi triggered True. When taking a closer look at it, 𝒰\mathcal{U} can be constructed as a nesting of basic operators and written as follows:

φ𝒰ψ(ψφ).\varphi\mathcal{U}\psi\equiv\diamond(\psi\wedge\Box\varphi). (65)

On the other hand, when one reads the sentence When ψ\psi would trigger True, φ\varphi had to have always been True before, a notion of the history of φ\varphi appears. Therefore, one can state that 𝒰\mathcal{U} is specifically interested in the history of φ\varphi. For this reason, the Until operator could be constructed also as follows

φ𝒰ψ(ψφ),\varphi\mathcal{U}\psi\equiv\diamond(\psi\wedge\Box^{\mathcal{B}}\varphi), (66)

New notation are introduced to take into account temporal direction in the property validity and in the propagation

  • \Box^{\mathcal{B}} indicates Always before;

  • 𝒜\Box^{\mathcal{A}} indicates Always after;

  • 𝜶\bm{\alpha}^{\rightarrow} indicates that STL variable 𝜶\bm{\alpha} is propagated forward because interested in the past (case of all of what has been done in this paper so far as well as in [MAGC22]);

  • 𝜶\bm{\alpha}^{\leftarrow} indicates that STL variable 𝜶\bm{\alpha} is propagated backward because interested in the future.

Another example using Until operator is depicted in Fig. 14 and represented as follows:

φ𝒰(𝒜ψ).\varphi\mathcal{U}(\Box^{\mathcal{A}}\psi). (67)

This nesting operator is equivalent to the following expression highlighting the propagation direction of the STL variables:

δ(𝒜αψ)𝛾(βφ).\underset{\delta^{\rightarrow}}{\diamond}(\underset{\alpha^{\leftarrow}}{\Box^{\mathcal{A}}}\psi)\underset{\gamma}{\wedge}(\underset{\beta^{\rightarrow}}{\Box^{\mathcal{B}}}\varphi). (68)

It is recalled that the naming conventions of STL variables follows the order of the Greek alphabet the more external or high in the tree the operator is. Here, the sign of δN\delta_{N} respects the given trajectory.

Refer to caption
Figure 14: Nesting operator example of Eq. (68).

4.3.3 General Formulation

To built a general formulation, about the propagation the following rules can be considered on its direction:

  • If interested in what happened before when the operator triggers, perform a forward propagation;

  • If interested in the future when the operator triggers, perform a backward propagation;

  • Bridges are not affected by propagation direction;

  • The last node is computed using a forward propagation in any case.

Now that the building blocks are generalized in any position of the tree, full generalization can take place as depicted in Fig. 15.
Let us define 𝒩i\mathcal{N}_{i} the generic operator (or node) of index ii, ={,}\mathcal{B}=\{\wedge,\lor\} the Bridge operator set, ={,}\mathcal{F}=\{\lozenge,\square\} the Flow operator set, φi\varphi_{i} the root predicates. One then gets

{αk𝒩i=Ak𝒫(𝒩i)αk𝒫(𝒩i)+Ak𝒫(𝒩i)αk𝒫(𝒩i)αk1𝒩i=Ak𝒩iαk𝒩i+Ak1𝒫(𝒩i)αk1𝒫(𝒩i)if(𝒞(𝒩i))(𝒯(𝒩i)=𝒜)αk+1𝒩i=Ak𝒩iαk𝒩i+Ak+1𝒫(𝒩i)αk+1𝒫(𝒩i)if(𝒞(𝒩i)=)(𝒯(𝒩i)=),\begin{cases}\alpha_{k}^{\mathcal{N}_{i}^{\mathcal{B}}}=A_{k}^{\mathcal{P}_{\mathcal{L}}\left(\mathcal{N}_{i}^{\mathcal{B}}\right)}\alpha_{k}^{\mathcal{P}_{\mathcal{L}}\left(\mathcal{N}_{i}^{\mathcal{B}}\right)}+A_{k}^{\mathcal{P}_{\mathcal{R}}\left(\mathcal{N}_{i}^{\mathcal{B}}\right)}\alpha_{k}^{\mathcal{P}_{\mathcal{R}}\left(\mathcal{N}_{i}^{\mathcal{B}}\right)}\\ \alpha_{k-1}^{\mathcal{N}_{i}^{\mathcal{F}}}=A_{k}^{\mathcal{N}_{i}^{\mathcal{F}}}\alpha_{k}^{\mathcal{N}_{i}^{\mathcal{F}}}+A_{k-1}^{\mathcal{P}\left(\mathcal{N}_{i}^{\mathcal{F}}\right)}\alpha_{k-1}^{\mathcal{P}\left(\mathcal{N}_{i}^{\mathcal{F}}\right)}&\mathrm{if}\;\;\;\left(\mathcal{C}\left(\mathcal{N}_{i}\right)\neq\varnothing\right)\lor\left(\mathcal{T}(\mathcal{N}_{i}^{\mathcal{F}})=\mathcal{A}\right)\\ \alpha_{k+1}^{\mathcal{N}_{i}^{\mathcal{F}}}=A_{k}^{\mathcal{N}_{i}^{\mathcal{F}}}\alpha_{k}^{\mathcal{N}_{i}^{\mathcal{F}}}+A_{k+1}^{\mathcal{P}\left(\mathcal{N}_{i}^{\mathcal{F}}\right)}\alpha_{k+1}^{\mathcal{P}\left(\mathcal{N}_{i}^{\mathcal{F}}\right)}&\mathrm{if}\;\;\;\left(\mathcal{C}\left(\mathcal{N}_{i}\right)=\varnothing\right)\lor\left(\mathcal{T}(\mathcal{N}_{i}^{\mathcal{F}})=\mathcal{B}\right)\\ \end{cases}, (69)

where

  • αk𝒩i\alpha_{k}^{\mathcal{N}_{i}^{\mathcal{F}}} and αk𝒩i\alpha_{k}^{\mathcal{N}_{i}^{\mathcal{B}}} are respectively the STL variables associated to the Flow and Bridge operators at position ii and time step kk;

  • Ak𝒩iA^{\mathcal{N}_{i}}_{k} are the Jacobian matrices associated to each operator 𝒩i\mathcal{N}_{i} in the tree at time step kk;

  • 𝒫(𝒩i)\mathcal{P}(\mathcal{N}_{i}) (respectively 𝒞(𝒩i)\mathcal{C}(\mathcal{N}_{i})) are the parent operator (respectively child operator) of node 𝒩i\mathcal{N}_{i} (it must be noted that for a predicate, by definition at the bottom of the tree, this coincides exactly with the margin function of the states throughout the trajectory);

  • 𝒯(𝒩i)\mathcal{T}(\mathcal{N}_{i}^{\mathcal{F}}) the temporal interest of Flow type node 𝒩i\mathcal{N}_{i}^{\mathcal{F}}, being equal to 𝒜\mathcal{A} for After and \mathcal{B} for Before;

  • \varnothing the empty set.

Refer to caption
Figure 15: General form of an STL graph.

Now, since all the equations are linearized, and since an STL variable solely depends on its parents, it is possible to write the entire constraint using block matrices and vectors. As example, the following nested operator is considered:

(φ𝛼ψ)𝒰γ,δ,ϵ(βζ).(\varphi\underset{\alpha}{\wedge}\psi)\underset{\gamma^{\rightarrow},\delta,\epsilon^{\rightarrow}}{\mathcal{U}}(\underset{\beta^{\leftarrow}}{\Box}\zeta). (70)
Refer to caption
Figure 16: Graph representation of the nested operator given by Eq. (70).

In reference to Fig. 16, the entire state-transition matrix has the following structure

[𝑨𝒙𝜶𝑨𝜶𝜶𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝑨𝒙𝜷𝟎𝑵×𝑵𝑨𝜷𝜷𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝑨𝜶𝜸𝟎𝑵×𝑵𝑨𝜸𝜸𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝑨𝜷𝜹𝑨𝜸𝜹𝑨𝜹𝜹𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝟎𝑵×𝑵𝑨𝜹ϵ𝑨ϵϵ][𝒙𝜶𝜷𝜸𝜹ϵ]=[𝒃𝜶𝒃𝜷𝒃𝜸𝒃𝜹𝒃ϵ].\begin{bmatrix}\bm{A^{\alpha}_{x}}&\bm{A^{\alpha}_{\alpha}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}\\ \bm{A^{\beta}_{x}}&\bm{0_{N\times N}}&\bm{A^{\beta}_{\beta}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}\\ \bm{0_{N\times N}}&\bm{A^{\gamma}_{\alpha}}&\bm{0_{N\times N}}&\bm{A^{\gamma}_{\gamma}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}\\ \bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{A^{\delta}_{\beta}}&\bm{A^{\delta}_{\gamma}}&\bm{A^{\delta}_{\delta}}&\bm{0_{N\times N}}\\ \bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{0_{N\times N}}&\bm{A^{\epsilon}_{\delta}}&\bm{A^{\epsilon}_{\epsilon}}\end{bmatrix}\begin{bmatrix}\bm{x}\\ \bm{\alpha}\\ \bm{\beta}\\ \bm{\gamma}\\ \bm{\delta}\\ \bm{\epsilon}\end{bmatrix}=\begin{bmatrix}\bm{b^{\alpha}}\\ \bm{b^{\beta}}\\ \bm{b^{\gamma}}\\ \bm{b^{\delta}}\\ \bm{b^{\epsilon}}\par\end{bmatrix}. (71)

with 𝑨\bm{A}_{\bullet}^{\bullet} and 𝒃\bm{b}_{\bullet}^{\bullet} defined following the theory presented in Sections 3 and 4. Finally, on top of this block-matrix equality, the inequality ϵN0\epsilon_{N}\geq 0 is added.

Graph representation of Fig. 16 can also be seen from the point of view of an electronic circuit, as shown in Fig. 17(a) and Fig. 17(b) (condensed form). Both representations are equivalent. From several predicates, the output is a number. Its sign defines the validity of the whole constraint.

Refer to caption
(a)
Refer to caption
(b)
Figure 17: Circuit graph representation of the nested operator given in Eq. (70). (a) Electronic analogy. (b) Input-output equivalence, condensed form.

5 Derived Operators

This section presents three more operators which can be expressed in function of the building blocks already defined. They can serve as a more visual way of modeling a problem by regrouping operators together.

5.1 Implies (\implies)

Implies (\implies) can be considered as a bridge operator linking two predicates φ\varphi and ψ\psi. Using the STL grammar the Implies operator can be expressed as follows:

φψ(¬φ)ψ.\varphi\implies\psi\equiv(\neg\varphi)\lor\psi. (72)

One should just be careful in what they mean when using Implies. Eq. (72) logically means either φ\varphi is False, or, φ\varphi and ψ\psi are True at the same time. This detail can be of great use to simplify graphs.

5.2 If and Only If (\iff)

If and Only If (\iff) can be considered as a double implication. Using the STL grammar it can be expressed as follows:

φψ(φϕ)(ψφ)(¬φψ)(¬ψφ).\varphi\iff\psi\equiv(\varphi\implies\phi)\wedge(\psi\implies\varphi)\equiv(\neg\varphi\lor\psi)\wedge(\neg\psi\lor\varphi). (73)

5.3 Exclusive Or (\oplus)

Operator Exclusive Or (\oplus) can be considered as a variant of the inclusive disjunction. It is also the negation of operator If and Only If for the De-Morgan’s law. Therefore, operator \oplus can be defined either as a nesting of disjunctions and conjunctions, or as a negation of the equivalence:

φψ[φ(¬ψ)][(¬φψ)]φ¬()ψ.\varphi\oplus\psi\equiv[\varphi\wedge(\neg\psi)]\lor[(\neg\varphi\wedge\psi)]\equiv\varphi\neg(\iff)\psi. (74)

5.4 Other Extensions

Defining new operators can be made using previously defined ones in the same philosophy as for Until. Other ideas could be neither nor, exclusive negation or, negative and, or maybe more complex operations like φ𝒰(ψ(ζ))\varphi\mathcal{U}(\psi\wedge\Box(\diamond\zeta)) or ((φ))\diamond(\Box(\diamond\varphi)). Extensions can be created and then used as a block by itself to form more complex logic, hence manipulating super-operators and getting closer to real-world operations.

6 Applications

This section presents two examples of STL constraints used in the context of the satellite trajectory optimization. The modified successive convexification scheme is presented in detail in Section 6.2, implemented for two satellite rendezvous mission applications and discussed in Sections 6.3 and 6.4.

6.1 Problem Setup

As general definition of a satellite rendezvous mission, one satellite (named as chaser) has to dock to another one (named as target). Here, the target is in a circular geostationary orbit around the Earth. The chaser has a mass of 1000 kg and it is initially at coordinates [-2000, 500, 200] m in an orbital frame centered in the target position and with a null relative velocity. The problem is of minimum-fuel optimization over a finite horizon of 5000 s. The maximum allowed thrust of the chaser is 1 N. The simulations were performed using Matlab R2021a and the Mosek solver [ApS23]. The initial trajectory was obtained with zero thrust (i.e., it is a free drift propagation). All the details of this problem statement can be found in [CLL+23].

6.2 Modified Successive Convexification Algorithm

Since the problem is in a convex form, the choice was made to use the powerful Successive Convexification (SCvx) framework which extends Sequential Convex Programming (SQP) using trust regions (shown on Fig. 18) for improved performance [MSA16]. The algorithm, which is a modified version of the one in [CLL+23] is presented in Algorithm 1.

Refer to caption
Figure 18: Trust region. The reference trajectory 𝒙¯(t)\bar{\bm{x}}(t) is the blue line while the new optimal solution 𝒙(t)\bm{x}^{*}(t)) is the red one. The light blue circles around the blue dots represent the trust regions around which each point of the next solution must lie in.

To integrate STL constraint in the trajectory optimization problem, the following hypotheses have been assumed.

  • As explained in Section 2.2.2, the constraints are functions of the reference trajectory appearing in the zero order term and in the evaluations of the gradients of the linearization. Therefore, a new optimal solution is only optimal with respect to the reference trajectory. To make sure that the new optimal solution really satisfies the STL constraint, the idea is to compute the margin of the STL constraint with the new updated optimal values. This is not a constraint anymore since optimization is already done for this iteration, but a model-checking step. Note that, as the solution converges, this check is less and less important (indeed the reference becomes closer to the new optimal trajectory).

  • The cost function to minimize is modified from

    J=J=\mathcal{E} (75)

    to

    JSTL=+wΩΩN.J_{STL}=\mathcal{E}+w_{\Omega}\Omega_{N}. (76)

    With respect to the energy \mathcal{E}, the additional second term is function of the STL variable ΩN\Omega_{N} associated to the last time step of the last child at the top of the graph, and of its associated weight wΩw_{\Omega}. As a design choice for the cost function, it was decided for ΩN\Omega_{N} to increase its weight wΩw_{\Omega} negatively until a first solution satisfying the STL constraint is found. Indeed, to minimize JSTLJ_{STL} with wΩ<0w_{\Omega}<0, ΩN\Omega_{N} has to be positive (i.e., constraint satisfied). After that, as long as the STL constraint stays True (ΩN>0)\Omega_{N}>0), wΩw_{\Omega} is increased, getting closer to zero from negative value, in orde to give more importance to the other objectives as the energy minimization. When ΩN\Omega_{N} becomes negative, the STL constraint becomes False by construction and more importance is again given to the STL constraint, in order to converge to the STL plane {ΩN=0}\{\Omega_{N}=0\} while minimizing the energy to find the optimal solution (see Fig. 19 for a graphical representation).

  • Moreover, it is also possible to play on the trust radius (see Fig. 18). The radius is increased until a solution satisfying the STL constraint is found, then is shrinks down to help convergence.

The modifications to the Successive Convexification algorithm present in [CLL+23] are in red within Algorithm 1’s description:

Algorithm 1 Modified Successive Convexification (SCvx)
Initialization
Scaling of variables
while Not Accurate or Not Converged do
     Linearization
5:     Discretization
     Constraints update
     Solving of the convexified sub-problem
     Non-linear repropagation
     STL model-checking
10:     if Not Feasible then
         Dilate trust region
         Update cost weights
     else
         if Not Accurate then
15:              Update trust region
              Update cost weights
         else
              if Not Converged then
                  Update trust region
20:                  Update reference
                  Update cost weights
              end if
         end if
     end if
25:end while

The theoretical behavior of the solution when adding the STL is shown in Fig. 19. In the case of a contradiction between satisfying the STL constraint and minimizing the cost (most relevant case, depicted in Fig. 19(a)), the iterations will converge to the STL plane {ΩN=0}\{\Omega_{N}=0\}, while minimizing the cost. In the other case (depicted in Fig. 19(b)), when the natural optimal solution is also fulfilling the STL requirement, the solution converges to the minimal cost, satisfying the STL constraint but not lying on its plane.

Refer to caption
(a)
Refer to caption
(b)
Figure 19: Theoretical behavior of the solution when adding the STL constraint. Value x0x_{0} represents the initial guess, the cost lines are in dotted black, the successive iterations are shown in blue, and the STL plane in green.

6.3 First Example: Safety Spacing in a Satellite Rendezvous Mission

In the first example, let us imagine that certain sensors (e.g., GPS or lidar) during the approach experience a failure. In that case, a possible safety maneuver to prevent collision to the target could be for the chaser to first go outside of a safety sphere around the target before trying to approach and dock it again. While maintaining the same other constraints and objectives, this constraint was modeled as Eventually get outside of a circle of radius dd, or, using the STL grammar, as:

𝒓ctd,\diamond\lVert\bm{r}_{ct}\rVert\geq d, (77)

where 𝒓ct\bm{r}_{ct} is the relative position vector between the chaser and the target in the relative orbital frame, and dd is the radius of the safety sphere. The iterations of the successive trajectories can be seen in Fig. 20. As one could guess, the optimal trajectory tangents to the safety sphere before going back and dock. In this context, convergence value ϵc\epsilon_{c} is defined as:

ϵc=maxi=1N𝒓(𝒊)ct𝒓¯(𝒊)ct,\epsilon_{c}=\max_{i=1\dots N}\left\lVert\bm{r^{*(i)}}_{ct}-\bm{\bar{r}^{(i)}}_{ct}\right\rVert, (78)

while trust radius TRTR is a standard constraint of the SCvx algorithm, written for each iteration as:

i[1,,N],𝒓(𝒊)ct𝒓¯(𝒊)ctTR(i),\forall i\in[1,\ldots,N],\;\;\left\lVert\bm{r^{*(i)}}_{ct}-\bm{\bar{r}^{(i)}}_{ct}\right\rVert\leq TR^{(i)}, (79)

with 𝒓ct\bm{r^{*}}_{ct} the optimal value of the position and 𝒓¯ct\bm{\bar{r}}_{ct} its reference value (i.e., the previous optimal solution). Fig. 21(a) shows convergence (with a threshold of ϵc=5\epsilon_{c}=5 m) and trust radius (no specific threshold) while the Δ\DeltaV representing the fuel consumption is observed in Fig. 21(b). The minimum-fuel optimal solution is found in two main steps. First, a feasible solution is obtained where the STL constraint is satisfied. From that point on, the solution is adjusted to keep satisfying the STL constraint, but this time giving more and more importance to the other objective (i.e., energy minimization).

Refer to caption
Figure 20: Iterations of the SCvx algorithm to solve the minimum-fuel optimization while imposing a safety spacing of 2500 m (red dashed line) around the target.
Refer to caption
(a)
Refer to caption
(b)
Figure 21: (a) Convergence and trust radius. (b) Energy minimization.

6.4 Second Example: Slow Approach in a Satellite Rendezvous Mission

The second example focuses on a nesting operator using a Bridge and a Flow operator. The objectives id that between 60% and 80% of the transfer time, the relative distance between target and chaser is always less than R=500R=500 m, and that the norm of the thrust vector 𝑭\bm{F} is below the half of its maximum value of 1 N. Using the STL grammar, these constraints can be formalized as follows:

[60%,80%]{(𝒓ctR)(𝑭Fmax/2)}.\Box_{[60\%,80\%]}\{(\lVert\bm{r}_{ct}\rVert\leq R)\wedge(\lVert\bm{F}\rVert\leq F_{max}/2)\}. (80)

Fig. 22(a) shows the distance of the chaser to the target over time. As one would think, the iterations converge to the threshold at one of the time bounds. The thrust norm over time is represented in Fig. 22(b). The iterations converge meeting the constraint.

Then, in Fig. 23, the evolution of the fuel consumption is shown at each iteration. It increases until the STL constraint becomes positive.

Refer to caption
(a)
Refer to caption
(b)
Figure 22: (a) Distance of the chaser to the target over time. (b) Thrust norm over time.
Refer to caption
Figure 23: Total fuel consumption at each iteration.

7 Conclusion

In this work, an end-to-end methodology was presented to be able to take into account arbitrarily-complex Signal Temporal Logic constraints in optimization problem solving. It was shown that basic logic operators such as Or, And, Eventually, Always can be nested together, discretized and linearized to fit powerful convex frameworks. Moreover, graph-based STL formalism is well suited for the construction of super-operators, which, in turn, ease the understanding and the design of complex high-level mission scenarios and pave the way towards realistic agile operations. Using a modified Successive Convexification scheme, two examples were discussed in the context of the safety in autonomous spacecraft rendezvous missions. The results demonstrated high precision and fast convergence properties.

8 Acknowledgment

This paper is part of a Ph.D. work in progress at ISAE-SUPAERO, funded by the IRT (Technological Research Institute) of Saint-Exupéry, in the context of the RAPTOR project (Robotic and Artificial intelligence Processing Test on Representative target) for satellite rendezvous missions, in collaboration with Thales Alenia Space.

References

  • [ApS23] MOSEK ApS. The MOSEK optimization toolbox for MATLAB manual. Version 10.0., 2023.
  • [BV04] Stephen Boyd and Lieven Vandenberghe. Convex Optimization. Cambridge University Press, March 2004.
  • [CLL+23] Thomas Claudet, Jérémie Labroquère, Damiana Losa, Francesco Sanfedino, and Daniel Alazard. Successive convexification for on-board scheduling of spacecraft rendezvous missions. ESA GNC, 2023.
  • [DM10] Alexandre Donzé and Oded Maler. Robust satisfaction of temporal logic over real-valued signals. In Krishnendu Chatterjee and Thomas A. Henzinger, editors, Formal Modeling and Analysis of Timed Systems, pages 92–106, Berlin, Heidelberg, 2010. Springer Berlin Heidelberg.
  • [LAP23] Karen Leung, Nikos Aréchiga, and Marco Pavone. Backpropagation through signal temporal logic specifications: Infusing logical structure into gradient-based methods. The International Journal of Robotics Research, 42(6):356–370, 2023.
  • [MAGC22] Yuanqi Mao, Behcet Acikmese, Pierre-Loic Garoche, and Alexandre Chapoutot. Successive convexification for optimal control with signal temporal logic specifications. In Proceedings of the 25th ACM International Conference on Hybrid Systems: Computation and Control, HSCC ’22, New York, NY, USA, 2022. Association for Computing Machinery.
  • [MGFS20] Meiyi Ma, Ji Gao, Lu Feng, and John Stankovic. Stlnet: Signal temporal logic enforced multivariate recurrent neural networks. Advances in Neural Information Processing Systems, 33:14604–14614, 2020.
  • [MSA16] Yuanqi Mao, Michael Szmuk, and Behçet Açıkmeşe. Successive convexification of non-convex optimal control problems and its convergence properties. In 2016 IEEE 55th Conference on Decision and Control (CDC), pages 3636–3641, 2016.
  • [PDN21] Aniruddh G Puranic, Jyotirmoy V Deshmukh, and Stefanos Nikolaidis. Learning from demonstrations using signal temporal logic in stochastic and continuous domains. IEEE Robotics and Automation Letters, 6(4):6250–6257, 2021.
  • [Pnu77] Amir Pnueli. The temporal logic of programs. 18th Annual Symposium on Foundations of Computer Science (sfcs 1977), pages 46–57, 1977.
  • [RDM+14] Vasumathi Raman, Alexandre Donzé, Mehdi Maasoumy, Richard M. Murray, Alberto Sangiovanni-Vincentelli, and Sanjit A. Seshia. Model predictive control with signal temporal logic specifications. In 53rd IEEE Conference on Decision and Control, pages 81–87, 2014.
  • [Ric05] Arthur Richards. Trajectory optimization using mixed-integer linear programming. 05 2005.
  • [VCDJS17] Marcell Vazquez-Chanlatte, Jyotirmoy V Deshmukh, Xiaoqing Jin, and Sanjit A Seshia. Logical clustering and learning for time-series data. In Computer Aided Verification: 29th International Conference, CAV 2017, Heidelberg, Germany, July 24-28, 2017, Proceedings, Part I 30, pages 305–325. Springer, 2017.
  • [WBT21] Changhao Wang, Jeffrey Bingham, and Masayoshi Tomizuka. Trajectory splitting: A distributed formulation for collision avoiding trajectory optimization. In 2021 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pages 8113–8120, 2021.
  • [YYW+19] Tao Yang, Xinlei Yi, Junfeng Wu, Ye Yuan, Di Wu, Ziyang Meng, Yiguang Hong, Hong Wang, Zongli Lin, and Karl H. Johansson. A survey of distributed optimization. Annual Reviews in Control, 47:278–305, 2019.