A computer implemented modeling method and system that includes using a visual programming language to create a topological framework model configured to spatially arrange a set of one more agent submodels and incorporate an environmental submodel for each position of the topological framework model. The method further includes capturing the topological framework model by converting elements of the visual programming language into a textual programming language.