Structures
Structures may contain multiple FISH variables. This is a programming data structure that can be used to compartmentalize FISH variables. See the Structure Utilities for available methods.
A structure definition is defined with the struct statement. An instantiation of the structure construct statement.
The example below illustrates the use of structures.
model new
fish define test
struct mystruct val1 val2 val3
construct mystruct fred(1,2,3)
test = fred->val1
end
[test]
fish define test2
construct mystruct fred(1,2,3)
construct mystruct george(1,2,3)
if ( fred == george )
test2 = 7
endif
end
[test2]
Was this helpful? ... | PFC 6.0 © 2019, Itasca | Updated: Nov 19, 2021 |