%
% figure 14-1
%
global rate
%
figure;
rate = 6;
[ t1, c1 ] = ode45( 'Function_14_1', [ 0 10 ], 20 );
rate = 8;
[ t2, c2 ] = ode45( 'Function_14_1', [ 0 10 ], 20 );
%
hax = plotyy( t1, c1, t2, c2 );
axesyy( hax, [ 0 10 -30 25 -5 50 ], ...
   'Residence time in hours', ...
   'Nutrient profile in mg/l', ...
   'Nutrient profile in mg/l', 2, ...
   [ 0 10 20 ], [ 0 10 20 ] );
%
hold on;
rate = 20;
[ t1, c1 ] = ode45( 'Function_14_1', [ 0 10 ], 20 );
plot( t1, c1 );
rate = 14;
[ t2, c2 ] = ode45( 'Function_14_1', [ 0 10 ], 20 );
plot( t2, c2-25 );
%
line( [7.5 7.5], [1 6] );
arrow( [8.75 5], [10 5] );
arrow( [8.75 5], [7.5 5] );
h = text( 8, 11, 'design' );
set( h, 'fontsize', 20 );
h = text( 8, 8, 'margin' );
set( h, 'fontsize', 20 );
%
arrow( [2 5], [3.7 5] );
arrow( [2 5], [1.1 5] );
h = text( 1, 11, 'uncontrolled' );
set( h, 'fontsize', 20 );
h = text( 1, 8, 'load variation' );
set( h, 'fontsize', 20 );
%
line( [5.5 5.5], [-19 -24] );
line( [7 7], [-19 -24] );
arrow( [6.25 -20], [7 -20] );
arrow( [6.25 -20], [5.5 -20] );
h = text( 5.5, -14, 'design' );
set( h, 'fontsize', 20 );
h = text( 5.5, -17, 'margin' );
set( h, 'fontsize', 20 );
%
arrow( [8.5 -20], [10 -20] );
arrow( [8.5 -20], [7 -20] );
h = text( 7.4, -14, 'additional' );
set( h, 'fontsize', 20 );
h = text( 7.5, -17, 'capacity' );
set( h, 'fontsize', 20 );
%
arrow( [2.1 -20], [2.7 -20] );
arrow( [2.1 -20], [1.6 -20] );
h = text( 0.7, -14, 'controlled' );
set( h, 'fontsize', 20 );
h = text( 0.7, -17, 'load variation' );
set( h, 'fontsize', 20 );
hold off;
%
printsto -f1 -deps2 fig14-02.eps
%
