From Boolean networks to linear dynamical systems: a simplified route

ABSTRACT Boolean Networks can be converted to discrete linear dynamical systems on finite spaces by a semi-tensor-product approach. This approach has been used by many to study the dynamics and control of Boolean systems. However, the process of getting the linear representation using the semi-tensor-product method is complicated even for a simple three-node network and requires the help of a computer program. In this work, we show that we can skip the semi-tensor process and obtain the same linear representation with a straightforward mapping. Moreover, our approach produces a large number of isomorphic representations which provides a flexible framework. Importantly, it could simplify the analytical study of networks with unspecified number of nodes that have some structure.


Introduction
An n-node autonomous Boolean network is a discrete dynamical system with the form x i (t + 1) = g i (x 1 (t), x 2 (t), . . . , x n (t)), ( 1 ) where x i is the state variable of the ith node, t is the current time step, t + 1 is the next time step and g i is a Boolean function with a value of either 0 or 1. To simplify the notation, we rewrite Equation (1) as: where x is a vector of size n, containing the states of all the Boolean nodes at the current step, x + is the state of the n Boolean nodes in the next step and g = [g 1 , g 2 , . . . , g n ] T . Since first introduced by Kauffman [22], Boolean networks have been widely used to model biological regulatory networks [1,2,6,14,18,36,37,40,41,46]. They can be set up in situations where the detailed kinetic characterization of an interaction is not available or not essential and provide many valuable insights [4,12,13,18,35,38,42,43].
Identifying fixed points and cycles is crucial for understanding the overall dynamical behaviour of a Boolean network. When a network is small, cycles can be obtained by exhaustive enumeration. However, as the number of nodes increases, the number of states grows exponentially. For large networks, numerical methods are the main tools for investigating the dynamics [7,10,25,30,31,34,44]. To facilitate better understanding of Boolean networks, several representations other than truth tables were proposed in recent years such as linear representation [9], polynomial representation [20,28,44] and directed graphs [27,32]. Among these, the linear representation proposed by Cheng and Qi [9] has been used by many to analyse the dynamics and control of Boolean networks [21,23,26,45,47,48]. The advantage of a linear representation is that it enables us to use existing theory from discrete dynamical systems to study Boolean networks.
While the resulting linear representation is very useful, without computer-aided calculation, the process of obtaining it using semi-tensor products is not easy even for a small three-node network. This makes it impossible to study more general network systems, where the number of nodes is not specified. To address this issue, we propose here a straightforward approach to obtain the same linear representation. Moreover, since there are an infinite number of isomorphic representations for a given Boolean network, our method makes it easier to choose the most convenient one to work with. In addition, we can construct a hybrid system that is in part Boolean and in part non-Boolean if it is needed. Our result thus provides a flexible way of representing Boolean networks that facilitates theoretical studies about their general properties.
This note is constructed as follows. In Section 2, we briefly review the semi-tensorproduct approach for obtaining a linear representation, and then show that the representation can be obtained by a straightforward map. In Section 3, we introduce a truth matrix, which is a compact way to work with a linear representation. We then provide an algorithm for identifying cycles and fixed points. We show in the Appendix how our method can be applied for analysing Boolean representation of neural networks.

Linear representation of Boolean networks
The aim of this section is to write the Boolean network (2) as a discrete linear system: We show that y is a 2 n × 1 vector and L is a 2 n × 2 n matrix (recall that n is the number of nodes in the original Boolean network and that y + is y in the next step). We introduce two methods for obtaining y and L. Both methods lead to the same y and L but the processes to derive the result are distinct. The first method was proposed by Cheng and Qi [9] and the second method is a simplification we propose here for the first time. We review the first method in Section 2.1 to make the comparison with our method easier. Then, in Section 2.2 we discuss our alternative approach.

Linear representation of Boolean networks based on semi-tensor product [9]
Semi-tensor product: Let A m×n and B p×q be two matrices. When n = kp or p = kn for some positive integer k > 0, the semi-tensor product of A and B is defined as follows where ⊗ is the Kronecker product and I k is a k × k identity matrix. For example, if A and B are two column vectors: A = (a 1 , . . . , a m ) T and B = (b 1 , . . . , b p ) T , then is an mp × 1 vector. By its definition, the semi-tensor product is a generalization of conventional matrix product. We thus will assume that the matrix product is a semi-tensor product and the notation will be omitted later on.
Matrix expression of logic: Let δ i k be the i th column of the identity matrix I k and The logical states T = 1, F = 0 are mapped into: Next, matrices for each logic operation are defined. For example, the matrices corresponding to negation (¬), disjunction/or (∨) and conjunction/and, ∧ are M n , M d and M c respectively as follows: Logic functions can then be converted to matrix semi-tensor products. For example, the operation F ∧ T = F is converted to the semi-tensor product: Deriving linear representations of Boolean systems : Next we show an example ([9, Example IV.7]) of how the linear representation is derived through semi-tensor product.
Consider the system where Based on the matrix expression of logic operators in (5) and the identification given in (4), system (7) can be rewritten as follows where A, B, C ∈ 2 = {δ 1 2 , δ 2 2 }. Next, define y = ABC which gives y ∈ 8 . To derive L, we need two additional matrices: the swap matrix W [m,n] , and the power-reducing matrix M r (see details in [9]). Then using the semi-tensor product and its properties we get [9]: [2,4] [3,7,7,8,1,5,5,6] As can be seen, although the resulting linear expression is simple, the intermediate steps and expressions are rather complicated. The above calculation can be simplified by a recent development of the semi-tensor process in [24]. However, even with this simplification it is still not an easy calculation for such a small system. We show in the next subsection that we do not have to go through all these steps to find the linear representation.

Proposed alternative conversion to discrete dynamical system
In this section, we show in Theorem 2.1 that any bijection from {0, 1} n → 2 n converts a Boolean network to a discrete linear dynamical system y + = L y. Then we prove in Theorem 2.2 that the semi-tensor product used for the construction of y is the same as a specific bijection from {0, 1} n → 2 n . We begin by defining a bijection that takes a state of a Boolean network and convert it into a distinct number. Let Q = {q 1 , . . . , q 2 n } be a set of 2 n distinct numbers and h : {0, 1} n → Q be a bijection function that associates each Boolean state with a single number. Depending on the set Q, the function h could take different forms and is not unique. For example, if Q = {0, 1, 2, . . . , 2 n − 1} the function h could be and many more. If Q = {1, 2, 3, . . . , 2 n } the function h could be: or and many more.
is isomorphic to g and can be represented as g(y) = Ly, for y ∈ U n with L = [g(e 1 ),g(e 2 ), . . . ,g(e 2 n )]. Table 1. Truth table of the isomorphic linear dynamical system of the Boolean system (7). H is defined in Theorem 2.1 with h defined by Equation (12). By Theorem 2.1, the isomorphic linear representation of the Boolean system x + = g(x) is y + = [e 3 , e 7 , e 7 , e 8 , e 1 , e 5 , e 5 , e 6 ]y, which is the same as was obtained by the semi-tensor product in (9). Theorem 2.2: Let x i ∈ {0, 1} and z i ∈ 2 be the vector associated to x i by (4) for 1 ≤ i ≤ n. Then Proof: We use induction to prove the theorem. When n = 1, by (4), We will prove the result by considering two possible cases: (Case 1) when x 1 = 0 and (Case 2) when where the bold-faced 0 is a zero vector with dimension 2 m × 1. So (13) holds in this case when n = m + 1.
(Case 2) When (13) holds for this case as well.

Truth matrix: an abreviated linear representation of Boolean networks
In this section, we show another way of analysing Boolean networks, similar to the way permutation matrices are reperesented [3]. Let g : {0, 1} n → {0, 1} n be a Boolean map and h : {0, 1} n → Q be a bijection function as defined in Section 2. We can now define a new map f : Q → Q that is isomorphic to g as follows We can represent the map f by the following matrix ( 1, 0, 1) Table 3. A map isomorphic to the one in Table 2.
where q i ∈ Q. As an example, consider the Boolean map g in Table 2. If h is defined by Equation (10), then its isomorphic map f is shown in Table 3.
Note that T(f ) in Equation (15) is just another way to represent the truth table (such as the one shown in Table 3). However, it has a simpler appearance, which provides an easier way to identify the Boolean states and their corresponding next states and potential patterns. Such representation facilitates analytical studies of Boolean networks, even of networks with unspecified number of nodes. We illustrate this aspect in the Appendix where we show a few examples. For convenience, we call T(f ) in Equation (15) a truth matrix of f. Note that the exact components of truth matrices depend on the choice of h.
We now provide some general results.

Definition 3.1 (Limit set and transient state):
Consider an n-node Boolean network,

Lemma 3.2: Let T be a truth matrix of the isomorphic map f. If q i is not in the second row of T, then q i is a transient state.
Proof: Since the second row of T consists of all the images of Q = h(x), then the fact that q i is not in the second row of T means that q i is not an image of any element on the first row. So q i is a transient state.

Theorem 3.3:
Let T be a truth matrix and q 0 ∈ T be a transient state. LetT be the matrix resulting from removing the columns containing q 0 . Then the limit set of T is the same as the limit set ofT.

Proof:
We only need to prove that if q i is in the limit set of T, then it must be in the limit set ofT. Suppose that q i is in the limit set of T. By definition of a limit set, there must exist q j in the limit set of T such that f (q j ) = q i . Therefore, q i = q 0 and is not a transient state by Lemma 3.2. It follows that q i is inT. Hence, removing columns related to the transient state q 0 does not reduce the limit set.
Based on these results, we propose the following algorithm for finding all possible cycles of a given Boolean network. 5. Repeat the previous step until T is empty.
6. Convert the states back to the original Boolean representation.

Example 3.4:
We use the example from Table 3 to show the algorithm. First remove those columns whose first element does not show up in the second row, which we have indicated in red. Repeat the process until all the elements in the first row are in the second row. We then pick any element, say 1 and trace its trajectory. In this case, we find that there is only one cycle: 1 → 3 → 7 → 5 → 1. Then in the original system, the cycle is 001 → 011 → 111 → 101 → 001.

Remark 3.1:
(1) There is a considerable body of literature on how to find cycles in Boolean networks numerically [5,11,[15][16][17]19,29,33,39,49]. Our algorithm is for facilitating analytical studies of networks. It has the advantage of dealing with networks with unspecified number of nodes. We show its flexibility and advantage by presenting some examples in Appendix A. (2) By Theorem 3.3, in order to find cycles, we can throw away known transient states from the beginning, which cannot be done with the linear representation (3).
(3) For large networks, we could divide nodes into groups. Importantly, the variables of each group can be associated with a different isomorphic representation. We illustrate this idea in Appendix A.

Discussion and conclusions
In this work we suggest an alternative approach for converting a Boolean Network to a discrete linear dynamical system on a finite space. Our approach is straightforword and much simpler than the semi-tensor product approach developed by [9] and produces a large number of isomorphic representations. We proved that our approach, when used with a specific isomorphic representation, gives the same end result as the linear representation obtained through the semi-tensor product. In addition, we introduced a truth matrix and an algorithm to analyse Boolean networks. The truth matrix can be viewed as a different version of a truth table, however, we find it more tractable. Our methodology facilitates analytical studies of networks. Importantly, it allows us to obtain general results for Boolean networks with unspecified number of nodes if they have some structure, which cannot be done under the semi-tensor product framework. On the other hand, we did not consider how our methodology could deal with delayed and/or controlled systems, for which the semi-tensor product method has provided a platform [8]. Our ability to obtain general results using our methodology and the flexibility of our approach is illustrated with a few case studies in Appendix A.

Appendix A. Case studies
In this appendix we present three case studies that correspond to three Boolean networks introduced in [4]. The dynamical properties of these networks were derived theoretically in [4] deploying a different methodology than the one presented in this appendix. To illustrate the advantages and flexibility of the approach we present in this paper, we prove the results found in [4] using the truth matrix, isomorphic decimal representation and the algorithm we proposed (Algorithm 1). Specifically, in Appendix A.1, we give the detailed construction of the truth matrix associated with the example, including the states of all nodes, and use Algorithm 1 to derive the network limit sets. In Appendix A.2, we exemplify how prior knowledge on the dynamics of certain sub-networks can be used to simplify significantly the construction of the truth matrix from the beginning. In Appendix A.3, we illustrate how to analyse a large network by decomposing it into smaller sub-networks and use different isomorphic representations simultaneously.

A.1. Periodic signal generator
In [4], we considered the following Boolean network, whose architecture is presented in Figure A1.
This network system generates a periodic output with period n of the form (1 0 · · · 0 n−1 ), where the pattern under the line repeats.
Here we use the truth matrix and Algorithm 1 to prove the following result that is equivalent to the one in [4, Lemma 1].

which corresponds to the cycle under the map h in Equation
Note that a binary number is odd if and only if the last digit is 1. So Equation (A2) means that when the number q i ∈ {0, 1, 2, . . . , 2 n − 1} is such that q i = 0 then , when q i is odd. Hence, the truth matrix of the system is Note that all numbers larger than 2 n−1 are not in the range (the second row). So we can remove all those columns whose first element > 2 n−1 . The resulting truth matrix is Next note that all numbers between 2 n−2 and 2 n−1 are not in the range of the truth matrix T 1 in Equation (A3). We can reduce the matrix by removing all those columns whose first elements are in (2 n−2 , 2 n−1 ). Repeat this process, that is, remove those columns whose first elements are between 2 n−3 and 2 n−2 then those between (2 n−4 and 2 n−3 etc., and we obtain the following matrix It is easy to see from the matrixT in Equation (A4) that the limit set of the map consists of a unique cycle 0 → 2 n−1 → 2 n−2 → · · · → 2 → 1 → 0.

A.2. Excitatory network with periodic input
In this section, we consider the Boolean system associated with the network in Figure A2, previously introduced in [4]. The system can be described by the following equations.
where k is the number of S nodes, K = {1, . . . , k} and The System (A5) is of the form where S = (S 1 , . . . , S k ). Since it is a feed-forward network, we first look at the limit sets of S + = g 1 (S, C 1 ), then determine the dynamics of X 1 . Our end result is the same as presented in [4] but the proof is different, and, due to the new representation we introduced in this paper, easier to validate. Figure A2. Excitatory network with periodic input [4]. C 1 is a periodic signal of period p, that is, it has a repeated pattern of one followed by p−1 zeros. X 1 = 1 in the next step whenever there are at least N ones in (S 1 , . . . , S k ) at the current step.

Lemma A.2: Consider the system
where C 1 = (1 0 · · · 0 p−1 ) and p ≥ 1. Let l 0 = k p and r 0 = k − l 0 p. Denote where j is an integer such that 0 ≤ j < p. Then System (A7) has the following unique cycle after each point on the cycle has been transformed by the map h(S 1 , . . . , S k ) = S 1 + 2S 2 + · · · + 2 n−1 S n .
Proof: Note that after the first k transient steps, the chain (S 1 S 2 · · · S k ) exhibits the periodic pattern of the controller C 1 . More specifically, (S 1 S 2 · · · S k ) has the value of C 1 at the previous k time steps. Thus, (S 1 S 2 · · · S k ) must have the pattern (· · · 10 · · · 010 · · · ), where there are exactly p−1 zeros between two consecutive 1s. Therefore, it is sufficient to construct a truth matrix that contains these states only. By (A7), S + = (S 1 , . . . , S k ) + is just one unit shift to the right with an exception for S 1 , which is determined by C 1 , and the ending element that is pushed out of the chain. If j is the number of shifts to the right we can expect h(0 · · · 0 j 1 0 · · · 0 p−1 10 · · · ) = 2 j (1 + 2 p + 2 2p + · · · + 2 lp ), for some j with 0 ≤ j < p, where l = l 0 or l = l 0 − 1. We next consider the detailed expression of h(S + ) = h(S) + on a case by case basis.
(1) Consider first the case r 0 = 0. In this case, k = l 0 p and there are exactly l 0 number of S i with a value of 1.
Similar to the arguments in the previous case, we can see that In summary, we can write the truth matrix M for this case as follows.
When r 0 = 1, the cycle is: Note that in all cases the cycle is of period p.
We can now prove the dynamics of X 1 in Equation A5. ). Then the system has the following limit sets when N > 1: When N = 1 the limit sets are: Remark A.1: Limit sets in Boolean networks are usually classified as fixed points or cycles. However, in [4] a more sophisticated classification of limit sets has been introduced. The solution X 1 = {1} is a fixed point but was also classified in [4] as a periodic solution with period p = 1. The solution is a cycle with period p. It was classified in [4] as "bursting" with period p (see [4] for the precise definition). Note that the functions f 1 and f 2 have the range of the function h (see Section 2) while the function f 3 has the range of {0, 1}. Next we prove Theorem A.4 below, which is similar to Theorem 2.6 in the supplement of [4] (there are small differences in the wording of the theorem). While the end result is the same, the proof is different and uses the various representations of the network shown in Figure A3. Proof: First note the following observations, assuming that the isomorphic system (A11) was created using the map h(S 1 , . . . , S k ) = S 1 + 2S 2 + · · · + 2 n−1 S n : then the dynamics of the network (A10) is the same as that of the network in Figure A2 with m = k. (iii) The dynamics of sub-network 1 is governed by Lemma A.2.
We now prove the theorem point by point.
(1) Suppose p ≤ m 2 . Considering only the interaction between Sub-network 1 and X 1 , by Theorem A.3 with N = 2 and k = m, X 1 = {1}. Since the inputs from S m+1 , . . . , S M are activating, the additional interaction between these nodes and X 1 do not change the dynamics of X 1 . Thus, when considering the full network, X 1 = {1}.
Notice that independent of the initial values of X 1 and V, if W(0) = Y 0 , then X 1 (t) = 1 for 1 ≤ t ≤ r 0 . The reason is as follows. By Lemma A.2, along C 2 , From the proof of Lemma A.2, Part 2, it follows that there are exactly two S i having a value 1 when 0 ≤ t ≤ r 0 − 1 and exactly one S i having a value of 1 when r 0 ≤ t ≤ p − 1. Hence, X 1 = 1 for consecutive r 0 time steps, which effectively leads to V = 0 all the time. Hence To prove Points 3 and 4, we group S 1 , . . . , S M as one entity and X 1 as another. Let W = h(S 1 , . . . , S M ), then the system isomorphic to System (A10) is of the form Suppose m − 2 < p ≤ M − 1. We first show that all possible trajectories have to pass through ( W, X 1 ) = (1 + 2 p , 0). We show it in two steps: (a) we show that X 1 can neither remain 0 nor remain 1 in any trajectory. (b) We show that if X 1 = 0, it will next be excited by W = 1 + 2 p .
(a) X 1 can neither remain 0 nor remain 1 in any trajectory. Suppose X 1 (t) = 0 for all t, then S 1 , . . . S M behave exactly as in Theorem A.3 with k = M. Since p < M, X 1 (t) = 1 for some t. This contradicts the assumption that X 1 (t) = 0 for all t. Hence, X 1 cannot remain 0 in any trajectory. On the other hand, suppose X 1 (t) = 1 for all t, then S i (t) = 0 for all t when m + 1 ≤ i ≤ M because X 1 suppresses these nodes. Additionally, note that after the first initial M steps, the first m S i must have a pattern of the form (0 · · · 010 · · · 010 · · · ), where there are exactly p−1 zeros between two consecutive ones. Since the pattern shifts one unit to the right after each step, and since p > m 2 there exists time t 0 for which there is only one S i with a value of 1. This implies X 1 (t 0 + 1) = 0 which contradicts the assumption X 1 (t) = 1 for all t. Hence, X 1 cannot remain 1 in any trajectory.
(b) If X 1 = 0, it will next be excited by W = 1 + 2 p . From Point (a) above, it is clear that when X 1 changes from X 1 = 1 to X 1 = 0, S i = (0 · · · 010 · · · ). The first time two ones will appear in S i will be when (S 1 S 2 · · · S p S p+1 · · · ) = (10 · · · 01 · · · ) and X 1 = 0, that is, when ( W, X 1 ) = (1 + 2 p , 0). We next prove Points 3 and 4 by considering trajectories that start at ( W, X 1 ) = (1 + 2 p , 0). Recall that a shift to the right in S i is equivalent to a multiplication by 2 in W (see the proof of Lemma A.2).