source: MML/trunk/machine/SOLEIL/common/toolbox/chebfun_v2_0501/chebfun/chebtests/remeztest.m @ 4

Last change on this file since 4 was 4, checked in by zhangj, 11 years ago

Initial import--MML version from SOLEIL@2013

File size: 333 bytes
Line 
1function pass = remeztest
2
3% Nick Trefethen, 27 March 2009
4
5% Test remez:
6x = chebfun('x',[-1 1]);
7f = abs(x) + x;
8pexact = .5+x;
9pbest = remez(f,1);
10err = norm(pbest-pexact);
11pass(1) = (err<1e-10);
12
13% Test remez and cf:
14f = exp(sin(exp(x)));
15pcf = cf(f,7);
16pbest = remez(f,7);
17pass(2) = (norm(pcf-pbest)<0.0003);
18
19pass = all(pass);
Note: See TracBrowser for help on using the repository browser.