Chernobyl Reactor
Model was written in NetLogo 6.1.0
•
Viewed 108 times
•
Downloaded 5 times
•
Run 0 times
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
Info tab cannot be displayed because of an encoding error
Comments and Questions
Please start the discussion about this model!
(You'll first need to log in.)
Click to Run Model
patches-own [I-135 Xe-135] globals [integral prev-err dt] to setup clear-all ask patches [ if distancexy 0 0 < 24 [ set pcolor gray ] if distancexy 0 0 < 16 [ if pxcor mod 8 = 4 and pycor = 0 and pcolor = gray [ set pcolor red ] if pxcor = 0 and pycor mod 8 = 4 and pcolor = gray [ set pcolor red ] if pxcor mod 16 = 8 and pycor mod 16 = 8 and pcolor = gray [ set pcolor red ] ] if pxcor mod 16 = 8 and pycor mod 16 = 0 and pcolor = gray [ set pcolor blue ] if pxcor mod 16 = 0 and pycor mod 16 = 8 and pcolor = gray [ set pcolor blue ] if pxcor mod 8 = 4 and pycor mod 8 = 4 and pcolor = gray [ set pcolor yellow ] if pxcor mod 4 = 0 and pycor mod 4 = 0 and pcolor = gray [ set pcolor green ] if pxcor mod 4 = 2 and pycor mod 4 = 2 and pcolor = gray [ set pcolor green ] set I-135 0 set Xe-135 0 ] set prev-err 0 set dt 1 ;h reset-ticks end to set-standard-værdier set p-fission 10 set p-neutron 5 set p-absorption 90 set p-Xe-absorption 6 set p-vand-absorption 8 set grøn-kontrolstav-position 50 set gul-kontrolstav-position 50 set rød-kontrolstav-position 50 set grøn-automatik false set gul-automatik false set rød-automatik true set void false set void-tærskel 20000 end to go ; automatik if ønsket-neutron-antal = 0 [ set ønsket-neutron-antal 1 ] let err count turtles - ønsket-neutron-antal set integral integral + err let differential err - prev-err set prev-err err if rød-automatik = true [ set rød-kontrolstav-position round( 50 / ønsket-neutron-antal * err + 0.00005 * integral + 0.05 * differential) + 50 if rød-kontrolstav-position < 0 [ set rød-kontrolstav-position 0 ] if rød-kontrolstav-position > 100 [ set rød-kontrolstav-position 100 ] ] if gul-automatik = true [ set gul-kontrolstav-position round( 50 / ønsket-neutron-antal * err + 0.00005 * integral + 0.05 * differential) + 50 if gul-kontrolstav-position < 0 [ set gul-kontrolstav-position 0 ] if gul-kontrolstav-position > 100 [ set gul-kontrolstav-position 100 ] ] if grøn-automatik = true [ set grøn-kontrolstav-position round( 50 / ønsket-neutron-antal * err + 0.00005 * integral + 0.05 * differential) + 50 if grøn-kontrolstav-position < 0 [ set grøn-kontrolstav-position 0 ] if grøn-kontrolstav-position > 100 [ set grøn-kontrolstav-position 100 ] ] ; neutronkilde ask patches with [pcolor = blue] [ if random 100 < p-neutron [ sprout 1 [ set color white set heading random 360 ] ] ] ; Xe-135 henfald i brænselsstave ask patches with [pcolor = gray] [ set Xe-135 Xe-135 * (1 - 0.0076 * dt) ] ; I-135 henfald i brænselsstave ask patches with [pcolor = gray] [ let d-I-135 I-135 * 0.0105 * dt set I-135 I-135 - d-I-135 set Xe-135 Xe-135 + d-I-135 ] ; brændselsstav let n-Xe sum [Xe-135] of patches ask patches with [pcolor = gray] [ ask turtles-here [ ; fission if random 100 < p-fission [ ; skab nye neutroner hatch 2 [ ;Antal??? set color white set heading random 360 ] ; Skab I-135 (6% af fisionsprodukterne biver til I-135) set I-135 I-135 + .06 ] ; Absorption pga. Xe-135 (Xe-forgiftning) if random 10000 < n-Xe * p-Xe-absorption [ set Xe-135 Xe-135 - 1 ; Burn-off if Xe-135 < 0 [ set Xe-135 0 ] die ] ; Absorption pga. kølevand / void (når der er mange neutroner fordamper kølevandet) if (void = false or count turtles < void-tærskel) and random 100 < p-vand-absorption [ die ] ] ] ;kontrolstave ask patches with [pcolor = green] [ ask turtles-here [ if random 100 < p-absorption * grøn-kontrolstav-position / 100 [ die ] ] ] ask patches with [pcolor = yellow] [ ask turtles-here [ if random 100 < p-absorption * gul-kontrolstav-position / 100 [ die ] ] ] ask patches with [pcolor = red] [ ask turtles-here [ if random 100 < p-absorption * rød-kontrolstav-position / 100 [ die ] ] ] ask turtles [ if not can-move? 1 [die] fd 1 ] ask patches with [pcolor = black] [ ask turtles-here [ die ] ] tick end
There is only one version of this model, created over 1 year ago by Solveig Skadhauge.
Attached files
File | Type | Description | Last updated | |
---|---|---|---|---|
Chernobyl Reactor.png | preview | Preview for 'Chernobyl Reactor' | over 1 year ago, by Solveig Skadhauge | Download |
This model does not have any ancestors.
This model does not have any descendants.