Mercurial > hg > octave-lyh
comparison scripts/elfun/acsc.m @ 7385:8b7b4f58199f
[project @ 2008-01-15 20:49:09 by jwe]
author | jwe |
---|---|
date | Tue, 15 Jan 2008 20:49:10 +0000 |
parents | a1dbe9d80eee |
children | 95ecf219a582 |
comparison
equal
deleted
inserted
replaced
7384:47c919254791 | 7385:8b7b4f58199f |
---|---|
31 endif | 31 endif |
32 | 32 |
33 w = asin (1 ./ z); | 33 w = asin (1 ./ z); |
34 | 34 |
35 endfunction | 35 endfunction |
36 | |
37 %!test | |
38 %! rt2 = sqrt (2); | |
39 %! rt3 = sqrt (3); | |
40 %! v = [pi/6, pi/4, pi/3, pi/2, pi/3, pi/4, pi/6]; | |
41 %! x = [2, rt2, 2*rt3/3, 1, 2*rt3/3, rt2, 2]; | |
42 %! assert(all (abs (acsc (x) - v) < sqrt (eps)) | |
43 %! ); | |
44 | |
45 %!error acsc (); | |
46 | |
47 %!error acsc (1, 2); | |
48 |