bubble-chamber: Add small, medium, and large configurations like those on the complexification web site

db4
Eduardo Cavazos 2008-12-15 19:50:25 -06:00
parent 6098fb09cb
commit 5662d5fda6
1 changed files with 67 additions and 0 deletions

View File

@ -504,6 +504,16 @@ M:: <bubble-chamber> update-frame-buffer ( BUBBLE-CHAMBER -- )
: big-bang ( bubble-chamber -- bubble-chamber )
dup particles>> [ collide ] each ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
: collide-one-of-each ( bubble-chamber -- bubble-chamber )
dup
particles>>
[ [ <muon>? ] filter random collide ]
[ [ <quark>? ] filter random collide ]
[ [ <hadron>? ] filter random collide ]
tri ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
! Some initial configurations
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@ -538,6 +548,60 @@ M:: <bubble-chamber> update-frame-buffer ( BUBBLE-CHAMBER -- )
big-bang
drop ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
: small ( -- )
<bubble-chamber> new-gadget
{ 200 200 } >>size
randomize-collision-theta
dup start-bubble-chamber-thread
dup "Bubble Chamber" open-window
42 [ muon add-particle ] times
30 [ quark add-particle ] times
21 [ hadron add-particle ] times
7 [ axion add-particle ] times
collide-one-of-each
drop ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
: medium ( -- )
<bubble-chamber> new-gadget
{ 400 400 } >>size
randomize-collision-theta
dup start-bubble-chamber-thread
dup "Bubble Chamber" open-window
100 [ muon add-particle ] times
81 [ quark add-particle ] times
60 [ hadron add-particle ] times
9 [ axion add-particle ] times
collide-one-of-each
drop ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
: large ( -- )
<bubble-chamber> new-gadget
{ 600 600 } >>size
randomize-collision-theta
dup start-bubble-chamber-thread
dup "Bubble Chamber" open-window
550 [ muon add-particle ] times
339 [ quark add-particle ] times
100 [ hadron add-particle ] times
11 [ axion add-particle ] times
collide-one-of-each
drop ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
! Experimental
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@ -575,3 +639,6 @@ M:: <bubble-chamber> update-frame-buffer ( BUBBLE-CHAMBER -- )
111 [ axion add-particle ] times
dup particles>> [ collide randomize-collision-theta ] each
drop ;
! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!