#!/usr/bin/env python # coding: utf-8 # In[1]: import boolsim from colomoto_jupyter import tabulate # for display # ### Input from a GINsim model # In[2]: import ginsim # In[3]: lrg = ginsim.load("https://zenodo.org/record/3719029/files/SuppMat_Model_Master_Model.zginml") # In[4]: get_ipython().run_line_magic('time', 'A = boolsim.attractors(lrg)') tabulate(A) # ### Input from a `minibn.BooleanNetwork` object # In[5]: from colomoto.minibn import BooleanNetwork # In[6]: bn = BooleanNetwork({ "a": "(a|b)&!(a&b)", "b": "(a|b)&!(a&b)" }) # In[7]: a = boolsim.attractors(bn) tabulate(a) # The attractor `1` is a fixed point: # In[8]: a[1] # The attractor `0` is a complex attractor, being represented as a list of hypercubes: # In[9]: a[0] # In[ ]: