Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

2015 American Control Conference

Palmer House Hilton


July 1-3, 2015. Chicago, IL, USA

Computation of the maximum time for failure diagnosis of


discrete-event systems
Gustavo S. Viana, João C. Basilio, Marcos V. Moreira

Abstract— Although the theory of failure diagnosis of occurrence (diagnosis) is taken based on observed events
discrete-event systems has been proved effective, one question only, i.e., those events whose occurrence can be recorded by
remains open: assuming that the generated language is diag- sensors. Therefore, when using diagnosers offline in order to
nosable, how long does the diagnosis system take to detect the
failure occurrence? In this paper, although we still consider predict the time spent to diagnose the failure, it is impossible
the DES as a dynamic system whose evolution is determined to take into account the time interval between occurrences of
by the asynchronous occurrence of events, we add to each observable events that have unobservable events in-between.
transition a weight that corresponds to the maximum time that In order to overcome this apparent diagnoser deficiency we
takes for the event to occur since the moment it fires (the so- propose in this paper a new test for verification of language
called time-weighted model), to propose an effective algorithm
to determining the maximum time for failure diagnosis. This diagnosability of DES, also based on diagnosers, which has
result was only possible because we derive a new necessary the following advantages over the usual diagnosability tests
and sufficient condition for diagnosability verification and by based on diagnosers: (i) the verification diagnoser event set
the use of max-plus algebra to obtain a matrix representation has both, observable and unobservable events; (ii) it does not
for time-weighted automata. require the usual assumptions on language liveness and non-
I. I NTRODUCTION existence of cycles of states connected with unobservable
events [1], [2]; (iii) it is based on the search for strongly
One approach to fault diagnosis is by constructing a connected components, as opposed to cycles in the usual
discrete-event model of the system whose fault occurrence tests using diagnosers [1], [3]; it is worth noting that search
must be diagnosed [1]. In practice, this is usually carried for cycles has computational complexity that is worse than
out by means of a deterministic automaton called diagnoser, exponential [4], [5], whereas the search for strongly con-
whose states are sets formed with the states of the automaton nected components is linear.
the models plant together with labels that indicate if the trace Although the diagnosability verification test proposed here
occurred so far possesses or not the fault event; diagnosers provides all information regarding occurrences of both ob-
are also used offline for diagnosability verification. In the servable and unobservable events, it is also necessary to have
design of a failure diagnosis system for DES, the first step is the information on the time interval between two consecutive
to check whether the language generated by an automaton is event occurrences. In this paper, this information will be
diagnosable, i.e., whether the system is able to diagnose the provided by modeling the DES by time-weighted automata
failure occurrence in a finite number of events occurrences. [6]. The calculation of the time the diagnosis system takes
Another aspect that is not analysed and is equally im- to detect the failure diagnosis can then be obtained by
portant is that, given that a language is diagnosable, how using the so-called max-plus matrix [7] associated with the
long it takes the diagnoser to reach a certain failure state; time-weighted verification diagnoser, a verification diagnoser
or better still, what is the maximum time required for the computed by using time-weighted automata as opposed to
system to be sure that the failure has occurred? In a real untimed automata.
system, a failure can impair an entire production line. But Diagnosability of timed DES has also been considered in
just being sure that the failure has occurred is not enough; [8] using the model proposed in [9], but without computing
for example, components may burn or parts may misalign the maximum time for failure diagnosis. This paper, on the
before the failure occurrence is detected. So, it is important other hand, not only provides a systematic way of computing
to analyse the detection time as a parameter to characterize the maximum time for diagnosability but also extends the
the diagnosability; possibly based on this parameter, we can diagnosability condition to timed DES modeled by time-
establish safety measures. weighted automaton.
The problem related to the computation of the time the This paper is structured as follows. In Section II, we
diagnosis system takes to inform with certainty the failure present the necessary background on DES, failure diagnosis
occurrence becomes more involved due to the existence of DES, max-plus algebra, time-weighted systems and max-
of unobservable events since the decision on the failure plus representation of time-weighted automata. In Section III,
*This work has been partially supported by the Brazilian Research we present a new necessary and sufficient condition for
Council (CNPq) and by the Ministry of Education (CAPES). diagnosability of discrete-event systems and a test based
The authors are with COPPE - Programa de Engenharia Elétrica, on the search of strongly connected components. In Sec-
Universidade Federal do Rio de Janeiro, 21949-900, Rio de Janeiro,
RJ, Brazil. gustavo.viana@poli.ufrj.br, basilio@dee.ufrj.br, tion IV we present an algorithm for computing the maxi-
moreira.mv@poli.ufrj.br mum time the diagnosis system takes to detect the failure

978-1-4799-8684-2/$31.00 ©2015 AACC 396


Authorized licensed use limited to: UNIVERSIDADE FEDERAL DO RIO DE JANEIRO. Downloaded on July 12,2023 at 15:07:35 UTC from IEEE Xplore. Restrictions apply.
occurrence; assuming, of course, language diagnosability. where s = {u ∈ Σ∗ : (∃v ∈ Σ∗ )[uv = s]}. Therefore, s ∈ L
An example is presented in Section V to illustrate the is a trace that has the failure event σf if Σf ∈ s. Language
results of the paper. Finally, conclusions and an outline of diagnosability can be formally defined as follows [1].
future works are presented in Section VI. Due to length Definition 1: A live and prefix-closed language L is diag-
constraints, all proofs have been omitted and can be found nosable with respect to Po : Σ∗ → Σ∗o and Σf if
in http://www.dee.ufrj.br/lca/artigos/acc2015full.pdf.
(∃n ∈ N)(∀s ∈ Ψ(Σf ))(∀t ∈ L/s, |t| ≥ n) ⇒
II. BACKGROUND
(∀ω ∈ Po−1 [Po (st)] ∩ L)(Σf ∈ ω).
Let G = (X, Σ, f, Γ, x0 , Xm ) denote a deterministic One way to verify diagnosability is by means of an
automaton, where X is the finite state space, Σ is the set automaton called diagnoser [1], [3] which is given by
of events, f is the transition function, assumed here to be
partially defined in the event set, Γ is the active event set, i. e., Gd = (Xd , Σo , fd , Γd , x0d ) = Obs(GkA` ),
Γ(x) = {σ ∈ Σ : (∃y ∈ X)[f (x, σ) = y]}, x0 is the initial
state, and Xm is the set of marked states. We will assume where A` = (X` , Σ` , f` , Γ` , x0` ) is the so-called label
that the event set is partitioned as Σ = Σo ∪Σ ˙ uo , where Σo automaton, with X` = {N, Y }, Σ` = {σf }, f` (N, σf ) =
(resp. Σuo ) denotes the set of observable (resp. unobservable) f` (Y, σf ) = Y , Γ` (N ) = Γ` (Y ) = Σ` and x0` = N . It is not
events. The languages generated and marked by G will be difficult to see that L(Gd ) = Po (GkA` ) = Po (L). A state
denoted as L(G) = L and Lm (G) = Lm , respectively. xd ∈ Xd is called certain (or faulty), if ` = Y for all (x, `) ∈
Given a trace s ∈ L, we define the post-language of L xd , and normal (or non-faulty) if ` = N for all (x, `) ∈ xd . If
there exist (x, `), (y, `) ˜ ∈ xd , x not necessarily distinct from
after s as L/s = {t ∈ Σ∗ : st ∈ L}. The assumption
usually made in the literature [1], [2] that G does not possess y such that ` = Y and `˜ = N , then xd is an uncertain state
cyclic paths formed with unobservable events only is not of Gd . When the diagnoser is in a certain (normal) state, it
required here. As a consequence, we can also assume that is certain that a fault has (resp. has not) occurred. However,
the language generated by G is always live, since any non- if the diagnoser is in an uncertain state, it is not sure if the
live language can be made live by adding self-loops labeled fault event has occurred or not. As a consequence, if there
by unobservable events at the states x for which Γ(x) = ∅. exists a cycle formed with uncertain states, only, where the
The natural projection Po : Σ∗ → Σ∗o is defined in the diagnoser can remain forever, then it will never be able to
usual way [10]. Its extension to a language L is carried out diagnose the fault occurrence; on the other hand if somehow
in a straightforward way by applying Po to all traces of L, it always leaves this cycle of uncertain states, then this cycle
i.e., Po (L) = {t ∈ Σ∗o : (∃s ∈ L)[Po (s) = t]}. The inverse is not indeterminate. Therefore, it is important to distinguish

projection is the mapping Po−1 : Σ∗o → 2Σ , where, for any between cycles of uncertain states that are indeterminate (in
s ∈ Σ∗o , Po−1 (s) = {t ∈ Σ∗ : Po (t) = s}. the sense that the diagnoser is not able to determine if the
Let G1 = (X1 , Σ1 , f1 , Γ1 , x01 , Xm1 ) and G2 = fault has occurred) and those cycles of uncertain states that
(X2 , Σ2 , f2 , Γ2 , x02 , Xm2 ) denote two automata whose gen- are not indeterminate.
erated languages are L1 and L2 , respectively. The parallel Definition 2: [1] (Indeterminate observed cycles of Gd )
composition between G1 and G2 as defined in [11] will be A set of uncertain states {xd1 , xd2 , . . . , xdp } ⊂ Xd forms
denoted as G1 kG2 . If we define Σ = Σ1 ∪Σ2 , P1 : Σ∗ → Σ1 an indeterminate observed cycle if the following conditions
and P2 : Σ∗ → Σ2 , then, it is not difficult to prove that hold true:
L(G1 kG2 ) = P1−1 (L1 ) ∩ P2−1 (L2 ). IOC.1) xd1 , xd2 , . . . , xdp form a cycle in Gd ;
The dynamic behavior of a deterministic automaton G IOC.2) ∃(xkl l , Y ), (x̃rl l , N ) ∈ xdl , xkl l not necessarily
with unobservable events can be described by a deterministic distinct from x̃rl l , l = 1, 2, . . . , p, kl = 1, 2, . . . , ml ,
automaton called observer, here denoted as Obs(G) = and rl = 1, 2, . . . , m̃l in such a way that the
(Xobs , Σo , fobs , Γobs , x0obs , Xmobs ). The states of Xobs in- sequence of states {xkl l }, l = 1, 2, . . . , p, kl =
dicate where automaton G can be after observable events 1, 2, . . . , ml and {x̃rl l }, l = 1, 2, . . . , p, rl =
are recorded, and for this reason Xobs ∈ 2X (2X denotes 1, 2, . . . , m̃l form cycles in G;
the power set of X). An algorithm for computing all the IOC.3) there exist s = s1 s2 . . . sp ∈ Σ∗ and s̃ =
states and transitions of Obs(G) can be seen in [11, p. 89]. s̃1 s̃2 . . . s̃p ∈ Σ∗ such that Po (s) = Po (s̃) 6=
, where sl = σl,1 σl,2 . . . σl,ml −1 , f (xjl , σl,j ) =
A. Failure diagnosis of DES xj+1 , j = 1, 2, . . . , ml − 1, f (xm l , σl+1,0 ) = xl+1 ,
l 1
l
mp
Let Σf = {σf } ⊆ Σuo denote the set of failure events of and f (xp , σ1,0 ) = x1 , and similarly for s˜l .
1

G and assume that the occurrence of σf must be diagnosed, Assume now that there exists a set of states
i.e, we must somehow be sure, after a finite number of steps {xi1 , xi2 , . . . , xik } ⊂ X that form a cycle of states
of the occurrence of σf that it has actually occurred. This connected with unobservable events. Consider a trace
language property is called diagnosability. s = so (σi1 , σi2 , . . . , σik )n ∈ L (n ∈ N), where
Let us assume that Ψ(Σf ) denote the set of all traces of (σi1 , σi2 , . . . , σik )n ∈ Σ∗uo and assume, without loss
L that ends with the failure event σf . With a slight abuse of generality, that the last event of so is observable.
of notation, we use Σf ∈ s to denote that s ∩ Ψ(Σf ) 6= ∅, Let us suppose, initially, that σf ∈ / s and that there

397
Authorized licensed use limited to: UNIVERSIDADE FEDERAL DO RIO DE JANEIRO. Downloaded on July 12,2023 at 15:07:35 UTC from IEEE Xplore. Restrictions apply.
is no faulty trace1 s0 such that Po (s) = Po (s0 ). In transition of G and is defined over a pair (x, σ) ∈ X × Σ
this case there will exist in Gd a state xN d such that if, and only if, transition f (x, σ) is defined. The weights
{xi1 N, xi2 N, . . . , xik N } ⊆ xN d . On the other hand, denote the duration required for the corresponding transition
if Σf ∈ so and f` (x0,` , so ) = xY` , where f` is the to be completed. A time-weighted automaton is a three-tuple
transition function of G` = GkA` , x0,` and xY` are, G = ((G, w), h) where (G, w) is a finite-weighted automaton
respectively, the initial and a certain state of G` , and if and h ⊆ Σ × Σ is a reflexive and symmetric binary relation
there is no normal trace s00 such that Po (s) = Po (s00 ), called intrinsic mutual exclusion relation. A pair (σ, σ 0 ) ∈ h
then, there will exist a certain state xYd of Gd such if the firings of σ and σ 0 are mutually exclusive, i.e., if one
that (xY` ∪ {xi1 Y, xi2 Y, . . . , xik Y }) ⊆ xYd . It is still event is under execution, the other event will not be initiated;
possible that a normal trace s00 (bounded length or not) otherwise, (σ, σ 0 ) ∈
/ h. The term “intrinsic” means that the
such that f` (x0,` , so ) = xN ` , where x`
N
is a normal mutual exclusion relation imposed by h is a property of the
state of G` , and Po (s) = Po (s ), exists. In this case,
00
system. In each automaton G, the order of events in a string
there will exist an uncertain state xYd N in Gd such that s ∈ L(G) denotes the order of the corresponding starting
(xY` ∪ {xi1 Y, xi2 Y, . . . , xik Y } ∪ xN ` ) ⊆ xd . In all the moments of event firings, and it is possible that the starting
YN

above cases, Gd halts when it reaches the corresponding moments of two consecutive firings in s are identical. For
normal, faulty and uncertain states, in spite of the plant example, suppose s = ab ∈ L(G) and let ta , tb ∈ R+ ∪ {0}
evolution. We say, in this case, that there exist hidden cycles be the corresponding starting moments of events a and b.
in the above states. Thus, ta ≤ tb . On the other hand, if (a, b) ∈ h, then
Definition 3: [3] (Hidden cycles and indeterminate hidden necessarily, tb ≥ ta + w(x0 , a). As in the definition of ordi-
cycles of Gd ) Let xd = {x1 `1 , x2 `2 , . . . , xn `n } be a state nary finite-state automata, if an event σ is shared by several
of Gd . There exists a hidden cycle in xd if for some component automata, then the starting moments of the firings
{i1 , i2 , . . . , ik } ⊆ {1, 2, . . . , n}, the following conditions of σ in all automata must be synchronized. Figure 1 depicts
hold true: time-weighted automaton G. Notice that label “a/2” over
HC.1) xi1 , xi2 , . . . , xik form a cycle in G; transition f (1, a) = 2 means that w(1, a) = 2; the remain-
HC.2) {σi1 , σi2 , . . . , σik } ⊆ Σuo , where σi1 , σi2 , . . . , σik ing labels are interpreted similarly. Given two finite-state
are such that f (xij , σij ) = xij+1 , j = 1, 2, . . . , k −
1, and f (xik , σik ) = xi1 . a/2 b/1, c/3
1 2 3
If xd is an uncertain state of Gd and besides conditions HC.1) d/1 a/2
and HC.2), the following condition is also satisfied,
4
HC.3) `ij = Y , j = 1, 2, . . . , k,
then xd has an indeterminate hidden cycle. 
Fig. 1. A time-weighted automaton G.
In accordance with Definition 3, there exist hidden cycles
in states xN d and xd of Gd and an indeterminate hidden
Y
weighted automata ((Gi = Xi , Σi , fi , xi,0 , Xi,m ), wi )(i =
cycle in xd . Notice that in the verification of language
YN
1, 2), the parallel composition of (G1 , w1 ) and (G2 , w2 ),
diagnosability, state xYd (xN d ) ensures that the fault has denoted as (G1 , w1 )||(G2 , w2 ), is a weighted automaton
(resp. has not) occurred, and so, the existence of hidden
((G = X, Σ, f, x0 , Xm ), w), where X = X1 × X2 , Σ :=
cycles in normal or certain states of Gd does not affect the
Σ1 ∪ Σ2 , x0 := (x1,0 , x2,0 ), Xm = X1,m × X2,m , and
language diagnosability. On the other hand, the existence
w : X1 × X2 × (Σ1 ∪ Σ2 ) → X1 × X2 is defined as
of indeterminate hidden cycles implies that the language is
follows: (i) f ((x1 , x2 ), σ) is defined according to the parallel
not diagnosable since there exist two traces, a faulty one
composition rules presented in [11]; (ii) w : X1 ×X2 ×(Σ1 ∪
(unbounded), s, and a normal one bounded, s00 , such that
Σ2 ) → R+ is defined as follow: w((x1 , x2 ), σ) = w(x1 , σ),
Po (s) = Po (s00 ). The following necessary and sufficient
if σ ∈ Γ1 \ Σ2 , w((x1 , x2 ), σ) = w(x2 , σ), if σ ∈ Γ2 \ Σ1 ,
condition for diagnosability can be stated.
w((x1 , x2 ), σ) = max{w(x1 , σ), w(x2 , σ)}, if σ ∈ Γ1 ∩ Γ2 ,
Theorem 1: [1], [3] The language L generated by automa-
and undefined, otherwise.
ton G is diagnosable with respect to projection Po : Σ∗ →
Σ∗o and Σf = {σf } if, and only if, its diagnoser Gd has no
C. Max-plus matrix representation of time-weighted au-
indeterminate (observed or hidden) cycles.
tomata
B. Time-weighted systems Let us define ε := −∞, e := 0 and Rmax = R ∪ {ε},
In this section, we will review the main concepts of time- where R denotes the set of real numbers. For two elements
weighted systems. For a more complete treatment, the reader a, b ∈ Rmax , the ⊕ and ⊗ operations are defined as follows:
is referred to the seminal paper by Su et al. [6].
A finite-weighted automaton is a two-tuple (G, w), where a ⊕ b := max(a, b) and a ⊗ b := a + b. (1)
G = (X, Σ, f, Γ, x0 , Xm ) and w : X × Σ → R+ is the
weighting function which assigns a positive weight to each It is not difficult to see that a ⊕ ε = ε ⊕ a = a and a ⊗ ε =
ε ⊗ a = ε. The five-tuple (Rmax , ⊕, ⊗, ε, e) is called a max-
1A trace s is said to be faulty (normal) if Σf ∈ s (resp. Σf ∈
/ s). plus algebra. As in the conventional algebra, ⊗ operation has

398
Authorized licensed use limited to: UNIVERSIDADE FEDERAL DO RIO DE JANEIRO. Downloaded on July 12,2023 at 15:07:35 UTC from IEEE Xplore. Restrictions apply.
priority over ⊕ and distributes over ⊕. Powers are defined ((X, Σ, f, Γ, x0 , Xm ), w), where X = {1, 2, . . . , n}. Define
in max-plus algebra in the usual way as follows: the following matrix:
n
x⊗n := x ⊗ x ⊗ x . . . ⊗ x = n × x. (2) M
| {z } A+ := A⊗k = A ⊕ A⊗2 ⊕ A⊗3 ⊕ . . . ⊕ A⊗n . (5)
n times k=1

The set of m × n max-plus matrices is denoted as Rmaxm×n


. Then, the maximum weight sum of all paths from state j to
The element aij of a matrix A ∈ Rmax is sometimes denoted state i is equal to element [A+ ]ij . Moreover, if L
we truncate
p
as [A]ij . The sum of two matrices A, B ∈ Rm×nmax is denoted the above sum to p (p < n) and define A+ p := k=1 A
⊗k
,
as [A ⊕ B]ij = aij ⊕ bij = max(aij , bij ). Clearly, A ⊕ B = then [Ap ]ij will represent the maximum weight of all paths
+

B ⊕ A. In addition, for α ∈ Rmax , then [α ⊗ A]ij = α ⊗ aij . from j to i of length p.


For two matrices C ∈ Rm×l max and B ∈ Rmax the product
l×n
Matrix A+ is called maximum weight matrix. For automaton
matrix A ⊗ B is defined as follows: G of Figure 1, the maximum weight matrix A+ is given by:
 
l
M ε ε ε ε
[A ⊗ B]ik = aij ⊗ bjk = max{aij + bjk }, i ∈ m, k ∈ n,  2 ε ε ε 
j=1
j∈l A+ =  5 3 ε ε 

where m = {1, 2, . . . , m} and n = {1, 2, . . . , n}. The 7 5 2 ε


m × n matrices ε(m, n) and E(m, n) whose elements as Notice that element a+ 41 = 7, which is equal to the maximum
defined as [E(m, n)]ij = e, if i = j and ε, satisfy the weight of the paths from initial state 1 to marked state 4.
following relationships: A ⊕ ε(n, m) = A = ε(m, n) ⊕ A Remark 1: Notice that the max-plus matrix A above is
and A ⊗ E(n, n) = A = E(m, m) ⊗ A. In addition, strictly lower triangular (the elements on the main diagonal
for k ≥ 1, we have that A ⊗ ε(n, k) = ε(m, k) and and above are all equal ε, which implies that all powers of A
ε(k, m) ⊗ A = ε(k, n). For Rm×nmax , the matrix addition ⊕ is are also strictly lower triangular). This is true for all max-plus
associative, commutative, and has zero element ε(m, n) and matrices associated with acyclic time-weighted automata.
the matrix product ⊗ is associative, distributive with respect Using this fact, it is possible to develop a procedure to
to ⊕, possesses the unit element E(n, n), and is absorbing obtain the maximum weight of all paths from j to i of length
for ε(n, n). As in the conventional algebra, ⊗ is not, in p without computing max-plus powers of A. The resulting
general, commutative. In the addition and multiplication of procedure is similar (regarding computational complexity) to
scalars, the matrix product ⊗ has priority over ⊕. For a that proposed in [12]. 
matrix A ∈ Rn×nmax , a k-th power of A is defined as:
III. A NEW NECESSARY AND SUFFICIENT CONDITION
A⊗k := A ⊗ A ⊗ ... ⊗ A . (3) FOR DIAGNOSABILITY OF DISCRETE EVENT SYSTEM
| {z }
k times In this section, we will present a different approach to
By definition, A := E(n, n).
⊗0 the verification of language diagnosability that leads to a
Let G denote a time-weighted automaton with n states and new necessary and sufficient condition. The idea behind the
assume that the states of G have been renamed in a such way proposed approach is motivated by the following reasons:
that X = {1, 2, . . . , n}. The max-plus matrix that represents (i) diagnoser Gd does not carry enough information to
G is a square matrix A(n, n) whose i, j-th element is defined determine if an observed cycle of uncertain states is an
as follows: indeterminate cycle; (ii) in order to determine the nature of
 L a hidden cycle in G, it is necessary to search for cycles
 σk ∈Γ(j) w(j, σk ), of states connected with unobservable events in G; (iii) as
[A(n, n)]ij = if f (j, i) is defined, (4) pointed out in [4], the problem of finding cycles is worse
ε, otherwise. than exponential is the number of states.

As an example, the max-plus matrix for the time weighted Let us define Gscc = Gd ||G` , where G` = G||A` , and,
automaton G of Figure 1 can be obtained using equation (4), Gd = Obs(G` ) according to Section II. We may state the
being given as: following result.
  Lemma 2: L(Gscc ) = L(G` ) = L(G).
ε ε ε ε Notice that, since automaton Gscc is obtained by performing
 2 ε ε ε 
A=  a parallel composition between Gd and G` , its states are
 ε 3 ε ε  of the type (xd , x` ). Moreover, there exists the following
ε 1 2 ε inclusion relationship between x` and xd .
Notice that element a32 = 3, because it is the maximum Lemma 3: All states (xd , x` ) of Gscc satisfies the follow-
weight among all transitions from state 2 to state 3. ing inclusion: x` ⊆ xd .
Lemma 1: [7] Let A ∈ Rn×n max be the max-plus
We will now present a necessary and sufficient condition
matrix associated with an acyclic automaton2 G = for language diagnosability that replaces the search for cycles
with the search for strongly connected components. Strongly
2 An acyclic automaton is an automaton that has no cycle of states. connected components, although being also cycles, are less

399
Authorized licensed use limited to: UNIVERSIDADE FEDERAL DO RIO DE JANEIRO. Downloaded on July 12,2023 at 15:07:35 UTC from IEEE Xplore. Restrictions apply.
computationally demanding since in the worst case are linear Remark 2: Note that automata formed in algorithm 1 are
in the number of transitions [5], [13]. obtained by unary operations with input automata. Therefore,
We may now state the following result. in the worst case, the computational complexity of forming
Theorem 2: The language L generated by automaton G all automata Gf i , i = 1, 2, . . . , p is O(|Xd ||X|2 ).
is diagnosable with respect to projection Po : Σ∗ → Σ∗o and We may state the following results.
Σf = {σf } if, and only if, Gscc has no strongly connected Lemma 4: Let L(Gfi ) denote the language generated by
components formed with states (xd , x` ), such that xd is Gfi , i = 1, 2, . . . , p. Then
uncertain and x` certain.
∪pi=1 L(Gfi ) = {t ∈ Σ∗ : (∃s ∈ Ψ(Σf ) ∩ L(Gscc m
)∧
IV. C OMPUTING THE MAXIMUM TIME TO DIAGNOSE m
(∃xm ∈ Xscc,m )[(st ∈ L(Gscc ))∧ m
m
FAILURE OCCURRENCES (fscc (xiscc,0 , t) = xm )]}
In this section we will address the problem of finding the Lemma 5: Automaton Gfi , i = 1, 2, . . . , p does not have
maximum time the diagnosis system takes to diagnose a fault strongly connected components.
occurrence. In order to do so, we make two assumptions. Lemma 4 shows that all language continuation of all traces
A1. The language L is diagnosable with respect to projection of G that end with a failure event and leads to certain
Po and Σf . states of Gd are covered by automaton Gfi , i = 1, 2, . . . , p,
A2. The time-weighted automaton G = ((G, w), h) is such whereas Lemmas 5 ensures that Gfi , i = 1, 2, . . . , p has
that h = Σ × Σ. no strongly connected components. Therefore, the maximum
Assumption A1. is necessary since the problem addressed time necessary to diagnose the fault occurrence can be
here would not make sense if L were not diagnosable. calculated according to the following result.
Assumption A2. implies that any event cannot start firing Theorem 3: Let the states of Gfi , i = 1, 2, . . . , m be
if there is another one that is under execution, which makes renamed such that Xfi = {1, 2, . . . , qi }, where qi = |Xfi |,
sense since we are interested in computing the maximum x0,fi = 1 and Xfi ,m = {i1 , i2 , . . . , iki } ⊆ {1, 2, . . . , qi }.
time for diagnosis. Let Ai denote the max-plus matrix associated with Gfi ,
Let G denote the time-weighted automaton that models the i = 1, 2, . . . , m. Then
plant and A` the time-weighted label automaton. In addition, (a) The time tfi the diagnoser takes to diagnose the failure
let us denote G` = GkA` and Gd = Obs(G` ) with respect to occurrence due to the paths existing in automaton Gfi
Po . We start by calculating a new automaton Gfi according is given by:
to the following algorithm.  
Algorithm 1:
M
tfi =  [A+i ]i,1
 ⊗ tσf ,i
Input Time-weighted automata G, G` , and Gd . i∈{i1 ,i2 ,...,iki }
Output Automaton Gfi .
S TEP 1. Compute G`m from G` by marking all states of where tσf ,i is the weight associated with the failure
G` with label Y. event that formed Gfi .
S TEP 2. Compute Gdm from Gd by marking all certain states (b) The maximum time tf to diagnose the failure occur-
of Gd . rence is m
S TEP 3. Compute
M
tf = tfi .
m i=1
Gscc = Gdm kG`m = (Xscc
m m
, Σ, fscc , Γm m m
scc , xscc,0 , Xscc,m )
V. E XAMPLE
.
In order to illustrate the results of the paper, let us consider
S TEP 4. Set Γ(xm ) = ∅ for all marked states xm of Gscc m
,
automaton G depicted in Figure 2, where Σuo = {σf }.
i.e., remove all output transitions from the marked
states xm of Gscc
m
, and compute
σf /1 a/9
m
Gscc,t = m
trim(Gscc ) 11 1 2 3
m m g/1 b/3 d/4 b/3
= (Xscc,t , Σ, fscc,t , Γm m m
scc,t , xscc,t,0 , Xscc,t,m ) a/9
g/1
12 7 9 10 4
S TEP 5. Find all states xi of Gscc,t
m
that satisty σf ∈ Γ(xi ). d/4
σf /1 d/4
t/2 g/1
Suppose that there exist p states that satisfy this
b/3 t/2
requirement. For each i = 1, 2, . . . , p: 8 6 5
t/2
S TEP 5.1 Construct an automaton
i i
Gscc,i = (Xscc , Σ, fscc , Γiscc , xiscc,0 , Xscc,m
i
), Fig. 2. Time-weighted automaton G.

such that Xscc


i m
= Xscc,t , fscc
i m
= fscc,t , In order to compute the maximum time to diagnose the
Γscc = Γscc,t , xscc,0 = fscc,t (xi , σf ) e
i m i m
occurrence of σf , the first step is to form the time-weighted
i
Xscc,m m
= Xscc,t . diagnoser Gdm = Obs(G m kG`m ), which is shown in Figure 3.
S TEP 5.2 Gfi = trim(Gscci )

400
Authorized licensed use limited to: UNIVERSIDADE FEDERAL DO RIO DE JANEIRO. Downloaded on July 12,2023 at 15:07:35 UTC from IEEE Xplore. Restrictions apply.
{11N, 9Y, 4Y} d/4
b/3 b/3
a/9 ({3Y, 8Y, 7N}, 8Y) ({11N, 9Y, 4Y}, 9Y)
{2Y, 1N} {3Y, 8Y, 7N} g/1
t/2 {6Y}
g/1
d/4 d/4
{10Y, 12N, 5Y} t/2 ({3Y, 8Y, 7N}, 3Y) ({10Y, 12N, 5Y}, 10Y)
b/3 t/2
d/4
Fig. 3. Time-weighted diagnoser automaton Gdm . ({11N, 9Y, 4Y}, 4Y) ({ 6Y}, 6Y)
g/1 t/2
({10Y, 12N, 5Y}, 5Y)
({2Y, 1N}, 1N) ({3N, 4N, 6Y}, 4N)
σf /1 a/9 d/4 g/1 Fig. 5. Time-weighted automaton Gf1 .
b/3
({2Y, 1N}, 2Y) ({3Y, 8Y, 7N}, 7N) ({11N, 9Y, 4Y}, 11N)
σf /1 VI. C ONCLUSIONS
a/9
({11N, 9Y, 4Y}, 9Y) b/3 ({3Y, 8Y, 7N}, 8Y) In this paper the problem of finding the maximum time
d/4
g/1 for failure diagnosis of DES has been addressed. In order
({3Y, 8Y, 7N}, 3Y) ({10Y, 12N, 5Y}, 10Y)
b/3 t/2
to do so, the DES has been modeled using time-weighted
({11N, 9Y, 4Y}, 4Y)
d/4
({ 6Y}, 6Y)
automaton, recently introduced in the literature. In order to
g/1 t/2 take into account the time interval between occurrences of
({10Y, 12N, 5Y}, 5Y)
t/2
observable events that have unobservable events in between,
a new test for verification of language diagnosability of
Fig. 4. Time-weighted test diagnoser automaton Gscc
m .
DES, also based on diagnosers has been proposed. Besides
incorporating unobservable events to its event set, the diag-
nosability test based on verification diagnosers, also has the
The next step is to compute Gscc m
= Gdm kG`m , which is following advantages: it does not require the usual assump-
depicted in Figure 4. Notice that since Gsccm
has no strongly tions on language liveness and cycles of states connected
connected components formed with states (xd , x` ), xd uncer- with unobservable events and it is based on the search for
tain and x` certain, the language is diagnosable with respect strongly connected components, as opposed to cycles as the
to Po e Σf . In addition, notice that Gscc
m
has only one marked usual diagnoser tests. With the new test, the computation
state ({{6Y }, 6Y }) and there are two states xscc such that of the maximum time for diagnosing failure occurrences
σf ∈ Γm scc (xscc ). As a consequence, according to Step 5 of can be carried out in a straightforward by using either the
Algorithm 1, two automata, Gf1 and Gf2 , must be formed; automaton max-plus matrix (as done in the paper) or the
for conciseness reasons, only automaton Gf1 , depicted in iterative algorithm [12] recently proposed in the literature.
Figure 5, will be analyzed here.
The max-plus matrix A1 that corresponds to Gf1 , as well as R EFERENCES
its maximal weight matrix A+ 1 are given by: [1] M. Sampath, R. Sengupta, S. Lafortune, K. Sinnamohideen, and
  D. Teneketzis, “Diagnosability of discrete-event systems,” IEEE Trans-
ε ε ε ε ε ε ε actions on Automatic Control, vol. 40, no. 9, pp. 1555–1575, 1995.
 3 ε ε ε ε ε ε  [2] R. Debouk, S. Lafortune, and D. Teneketzis, “Coordinated decentral-
ized protocols for failure diagnosis of discrete event systems,” Discrete
 
 ε 1 ε ε ε ε ε 
  Event Dynamic Systems: Theory and Applications, vol. 10, no. 1, pp.
A1 =   ε ε 4 ε ε ε ε  33–86, 2000.

 ε ε ε 3 ε ε ε  [3] L. K. Carvalho, J. C. Basilio, and M. V. Moreira, “Robust diagnosis
of discrete event systems against intermittent loss of observations,”
 
 ε ε ε ε 1 ε ε 
Automatica, vol. 48, no. 9, pp. 2068–2078, 2012.
ε ε 2 ε 4 2 ε [4] D. B. Johnson, “Finding all the elementary circuits of a directed
graph,” SIAM Journal of Computing, vol. 4, no. 1, pp. 77–84, 1975.
and [5] T. H. Cormen, C. E. Leiserson, R. L. Rivest, and C. Stein, Introduction
to Algorithms. Cambridge, MA: MIT Press, 2007.
 
ε ε ε ε ε ε ε
[6] R. Su, J. van Schuppen, and J. E. Rooda., “The synthesis of time

 3 ε ε ε ε ε ε 
 optimal supervisors by using heaps-of-pieces,” IEEE Transactions on
 4 1 ε ε ε ε ε  Automatic Control, vol. 57, no. 1, pp. 105–118, 2012.
A+ [7] B. Heidergott, G. J. Olsder, , and J. W. van der Woude, Max Plus at
 
1 =  8 5 4 ε ε ε ε 
.
 Work. New Jersey, NJ: Princeton University Press, 2006.

 11 8 7 3 ε ε ε 
 [8] S. Tripakis, “Fault diagnosis for timed automata,” In Proc. Int. Conf. on
 12 9 8 4 1 ε ε  Formal Techniques in Real Time and Fault Tolerant Systems., vol. 24,
15 12 11 7 4 2 ε no. 3, pp. 205–224, 2002.
[9] R. Alur and D. L. Dill, “Optimal paths in weighted timed automata,”
Notice that element a71 = 15, and thus, the maximum Theoret. Comput. Sci., vol. 126, no. 2, pp. 183–235, 1994.
weight from initial state ({3Y, 8Y, 7N }, 8Y ) to marked state [10] P. J. Ramadge and W. M. Wonham, “The control of discrete-event
systems,” Proceedings of the IEEE, vol. 77, no. 1, pp. 81–98, 1989.
({6Y }, 6Y ) is equal to 15. Since the failure weight is ts = 1, [11] C. G. Cassandras and S. Lafortune, Introduction to Discrete Events
then tf1 = 15 + 1 = 16. Proceeding the same way, the Systems, 2nd ed. New York, NY : USA: Springer, 2008.
maximum time to diagnose σf following the paths given in [12] R. Su and G. Woeginger, “String execution time for finite languages:
Max is easy, min is hard,” Automatica, vol. 47, no. 10, 2011.
Gf2 is tf2 = 17. Therefore, the maximal time to diagnose the [13] R. Tarjan, “Depth first search and linear graph algorithms,” SIAM
occurrence of σf is tf = tf1 ⊕ tf2 = max(tf1 , tf2 ) = 17. Journal of Computer, vol. 1, no. 2, pp. 146–160, 1972.

401
Authorized licensed use limited to: UNIVERSIDADE FEDERAL DO RIO DE JANEIRO. Downloaded on July 12,2023 at 15:07:35 UTC from IEEE Xplore. Restrictions apply.

You might also like