% M-file  cg solver ofr 1-d poisson eqn

clear 
format long ;
du = load( 'D:/data/fort.41' ) ;

u = load( 'D:/data/fort.42' ) ;

size(u)
fort = load( 'D:/data/fort.32' ) ;
nx = fort(1,1)  ;

op = load( 'D:/data/fort.43' ) ;
size(op)

nx
x = 0:1/nx:1;
size(x)
figure(1), plot(x,u,'-');
figure(2), plot(x,du,'*') ;
figure(3), plot(x,op,'*') ;
 