%data for Exercise Set 2.7
           
ex = input('Exercise number (1-9)? ');
           
if ex==1     
   A = [110 130;4 3;20 18;2 5], u = [295;9;48;8]    
elseif ex==2  
   COB = [110;3;21;3], Crp = [110;2;25;0], u = [3;2]       
elseif ex==3      
   A = [36 51 13 80;52 34 74 0;0 7 1.1 3.4;1.26 .19 .8 .18], b = [33;45;3;.8] 
elseif ex==4 
   A = [10 20 20;50 40 10;30 10 40], b = [100;300;200]      
elseif ex==5      
   M = [.96 .03;.04 .97], x0 = [600000;400000]
   disp('Note that numbers are entered in MATLAB without commas.  The number 600,000')
   disp('  in MATLAB scientific notation is 6e5.  A small number, such as .00000012')
   disp('  is written as 1.2e-7.') 
elseif ex==6  
   M = [.94 .04;.06 .96], x0 = [800000;500000], v = [10000;8000]  
elseif ex==7
   M = [.98285 .002576;.01715 .997424], x0 = [29716000; 218994000] 
   disp('To get four significant figures in M(1,2), you need 6 decimal places.')
   disp('  Use the command   format long   to see more decimal places.  The')
   disp('  command   format short   will return MATLAB to the standard display.') 
elseif ex==8
   M = [.97 .05 .10; 0 .90 .05; .03 .05 .85], x0 = [304; 48; 98] 
elseif ex==9  
   M = [.95 .03;.05 .97], x0 = [600000;400000], y0 = [350000;650000]
else
   disp('No data for this exercise in Section 2.7.') 
end
