# Simulation file of basic diffusion and reaction # This file is used to test and demonstrate observation commands graphics opengl graphic_iter 1 graphic_delay 10 accuracy 5 dim 3 species red blue max_mol 1000 molperbox 4 time_start 0 time_stop 200 time_step 0.1 output_files stdout cmd e warnescapee all stdout cmd e ifmore red 95 echo stdout ">95 red molecules\n" cmd @ 10 echo stdout "...simulation paused, press spacebar...\n" cmd @ 10 pause cmd @ 12 echo stdout "...molmoments...\n" cmd i 12 18 0.1 molmoments blue stdout cmd @ 20 echo stdout "...beeping...\n" cmd @ 20 beep cmd @ 20 beep cmd @ 20 echo stdout "...keypress =...\n" cmd i 20 30 0.1 keypress r cmd @ 30 echo stdout "...molcountheader =...\n" cmd @ 30 molcountheader stdout cmd @ 30 echo stdout "...molcount =...\n" cmd i 30 40 1 molcount stdout cmd @ 45 echo stdout "...molcountinbox =...\n" cmd i 45 55 1 molcountinbox 0 50 50 100 -20 30 cmd @ 60 echo stdout "...listmols =...\n" cmd @ 60 listmols stdout cmd @ 61 echo stdout "...listmols2 =...\n" cmd @ 61 listmols2 stdout cmd @ 62 echo stdout "...listmols3 =...\n" cmd @ 62 listmols3 red stdout cmd @ 65 echo stdout "meansqrdisp...\n" cmd i 65 75 1 meansqrdisp blue all stdout cmd n 100 ifless red 2 ifmore red 0 echo stdout "last red molecule\n" cmd e ifno red stop cmd a ifno red echo stdout "no red molecules; stopping.\n" difc red 1 difc blue 1 color red 1 0 0 color blue 0 0 1 boundaries 0 0 100 r boundaries 1 0 100 r boundaries 2 0 100 r mol 100 red u u u mol 10 blue 50 50 50 reaction rxn red -> 0 0.04 end_file