reset : true w 50 scriptmode : direct
layoutmenu : 1plot

pan0 : blankplot
blankplot : title~CO2emit
CO2emit : clear : scale~giga&ton&carbon~1000~1000
CO2emit.legw : 220 
CO2emit.ymin : 0
CO2emit.ymax : 10000

emitmenu _ stabconc 
stabconc&atlevel : 500
stabconc&inyear : 2125
climodmenu : hadcm3 

lucfemit1990 : 1300 nextlu  
fertbeta : 0.187 nextfert 
ceddydiff : 0.5 nexteddy
chighlat : 19 nexthl
csidemix : 0.0009 nextsm
asgasex : 0.03 nextax
 
$e : carboncycle.error ?
if ( $e < 2.5 ) ( sub main )

asgasex : asgasex + 0.03 if ( asgasex <  0.10 ) ( goto nextax ) 
csidemix : csidemix + 0.0009 if ( csidemix < 0.0030 ) ( goto nextsm ) 
chighlat : chighlat + 19 if ( chighlat < 60 ) ( goto nexthl ) 
ceddydiff : ceddydiff + 0.5 if ( ceddydiff < 1.6 ) ( goto nexteddy ) 
fertbeta : fertbeta + 0.05 if ( fertbeta < 0.39 ) ( goto nextfert ) 
lucfemit1990 : lucfemit1990 + 200 if ( lucfemit1990 < 2400 ) ( goto nextlu ) 

end

main (
	$r : int ( $e  - 1.5 * 255 ) 
	if ( $r < 0 ) ( $r : 0 ) 
	$g : $r $b : $r 
	$c : $r ~ ' , ' ~ $g ~ ' , ' ~ $b 
	$t  : lucfemit1990 ~  ' / '  ~ fertbeta ~ ' / ' ~  ceddydiff ~ ' / '  ~  chighlat ~ ' / '  ~  csidemix ~ ' / '  ~  asgasex ~ ' / '  ~  carboncycle.error 
	CO2emit : ( ' curve~carboncycle.totemit~ ' ~ $t ~ ' ~true~ ' ~ $c )
)
