The Transitive Closures of Matrices Over Idempotent Semirings and Its Applications*

The Transitive Closures of Matrices Over Idempotent Semirings and Its Applications*

International Conference on Advanced Computer Science and Electronics Information (ICACSEI 2013) The Transitive Closures of Matrices over Idempotent Semirings and its Applications* Wang Zhixi1, Wang Yana1, He Yong1, Hu Binliang2 1 School of Computer Science and Engineering, Hunan University of Science and Technology, Xiangtan 411201, Hunan, China 2Colleges of Electromechanical Engineering, Hunan University of Science and Technology, Xiangtan 411201, Hunan, China [email protected], [email protected], [email protected], [email protected] Abstract - The Algebraic Path Problem is an important issue method has been improved from every angle and its with a broad background. Consider the problem to solve the application has a gradual expansion from some special algebraic path problem can be concluded to find the Kleene closure semirings first to general cases, and the computing power of the adjacency matrix, an algorithm of time complexity O() n 3 to with the introduction of advanced technologies such as find the transitive closure of matrices over idempotent semiring is parallel computing has been greatly improved [7-14]. constructed, as well as the conditions applicable to it are provided. However, the semirings applied to Gauβ- Jordan elimination Compared with the Gauβ-Jordan elimination, this algorithm could method always required completeness and closeness. extend the applicable range to certain semirings which do not have Note that the Kleene Closures of matrices over completeness and closeness, Thus, it has a wide application since it Idempotent semirings are easily obtained by their Transitive can provide a new method to solve the algebraic path problem over Closures. This paper constructs an algorithm to find the idempotent semirings which do not have completeness and closeness. Transitive Closures of matrices over idempotent semiring and Index Terms - Idempotent semiring, Transitive Closures, provides conditions applicable to it. Actually, the algorithm Transitive_Closure Algorithm, Algebraic Path Problem. extends the applicable range of Gauβ-Jordan elimination method to certain semirings which do not have completeness I. Introduction and closeness. The Algebraic Path Problem, which is to perform a II. Preliminary special unary operation, called closure, on a square matrix over semirings based on semirings-algebraic theory, is an Let R be a non-empty set defined the addition and important issue with a broad background. This problem the multiplication . If (,)R is a commutative monoid, and generalizes some matrix problems(such as computing the (,)R is a semigroup, moreover, multiplication satisfies inverse of a real-valued matrix), graph problems(e.g. transitive closure, shortest path, the stochastic communication the distributive law to addition , then the algebraic system network problem), and regular language problems(e.g. the RR(,,) is called a semiring. Usually, the product a b proof of the correspondence between regular expressions and of elements a , b over semiring R is denoted byab . Denote finite automata). Algebraic path problem and its algorithms that a(m ) a a 2 am for the element a of R and positive have a wide application in the field of network engineering, image processing and pattern recognition. integer m . In 1956, Kleene proved that every regular language can Assume that R is a semiring. If 1R is the identity be represented by a regular expression. Actually, it was the element of (,)R , then we say that 1 is the identity element first algorithm for the algebraic path problem[1]. And in of R . If 0R is the identity element of (,)R and the zero 1962, Warshall algorithm for computing the transitive closure and Floyd algorithm for shortest path problem were element of(,)R , then we say 0 is the zero element of R . respectively proposed[2-3]. Later, Gaussian elimination for Define the relation over semiring R as computing the inverse of matrices was also presented[4-5]. a b a b a . We call R an idempotent semiring if for any Warshall algorithms, Floyd algorithms and Gaussian a R , then a a . It is easy to prove that the relation over elimination method are classical algorithms for these three the idempotent semirings is a partial order relation. The problems respectively [2-4]. Until 1971, Carré discovered the idempotent semirings have a significant application in similarities between these algorithms and proposed their solving optimization problems and the classification of general form Gauβ-Jordan elimination for solving them based regular languages, c.f. [14-16]. on semirings algebra theory. The algorithm for solving algebraic path problem boiled down to find the Kleene For the element a of R , let (a ) { x R x a, x xx} , closure of adjacency matrix, i.e., the summation of all non- we call that at is the transitive closure of a if at () a and negative integer powers of the adjacency matrix[6]. Since t then, with an in-depth study, Gauβ-Jordan elimination for any x()A , x a . * This work is supported by National Nature Science Foundation of China (No:61272196), Hunan Provincial Natural Science Foundation of China ( No: 10JJ3067), and Scientific Research Fund of Hunan Provincial Education Department (No: 11C0534). © 2013. The authors - Published by Atlantis Press 174 Similar to the numerical matrices, we can define The Analysis of The Complexity of Algorithm. matrices and their addition and multiplication over semiring The algorithm firstly is to compute the matrices A[]n , R . Denote the element (,)i j of A over R by Aij , and then is to check the applicable conditions of the algorithm. Taken the assignment, addition, multiplication and matrix that the element (,)i j is a over R by ()a . The set ij ij comparison operations of the elements of the semiring as a of all n square matrix over R is recorded as MRn() .Then basic operation respectively, we can conclude that the first 2 part needs 3n ( n 1) times of basic operations, and the second MRn() with regard to matrix addition and multiplication also forms a semiring called an n square matrix semiring over part takes up at most 2n 3 times of the basic operations. 3 R . The relation on MRn() is defined as: ABAB ij ij Hence, the time complexity of the algorithm is O() n , which has the same order with the time complexity of the Floyd for 1i , j n . Obviously, MRn() is idempotent if and only if algorithm and the Gauβ-Jordan algorithm, c.f. [4], [12]. R is idempotent. For the n square matrix A over R and positive integer m , we set AAAA(m ) 2 m , and denote IV. Proof Of The Transitive_Closure Algorithm m m the element (,)i j of A by Aij , and also the element In this section, we assume that R is an idempotent ()m ()m semiring, n is a given positive integer, and A()() aij M n R . (,)i j of A by Aij . The basic properties of matrices We need Lemma 2 to Lemma 4 as follows to prove the over semirings and the details of semirings can be found in Transitive_Closure algorithm, i.e., the Theorem 1. literature [15]. Lemma 2 Let a,,,, b c d x R with 1i m . Then the following For the n square matrix A over R and the non- i [][]k k condition holds: negative integer k with kn , we define matrices AA ij m a x a x i1, 2, , m recursively as follows: (1) i if and only if i , for . i1 A , k0 ij (2) If there exists an integer i such that xi a , then AA[k ] [ k 1] , i k or j k ij ij m A[k 1] A [ k 1] A [ k 1] , 1 k n and i k and j k ij ik kj xi a . i1 III. The Analysis Of The Complexity Of Transitive_Closure (3) If a b , cd , then acbd . Algorithm Proof. (1) Assume that a xi with i1, 2, , m , then The following theorem is the main conclusion of this m m m article, and we will consider the proof of this matter in next a xi () a xi a a . section. i1 i 1 i1 m Theorem 1. Let R is an idempotent semiring, AMRn() , Conversely, assume that a xi , then for each xi , we i1 t[] n [][][]n n n then AA if and only if AAAij ik kj for 1i , j , k n . m m have a xi a xi x i a xi a . Theorem 1 provides an algorithm to compute the i1 i1 transitive closures of the n square matrix over idempotent (2) Assume that there exists an integer i such that semiring, the algorithm can be described by the pseudo codes x a . Further assume that i1 , then as follows: i m m m Transitive_Closure Algorithm a xi () a x1 xi x i . i1 i2 i 1 Function Transitive_Closure(Matrix A, Matrix W) (3) Assume that a b , c d , then n = A.rows, W = A ac bd ( a b )( c d ) bd '' n is the order of the matrix, W is the result matrix '' First part: Calculate the matrix W, i.e., the matrix A[n] ac ad bc bd bd For k = 1 To n ac ad bc bd . For i = 1 To n, j = 1 To n Do '' Calculate the matrix A[k] (a b )( c d ) If i = k Or j = k Then Continue For ac W(i, j) = W(i, j) + W(i, k) * W(k, j)) Lemma 3. Assume a R , x() a , then the following Next Next k conditions holds: '' Second part: Check the applicable condition of the algorithm (max(r , p q )) For i = 1 To n, j = 1 To n, k = 1 To n Do (1) a()()()r a p a q a , where r,, p q are all positive '' Check whether W <= W * W integers.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    4 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us