/ concept-collection / windowedFourierProjection
Sign in
concept-collection / windowedFourierProjection
windowedFourierProjection / wfp_1Dspringscattering / printOutResults.m
16 lines · 441 BBlameHistoryRaw
1function [rate] = printOutResults(m,t,Nt,K0,dt,err,ht)
2% PRINTOUTRESULTS prints out error results and rates in the command window
3%
4% printOutResults(m,t,Nt,K0,dt,err,L2err,ht)
6rate = 0;
7fprintf('t=%8.2e: Nt=%4d K = %3d dt=%9.3e max-err=%8.2e',t,Nt,K0,dt,err(m));
8if( m>1 )
9 rate = log(err(m-1)/err(m))/log(ht(m-1)/ht(m));
10 fprintf(' <strong>inf-rate=%4.2f</strong>',rate);
11 fprintf('\n');
12else
13 fprintf('\n');
14end
16end
moveopenescclose