annotate src/of-specfun-1-deprecated.patch @ 7207:9ed6500e56d3 default tip @

maint: Merge release to default.
author Markus Mützel <markus.muetzel@gmx.de>
date Fri, 17 May 2024 20:16:41 +0200
parents 79edc3a96749
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4931
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1 # HG changeset patch
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
2 # User carandraug
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
3 # Date 1367241519 0
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
4 # Mon Apr 29 13:18:39 2013 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
5 # Node ID fba373975f9fbf1ab368727b3243681d8e8010da
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
6 # Parent 218107f7d15193bc2d88071cf747388091783a83
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
7 specfun: removing ellipj, ellipke, and expint (merged into octave core)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
8 (grafted from 153e6946b5cb58c22af6a28cbb7c37d9fdf4a892)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
9
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
10 diff -r 218107f7d151 -r fba373975f9f inst/ellipke.m
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
11 --- a/inst/ellipke.m Thu Dec 15 02:18:02 2011 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
12 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
13 @@ -1,125 +0,0 @@
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
14 -## Copyright (C) 2001 David Billinghurst
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
15 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
16 -## This program is free software; you can redistribute it and/or modify
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
17 -## it under the terms of the GNU General Public License as published by
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
18 -## the Free Software Foundation; either version 3 of the License, or
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
19 -## (at your option) any later version.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
20 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
21 -## This program is distributed in the hope that it will be useful,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
22 -## but WITHOUT ANY WARRANTY; without even the implied warranty of
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
23 -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
24 -## GNU General Public License for more details.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
25 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
26 -## You should have received a copy of the GNU General Public License
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
27 -## along with this program; If not, see <http://www.gnu.org/licenses/>.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
28 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
29 -## -*- texinfo -*-
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
30 -## @deftypefn {Function File} {[@var{k}, @var{e}] =} ellipke (@var{m}[,@var{tol}])
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
31 -## Compute complete elliptic integral of first K(@var{m}) and second E(@var{m}).
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
32 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
33 -## @var{m} is either real array or scalar with 0 <= m <= 1
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
34 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
35 -## @var{tol} will be ignored (@sc{Matlab} uses this to allow faster, less
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
36 -## accurate approximation)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
37 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
38 -## Ref: Abramowitz, Milton and Stegun, Irene A. Handbook of Mathematical
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
39 -## Functions, Dover, 1965, Chapter 17.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
40 -## @seealso{ellipj}
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
41 -## @end deftypefn
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
42 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
43 -## Author: David Billinghurst <David.Billinghurst@riotinto.com>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
44 -## Created: 31 January 2001
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
45 -## 2001-02-01 Paul Kienzle
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
46 -## * vectorized
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
47 -## * included function name in error messages
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
48 -## 2003-1-18 Jaakko Ruohio
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
49 -## * extended for m < 0
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
50 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
51 -function [k,e] = ellipke( m )
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
52 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
53 - if (nargin < 1 || nargin > 2)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
54 - print_usage;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
55 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
56 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
57 - k = e = zeros(size(m));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
58 - m = m(:);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
59 - if any(~isreal(m))
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
60 - error("ellipke must have real m");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
61 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
62 - if any(m>1)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
63 - error("ellipke must have m <= 1");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
64 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
65 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
66 - Nmax = 16;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
67 - idx = find(m == 1);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
68 - if (!isempty(idx))
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
69 - k(idx) = Inf;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
70 - e(idx) = 1.0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
71 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
72 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
73 - idx = find(m == -Inf);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
74 - if (!isempty(idx))
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
75 - k(idx) = 0.0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
76 - e(idx) = Inf;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
77 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
78 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
79 - ## Arithmetic-Geometric Mean (AGM) algorithm
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
80 - ## ( Abramowitz and Stegun, Section 17.6 )
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
81 - idx = find(m != 1 & m != -Inf);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
82 - if (!isempty(idx))
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
83 - idx_neg = find(m < 0 & m != -Inf);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
84 - mult_k = 1./sqrt(1-m(idx_neg));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
85 - mult_e = sqrt(1-m(idx_neg));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
86 - m(idx_neg) = -m(idx_neg)./(1-m(idx_neg));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
87 - a = ones(length(idx),1);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
88 - b = sqrt(1.0-m(idx));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
89 - c = sqrt(m(idx));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
90 - f = 0.5;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
91 - sum = f*c.*c;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
92 - for n = 2:Nmax
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
93 - t = (a+b)/2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
94 - c = (a-b)/2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
95 - b = sqrt(a.*b);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
96 - a = t;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
97 - f = f * 2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
98 - sum = sum + f*c.*c;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
99 - if all(c./a < eps), break; endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
100 - endfor
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
101 - if n >= Nmax, error("ellipke: not enough workspace"); endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
102 - k(idx) = 0.5*pi./a;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
103 - e(idx) = 0.5*pi.*(1.0-sum)./a;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
104 - k(idx_neg) = mult_k.*k(idx_neg);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
105 - e(idx_neg) = mult_e.*e(idx_neg);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
106 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
107 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
108 -endfunction
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
109 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
110 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
111 -%! ## Test complete elliptic functions of first and second kind
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
112 -%! ## against "exact" solution from Mathematica 3.0
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
113 -%! ##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
114 -%! ## David Billinghurst <David.Billinghurst@riotinto.com>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
115 -%! ## 1 February 2001
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
116 -%! m = [0.0; 0.01; 0.1; 0.5; 0.9; 0.99; 1.0 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
117 -%! [k,e] = ellipke(m);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
118 -%!
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
119 -%! # K(1.0) is really infinity - see below
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
120 -%! K = [
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
121 -%! 1.5707963267948966192;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
122 -%! 1.5747455615173559527;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
123 -%! 1.6124413487202193982;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
124 -%! 1.8540746773013719184;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
125 -%! 2.5780921133481731882;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
126 -%! 3.6956373629898746778;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
127 -%! 0.0 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
128 -%! E = [
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
129 -%! 1.5707963267948966192;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
130 -%! 1.5668619420216682912;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
131 -%! 1.5307576368977632025;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
132 -%! 1.3506438810476755025;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
133 -%! 1.1047747327040733261;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
134 -%! 1.0159935450252239356;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
135 -%! 1.0 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
136 -%! if k(7)==Inf, k(7)=0.0; endif;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
137 -%! assert(K,k,8*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
138 -%! assert(E,e,8*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
139 diff -r 218107f7d151 -r fba373975f9f inst/expint.m
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
140 --- a/inst/expint.m Thu Dec 15 02:18:02 2011 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
141 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
142 @@ -1,34 +0,0 @@
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
143 -## Copyright (C) 2006 Sylvain Pelissier <sylvain.pelissier@gmail.com>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
144 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
145 -## This program is free software; you can redistribute it and/or modify
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
146 -## it under the terms of the GNU General Public License as published by
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
147 -## the Free Software Foundation; either version 3 of the License, or
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
148 -## (at your option) any later version.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
149 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
150 -## This program is distributed in the hope that it will be useful,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
151 -## but WITHOUT ANY WARRANTY; without even the implied warranty of
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
152 -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
153 -## GNU General Public License for more details.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
154 -##
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
155 -## You should have received a copy of the GNU General Public License
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
156 -## along with this program; If not, see <http://www.gnu.org/licenses/>.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
157 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
158 -## -*- texinfo -*-
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
159 -## @deftypefn {Function File} {@var{y} =} expint (@var{x})
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
160 -## Compute the exponential integral,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
161 -## @verbatim
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
162 -## infinity
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
163 -## /
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
164 -## expint(x) = | exp(t)/t dt
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
165 -## /
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
166 -## x
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
167 -## @end verbatim
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
168 -## @seealso{expint_E1, expint_Ei}
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
169 -## @end deftypefn
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
170 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
171 -function y = expint(x)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
172 - if (nargin != 1)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
173 - print_usage;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
174 - endif
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
175 - y = expint_E1(x);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
176 -endfunction
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
177 diff -r 218107f7d151 -r fba373975f9f src/Makefile
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
178 --- a/src/Makefile Thu Dec 15 02:18:02 2011 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
179 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
180 @@ -1,6 +0,0 @@
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
181 -all: ellipj.oct
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
182 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
183 -%.oct: %.cc
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
184 - mkoctfile -s $<
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
185 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
186 -clean: ; -rm *.o core octave-core *.oct *~
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
187 diff -r 218107f7d151 -r fba373975f9f src/ellipj.cc
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
188 --- a/src/ellipj.cc Thu Dec 15 02:18:02 2011 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
189 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
190 @@ -1,909 +0,0 @@
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
191 -/*
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
192 - Copyright (C) 2001 Leopoldo Cerbaro <redbliss@libero.it>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
193 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
194 - This program is free software; you can redistribute it and/or modify
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
195 - it under the terms of the GNU General Public License as published by
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
196 - the Free Software Foundation; either version 3 of the License, or
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
197 - (at your option) any later version.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
198 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
199 - This program is distributed in the hope that it will be useful,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
200 - but WITHOUT ANY WARRANTY; without even the implied warranty of
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
201 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
202 - GNU General Public License for more details.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
203 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
204 - You should have received a copy of the GNU General Public License
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
205 - along with this program; If not, see <http://www.gnu.org/licenses/>.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
206 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
207 - Compute the Jacobi elliptic functions sn(u|m), cn(u|m) and dn(u|m) for
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
208 - argument u (real or complex) and parameter m.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
209 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
210 - usage: [sn,cn,dn] = ellipj(u,m[,tol])
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
211 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
212 - u and can be complex.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
213 - m is restricted to 0 <= m <= 1.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
214 - They can be scalars, matrix and scalar, scalar and matrix,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
215 - column and row, conformant matrices.
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
216 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
217 - modified so u can be complex. Leopoldo Cerbaro redbliss@libero.it
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
218 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
219 - Ref: Abramowitz, Milton and Stegun, Irene A
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
220 - Handbook of Mathematical Functions, Dover, 1965
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
221 - Chapter 16 (Sections 16.4, 16.13 and 16.15)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
222 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
223 - Based upon ellipj.m made by David Billinghurst <David.Billinghurst@riotinto.com>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
224 - and besselj.cc
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
225 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
226 - Author: Leopoldo Cerbaro <redbliss@libero.it>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
227 - Created: 15 December 2001
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
228 -*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
229 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
230 -#include "oct.h"
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
231 -#include "lo-ieee.h" /* for octave_NaN */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
232 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
233 -static void
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
234 -gripe_ellipj_arg ( const char *arg)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
235 -{
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
236 - error ("ellipj: expecting scalar or matrix as %s argument", arg);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
237 -}
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
238 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
239 -const double eps = 2.220446049e-16;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
240 -const int Nmax = 16;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
241 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
242 -static void
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
243 -sncndn ( double u, double m, double& sn, double& cn, double& dn, double& err) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
244 -/* real */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
245 -double sqrt_eps, m1, t=0., si_u, co_u, se_u, ta_u, b, c[Nmax], a[Nmax], phi;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
246 -int n, Nn, ii;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
247 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
248 - if (m < 0. || m > 1.) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
249 - warning ("ellipj: expecting 0. <= m <= 1."); /* -lc- */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
250 - sn = cn = dn = lo_ieee_nan_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
251 - return;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
252 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
253 - sqrt_eps = sqrt(eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
254 - if (m < sqrt_eps) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
255 - /* # For small m, ( Abramowitz and Stegun, Section 16.13 ) */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
256 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
257 - si_u = sin(u);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
258 - co_u = cos(u);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
259 - t = 0.25*m*(u-si_u*co_u);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
260 - sn = si_u - t * co_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
261 - cn = co_u + t * si_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
262 - dn = 1.0 - 0.5*m*si_u*si_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
263 -/*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
264 - } else if ( (1.0 - m) < sqrt_eps ) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
265 - /* For m1 = (1-m) small ( Abramowitz and Stegun, Section 16.15 ) */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
266 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
267 - m1 = 1.0-m;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
268 - si_u = sinh(u);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
269 - co_u = cosh(u);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
270 - ta_u = tanh(u);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
271 - se_u = 1.0/co_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
272 - sn = ta_u + 0.25*m1*(si_u*co_u-u)*se_u*se_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
273 - cn = se_u - 0.25*m1*(si_u*co_u-u)*ta_u*se_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
274 - dn = se_u + 0.25*m1*(si_u*co_u+u)*ta_u*se_u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
275 -/*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
276 - } else {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
277 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
278 - /*
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
279 - // Arithmetic-Geometric Mean (AGM) algorithm
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
280 - // ( Abramowitz and Stegun, Section 16.4 )
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
281 - */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
282 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
283 - a[0] = 1.0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
284 - b = sqrt(1.0-m);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
285 - c[0] = sqrt(m);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
286 - for (n = 1; n<Nmax; ++n) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
287 - a[n] = (a[n-1]+b)/2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
288 - c[n] = (a[n-1]-b)/2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
289 - b = sqrt(a[n-1]*b);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
290 - if ( c[n]/a[n] < eps) break;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
291 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
292 - if ( n >= Nmax-1) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
293 - // fprintf(stderr, "Not enough workspace\n");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
294 - err = 1.;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
295 - return;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
296 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
297 - Nn = n;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
298 - for ( ii = 1; n>0; ii = ii*2, --n) ; // pow(2, Nn)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
299 - phi = ii*a[Nn]*u;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
300 - for ( n = Nn; n > 0; --n) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
301 - t = phi;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
302 - phi = (asin((c[n]/a[n])* sin(phi))+phi)/2.;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
303 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
304 - sn = sin(phi);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
305 - cn = cos(phi);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
306 - dn = cn/cos(t-phi);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
307 -/*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
308 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
309 - return;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
310 -}
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
311 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
312 -static void
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
313 -sncndn ( Complex& u, double m,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
314 - Complex& sn, Complex& cn, Complex& dn, double& err) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
315 -double m1 = 1.-m, ss1, cc1, dd1;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
316 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
317 - sncndn( imag(u), m1, ss1, cc1, dd1, err);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
318 - if ( real(u) == 0.) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
319 - /* u is pure imag: Jacoby imag. transf. */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
320 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
321 - sn = Complex (0. , ss1/cc1);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
322 - cn = 1/cc1; // cn.imag = 0.;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
323 - dn = dd1/cc1; // dn.imag = 0.;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
324 - /*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
325 - } else {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
326 - /* u is generic complex */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
327 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
328 - double ss, cc, dd, ddd;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
329 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
330 - sncndn( real(u), m, ss, cc, dd, err);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
331 - ddd = cc1*cc1 + m*ss*ss*ss1*ss1;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
332 - sn = Complex (ss*dd1/ddd, cc*dd*ss1*cc1/ddd);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
333 - cn = Complex (cc*cc1/ddd, -ss*dd*ss1*dd1/ddd);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
334 - dn = Complex (dd*cc1*dd1/ddd, -m*ss*cc*ss1/ddd);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
335 - /*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
336 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
337 - return;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
338 -}
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
339 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
340 -DEFUN_DLD (ellipj, args, nargout,
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
341 - "-*- texinfo -*-\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
342 -@deftypefn {Loadable Function} {[@var{sn}, @var{cn}, @var{dn}] =} \
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
343 -ellipj (@var{u}, @var{m}, @var{err})\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
344 -Compute the Jacobi elliptic functions sn, cn, dn of complex argument and real parameter.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
345 -\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
346 -If @var{m} is a scalar, the results are the same size as @var{u}.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
347 -If @var{u} is a scalar, the results are the same size as @var{m}.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
348 -If @var{u} is a column vector and @var{m} is a row vector, the\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
349 -results are matrices with @code{length (@var{u})} rows and\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
350 -@code{length (@var{m})} columns. Otherwise, @var{u} and\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
351 -@var{m} must conform and the results will be the same size.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
352 -\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
353 -The value of @var{u} may be complex.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
354 -The value of @var{m} must be 0 <= m <= 1. .\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
355 -\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
356 -If requested, @var{err} contains the following status information\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
357 -and is the same size as the result.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
358 -\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
359 -@enumerate 0\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
360 -@item\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
361 -Normal return.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
362 -@item\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
363 -Error---no computation, algorithm termination condition not met,\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
364 -return @code{NaN}.\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
365 -@end enumerate\n\
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
366 -@end deftypefn")
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
367 -{
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
368 - octave_value_list retval;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
369 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
370 - int nargin = args.length ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
371 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
372 - if (nargin == 2 ) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
373 - octave_value u_arg = args(0);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
374 - octave_value m_arg = args(1);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
375 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
376 - if (m_arg.is_scalar_type ()) { // m is scalar
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
377 - double m = args(1).double_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
378 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
379 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
380 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
381 - if (u_arg.is_scalar_type ()) { /* u scalar */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
382 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
383 - if (u_arg.is_real_type ()) { // u real
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
384 - double u = args(0).double_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
385 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
386 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
387 - double sn, cn, dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
388 - double err=0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
389 - octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
390 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
391 - sncndn(u, m, sn, cn, dn, err);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
392 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
393 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
394 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
395 - if (nargout > 3)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
396 - retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
397 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
398 - gripe_ellipj_arg ( "first");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
399 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
400 - } else { // u complex
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
401 - Complex u = u_arg.complex_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
402 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
403 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
404 - Complex sn, cn, dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
405 - double err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
406 - octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
407 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
408 - sncndn( u, m, sn, cn, dn, err);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
409 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
410 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
411 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
412 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
413 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
414 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
415 - gripe_ellipj_arg ( "second");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
416 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
417 - /*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
418 - } else { /* u is matrix ( m is scalar ) */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
419 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
420 - ComplexMatrix u = u_arg.complex_matrix_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
421 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
422 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
423 - octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
424 - int nr = u.rows ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
425 - int nc = u.cols ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
426 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
427 - ComplexMatrix sn (nr, nc), cn (nr, nc), dn (nr, nc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
428 - Matrix err (nr, nc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
429 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
430 - for (int j = 0; j < nc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
431 - for (int i = 0; i < nr; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
432 - sncndn (u(i,j), m, sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
433 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
434 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
435 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
436 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
437 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
438 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
439 - gripe_ellipj_arg ( "first");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
440 - /*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
441 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
442 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
443 - gripe_ellipj_arg ( "second");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
444 - } else { // m is matrix
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
445 - Matrix m = args(1).matrix_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
446 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
447 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
448 - int mr = m.rows ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
449 - int mc = m.cols ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
450 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
451 - if (u_arg.is_scalar_type ()) { /* u is scalar */
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
452 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
453 - octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
454 - int nr = m.rows ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
455 - int nc = m.cols ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
456 - Matrix err (nr, nc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
457 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
458 - if (u_arg.is_real_type ()) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
459 - double u = u_arg.double_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
460 - Matrix sn (nr, nc), cn (nr, nc), dn (nr, nc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
461 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
462 - for (int j = 0; j < nc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
463 - for (int i = 0; i < nr; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
464 - sncndn (u, m(i,j), sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
465 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
466 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
467 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
468 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
469 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
470 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
471 - gripe_ellipj_arg ( "first");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
472 - } else {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
473 - Complex u = u_arg.complex_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
474 - ComplexMatrix sn (nr, nc), cn (nr, nc), dn (nr, nc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
475 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
476 - for (int j = 0; j < nc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
477 - for (int i = 0; i < nr; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
478 - sncndn (u, m(i,j), sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
479 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
480 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
481 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
482 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
483 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
484 - gripe_ellipj_arg ( "first");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
485 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
486 - /*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
487 - } else { // u is matrix (m is matrix)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
488 - /*{{{*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
489 - if (u_arg.is_real_type ()) { // u real matrix
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
490 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
491 - Matrix u = u_arg.matrix_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
492 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
493 - int ur = u.rows ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
494 - int uc = u.cols ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
495 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
496 - if (mr == 1 && uc == 1) { // u column, m row
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
497 - RowVector rm = m.row ((octave_idx_type)0);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
498 - ColumnVector cu = u.column ((octave_idx_type)0);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
499 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
500 - Matrix sn (ur, mc), cn (ur, mc), dn (ur, mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
501 - Matrix err(ur,mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
502 -// octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
503 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
504 - for (int j = 0; j < mc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
505 - for (int i = 0; i < ur; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
506 - sncndn (cu(i), rm(j), sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
507 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
508 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
509 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
510 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
511 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
512 - } else if (ur == mr && uc == mc) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
513 - Matrix sn (ur, mc), cn (ur, mc), dn (ur, mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
514 - Matrix err(ur,mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
515 -// octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
516 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
517 - for (int j = 0; j < uc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
518 - for (int i = 0; i < ur; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
519 - sncndn (u(i,j), m(i,j), sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
520 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
521 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
522 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
523 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
524 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
525 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
526 - error("u m invalid");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
527 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
528 - gripe_ellipj_arg ( "first ");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
529 - } else { // u complex matrix
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
530 - ComplexMatrix u = u_arg.complex_matrix_value ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
531 - if (! error_state) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
532 - int ur = u.rows ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
533 - int uc = u.cols ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
534 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
535 - if (mr == 1 && uc == 1) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
536 - RowVector rm = m.row ((octave_idx_type)0);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
537 - ComplexColumnVector cu = u.column ((octave_idx_type)0);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
538 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
539 - ComplexMatrix sn (ur, mc), cn (ur, mc), dn (ur, mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
540 - Matrix err(ur,mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
541 -// octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
542 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
543 - for (int j = 0; j < mc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
544 - for (int i = 0; i < ur; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
545 - sncndn (cu(i), rm(j), sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
546 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
547 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
548 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
549 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
550 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
551 - } else if (ur == mr && uc == mc) {
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
552 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
553 - ComplexMatrix sn (ur, mc), cn (ur, mc), dn (ur, mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
554 - Matrix err(ur,mc);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
555 -// octave_value result;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
556 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
557 - for (int j = 0; j < uc; j++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
558 - for (int i = 0; i < ur; i++)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
559 - sncndn (u(i,j), m(i,j), sn(i,j), cn(i,j), dn(i,j), err(i,j));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
560 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
561 - retval (0) = sn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
562 - retval (1) = cn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
563 - retval (2) = dn;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
564 - if (nargout > 3) retval(3) = err;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
565 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
566 - error("u m invalid");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
567 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
568 - gripe_ellipj_arg ( "second");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
569 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
570 - /*}}}*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
571 - }
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
572 - } else
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
573 - gripe_ellipj_arg ( "second");
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
574 - } // m matrix
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
575 - } else // wrong n. of argin
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
576 - print_usage ();
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
577 - return retval;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
578 -}
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
579 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
580 -/*
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
581 -## demos taken from inst/ellipj.m
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
582 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
583 -%!demo
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
584 -%! N = 150;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
585 -%! % m = [1-logspace(0,log(eps),N-1), 1]; ## m near 1
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
586 -%! % m = [0, logspace(log(eps),0,N-1)]; ## m near 0
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
587 -%! m = linspace(0,1,N); ## m equally spaced
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
588 -%! u = linspace(-20,20,N);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
589 -%! M = ones(length(u),1) * m;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
590 -%! U = u' * ones(1, length(m));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
591 -%! [sn, cn, dn] = ellipj(U,M);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
592 -%!
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
593 -%! %% Plotting
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
594 -%! figure(2)
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
595 -%! c = colormap(hot(64));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
596 -%! data = {sn,cn,dn};
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
597 -%! dname = {"sn","cn","dn"};
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
598 -%! for i=1:3
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
599 -%! subplot(1,3,i);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
600 -%! image(m,u,32*clip(data{i},[-1,1])+32); # clip function belongs to audio package
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
601 -%! title(dname{i});
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
602 -%! end
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
603 -%! colormap(c);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
604 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
605 -%!demo
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
606 -%! N = 200;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
607 -%! % m = [1-logspace(0,log(eps),N-1), 1]; ## m near 1
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
608 -%! % m = [0, logspace(log(eps),0,N-1)]; ## m near 0
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
609 -%! m = linspace(0,1,N); ## m equally spaced
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
610 -%! u = linspace(0,20,5);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
611 -%! M = ones(length(u),1) * m;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
612 -%! U = u' * ones(1, length(m));
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
613 -%! [sn, cn, dn] = ellipj(U,M);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
614 -%!
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
615 -%! %% Plotting
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
616 -%! data = {sn,cn,dn};
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
617 -%! dname = {"sn","cn","dn"};
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
618 -%! for i=1:3
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
619 -%! subplot(1,3,i);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
620 -%! plot(m, data{i});
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
621 -%! title(dname{i});
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
622 -%! grid on;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
623 -%! end
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
624 -*/
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
625 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
626 -/*
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
627 -## tests taken from inst/test_sncndn.m
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
628 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
629 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
630 -%! k = (tan(pi/8.))^2; m = k*k;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
631 -%! SN = [
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
632 -%! -1. + I * 0. , -0.8392965923 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
633 -%! -1. + I * 0.2 , -0.8559363407 + 0.108250955 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
634 -%! -1. + I * 0.4 , -0.906529758 + 0.2204040232 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
635 -%! -1. + I * 0.6 , -0.9931306727 + 0.3403783409 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
636 -%! -1. + I * 0.8 , -1.119268095 + 0.4720784944 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
637 -%! -1. + I * 1. , -1.29010951 + 0.6192468708 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
638 -%! -1. + I * 1.2 , -1.512691987 + 0.7850890595 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
639 -%! -1. + I * 1.4 , -1.796200374 + 0.9714821804 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
640 -%! -1. + I * 1.6 , -2.152201882 + 1.177446413 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
641 -%! -1. + I * 1.8 , -2.594547417 + 1.396378892 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
642 -%! -1. + I * 2. , -3.138145339 + 1.611394819 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
643 -%! -0.8 + I * 0. , -0.7158157937 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
644 -%! -0.8 + I * 0.2 , -0.7301746722 + 0.1394690862 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
645 -%! -0.8 + I * 0.4 , -0.7738940898 + 0.2841710966 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
646 -%! -0.8 + I * 0.6 , -0.8489542135 + 0.4394411376 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
647 -%! -0.8 + I * 0.8 , -0.9588386397 + 0.6107824358 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
648 -%! -0.8 + I * 1. , -1.108848724 + 0.8038415767 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
649 -%! -0.8 + I * 1.2 , -1.306629972 + 1.024193359 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
650 -%! -0.8 + I * 1.4 , -1.563010199 + 1.276740951 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
651 -%! -0.8 + I * 1.6 , -1.893274688 + 1.564345558 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
652 -%! -0.8 + I * 1.8 , -2.318944084 + 1.88491973 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
653 -%! -0.8 + I * 2. , -2.869716809 + 2.225506523 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
654 -%! -0.6 + I * 0. , -0.5638287208 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
655 -%! -0.6 + I * 0.2 , -0.5752723012 + 0.1654722474 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
656 -%! -0.6 + I * 0.4 , -0.610164314 + 0.3374004736 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
657 -%! -0.6 + I * 0.6 , -0.6702507087 + 0.5224614298 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
658 -%! -0.6 + I * 0.8 , -0.7586657365 + 0.7277663879 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
659 -%! -0.6 + I * 1. , -0.8803349115 + 0.9610513652 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
660 -%! -0.6 + I * 1.2 , -1.042696526 + 1.230800819 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
661 -%! -0.6 + I * 1.4 , -1.256964505 + 1.546195843 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
662 -%! -0.6 + I * 1.6 , -1.540333527 + 1.916612621 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
663 -%! -0.6 + I * 1.8 , -1.919816065 + 2.349972151 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
664 -%! -0.6 + I * 2. , -2.438761841 + 2.848129496 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
665 -%! -0.4 + I * 0. , -0.3891382858 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
666 -%! -0.4 + I * 0.2 , -0.3971152026 + 0.1850563793 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
667 -%! -0.4 + I * 0.4 , -0.4214662882 + 0.3775700801 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
668 -%! -0.4 + I * 0.6 , -0.4635087491 + 0.5853434119 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
669 -%! -0.4 + I * 0.8 , -0.5256432877 + 0.8168992398 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
670 -%! -0.4 + I * 1. , -0.611733177 + 1.081923504 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
671 -%! -0.4 + I * 1.2 , -0.7278102331 + 1.391822501 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
672 -%! -0.4 + I * 1.4 , -0.8833807998 + 1.760456461 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
673 -%! -0.4 + I * 1.6 , -1.093891878 + 2.205107766 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
674 -%! -0.4 + I * 1.8 , -1.385545188 + 2.747638761 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
675 -%! -0.4 + I * 2. , -1.805081271 + 3.41525351 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
676 -%! -0.2 + I * 0. , -0.1986311721 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
677 -%! -0.2 + I * 0.2 , -0.2027299916 + 0.1972398665 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
678 -%! -0.2 + I * 0.4 , -0.2152524522 + 0.402598347 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
679 -%! -0.2 + I * 0.6 , -0.2369100139 + 0.6246336356 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
680 -%! -0.2 + I * 0.8 , -0.2690115146 + 0.8728455227 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
681 -%! -0.2 + I * 1. , -0.3136938773 + 1.158323088 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
682 -%! -0.2 + I * 1.2 , -0.3743615191 + 1.494672508 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
683 -%! -0.2 + I * 1.4 , -0.4565255082 + 1.899466033 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
684 -%! -0.2 + I * 1.6 , -0.5694611346 + 2.39667232 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
685 -%! -0.2 + I * 1.8 , -0.7296612675 + 3.020990664 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
686 -%! -0.2 + I * 2. , -0.9685726188 + 3.826022536 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
687 -%! 0. + I * 0. , 0. + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
688 -%! 0. + I * 0.2 , 0. + 0.201376364 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
689 -%! 0. + I * 0.4 , 0. + 0.4111029248 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
690 -%! 0. + I * 0.6 , 0. + 0.6380048435 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
691 -%! 0. + I * 0.8 , 0. + 0.8919321473 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
692 -%! 0. + I * 1. , 0. + 1.184486615 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
693 -%! 0. + I * 1.2 , 0. + 1.530096023 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
694 -%! 0. + I * 1.4 , 0. + 1.947754612 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
695 -%! 0. + I * 1.6 , 0. + 2.464074356 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
696 -%! 0. + I * 1.8 , 0. + 3.119049475 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
697 -%! 0. + I * 2. , 0. + 3.97786237 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
698 -%! 0.2 + I * 0. , 0.1986311721 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
699 -%! 0.2 + I * 0.2 , 0.2027299916 + 0.1972398665 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
700 -%! 0.2 + I * 0.4 , 0.2152524522 + 0.402598347 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
701 -%! 0.2 + I * 0.6 , 0.2369100139 + 0.6246336356 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
702 -%! 0.2 + I * 0.8 , 0.2690115146 + 0.8728455227 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
703 -%! 0.2 + I * 1. , 0.3136938773 + 1.158323088 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
704 -%! 0.2 + I * 1.2 , 0.3743615191 + 1.494672508 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
705 -%! 0.2 + I * 1.4 , 0.4565255082 + 1.899466033 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
706 -%! 0.2 + I * 1.6 , 0.5694611346 + 2.39667232 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
707 -%! 0.2 + I * 1.8 , 0.7296612675 + 3.020990664 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
708 -%! 0.2 + I * 2. , 0.9685726188 + 3.826022536 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
709 -%! 0.4 + I * 0. , 0.3891382858 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
710 -%! 0.4 + I * 0.2 , 0.3971152026 + 0.1850563793 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
711 -%! 0.4 + I * 0.4 , 0.4214662882 + 0.3775700801 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
712 -%! 0.4 + I * 0.6 , 0.4635087491 + 0.5853434119 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
713 -%! 0.4 + I * 0.8 , 0.5256432877 + 0.8168992398 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
714 -%! 0.4 + I * 1. , 0.611733177 + 1.081923504 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
715 -%! 0.4 + I * 1.2 , 0.7278102331 + 1.391822501 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
716 -%! 0.4 + I * 1.4 , 0.8833807998 + 1.760456461 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
717 -%! 0.4 + I * 1.6 , 1.093891878 + 2.205107766 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
718 -%! 0.4 + I * 1.8 , 1.385545188 + 2.747638761 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
719 -%! 0.4 + I * 2. , 1.805081271 + 3.41525351 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
720 -%! 0.6 + I * 0. , 0.5638287208 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
721 -%! 0.6 + I * 0.2 , 0.5752723012 + 0.1654722474 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
722 -%! 0.6 + I * 0.4 , 0.610164314 + 0.3374004736 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
723 -%! 0.6 + I * 0.6 , 0.6702507087 + 0.5224614298 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
724 -%! 0.6 + I * 0.8 , 0.7586657365 + 0.7277663879 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
725 -%! 0.6 + I * 1. , 0.8803349115 + 0.9610513652 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
726 -%! 0.6 + I * 1.2 , 1.042696526 + 1.230800819 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
727 -%! 0.6 + I * 1.4 , 1.256964505 + 1.546195843 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
728 -%! 0.6 + I * 1.6 , 1.540333527 + 1.916612621 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
729 -%! 0.6 + I * 1.8 , 1.919816065 + 2.349972151 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
730 -%! 0.6 + I * 2. , 2.438761841 + 2.848129496 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
731 -%! 0.8 + I * 0. , 0.7158157937 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
732 -%! 0.8 + I * 0.2 , 0.7301746722 + 0.1394690862 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
733 -%! 0.8 + I * 0.4 , 0.7738940898 + 0.2841710966 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
734 -%! 0.8 + I * 0.6 , 0.8489542135 + 0.4394411376 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
735 -%! 0.8 + I * 0.8 , 0.9588386397 + 0.6107824358 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
736 -%! 0.8 + I * 1. , 1.108848724 + 0.8038415767 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
737 -%! 0.8 + I * 1.2 , 1.306629972 + 1.024193359 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
738 -%! 0.8 + I * 1.4 , 1.563010199 + 1.276740951 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
739 -%! 0.8 + I * 1.6 , 1.893274688 + 1.564345558 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
740 -%! 0.8 + I * 1.8 , 2.318944084 + 1.88491973 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
741 -%! 0.8 + I * 2. , 2.869716809 + 2.225506523 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
742 -%! 1. + I * 0. , 0.8392965923 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
743 -%! 1. + I * 0.2 , 0.8559363407 + 0.108250955 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
744 -%! 1. + I * 0.4 , 0.906529758 + 0.2204040232 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
745 -%! 1. + I * 0.6 , 0.9931306727 + 0.3403783409 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
746 -%! 1. + I * 0.8 , 1.119268095 + 0.4720784944 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
747 -%! 1. + I * 1. , 1.29010951 + 0.6192468708 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
748 -%! 1. + I * 1.2 , 1.512691987 + 0.7850890595 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
749 -%! 1. + I * 1.4 , 1.796200374 + 0.9714821804 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
750 -%! 1. + I * 1.6 , 2.152201882 + 1.177446413 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
751 -%! 1. + I * 1.8 , 2.594547417 + 1.396378892 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
752 -%! 1. + I * 2. , 3.138145339 + 1.611394819 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
753 -%! ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
754 -%! CN = [
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
755 -%! -1. + I * 0. , 0.5436738271 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
756 -%! -1. + I * 0.2 , 0.5541219664 + 0.1672121517 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
757 -%! -1. + I * 0.4 , 0.5857703552 + 0.3410940893 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
758 -%! -1. + I * 0.6 , 0.6395034233 + 0.5285979063 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
759 -%! -1. + I * 0.8 , 0.716688504 + 0.7372552987 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
760 -%! -1. + I * 1. , 0.8189576795 + 0.9755037374 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
761 -%! -1. + I * 1.2 , 0.9477661951 + 1.253049471 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
762 -%! -1. + I * 1.4 , 1.103540657 + 1.581252712 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
763 -%! -1. + I * 1.6 , 1.284098214 + 1.973449038 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
764 -%! -1. + I * 1.8 , 1.481835651 + 2.4449211 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
765 -%! -1. + I * 2. , 1.679032464 + 3.011729224 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
766 -%! -0.8 + I * 0. , 0.6982891589 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
767 -%! -0.8 + I * 0.2 , 0.71187169 + 0.1430549855 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
768 -%! -0.8 + I * 0.4 , 0.7530744458 + 0.2920273465 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
769 -%! -0.8 + I * 0.6 , 0.8232501212 + 0.4531616768 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
770 -%! -0.8 + I * 0.8 , 0.9245978896 + 0.6334016187 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
771 -%! -0.8 + I * 1. , 1.060030206 + 0.8408616109 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
772 -%! -0.8 + I * 1.2 , 1.232861756 + 1.085475913 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
773 -%! -0.8 + I * 1.4 , 1.446126965 + 1.379933558 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
774 -%! -0.8 + I * 1.6 , 1.701139468 + 1.741030588 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
775 -%! -0.8 + I * 1.8 , 1.994526268 + 2.191509596 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
776 -%! -0.8 + I * 2. , 2.312257188 + 2.762051518 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
777 -%! -0.6 + I * 0. , 0.8258917445 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
778 -%! -0.6 + I * 0.2 , 0.842151698 + 0.1130337928 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
779 -%! -0.6 + I * 0.4 , 0.8915487431 + 0.2309124769 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
780 -%! -0.6 + I * 0.6 , 0.975948103 + 0.3588102098 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
781 -%! -0.6 + I * 0.8 , 1.098499209 + 0.5026234141 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
782 -%! -0.6 + I * 1. , 1.263676101 + 0.6695125973 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
783 -%! -0.6 + I * 1.2 , 1.477275851 + 0.8687285705 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
784 -%! -0.6 + I * 1.4 , 1.746262523 + 1.112955966 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
785 -%! -0.6 + I * 1.6 , 2.078179075 + 1.420581466 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
786 -%! -0.6 + I * 1.8 , 2.479425208 + 1.819580713 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
787 -%! -0.6 + I * 2. , 2.950586798 + 2.354077344 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
788 -%! -0.4 + I * 0. , 0.9211793498 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
789 -%! -0.4 + I * 0.2 , 0.9395019377 + 0.07822091534 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
790 -%! -0.4 + I * 0.4 , 0.9952345231 + 0.1598950363 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
791 -%! -0.4 + I * 0.6 , 1.090715991 + 0.2487465067 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
792 -%! -0.4 + I * 0.8 , 1.229998843 + 0.34910407 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
793 -%! -0.4 + I * 1. , 1.419103868 + 0.4663848201 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
794 -%! -0.4 + I * 1.2 , 1.666426377 + 0.607877235 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
795 -%! -0.4 + I * 1.4 , 1.983347336 + 0.7841054404 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
796 -%! -0.4 + I * 1.6 , 2.385101684 + 1.01134031 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
797 -%! -0.4 + I * 1.8 , 2.89185416 + 1.316448705 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
798 -%! -0.4 + I * 2. , 3.529393374 + 1.74670531 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
799 -%! -0.2 + I * 0. , 0.9800743122 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
800 -%! -0.2 + I * 0.2 , 0.9997019476 + 0.03999835809 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
801 -%! -0.2 + I * 0.4 , 1.059453907 + 0.08179712295 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
802 -%! -0.2 + I * 0.6 , 1.16200643 + 0.1273503824 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
803 -%! -0.2 + I * 0.8 , 1.312066413 + 0.1789585449 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
804 -%! -0.2 + I * 1. , 1.516804331 + 0.2395555269 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
805 -%! -0.2 + I * 1.2 , 1.786613221 + 0.313189147 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
806 -%! -0.2 + I * 1.4 , 2.136422971 + 0.405890925 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
807 -%! -0.2 + I * 1.6 , 2.588021972 + 0.527357091 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
808 -%! -0.2 + I * 1.8 , 3.174302819 + 0.6944201617 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
809 -%! -0.2 + I * 2. , 3.947361147 + 0.9387994989 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
810 -%! 0. + I * 0. , 1. + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
811 -%! 0. + I * 0.2 , 1.020074723 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
812 -%! 0. + I * 0.4 , 1.08120563 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
813 -%! 0. + I * 0.6 , 1.18619146 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
814 -%! 0. + I * 0.8 , 1.339978715 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
815 -%! 0. + I * 1. , 1.550164037 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
816 -%! 0. + I * 1.2 , 1.827893279 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
817 -%! 0. + I * 1.4 , 2.189462954 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
818 -%! 0. + I * 1.6 , 2.659259752 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
819 -%! 0. + I * 1.8 , 3.275434266 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
820 -%! 0. + I * 2. , 4.101632484 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
821 -%! 0.2 + I * 0. , 0.9800743122 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
822 -%! 0.2 + I * 0.2 , 0.9997019476 - 0.03999835809 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
823 -%! 0.2 + I * 0.4 , 1.059453907 - 0.08179712295 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
824 -%! 0.2 + I * 0.6 , 1.16200643 - 0.1273503824 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
825 -%! 0.2 + I * 0.8 , 1.312066413 - 0.1789585449 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
826 -%! 0.2 + I * 1. , 1.516804331 - 0.2395555269 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
827 -%! 0.2 + I * 1.2 , 1.786613221 - 0.313189147 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
828 -%! 0.2 + I * 1.4 , 2.136422971 - 0.405890925 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
829 -%! 0.2 + I * 1.6 , 2.588021972 - 0.527357091 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
830 -%! 0.2 + I * 1.8 , 3.174302819 - 0.6944201617 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
831 -%! 0.2 + I * 2. , 3.947361147 - 0.9387994989 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
832 -%! 0.4 + I * 0. , 0.9211793498 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
833 -%! 0.4 + I * 0.2 , 0.9395019377 - 0.07822091534 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
834 -%! 0.4 + I * 0.4 , 0.9952345231 - 0.1598950363 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
835 -%! 0.4 + I * 0.6 , 1.090715991 - 0.2487465067 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
836 -%! 0.4 + I * 0.8 , 1.229998843 - 0.34910407 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
837 -%! 0.4 + I * 1. , 1.419103868 - 0.4663848201 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
838 -%! 0.4 + I * 1.2 , 1.666426377 - 0.607877235 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
839 -%! 0.4 + I * 1.4 , 1.983347336 - 0.7841054404 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
840 -%! 0.4 + I * 1.6 , 2.385101684 - 1.01134031 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
841 -%! 0.4 + I * 1.8 , 2.89185416 - 1.316448705 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
842 -%! 0.4 + I * 2. , 3.529393374 - 1.74670531 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
843 -%! 0.6 + I * 0. , 0.8258917445 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
844 -%! 0.6 + I * 0.2 , 0.842151698 - 0.1130337928 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
845 -%! 0.6 + I * 0.4 , 0.8915487431 - 0.2309124769 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
846 -%! 0.6 + I * 0.6 , 0.975948103 - 0.3588102098 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
847 -%! 0.6 + I * 0.8 , 1.098499209 - 0.5026234141 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
848 -%! 0.6 + I * 1. , 1.263676101 - 0.6695125973 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
849 -%! 0.6 + I * 1.2 , 1.477275851 - 0.8687285705 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
850 -%! 0.6 + I * 1.4 , 1.746262523 - 1.112955966 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
851 -%! 0.6 + I * 1.6 , 2.078179075 - 1.420581466 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
852 -%! 0.6 + I * 1.8 , 2.479425208 - 1.819580713 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
853 -%! 0.6 + I * 2. , 2.950586798 - 2.354077344 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
854 -%! 0.8 + I * 0. , 0.6982891589 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
855 -%! 0.8 + I * 0.2 , 0.71187169 - 0.1430549855 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
856 -%! 0.8 + I * 0.4 , 0.7530744458 - 0.2920273465 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
857 -%! 0.8 + I * 0.6 , 0.8232501212 - 0.4531616768 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
858 -%! 0.8 + I * 0.8 , 0.9245978896 - 0.6334016187 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
859 -%! 0.8 + I * 1. , 1.060030206 - 0.8408616109 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
860 -%! 0.8 + I * 1.2 , 1.232861756 - 1.085475913 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
861 -%! 0.8 + I * 1.4 , 1.446126965 - 1.379933558 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
862 -%! 0.8 + I * 1.6 , 1.701139468 - 1.741030588 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
863 -%! 0.8 + I * 1.8 , 1.994526268 - 2.191509596 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
864 -%! 0.8 + I * 2. , 2.312257188 - 2.762051518 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
865 -%! 1. + I * 0. , 0.5436738271 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
866 -%! 1. + I * 0.2 , 0.5541219664 - 0.1672121517 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
867 -%! 1. + I * 0.4 , 0.5857703552 - 0.3410940893 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
868 -%! 1. + I * 0.6 , 0.6395034233 - 0.5285979063 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
869 -%! 1. + I * 0.8 , 0.716688504 - 0.7372552987 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
870 -%! 1. + I * 1. , 0.8189576795 - 0.9755037374 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
871 -%! 1. + I * 1.2 , 0.9477661951 - 1.253049471 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
872 -%! 1. + I * 1.4 , 1.103540657 - 1.581252712 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
873 -%! 1. + I * 1.6 , 1.284098214 - 1.973449038 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
874 -%! 1. + I * 1.8 , 1.481835651 - 2.4449211 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
875 -%! 1. + I * 2. , 1.679032464 - 3.011729224 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
876 -%! ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
877 -%! DN = [
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
878 -%! -1. + I * 0. , 0.9895776106 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
879 -%! -1. + I * 0.2 , 0.9893361555 + 0.002756935338 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
880 -%! -1. + I * 0.4 , 0.9885716856 + 0.005949639805 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
881 -%! -1. + I * 0.6 , 0.9871564855 + 0.01008044183 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
882 -%! -1. + I * 0.8 , 0.9848512162 + 0.01579337596 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
883 -%! -1. + I * 1. , 0.9812582484 + 0.02396648455 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
884 -%! -1. + I * 1.2 , 0.9757399152 + 0.0358288294 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
885 -%! -1. + I * 1.4 , 0.9672786056 + 0.0531049859 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
886 -%! -1. + I * 1.6 , 0.954237868 + 0.0781744383 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
887 -%! -1. + I * 1.8 , 0.933957524 + 0.1141918269 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
888 -%! -1. + I * 2. , 0.9020917489 + 0.1650142936 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
889 -%! -0.8 + I * 0. , 0.992429635 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
890 -%! -0.8 + I * 0.2 , 0.9924147861 + 0.003020708044 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
891 -%! -0.8 + I * 0.4 , 0.99236555 + 0.00652359532 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
892 -%! -0.8 + I * 0.6 , 0.9922655715 + 0.0110676219 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
893 -%! -0.8 + I * 0.8 , 0.9920785856 + 0.01737733806 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
894 -%! -0.8 + I * 1. , 0.9917291795 + 0.02645738598 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
895 -%! -0.8 + I * 1.2 , 0.9910606387 + 0.03974949378 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
896 -%! -0.8 + I * 1.4 , 0.9897435004 + 0.05935252515 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
897 -%! -0.8 + I * 1.6 , 0.987077644 + 0.08832675281 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
898 -%! -0.8 + I * 1.8 , 0.9815667458 + 0.1310872821 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
899 -%! -0.8 + I * 2. , 0.970020127 + 0.1938136793 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
900 -%! -0.6 + I * 0. , 0.9953099088 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
901 -%! -0.6 + I * 0.2 , 0.995526009 + 0.002814772354 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
902 -%! -0.6 + I * 0.4 , 0.9962071136 + 0.006083312292 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
903 -%! -0.6 + I * 0.6 , 0.9974557125 + 0.01033463525 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
904 -%! -0.6 + I * 0.8 , 0.9994560563 + 0.01626207722 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
905 -%! -0.6 + I * 1. , 1.00249312 + 0.02484336286 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
906 -%! -0.6 + I * 1.2 , 1.006973922 + 0.0375167093 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
907 -%! -0.6 + I * 1.4 , 1.013436509 + 0.05645315628 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
908 -%! -0.6 + I * 1.6 , 1.022504295 + 0.08499262247 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
909 -%! -0.6 + I * 1.8 , 1.034670023 + 0.1283564595 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
910 -%! -0.6 + I * 2. , 1.049599899 + 0.194806122 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
911 -%! -0.4 + I * 0. , 0.9977686897 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
912 -%! -0.4 + I * 0.2 , 0.9981836165 + 0.002167241934 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
913 -%! -0.4 + I * 0.4 , 0.9994946045 + 0.004686808612 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
914 -%! -0.4 + I * 0.6 , 1.001910789 + 0.00797144174 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
915 -%! -0.4 + I * 0.8 , 1.005817375 + 0.01256717724 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
916 -%! -0.4 + I * 1. , 1.011836374 + 0.01925509038 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
917 -%! -0.4 + I * 1.2 , 1.020923572 + 0.02920828367 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
918 -%! -0.4 + I * 1.4 , 1.034513743 + 0.04425213602 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
919 -%! -0.4 + I * 1.6 , 1.054725746 + 0.06732276244 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
920 -%! -0.4 + I * 1.8 , 1.08462027 + 0.1033236812 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
921 -%! -0.4 + I * 2. , 1.128407402 + 0.1608240664 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
922 -%! -0.2 + I * 0. , 0.9994191176 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
923 -%! -0.2 + I * 0.2 , 0.9999683719 + 0.001177128019 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
924 -%! -0.2 + I * 0.4 , 1.001705496 + 0.00254669712 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
925 -%! -0.2 + I * 0.6 , 1.004913944 + 0.004334880912 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
926 -%! -0.2 + I * 0.8 , 1.010120575 + 0.006842775622 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
927 -%! -0.2 + I * 1. , 1.018189543 + 0.01050520136 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
928 -%! -0.2 + I * 1.2 , 1.030482479 + 0.01598431001 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
929 -%! -0.2 + I * 1.4 , 1.049126108 + 0.02433134655 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
930 -%! -0.2 + I * 1.6 , 1.077466003 + 0.0372877718 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
931 -%! -0.2 + I * 1.8 , 1.120863308 + 0.05789156398 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
932 -%! -0.2 + I * 2. , 1.188162088 + 0.09181238708 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
933 -%! 0. + I * 0. , 1. + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
934 -%! 0. + I * 0.2 , 1.000596698 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
935 -%! 0. + I * 0.4 , 1.002484444 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
936 -%! 0. + I * 0.6 , 1.005973379 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
937 -%! 0. + I * 0.8 , 1.011641536 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
938 -%! 0. + I * 1. , 1.020441432 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
939 -%! 0. + I * 1.2 , 1.033885057 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
940 -%! 0. + I * 1.4 , 1.054361188 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
941 -%! 0. + I * 1.6 , 1.085694733 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
942 -%! 0. + I * 1.8 , 1.134186672 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
943 -%! 0. + I * 2. , 1.210701071 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
944 -%! 0.2 + I * 0. , 0.9994191176 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
945 -%! 0.2 + I * 0.2 , 0.9999683719 - 0.001177128019 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
946 -%! 0.2 + I * 0.4 , 1.001705496 - 0.00254669712 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
947 -%! 0.2 + I * 0.6 , 1.004913944 - 0.004334880912 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
948 -%! 0.2 + I * 0.8 , 1.010120575 - 0.006842775622 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
949 -%! 0.2 + I * 1. , 1.018189543 - 0.01050520136 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
950 -%! 0.2 + I * 1.2 , 1.030482479 - 0.01598431001 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
951 -%! 0.2 + I * 1.4 , 1.049126108 - 0.02433134655 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
952 -%! 0.2 + I * 1.6 , 1.077466003 - 0.0372877718 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
953 -%! 0.2 + I * 1.8 , 1.120863308 - 0.05789156398 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
954 -%! 0.2 + I * 2. , 1.188162088 - 0.09181238708 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
955 -%! 0.4 + I * 0. , 0.9977686897 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
956 -%! 0.4 + I * 0.2 , 0.9981836165 - 0.002167241934 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
957 -%! 0.4 + I * 0.4 , 0.9994946045 - 0.004686808612 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
958 -%! 0.4 + I * 0.6 , 1.001910789 - 0.00797144174 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
959 -%! 0.4 + I * 0.8 , 1.005817375 - 0.01256717724 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
960 -%! 0.4 + I * 1. , 1.011836374 - 0.01925509038 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
961 -%! 0.4 + I * 1.2 , 1.020923572 - 0.02920828367 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
962 -%! 0.4 + I * 1.4 , 1.034513743 - 0.04425213602 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
963 -%! 0.4 + I * 1.6 , 1.054725746 - 0.06732276244 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
964 -%! 0.4 + I * 1.8 , 1.08462027 - 0.1033236812 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
965 -%! 0.4 + I * 2. , 1.128407402 - 0.1608240664 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
966 -%! 0.6 + I * 0. , 0.9953099088 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
967 -%! 0.6 + I * 0.2 , 0.995526009 - 0.002814772354 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
968 -%! 0.6 + I * 0.4 , 0.9962071136 - 0.006083312292 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
969 -%! 0.6 + I * 0.6 , 0.9974557125 - 0.01033463525 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
970 -%! 0.6 + I * 0.8 , 0.9994560563 - 0.01626207722 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
971 -%! 0.6 + I * 1. , 1.00249312 - 0.02484336286 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
972 -%! 0.6 + I * 1.2 , 1.006973922 - 0.0375167093 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
973 -%! 0.6 + I * 1.4 , 1.013436509 - 0.05645315628 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
974 -%! 0.6 + I * 1.6 , 1.022504295 - 0.08499262247 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
975 -%! 0.6 + I * 1.8 , 1.034670023 - 0.1283564595 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
976 -%! 0.6 + I * 2. , 1.049599899 - 0.194806122 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
977 -%! 0.8 + I * 0. , 0.992429635 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
978 -%! 0.8 + I * 0.2 , 0.9924147861 - 0.003020708044 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
979 -%! 0.8 + I * 0.4 , 0.99236555 - 0.00652359532 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
980 -%! 0.8 + I * 0.6 , 0.9922655715 - 0.0110676219 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
981 -%! 0.8 + I * 0.8 , 0.9920785856 - 0.01737733806 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
982 -%! 0.8 + I * 1. , 0.9917291795 - 0.02645738598 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
983 -%! 0.8 + I * 1.2 , 0.9910606387 - 0.03974949378 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
984 -%! 0.8 + I * 1.4 , 0.9897435004 - 0.05935252515 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
985 -%! 0.8 + I * 1.6 , 0.987077644 - 0.08832675281 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
986 -%! 0.8 + I * 1.8 , 0.9815667458 - 0.1310872821 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
987 -%! 0.8 + I * 2. , 0.970020127 - 0.1938136793 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
988 -%! 1. + I * 0. , 0.9895776106 + 0. * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
989 -%! 1. + I * 0.2 , 0.9893361555 - 0.002756935338 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
990 -%! 1. + I * 0.4 , 0.9885716856 - 0.005949639805 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
991 -%! 1. + I * 0.6 , 0.9871564855 - 0.01008044183 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
992 -%! 1. + I * 0.8 , 0.9848512162 - 0.01579337596 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
993 -%! 1. + I * 1. , 0.9812582484 - 0.02396648455 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
994 -%! 1. + I * 1.2 , 0.9757399152 - 0.0358288294 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
995 -%! 1. + I * 1.4 , 0.9672786056 - 0.0531049859 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
996 -%! 1. + I * 1.6 , 0.954237868 - 0.0781744383 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
997 -%! 1. + I * 1.8 , 0.933957524 - 0.1141918269 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
998 -%! 1. + I * 2. , 0.9020917489 - 0.1650142936 * I
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
999 -%! ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1000 -%! tol = 1e-9;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1001 -%! for x = 0:10
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1002 -%! for y = 0:10
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1003 -%! ur = -1 + x * 0.2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1004 -%! ui = y * 0.2;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1005 -%! ii = 1 + y + x*11;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1006 -%! [sn, cn, dn] = ellipj (ur + I * ui, m);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1007 -%! assert (SN (ii, 2), sn, tol);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1008 -%! assert (CN (ii, 2), cn, tol);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1009 -%! assert (DN (ii, 2), dn, tol);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1010 -%! endfor
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1011 -%! endfor
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1012 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1013 -## tests taken from test_ellipj.m
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1014 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1015 -%! u1 = pi/3; m1 = 0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1016 -%! res1 = [sin(pi/3), cos(pi/3), 1];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1017 -%! [sn,cn,dn]=ellipj(u1,m1);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1018 -%! assert([sn,cn,dn], res1, 10*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1019 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1020 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1021 -%! u2 = log(2); m2 = 1;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1022 -%! res2 = [ 3/5, 4/5, 4/5 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1023 -%! [sn,cn,dn]=ellipj(u2,m2);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1024 -%! assert([sn,cn,dn], res2, 10*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1025 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1026 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1027 -%! u3 = log(2)*1i; m3 = 0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1028 -%! res3 = [3i/4,5/4,1];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1029 -%! [sn,cn,dn]=ellipj(u3,m3);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1030 -%! assert([sn,cn,dn], res3, 10*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1031 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1032 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1033 -%! u4 = -1; m4 = tan(pi/8)^4;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1034 -%! res4 = [-0.8392965923,0.5436738271,0.9895776106];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1035 -%! [sn,cn,dn]=ellipj(u4, m4);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1036 -%! assert([sn,cn,dn], res4, 1e-10);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1037 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1038 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1039 -%! u5 = -0.2 + 0.4i; m5 = tan(pi/8)^4;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1040 -%! res5 = [ -0.2152524522 + 0.402598347i, ...
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1041 -%! 1.059453907 + 0.08179712295i, ...
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1042 -%! 1.001705496 + 0.00254669712i ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1043 -%! [sn,cn,dn]=ellipj(u5,m5);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1044 -%! assert([sn,cn,dn], res5, 1e-9);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1045 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1046 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1047 -%! u6 = 0.2 + 0.6i; m6 = tan(pi/8)^4;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1048 -%! res6 = [ 0.2369100139 + 0.624633635i, ...
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1049 -%! 1.16200643 - 0.1273503824i, ...
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1050 -%! 1.004913944 - 0.004334880912i ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1051 -%! [sn,cn,dn]=ellipj(u6,m6);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1052 -%! assert([sn,cn,dn], res6, 1e-8);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1053 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1054 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1055 -%! u7 = 0.8 + 0.8i; m7 = tan(pi/8)^4;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1056 -%! res7 = [0.9588386397 + 0.6107824358i, ...
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1057 -%! 0.9245978896 - 0.6334016187i, ...
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1058 -%! 0.9920785856 - 0.01737733806i ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1059 -%! [sn,cn,dn]=ellipj(u7,m7);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1060 -%! assert([sn,cn,dn], res7, 1e-10);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1061 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1062 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1063 -%! u=[0,pi/6,pi/4,pi/2]; m=0;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1064 -%! res = [0,1/2,1/sqrt(2),1;1,cos(pi/6),1/sqrt(2),0;1,1,1,1];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1065 -%! [sn,cn,dn]=ellipj(u,m);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1066 -%! assert([sn;cn;dn],res, 100*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1067 -%! [sn,cn,dn]=ellipj(u',0);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1068 -%! assert([sn,cn,dn],res', 100*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1069 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1070 -## XXX FIXME XXX
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1071 -## need to check [real,complex]x[scalar,rowvec,colvec,matrix]x[u,m]
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1072 -
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1073 -%!test
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1074 -%! ## Test Jacobi elliptic functions
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1075 -%! ## against "exact" solution from Mathematica 3.0
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1076 -%! ## David Billinghurst <David.Billinghurst@riotinto.com>
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1077 -%! ## 1 February 2001
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1078 -%! u = [ 0.25; 0.25; 0.20; 0.20; 0.672; 0.5];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1079 -%! m = [ 0.0; 1.0; 0.19; 0.81; 0.36; 0.9999999999];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1080 -%! S = [ sin(0.25); tanh(0.25);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1081 -%! 0.19842311013970879516;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1082 -%! 0.19762082367187648571;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1083 -%! 0.6095196917919021945;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1084 -%! 0.4621171572617320908 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1085 -%! C = [ cos(0.25); sech(0.25);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1086 -%! 0.9801164570409401062;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1087 -%! 0.9802785369736752032;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1088 -%! 0.7927709286533560550;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1089 -%! 0.8868188839691764094 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1090 -%! D = [ 1.0; sech(0.25);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1091 -%! 0.9962526643271134302;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1092 -%! 0.9840560289645665155;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1093 -%! 0.9307281387786906491;
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1094 -%! 0.8868188839812167635 ];
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1095 -%! [sn,cn,dn] = ellipj(u,m);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1096 -%! assert(sn,S,8*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1097 -%! assert(cn,C,8*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1098 -%! assert(dn,D,8*eps);
79edc3a96749 of-ode: patch for depreciated functions (Bug #55325)
John Donoghue
parents:
diff changeset
1099 -*/