WIP : working on space data structures coherence.

This commit is contained in:
Jean Sirmai 2021-12-09 15:59:38 +01:00
parent 0fd3966433
commit 71ddf7dd3d
Signed by: jean
GPG Key ID: FB3115C340E057E3
4 changed files with 14 additions and 7 deletions

View File

@ -34,7 +34,7 @@
<!-- Each site points towards a neighbouring space unit. -->
<!-- Several arrows can be stacked in the same site. -->
<site_multiplicity>6</site_multiplicity>
<site_multiplicity>5</site_multiplicity>
</space-param>
@ -60,13 +60,12 @@
<arrow site="2" weight="7" x="1"/>
<arrow site="1" weight="1" x="6"/>
<arrow site="2" weight="1" x="7"/>
<arrow site="1" weight="8" x="15"/>
<arrow site="1" weight="1" x="15"/>
<arrow site="0" weight="8" x="15"/>
<arrow site="2" weight="1" x="16"/>
<arrow site="1" weight="9" x="28"/>
<arrow site="5" weight="9" x="29"/>
<!-- Three dimers 1-1 are drawn in the global space
at locations (0,1) (6,7) and (15,16) -->
<arrow site="1" weight="1" x="28"/>
<arrow site="2" weight="1" x="29"/>
<arrow site="4" weight="9" x="29"/>
</space>

Binary file not shown.

View File

@ -7,6 +7,12 @@ nb_sites = int (model.testmodel.get_parameters().spaceparam.get_site_multiplicit
nb_arrows = int (model.testmodel.get_states().get_space(0).get_nb_arrows())
weight = int (model.testmodel.get_states().get_space(0).get_arrow(0).get_weight())
# TODO Contrôles cohérence des données (module à prévoir)
# pour condition et arrow : weight < weight_max (à définir)
# pour condition et arrow : arrow.site < site_multiplicity
# pour condition et arrow : arrow.x < space-param.dimension.x (idem autres axes)
# condition.parent <= condition.node_id max value (donc deux lectures)
space = []
cells = []
sites = []

View File

@ -414,3 +414,5 @@ modelPath = "../models/dimers random walk.xml"
schemaPath = "../schemas/models_0.2.1.xmls"
testmodel = Model(modelPath, schemaPath)
# TODO weight_max