Hybrid Event Shaping
to Stabilize Periodic Hybrid Orbits
James Zhu, Nathan J. Kong, George Council, and Aaron M. Johnson

Abstract—Many controllers for legged robotic systems leverage
open- or closed-loop control at discrete hybrid events to enhancestability. These controllers appear in several well studied phenomena such as the Raibert stepping controller, paddle juggling, andswing leg retraction. This work introduces hybrid event shaping(HES): a generalized method for analyzing and designing stablehybrid event controllers. HES utilizes the saltation matrix, which
gives a closed-form equation for the effect that hybrid events
have on stability. We also introduce shape parameters, which arehigher order terms that can be tuned completely independently of
the system dynamics to promote stability. Optimization methods
are used to produce values of these parameters that optimize
a stability measure. Hybrid event shaping captures previously
developed control methods while also producing new optimallystable trajectories without the need for continuous-domain feedback.

I. I NTRODUCTION
In general, the walking and running gaits of legged robots
are naturally unstable and challenging to control. Hybrid
systems such as these are difficult to work with due to thediscontinuities in state and dynamics that occur at hybrid
events, such as toe touchdown, which violate assumptions ofstandard controllers designed for purely continuous systems.
Several works have examined the utility of controlling hybrid event conditions to improve system stability without any
closed-loop continuous-domain control [2,3]. For example, [2]found that for the paddle juggler system, paddle acceleration
at impact uniquely determines the local stability properties ofa periodic trajectory, Fig. 1. So far, however, these results have
only been produced for the specific problem structure and are
not generalizable to more complex systems.
In this work, we propose the concept of hybrid event
shaping (HES), which describes how hybrid event parameters
can be chosen to affect the stability properties of a periodicorbit. We also propose methods to produce values of thesehybrid event parameters to optimize a stability measure of atrajectory.
This abstract is adapted from the conference paper, Hybrid Event Shaping
to Stabilize Periodic Hybrid Orbits presented at ICRA 2022 [1].
This material is based upon work supported by the National Science
Foundation under grant #CMMI-1943900 and #ECCS-1924723 as well as theU.S. Army Research Office under grant #W911NF-19-1-0080. The views andconclusions contained in this document are those of the authors and should
not be interpreted as representing the official policies, either expressed orimplied, of the National Science Foundation, the Army Research Office, orthe U.S. Government. The U.S. Government is authorized to reproduce anddistribute reprints for Government purposes notwithstanding any copyrightnotation herein.
All authors are with the Department of Mechanical Engineering, Carnegie
Mellon University, Pittsburgh, PA, USA, jameszhu@andrew.cmu.edu

Fig. 1.
The paddle juggler system [2] has no control authority while
the ball is in the air. The paddle acceleration at impact determines theconvergence/divergence of the system from initial points (cyan dots) to thefinal states (magenta stars) after 5 cycles. This example underscores how
hybrid event shaping can stabilize a periodic hybrid system.

II. P RELIMINARIES
Following the adaptation of [4] in [1], we define a hybrid
system as a tuple H := (J , Γ, D, F, G, R). The variational
equations of hybrid events are characterized by the saltation
matrix Ξ(I,J) (t̄i , x(t̄i ), u(t̄i )), which approximates the firstorder change in perturbations in state before a hybrid event at
δx(t̄i ) to perturbations afterward δx(ti+1 ) [5]. Following theformulation from [5], the saltation matrix is,Ξ = Dx R +(FJ − Dx R · FI − Dt R)Dx g
Dt g + Dx gFI(1)A dynamical system has a periodic trajectory (orbit) if it
repeats itself after period T . Initial perturbations δx0 can bemapped to perturbations δxT after period T by a linearized
mapping known as the monodromy matrix, Φ which can becomputed by sequentially composing the linearized variational
equations in each continuous domain (A) and the saltation
matrices (Ξ) at each hybrid event [6]:Φ = Ξ(N,1) AN . . . Ξ(2,3) A2 Ξ(1,2) A1(2)

The monodromy matrix determines local asymptotic orbital
stability. For nonautonomous systems, stability is determinedby the maximum magnitude of the eigenvalues, max(|λ|)[7]. We refer to this as the stability measure, ψ, where atrajectory is stable when ψ < 1. Autonomous systems always
have an eigenvalue that is equal to 1 since for non-timevarying dynamics, perturbations along the flow of the orbit
will by definition map back to themselves after period T [7].
Assuming non-convergence in this direction is allowable, ψ forautonomous systems is based on the remaining eigenvalues.

Fig. 2.

Biped walker system with kneestrike and toestrike hybrid events.

III. M ETHODS
Fig. 3. Error of perturbed Minimum Energy (ME), Hybrid Event Shaping
without virtual hybrid events (HES w/o VHE) and HES w/ VHE trajectories
over several steps. Bold lines show average error at each step and shaded
regions indicate ±1 standard deviation. The initial increase in error of theHES trajectories is allowable and is not considered by the stability measure.

The saltation matrix allows for an explicit understanding of
how to perform hybrid event shaping (HES), i.e. choosing
hybrid event parameters such as timing, state, input, andhigher order “shape parameters” to improve the stability ofa periodic trajectory. The key insight is that hybrid event
shaping introduces a generalizable method to stabilize openloop hybrid systems.
The saltation matrix is a function of higher order shapeparameters h that do not influence the dynamics of thesystem. These parameters arise from the derivatives of theguards and reset maps, but are not present in the guard, resetmap, or vector field definitions themselves. Therefore, shapeparameters have absolutely no effect on the nominal trajectoryand can be chosen completely freely.
One example of a shape parameter is the angular velocity ofa massless leg of a spring-loaded inverted pendulum (SLIP).
Since a massless leg does not induce any torque in the
air or forces at touchdown, only the position of the leg attouchdown affects the trajectory of the body. However, legvelocity appears in the saltation matrix and has a significant
effect on orbital stability [3]. Hybrid event shaping is able togenerate optimal retraction rates for stable SLIP hopping andthe similar paddle juggling phenomenon [1].
Shape parameters can also be induced with discrete changes
in control input. These “virtual hybrid events‘” introduce theirown saltation matrices to be shaped.

While the idea of hybrid event control is not novel, hybrid
event shaping provides a generalized method to analyze thestability of hybrid orbits and select hybrid event parameters
to optimize stability. HES unifies results of previous simple
hybrid event controllers while also being compatible with trajectory optimization techniques to produce stable trajectories
for complex systems.

IV. E XAMPLE AND R ESULTS

R EFERENCES

Consider a fully-actuated compass walker [8] with knees,Fig. 2. This biped model consists of two legs connected by anactuated hip joint. Each leg is separated into two sections, theupper leg (thigh) and lower leg (shank), which are connectedby an actuated knee joint that has a hard stop when the thighand shank are aligned. The ankles are also actuated. The
dynamics of this model are described in [1,8].
A direct collocation trajectory optimization method wasused with the cost consisting of the stability measure and a regularization on the input. Dynamics and periodicity constraints
were included along with a ground penetration constraint.
In this experiment, three trajectories were compared to examine how HES can generate stable trajectories and the effectthat virtual hybrid events have in further improving stability.
A trajectory without HES was produced as a control, withjust an input regularization term in the cost. This minimum
energy (ME) trajectory is comparable to conventional robot[1] J. Zhu, N. Kong, G. Council, and A. Johnson, “Hybrid event shapingto stabilize periodic hybrid orbits,” IEEE International Conference on
Robotics and Automation, 2022.
[2] D. Sternad, M. Duarte, H. Katsumata, and S. Schaal, “Bouncing a ball:
Tuning into dynamic stability,” Journal of Experimental Psychology:
Human Perception and Performance, vol. 27, pp. 1163–84, 11 2001.
[3] A. Seyfarth, H. Geyer, and H. Herr, “Swing-leg retraction: a simple
control model for stable running,” Journal of Experimental Biology, vol.
206, no. 15, pp. 2547–2555, 2003.
[4] A. M. Johnson, S. A. Burden, and D. E. Koditschek, “A hybrid systems
model for simple manipulation and self-manipulation systems,” TheInternational Journal of Robotics Research, vol. 35, no. 11, pp. 1354–1392, 2016.
[5] S. A. Burden, T. Libby, and S. D. Coogan, “On contraction analysis forhybrid systems,” arXiv preprint arXiv:1811.03956, 2018.
[6] H. Asahara and T. Kousaka, “Stability analysis using monodromy matrix
for impacting systems,” IEICE Transactions of Fundamentals of Electronics, Communications, and Computer Science, vol. E101-A, no. 6, 2018.
[7] R. Leine and H. Nijmeijer, Dynamics and Bifurcations of Non-SmoothMechanical Systems. Springer-Verlag Berlin Heidelberg, 2004.
[8] V. Chen, “Passive dynamic walking with knees: A point foot model,”Master’s thesis, Massachusetts Institute of Technology, 2007.

locomotion trajectories. Two HES trajectories were generated,
one with virtual hybrid events (HES w/ VHE) and one without(HES w/o VHE).
The stability properties of the generated trajectories weretested through simulation. 50 trials of each trajectory wereinitialized with random perturbations. Over a sequence of 10steps, the state error at each step was tracked for each trial.
Fig. 3 shows that after 10 steps, the HES trajectories havenearly converged back to the nominal trajectory whereas theME trajectories diverge quickly. The HES w/ VHE trajectory
converges to a smaller error after 10 steps compared to theHES w/o VHE trajectory.
V. C ONCLUSION