Keywords

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

This chapter is devoted to present numerical simulation results obtained with the siconos platform, on several simple circuits: the first circuit has been built to show that conventional analog simulators fail to converge; the other circuits are classical diode-bridge wave rectifiers, and the last one is a circuit that exhibits a sliding mode. In this chapter and in Chap. 8, five simulation software packages were used:

siconos::

the platform developed at INRIA Grenoble Rhône-Alpes (France) dealing with nonsmooth dynamical systems with dedicated time integrators and algorithms to solve sets of equations and inequalities (for instance LCP: linear complementarity problems).

ngspice::

an open-source version of the original SPICE3F5 software developed by Berkeley university. Even if this version may differ from existing commercial ones, it shares with them a common set of models and the solving algorithms belong also to the same class that deals with regular functions.

smash::

a commercial version of spice developed by Dolphin Integration (see http://www.dolphin.fr).

eldo::

a commercial version of spice with Newton-Raphson and OSR (one step relaxation) algorithms developed by Mentor Graphics (http://www.mentor.com).

plecs::

a simulink/matlab toolbox dedicated to the simulation of power electronics circuits (see http://www.plexim.com). The models and algorithms come from the hybrid approach. In our work the freely available demonstration version of plecs has been used.

1 Maffezzoni’s Example

This section is devoted to the modeling and the simulation of the circuit in Fig. 7.1. In Maffezzoni et al. (2006) it is shown that Newton-Raphson based methods fail to converge on such a circuit, with the switch model as in (1.46). The diode model is the equivalent resistor model in Fig. 1.2(d). On the contrary the OSNSP solver correctly behaves on the same model, as demonstrated next.

Fig. 7.1
figure 1

A simple switched circuit

1.1 The Dynamical Model

The dynamics of the circuit in Fig. 7.1 is obtained using the algorithm of automatic circuit equation formulation of Chap. 6. In a first step, the vector of unknown variables is built, in a second step, the dynamical system is written, and in a last step, the nonsmooth laws are added. Applying the automatic equations generation algorithm leads to the following 9-dimensional unknown (dynamic and algebraic unknown variables) vector: \(X=(V_{1}\;V_{2}\;V_{3}\;V_{4}\;I_{L}\;I_{03}\;I_{04}\;I_{s}\;I_{d})^{T}\) in the system (5.1) or x=(I L ) and \(z=(V_{1}\;V_{2}\;V_{3}\;V_{4}\;I_{03}\;I_{04}\;I_{s}\;I_{d})^{T}\) in the system (5.14), where the potentials and the currents are depicted in Fig. 7.1. Building the dynamical equations consists in writing the Kirchhoff current laws at each node, the constitutive equation of the smooth branch, and the nonsmooth law of the other branches. The two nonsmooth devices are the diode and the switch. It yields the following system, that fits within the general framework in (3.32). For the semi-explicit DAE, we obtain:

$$ \left\{ {\begin{array}{*{20}{l}} {L\frac{{d{I_L}}}{{dt}}(t) = {V_1}(t) - {V_2}(t),} \\ {\begin{array}{*{20}{c}} {{I_d}(t) + {I_S}(t) - {I_L}(t) = 0,}&{{I_L}(t) - \frac{{{V_2}(t)}}{R} = 0,} \end{array}} \\ {\begin{array}{*{20}{c}} {{I_{03}}(t) = 0,}&{{I_{04}}(t) - {I_s}(t) = 0,} \end{array}} \\ {\begin{array}{*{20}{c}} {{V_4}(4) = 20,}&{{V_3} = e(t).} \end{array}} \end{array}} \right. $$
(7.1)

For the input/output relations of the nonsmooth components, we get:

$$\left\{ \begin{matrix} {{V}_{1}}(t)=\frac{1}{2}({{\tau }_{1}}(t)-1){{R}_{\text{off}}}{{I}_{d}}(t)-\frac{1}{2}({{\tau }_{1}}(t)+1){{R}_{\text{on}}}{{I}_{d}}(t), \\ 2({{V}_{4}}(t)-{{V}_{1}}(t))=[(1+{{\tau }_{2}}(t)){{R}_{\text{off}}}+(1-{{\tau }_{2}}(t)){{R}_{\text{on}}}]{{I}_{s}}(t). \\ \end{matrix} \right. $$
(7.2)

Finally, the inclusion rule is written as:

$$ \left\{ {\begin{array}{*{20}{l}} {{V_1}(t) \in - {\mathbb{N}_{\left[ { - 1,1} \right]}}\left( {{\tau _1}\left( t \right)} \right)} \\ {100\left( {{V_3}\left( t \right) - {V_2}\left( t \right)} \right) \in - {\mathbb{N}_{\left[ { - 1,1} \right]}}\left( {{\tau _2}\left( t \right)} \right).} \end{array}} \right. $$
(7.3)

On this example, the fully implicit (θ=1) Moreau’s time-stepping scheme reads as:

$$ \left\{ {\begin{array}{*{20}{l}} {l\left( {{I_{L,k + 1}} - {1_L}} \right) = h\left( {{V_{1,k + 1}} - {V_{2,k + 1}},} \right)} \\ {{I_{d,k + 1}} + {I_{s,k + 1}} - {I_{L,k + 1}} = 0,\quad {I_{L,k + 1}} - \tfrac{1}{R}{V_{2,k + 1}} = 0,} \\ {{I_{03,k + 1}} = 0,\quad {I_{04,k + 1}} - {I_{s,k + 1}} = 0,} \\ {{V_{4,k + 1}} = 20,\quad {V_{3,k + 1}} = e\left( {{t_{k + 1}}} \right),} \\ {2{V_{1,k + 1}} = \left( {{\tau _{1,k + 1}} - 1} \right){R_{off}}{I_{d,k + 1}} - \left( {{\tau _{1,k + 1}} - 1} \right){R_{on}}{I_{d,k + 1}},} \\ {2\left( {{V_{4,k + 1}} - {V_{1,k + 1}}} \right) = \left[ {\left( {1 + {\tau _{2,k + 1}}} \right){R_{off}} + \left( {1 - {\tau _{2,k + 1}}} \right){R_{on}}} \right]{I_{s,k + 1}},} \\ {{V_{1,k + 1}} \in - {\mathbb{N}_{\left[ { - 1,1} \right]}}\left( {{\tau _{1,k + 1}}} \right),} \\ {100\left( {{V_{3,k + 1}} - {V_{2,k + 1}}} \right) \in - {\mathbb{N}_{\left[ { - 1,1} \right]}}\left( {{\tau _{2,k + 1}}} \right).} \end{array}} \right. $$
(7.4)

1.2 Simulation Results: Failure of the Newton-Raphson Algorithm

The simulation consists of two phases: a linear behavior followed by a change in the state of the switch.

1.2.1 A Linear Behavior

The time step has been fixed to 0.1 μs and the initial state is {0,7.5,0}. While the value of V 3V 2 is positive, the Newton-Raphson algorithm converges in one iteration. It is a linear circuit shown in Fig. 7.2. During this period, I L and V 2 are increasing and V 3 is decreasing. When V 2 becomes equals to V 3, the switch will change its state.

Fig. 7.2
figure 2

Equivalent linear circuit

1.2.2 The Switch Change of State

We denote N the integer such that the switch will change its state on [t N ,t N+1]. Figure 7.3 depicts the initial linearized circuit used by the Newton-Raphson iterations to compute the state at t N+1. Setting V 3 to the value e(t N+1), that is 1.20 V, leads to change the switch’s state. Figure 7.4 shows the equivalent circuit after the first Newton-Raphson iteration. We note that the switch is now OFF, due to the negative value of V 2V 3. The second Newton-Raphson iteration causes the decreasing of V 2 resulting in changing the states of the diode and of the switch. Figure 7.5 points out the new state of the circuit. The third iteration results in a new setting of both the switch and diode components depicted in Fig. 7.6. On this example, the linearization performed at each Newton-Raphson iteration leads to an oscillation between two incorrect states and never converges to the correct one. The Newton-Raphson iterations enter into an infinite loop without converging.

Fig. 7.3
figure 3

Circuit state at t=t N

Fig. 7.4
figure 4

Equivalent linear model, first step

Fig. 7.5
figure 5

Equivalent linear model, second step

Fig. 7.6
figure 6

Equivalent linear model, third step

1.2.3 The Newton-Raphson Iterations at t=t N

The next table summarizes the oscillation between two incorrect states:

 

k = 0

k = 1

k = 2

k = 3

k = 4

Solution

S

ON

OFF

ON

OFF

ON

OFF

D

OFF

OFF

ON

OFF

ON

ON

1.3 Numerical Results with Siconos

The time step has been fixed to 0.1 μs, the values of the parameters are R=1 Ω, R on =0.001 Ω, R off =1000 Ω, L=2.10−4 H and the initial condition is I L (0)=0 A. Figure 7.7(a) depicts the current evolution through the inductor L. Using the NSDS approach the OSNSP solver converges and computes the correct state. For such a simple system, any OSNSP solver gives a correct solution. We have used indifferently PATH and a SEMISMOOTH Newton method.

Fig. 7.7
figure 7

Switched circuit simulations

Remark 7.1

In Maffezzoni et al. (2006) an event-driven numerical method is proposed to solve the non convergence issue. However it is reliable only if the switching times can be precisely estimated, a shortcoming not encountered with the NSDS and the Moreau’s time-stepping method.

1.4 Numerical Results with Eldo

Eldo does not provide any nonsmooth switch model. But it furnishes the ‘VSWITCH’ one described in (7.6), where R S is the controlled resistor value of the switch, and V c the voltage control yielding to the model:

$$ {R_S}\left( t \right) = \left\{ {\begin{array}{*{20}{l}} {{R_{on}}\quad \quad \quad \quad \quad \quad \quad \quad \quad \quad if\,{V_c}\left( t \right) \geqslant {V_{on}},} \\ {{R_{off}}\quad \quad \quad \quad \quad \quad \quad \quad \quad \quad if\,{V_c}\left( t \right) \leqslant {V_{off}},} \\ {\left( {Vc\left( t \right){R_{off}} - {R_{on}}} \right) + {R_{on}}\,{V_{off}}} \\ {\quad {R_{off}}\,{V_{on}}/\left( {{V_{off}} - {V_{on}}} \right)\quad \quad \quad otherwise.} \end{array}} \right. $$
(7.6)

Setting V off to 0 and choosing a small value for V on lead to a model close to (1.46) for the chosen parameters. Simulations have been done using different sets of parameters. It is noteworthy that the behavior of Eldo depends on these values. For example, using a backward scheme Euler with the time step fixed to 0.1 μs and V on =10−4 V, V off =0 V, R off =1000 Ω, R on =0.001 Ω causes trouble during the Eldo simulation: ‘Newton no-convergence’ messages appear. Figure 7.7(b) shows the Eldo simulation. The values are very close to the Siconos simulation, except for the steps corresponding to the ‘no-convergence’ messages. In this case, the resulting current value is absurd.

This academic example demonstrates that standard analog tools (spice-like simulators) can fail to simulate a switched circuit.

2 A First Diode-Bridge Wave Rectifier

The chosen example is a four-diode bridge wave rectifier as shown in Fig.  7.8. In this sample, an LC oscillator initialized with a given voltage across the capacitor and a null current through the inductor provides the energy to a load resistance through a full-wave rectifier consisting of a 4-ideal-diode bridge. Both waves of the oscillating voltage across the LC are provided to the resistor with current flowing always in the same direction. The energy is dissipated in the resistor resulting in a damped oscillation. This section presents the modeling and the simulation of this circuit using the siconos platform and the automatic circuit equation formulation presented in Chap. 6.

Fig. 7.8
figure 8

A 4-diode bridge wave rectifier

2.1 Dynamical Equations

The automatic circuit equation formulation leads to the system (7.7), (7.9) and (7.8). The vector of unknown variables is (U C ,I L ,V 1,V 2,V 3,I DF1,I DF2,I DR1,I DR2)T∈ℝ9. The potentials V 1, V 2, V 3 are the potentials at the points indicated on the figure. We obtain:

$$ \left\{ {\begin{array}{*{20}{l}} { - {C_0}{{\dot U}_C}\left( t \right) + {I_L}\left( t \right) - {I_{D\,R2}}\left( t \right) + {I_{D\,F1}}\left( t \right) = 0,} \\ {L{{\dot I}_L}\left( t \right) + {V_1}\left( t \right) = 0,} \\ {\tfrac{{{V_3}\left( t \right) - {V_2}\left( t \right)}}{R} - {I_{D\,R1}}\left( t \right) - {I_{D\,F1}}\left( t \right) = 0,} \\ {\tfrac{{{V_2}\left( t \right) - {V_3}\left( t \right)}}{R} - {I_{D\,R2}}\left( t \right) - {I_{D\,F2}}\left( t \right) = 0,} \\ {{U_C}\left( t \right) - {V_1}\left( t \right) = 0,} \end{array}} \right. $$
(7.7)
$$ \left\{ {\begin{array}{*{20}{l}} {0 \leqslant {\lambda _1}\left( t \right) \bot {V_2}\left( t \right) - {V_1}\left( t \right) \geqslant 0,} \\ {0 \leqslant {\lambda _2}\left( t \right) \bot - {V_3}\left( t \right) \geqslant 0,} \\ {0 \leqslant {\lambda _3}\left( t \right) \bot {V_2}\left( t \right) \geqslant 0,} \\ {0 \leqslant {\lambda _4}\left( t \right) \bot {V_1}\left( t \right) - {V_3}\left( t \right) \geqslant 0,} \end{array}} \right. $$
(7.8)

with:

$$\lambda_1=-I_{DF1}\qquad\lambda_2=-I_{DF2}\qquad\lambda_3=-I_{DR1}\qquad \lambda_4=-I_{DR2}.$$
(7.9)

One may identify this dynamics with the canonical form in (2.54), where x may be chosen as the above vector of unknown variables. One has:

$$ E = \left( {\begin{array}{*{20}{l}} { - {C_0}\quad 0\quad 0\quad \cdots \quad 0} \\ {0\quad \quad L\quad 0\quad \cdots \quad 0} \\ {0\quad \quad \cdots \quad \quad \quad \quad 0} \\ {\quad \quad \quad \quad \vdots } \\ {0\quad \quad \cdots \quad \quad \quad \quad 0} \end{array}} \right){\mkern 1mu} \in {\mathbb{R}^{9 \times 9}},\quad \quad M = {I_4}, $$
$$ C = \left( {\begin{array}{*{20}{l}} {0\quad 0\quad - 1\quad 1\quad \,\,0\quad \cdots \quad \quad \,0} \\ {0\quad 0\quad \;\,0\quad 0\quad - 1\quad 0\quad \quad \,\,0} \\ {0\quad 0\quad \,\,0\quad 1\quad \,\,0\quad \,0\quad \cdots \quad 0} \\ {0\quad 0\quad \,\,1\quad 0\quad - 1\quad 0\quad \cdots \quad 0} \end{array}} \right) \in {\mathbb{R}^{4 \times 9}}. $$

Here I 4 is the 4×4 identity matrix.

2.2 Simulation Results

Figure 7.9 shows a simulation with siconos using the following numerical values: L=10−2 H, C=10−6 H, R=103 Ω, V 1(0)=10 V. The initial time is zero and the total simulation time is 5×10−3 s with a step of 10−6 s. The nonsmooth problem is written as a Mixed Linear Complementarity Problem (MLCP). It has been solved using indifferently PATH and SEMISMOOTH methods. Obviously an enumerative solver is also convenient for a problem of such a size. The comparison is made with the spice simulator smash. In this case, the system is equivalent to an ODE with Lipschitz right-hand-side. The simulation with standard spice simulator together with low order schemes (Backward Euler) still works.

Fig. 7.9
figure 9

Bridge wave rectifier simulation results

It is possible to modify the time-stepping algorithm described in Chap. 5 so that the time-step is adapted according to the local error. A practical error estimation is based on halved time-steps. Figure 7.10 presents the result of the step control mechanism using 10−3 for the relative and absolute tolerance. It is noteworthy that the time step is not decreased to pass through the diodes switching.

Fig. 7.10
figure 10

Step size control using a 10−3 tolerance. 193 steps +95 rejected

3 A Second Diode-Bridge Wave Rectifier

A little bit more complex example was simulated: a sinusoidal voltage supply providing energy to a resistor through a 4-diode bridge full-wave rectifier filtered with a capacitor (see Fig. 7.11). The automatic circuit equation formulation leads to the system (7.10) with the complementarity constraints in (7.9) and (7.8). The vector of unknown variables is (U C ,V 1,V 2,V 3,I E ,I DF1,I DF2,I DR1,I DR2)T∈ℝ9. The potentials V 1, V 2, V 3 are the potentials at the points indicated in the figure. We obtain:

$$ \left\{ {\begin{array}{*{20}{l}} { - C{{\dot U}_C}\left( t \right) + \tfrac{{{V_2}\left( t \right) - {V_3}\left( t \right)}}{R} + {I_{DR1}}\left( t \right) + {I_{DF1}}\left( t \right) = 0,} \\ { - {I_E}\left( t \right) + {I_{DR1}}\left( t \right) + {I_{DF2}}\left( t \right) = 0,} \\ {{I_{DF2}}\left( t \right) - {I_{DF1}}\left( t \right) + {I_{DF2}}\left( t \right) - {I_{DF1}}\left( t \right) = 0,} \\ {{V_1}\left( t \right) = e\left( t \right),} \\ {{U_C}\left( t \right) = {V_3} - {V_2}\left( t \right).} \end{array}} \right. $$
(7.10)
Fig. 7.11
figure 11

Filtered full wave rectifier

One may once again identify the dynamics of this circuit with the MLCS dynamics in (2.54), choosing for x the above vector of unknown variables. Figures 7.12, 7.13 and 7.14 show what happens with the spice algorithms when the time step is forced to a “high value” (here 10 μs): the spice simulator seems to converge but the results are erroneous while the nonsmooth approach provides accurate results. The spice package that has been used for these simulations is smash and the time-integration scheme is the trapezoidal rule. The results are taken from Denoyelle and Acary (2006).

Fig. 7.12
figure 12

siconos (a) and smash (b) simulations of the diode-bridge circuit, 0.1 μs time step

Fig. 7.13
figure 13

siconos (a) and smash (b) simulations of the diode-bridge circuit, 1 μs time step

Fig. 7.14
figure 14

smash (b) and siconos (a) simulations of the diode-bridge circuit, 10 μs time step

Figures 7.15 and 7.16 show a comparison between smash results with a time step of 0.1 μs and siconos results with respectively time steps of 2 μs and 1 μs. The 2 μs results are already very close to smash ones. At 1 μs the differences are almost unnoticeable, whereas a factor of 10 is gained on the time step.

These results suggest that with a small number of stiff components in a circuit, the convergence of the Newton-Raphson algorithm is already impaired, even if several tricks were added in the spice software to help it. When the integration time period becomes too large, some diodes may be completely blocked at a time step and completely passing at the next time step. The spice algorithms are not designed to handle such a case: they need to step a sufficient number of times to cover properly all the switching period which is very short here.

On the contrary, the nonsmooth approach is able to compute a consistent solution with relatively far time steps, assuming that it exists and it is unique, which is true here.

Fig. 7.15
figure 15

Simulation results of the diode-bridge circuit. (asiconos with h=2 μs (bsmash with h=0.1 μs

Fig. 7.16
figure 16

Simulation results of the diode-bridge circuit. (asiconos with h=1 μs (bsmash with h=0.1 μs

Similar circuits like parallel resonant converters can be modeled and simulated in a similar way by siconos,Footnote 1 showing the wide range of applicability of the NSDS method in this field of electrical engineering.

4 The Ćuk Converter

In this section, we are interested in a special type of DC/DC power converter: the Ćuk converter (Middlebrook and Ćuk 1976). The circuit is described in Fig. 7.17. The converter is supplied by a constant voltage supply E=10 V and loads a resistor R=50 Ω. The switch is modeled by a linear MOS transistor described in Sect. 4.7.5 with two hyperplanes. The parameters of the nMOS model are V T =5 V and K=10. The diode threshold voltage is 0.2 V. The capacitance are C 1=C 2=10 μF and the inductances are L 1=L 2=250 μH. There is no feedback on the regulation of the switch. The voltage V G at the gate of nMOS model is given a periodic door function of period T described in Fig. 7.18. In our numerical simulation, the parameters of the control of the switch are V Gmax =10, T=10 μs, T d =0.95 μs, T on =7.5 μs.

Fig. 7.17
figure 17

The Ćuk converter

Fig. 7.18
figure 18

Regulation function of the switch V G (t)

The results are displayed in Fig. 7.19 up to =0.001 s and in Fig. 7.20 for the remaining simulation up to t=0.01 s. The standard behaviour of the Ćuk converter is found with the siconos software as well as with the spice solver and the results are very similar. The main discrepancy between the nonsmooth approach and the spice approach is the choice of the time-step. The siconos simulations are performed with a time-step h=10−7 s and the spice simulations are performed with a time-step of 10−10 s. This last choice is mainly motivated by the numerical convergence problem of the Newton method when large time-steps are chosen. The gap between this two time-steps results in a gain of CPU time.

The nonsmooth approach allows the use of larger time-step for the same accuracy in avoiding the numerical convergence problem of the Newton method when the electrical characteristics are stiff. This results in more robustness of the simulating process and in lower simulation times.

Fig. 7.19
figure 19

Simulation values versus time (s) for the Ćuk Converter. (1C 1 voltage, (2) C 1 voltage, (3V G gate voltage, (4) MOS switch drain voltage, (5L 1 current and (6L 2 current

Fig. 7.20
figure 20

Simulation values versus time (s) for the Ćuk Converter. (1C 1 voltage, (2) C 1 voltage, (5) L 1 current and (6) L 2 current

5 A Circuit Exhibiting Sliding Modes

The goal of this section is to focus on the very interesting feature of the nonsmooth approach: the possibility to simulate consistently multivalued components and then coherently ideal components. The point is not to show that ideal components are better for the physical modeling accuracy, but rather that the regularization or standard hybrid approaches are not convenient for a high-level description and design.

Our goal is to show that it is better to have a right simulation with an ideal model rather than a simulation which does not work correctly with a regularized model and pseudo-physics.

Let us consider a multivalued component, more precisely, we choose a multivalued behavior of a couple of Zener-diodes as the one which has been already introduced in Sect. 2.5.8. The goal is to outline the efficiency of the nonsmooth model by inclusions to handle such a behavior, even when a sliding mode occurs. In this context, the sliding mode has to be understood as a mode whose operating point of the component is inside the multivalued part of the graph in Fig. 2.24. The circuit is depicted in Fig. 7.21.

Fig. 7.21
figure 21

RLC Zener-diodes circuit

5.1 Models and Dynamical System

The choice of the vector of unknowns is [I,V cap ]T and it yields:

$$L\frac{dI(t)}{dt}=-RI(t)-V_{\mathit{cap}}(t)+V(t),\qquad C\frac{dV_{\mathit{cap}}(t)}{dt}=I(t).$$
(7.11)

5.1.1 Nonsmooth Model of Double Opposite Zener Diodes

For simplicity’s sake, the two Zener diodes D 1 and D 2 in Fig. 7.21 are modeled as a single component. The behavior of the whole component is given by (see Fig. 2.24):

$$-I\in{\mathbb{N}}_{[-V_z,V_z]}(V),$$
(7.12)

which can be equivalently written as a complementarity problem (see the material in Sect. 2.4.6, especially (2.90)):

$$ \left\{ {\begin{array}{*{20}{l}} {V = {\lambda _2} - {V_z},} \\ {{y_1} = {V_z} - V,\quad and\quad 0 \leqslant \left( {\begin{array}{*{20}{l}} {{y_1}} \\ {{y_2}} \end{array}} \right) \bot \left( {\begin{array}{*{20}{l}} {{\lambda _1}} \\ {{\lambda _2}} \end{array}} \right) \geqslant 0.} \\ {{y_2} = I + {\lambda _1}.} \end{array}} \right. $$
(7.13)

5.1.2 A Hybrid Single Valued Ideal Model in Verilog/Eldo

Using a Netlist and a verilog description of the relation (7.14) to represent the couple of Zener diodes, a hybrid single valued model reads as:

$$ V = \left\{ {\begin{array}{*{20}{l}} {{V_z}\quad \quad if\;I\; < \;0,} \\ {0\quad \;\quad if\;I\; = \;0,} \\ { - {V_z}\;\quad if\;I\; > \;0.} \end{array}} \right. $$
(7.14)

5.1.3 A Smooth Model Using Hyperbolic Tangent Function in Eldo

Another approach consists in using the hyperbolic tangent function to approximate the multivalued components D 1 and D 2, i.e. the vertical branch in Fig. 2.24 or in Fig. 1.8(b), is replaced by a stiff smooth curve. The relation between V and I is V=−V z tanh (av). The coefficient a is chosen sufficiently large in order to neglect the influence of the regularization. We chose the value 105 to simulate the circuit using Eldo.

5.2 Simulation and Comparisons

The initial conditions are chosen as I(0)=0 A, V cap (0)=−10 V and the value of V z is 0.5 V. The simulation using the LCP is successfully achieved with Siconos. The result is shown in Fig. 7.22(a). This electrical circuit dissipates some energy, so V cap oscillates with a decreasing amplitude up to a threshold value V z . After the first event at t=t b , the current i vanishes and the voltage through the capacitor V cap is stabilized to a nonzero value, equal to v through the double Zener diodes component. Notice that this equilibrium point is located in the multivalued part of the characteristic.

Fig. 7.22
figure 22

Simulation of the circuit with a sliding mode

Such a behaviour exactly corresponds to the dynamics (7.117.12), for which the segment {(I,V cap )∣I=0,−V z V cap V z } is an attractive sliding surface, attained in a finite time. When I=0, it follows from (7.12) that V cap ∈[−V z ,V z ]. Figure 7.22(a) shows also the eldo simulation using the Netlist and the Verilog relation (7.14). In this case the simulation is correctly done until t b . At the first event at time t b , the simulation cannot be continued because the equilibrium point of the circuit is not handled by the model.

The simulation using the hyperbolic function has been made using Eldo. We focus our attention on the difference due to the regularization of the multivalued model. Figure 7.22(b) zooms on the moment where the current vanishes. At this instant, the circuit is equivalent to an RLC circuit where the value of R is the coefficient of the tangent to the hyperbolic curve a. Note that using a coefficient a larger than 105 leads to an artificial v oscillation around the value of V cap . The conclusion is that we cannot expect to observe the convergence toward an ideal behavior with such a regularization.

The NSDS method with Moreau’s implicit time-stepping scheme allows one to perfectly simulate sliding mode phenomena. This is not the case for the other approaches.

More details on the simulation of sliding mode systems may be found in Acary and Brogliato (2010).