Home > Src > Hyperbolic_1d > call_stat_hyp.m

call_stat_hyp

PURPOSE ^

CALL_STAT_HYP. Script to set input data and call stat_scalar_hyp

SYNOPSIS ^

This is a script file.

DESCRIPTION ^

 CALL_STAT_HYP. Script to set input data and call  stat_scalar_hyp

 to set input data: help stat_scalar_hyp
 these data are useful to reproduce figure 3.7, pag. 150 CHQZ2.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 % CALL_STAT_HYP. Script to set input data and call  stat_scalar_hyp
0002 %
0003 % to set input data: help stat_scalar_hyp
0004 % these data are useful to reproduce figure 3.7, pag. 150 CHQZ2.
0005 
0006 %   Written by Paola Gervasio
0007 %   $Date: 2007/04/01$
0008 
0009 xa=-1;xb=1;
0010 beta=1.5;
0011 param(1)=1; param(2)=0.75;
0012 
0013 %
0014 %  set functions
0015 %
0016 uex=@(x)[sin(6*x)];
0017 ul=sin(-6);
0018 f=@(x)[9*cos(6*x)];
0019 fid=fopen('error_stat','w');
0020 
0021 % strong, penalty and GNI
0022 for method=1:3
0023 param(1)=method;
0024 for nx=8:2:20;
0025 
0026 
0027 [x,u,err]=stat_scalar_hyp(xa,xb,beta,f,uex,ul,nx,param);
0028 fprintf('method=%d, nx=%d, err=%13.6e\n',method,nx,err);
0029 fprintf(fid,'method=%d, nx=%d, err=%13.6e\n',method,nx,err);
0030 end
0031 end
0032 
0033 fclose(fid);

Generated on Fri 21-Sep-2007 10:07:00 by m2html © 2003