Function Reference
Initialisation | Evolution | Statistics | Data Management
 
Introduction
RBN Overview
Using the Toolbox
Function Reference
Research/Gallery
Download
Literature/Links
Contact
 

 

 

 

 

 

 

 
 
 
 


findAttractor()

Return attractor length and states in attractor.

Syntax

[attrLength, attrStates] = findAttractor(tsm)
[attrLength, nodeAtAttractorEntry, tsmOut] = findAttractor(node, mode, tMax)

 

Description

findAttractor(tsm) searches tsm for an attractor and returns its length and the node-states in the attractor.

findAttractor(node, mode, tMax) evolves all nodes in node in mode update-scheme until an attractor is found. Returns attractor length, node structure-array in its first attractor state and the time state matrix up to and including the first attractor state. If after tmax steps no attractor is found, then the search is stopped and attrLength is set to zero.

Input:
tsm - n x k+1 matrix containing node-states for n nodes at k timesteps
node
- 1 x n structure-array containing node information
mode - String defining update scheme. Currently supported modes are:  CRBN, ARBN, DARBN, GARBN, DGARBN
tMax - Maximal number of time-steps to search for attractor

Output: 
attrLength - Attractor length; if tMax has been reached before having found an attractor, then attrLength is set to zero.
attrStates - n x attractorLength matrix with all node states in attractor
nodeAtAttractorEntry - 1 x n structure-array containing node information on entry in attractor
tsmOut - n x k+1 matrix containing node-states for n nodes at k timesteps. The visualization contains node states up to and including the first attractor state.

Example

The following commands create a network (N=50 and K=3) and search for an attractor in CRBN update-mode. The maximum number of time-steps to search for the attractor is set to infinity.

>> [node, conn, rule] = bsn(50,3,'line');
>> [attrLength, node, tsm] = findAttractor(node,'CRBN',inf);
The evolution of the network up to and including the first attractor state can be visualized:
>> displayTimeStateMatrix(tsm);

The attractor length is:
>> attrLength
attrLength = 42

In order to evolve the network in the attractor, type:

>> [node, tsm] = evolveCRBN(node,200);
>> displayTimeStateMatrix(tsm);

Now we can use the first syntax of the findAttractor function to check that the attractor length is really 42:

>> [attrStates, attrLength2] = findAttractor(tsm);
>> attrLength2
attrLength2 = 42

 

See also

evolveARBN(), evolveDARBN(), evolveGARBN(), evolveDGARBN(), evolveCRBN()

 

 
 
 
      Christian Schwarzer - EPFL