blib/lib/Math/GSL/Poly.pm untested

filter: Statementstmt 0.0% 0 / 243 Branchbran 0.0% 0 / 32 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 29 Podpod 0.0% 0 / 23 totaltotal 0.0% 0 / 327 CC 17 SCAR 22.1
CC
17
Cov
0%
DESTROY
20.0
DESTROY
20.0
DESTROY
20.0
CRAP 9.1
1 # This file was automatically generated by SWIG (https://www.swig.org).
2 # Version 4.2.0
3 #
4 # Do not make changes to this file unless you know what you are doing - modify
5 # the SWIG interface file instead.
6  
7 package Math::GSL::Poly;
8 use base qw(Exporter);
9 use base qw(DynaLoader);
10 package Math::GSL::Polyc;
11 bootstrap Math::GSL::Poly;
12 package Math::GSL::Poly;
13 @EXPORT = qw();
14  
15 # ---------- BASE METHODS -------------
16  
17 package Math::GSL::Poly;
18  
19 sub TIEHASH {
20 my ($classname,$obj) = @_;
21 return bless $obj, $classname;
22 }
23  
24 sub CLEAR { }
25  
26 sub FIRSTKEY { }
27  
28 sub NEXTKEY { }
29  
30 sub FETCH {
31 my ($self,$field) = @_;
32 my $member_func = "swig_${field}_get";
33 $self->$member_func();
34 }
35  
36 sub STORE {
37 my ($self,$field,$newval) = @_;
38 my $member_func = "swig_${field}_set";
39 $self->$member_func($newval);
40 }
41  
42 sub this {
43 my $ptr = shift;
44 return tied(%$ptr);
45 }
46  
47  
48 # ------- FUNCTION WRAPPERS --------
49  
50 package Math::GSL::Poly;
51  
52 *gsl_error = *Math::GSL::Polyc::gsl_error;
53 *gsl_stream_printf = *Math::GSL::Polyc::gsl_stream_printf;
54 *gsl_strerror = *Math::GSL::Polyc::gsl_strerror;
55 *gsl_set_error_handler = *Math::GSL::Polyc::gsl_set_error_handler;
56 *gsl_set_error_handler_off = *Math::GSL::Polyc::gsl_set_error_handler_off;
57 *gsl_set_stream_handler = *Math::GSL::Polyc::gsl_set_stream_handler;
58 *gsl_set_stream = *Math::GSL::Polyc::gsl_set_stream;
59 *gsl_poly_eval = *Math::GSL::Polyc::gsl_poly_eval;
60 *gsl_poly_complex_eval = *Math::GSL::Polyc::gsl_poly_complex_eval;
61 *gsl_complex_poly_complex_eval = *Math::GSL::Polyc::gsl_complex_poly_complex_eval;
62 *gsl_poly_eval_derivs = *Math::GSL::Polyc::gsl_poly_eval_derivs;
63 *gsl_poly_dd_init = *Math::GSL::Polyc::gsl_poly_dd_init;
64 *gsl_poly_dd_eval = *Math::GSL::Polyc::gsl_poly_dd_eval;
65 *gsl_poly_dd_taylor = *Math::GSL::Polyc::gsl_poly_dd_taylor;
66 *gsl_poly_dd_hermite_init = *Math::GSL::Polyc::gsl_poly_dd_hermite_init;
67 *gsl_poly_solve_quadratic = *Math::GSL::Polyc::gsl_poly_solve_quadratic;
68 *gsl_poly_complex_solve_quadratic = *Math::GSL::Polyc::gsl_poly_complex_solve_quadratic;
69 *gsl_poly_solve_cubic = *Math::GSL::Polyc::gsl_poly_solve_cubic;
70 *gsl_poly_complex_solve_cubic = *Math::GSL::Polyc::gsl_poly_complex_solve_cubic;
71 *gsl_poly_complex_workspace_alloc = *Math::GSL::Polyc::gsl_poly_complex_workspace_alloc;
72 *gsl_poly_complex_workspace_free = *Math::GSL::Polyc::gsl_poly_complex_workspace_free;
73 *gsl_poly_complex_solve = *Math::GSL::Polyc::gsl_poly_complex_solve;
74 *gsl_complex_polar = *Math::GSL::Polyc::gsl_complex_polar;
75 *gsl_complex_rect = *Math::GSL::Polyc::gsl_complex_rect;
76 *gsl_complex_arg = *Math::GSL::Polyc::gsl_complex_arg;
77 *gsl_complex_abs = *Math::GSL::Polyc::gsl_complex_abs;
78 *gsl_complex_abs2 = *Math::GSL::Polyc::gsl_complex_abs2;
79 *gsl_complex_logabs = *Math::GSL::Polyc::gsl_complex_logabs;
80 *gsl_complex_add = *Math::GSL::Polyc::gsl_complex_add;
81 *gsl_complex_sub = *Math::GSL::Polyc::gsl_complex_sub;
82 *gsl_complex_mul = *Math::GSL::Polyc::gsl_complex_mul;
83 *gsl_complex_div = *Math::GSL::Polyc::gsl_complex_div;
84 *gsl_complex_add_real = *Math::GSL::Polyc::gsl_complex_add_real;
85 *gsl_complex_sub_real = *Math::GSL::Polyc::gsl_complex_sub_real;
86 *gsl_complex_mul_real = *Math::GSL::Polyc::gsl_complex_mul_real;
87 *gsl_complex_div_real = *Math::GSL::Polyc::gsl_complex_div_real;
88 *gsl_complex_add_imag = *Math::GSL::Polyc::gsl_complex_add_imag;
89 *gsl_complex_sub_imag = *Math::GSL::Polyc::gsl_complex_sub_imag;
90 *gsl_complex_mul_imag = *Math::GSL::Polyc::gsl_complex_mul_imag;
91 *gsl_complex_div_imag = *Math::GSL::Polyc::gsl_complex_div_imag;
92 *gsl_complex_conjugate = *Math::GSL::Polyc::gsl_complex_conjugate;
93 *gsl_complex_inverse = *Math::GSL::Polyc::gsl_complex_inverse;
94 *gsl_complex_negative = *Math::GSL::Polyc::gsl_complex_negative;
95 *gsl_complex_sqrt = *Math::GSL::Polyc::gsl_complex_sqrt;
96 *gsl_complex_sqrt_real = *Math::GSL::Polyc::gsl_complex_sqrt_real;
97 *gsl_complex_pow = *Math::GSL::Polyc::gsl_complex_pow;
98 *gsl_complex_pow_real = *Math::GSL::Polyc::gsl_complex_pow_real;
99 *gsl_complex_exp = *Math::GSL::Polyc::gsl_complex_exp;
100 *gsl_complex_log = *Math::GSL::Polyc::gsl_complex_log;
101 *gsl_complex_log10 = *Math::GSL::Polyc::gsl_complex_log10;
102 *gsl_complex_log_b = *Math::GSL::Polyc::gsl_complex_log_b;
103 *gsl_complex_sin = *Math::GSL::Polyc::gsl_complex_sin;
104 *gsl_complex_cos = *Math::GSL::Polyc::gsl_complex_cos;
105 *gsl_complex_sec = *Math::GSL::Polyc::gsl_complex_sec;
106 *gsl_complex_csc = *Math::GSL::Polyc::gsl_complex_csc;
107 *gsl_complex_tan = *Math::GSL::Polyc::gsl_complex_tan;
108 *gsl_complex_cot = *Math::GSL::Polyc::gsl_complex_cot;
109 *gsl_complex_arcsin = *Math::GSL::Polyc::gsl_complex_arcsin;
110 *gsl_complex_arcsin_real = *Math::GSL::Polyc::gsl_complex_arcsin_real;
111 *gsl_complex_arccos = *Math::GSL::Polyc::gsl_complex_arccos;
112 *gsl_complex_arccos_real = *Math::GSL::Polyc::gsl_complex_arccos_real;
113 *gsl_complex_arcsec = *Math::GSL::Polyc::gsl_complex_arcsec;
114 *gsl_complex_arcsec_real = *Math::GSL::Polyc::gsl_complex_arcsec_real;
115 *gsl_complex_arccsc = *Math::GSL::Polyc::gsl_complex_arccsc;
116 *gsl_complex_arccsc_real = *Math::GSL::Polyc::gsl_complex_arccsc_real;
117 *gsl_complex_arctan = *Math::GSL::Polyc::gsl_complex_arctan;
118 *gsl_complex_arccot = *Math::GSL::Polyc::gsl_complex_arccot;
119 *gsl_complex_sinh = *Math::GSL::Polyc::gsl_complex_sinh;
120 *gsl_complex_cosh = *Math::GSL::Polyc::gsl_complex_cosh;
121 *gsl_complex_sech = *Math::GSL::Polyc::gsl_complex_sech;
122 *gsl_complex_csch = *Math::GSL::Polyc::gsl_complex_csch;
123 *gsl_complex_tanh = *Math::GSL::Polyc::gsl_complex_tanh;
124 *gsl_complex_coth = *Math::GSL::Polyc::gsl_complex_coth;
125 *gsl_complex_arcsinh = *Math::GSL::Polyc::gsl_complex_arcsinh;
126 *gsl_complex_arccosh = *Math::GSL::Polyc::gsl_complex_arccosh;
127 *gsl_complex_arccosh_real = *Math::GSL::Polyc::gsl_complex_arccosh_real;
128 *gsl_complex_arcsech = *Math::GSL::Polyc::gsl_complex_arcsech;
129 *gsl_complex_arccsch = *Math::GSL::Polyc::gsl_complex_arccsch;
130 *gsl_complex_arctanh = *Math::GSL::Polyc::gsl_complex_arctanh;
131 *gsl_complex_arctanh_real = *Math::GSL::Polyc::gsl_complex_arctanh_real;
132 *gsl_complex_arccoth = *Math::GSL::Polyc::gsl_complex_arccoth;
133  
134 ############# Class : Math::GSL::Poly::gsl_poly_complex_workspace ##############
135  
136 package Math::GSL::Poly::gsl_poly_complex_workspace;
137 use vars qw(@ISA %OWNER %ITERATORS %BLESSEDMEMBERS);
138 @ISA = qw( Math::GSL::Poly );
139 %OWNER = ();
140 %ITERATORS = ();
141 *swig_nc_get = *Math::GSL::Polyc::gsl_poly_complex_workspace_nc_get;
142 *swig_nc_set = *Math::GSL::Polyc::gsl_poly_complex_workspace_nc_set;
143 *swig_matrix_get = *Math::GSL::Polyc::gsl_poly_complex_workspace_matrix_get;
144 *swig_matrix_set = *Math::GSL::Polyc::gsl_poly_complex_workspace_matrix_set;
145 sub new {
146 my $pkg = shift;
147 my $self = Math::GSL::Polyc::new_gsl_poly_complex_workspace(@_);
148 bless $self, $pkg if defined($self);
149 }
150  
151 sub DESTROY {
152 return unless $_[0]->isa('HASH');
153 my $self = tied(%{$_[0]});
154 return unless defined $self;
155 delete $ITERATORS{$self};
156 if (exists $OWNER{$self}) {
157 Math::GSL::Polyc::delete_gsl_poly_complex_workspace($self);
158 delete $OWNER{$self};
159 }
160 }
161  
162 sub DISOWN {
163 my $self = shift;
164 my $ptr = tied(%$self);
165 delete $OWNER{$ptr};
166 }
167  
168 sub ACQUIRE {
169 my $self = shift;
170 my $ptr = tied(%$self);
171 $OWNER{$ptr} = 1;
172 }
173  
174  
175 ############# Class : Math::GSL::Poly::gsl_complex ##############
176  
177 package Math::GSL::Poly::gsl_complex;
178 use vars qw(@ISA %OWNER %ITERATORS %BLESSEDMEMBERS);
179 @ISA = qw( Math::GSL::Poly );
180 %OWNER = ();
181 %ITERATORS = ();
182 *swig_dat_get = *Math::GSL::Polyc::gsl_complex_dat_get;
183 *swig_dat_set = *Math::GSL::Polyc::gsl_complex_dat_set;
184 sub new {
185 my $pkg = shift;
186 my $self = Math::GSL::Polyc::new_gsl_complex(@_);
187 bless $self, $pkg if defined($self);
188 }
189  
190 sub DESTROY {
191 return unless $_[0]->isa('HASH');
192 my $self = tied(%{$_[0]});
193 return unless defined $self;
194 delete $ITERATORS{$self};
195 if (exists $OWNER{$self}) {
196 Math::GSL::Polyc::delete_gsl_complex($self);
197 delete $OWNER{$self};
198 }
199 }
200  
201 sub DISOWN {
202 my $self = shift;
203 my $ptr = tied(%$self);
204 delete $OWNER{$ptr};
205 }
206  
207 sub ACQUIRE {
208 my $self = shift;
209 my $ptr = tied(%$self);
210 $OWNER{$ptr} = 1;
211 }
212  
213  
214 ############# Class : Math::GSL::Poly::gsl_complex_long_double ##############
215  
216 package Math::GSL::Poly::gsl_complex_long_double;
217 use vars qw(@ISA %OWNER %ITERATORS %BLESSEDMEMBERS);
218 @ISA = qw( Math::GSL::Poly );
219 %OWNER = ();
220 %ITERATORS = ();
221 *swig_dat_get = *Math::GSL::Polyc::gsl_complex_long_double_dat_get;
222 *swig_dat_set = *Math::GSL::Polyc::gsl_complex_long_double_dat_set;
223 sub new {
224 my $pkg = shift;
225 my $self = Math::GSL::Polyc::new_gsl_complex_long_double(@_);
226 bless $self, $pkg if defined($self);
227 }
228  
229 sub DESTROY {
230 return unless $_[0]->isa('HASH');
231 my $self = tied(%{$_[0]});
232 return unless defined $self;
233 delete $ITERATORS{$self};
234 if (exists $OWNER{$self}) {
235 Math::GSL::Polyc::delete_gsl_complex_long_double($self);
236 delete $OWNER{$self};
237 }
238 }
239  
240 sub DISOWN {
241 my $self = shift;
242 my $ptr = tied(%$self);
243 delete $OWNER{$ptr};
244 }
245  
246 sub ACQUIRE {
247 my $self = shift;
248 my $ptr = tied(%$self);
249 $OWNER{$ptr} = 1;
250 }
251  
252  
253 ############# Class : Math::GSL::Poly::gsl_complex_float ##############
254  
255 package Math::GSL::Poly::gsl_complex_float;
256 use vars qw(@ISA %OWNER %ITERATORS %BLESSEDMEMBERS);
257 @ISA = qw( Math::GSL::Poly );
258 %OWNER = ();
259 %ITERATORS = ();
260 *swig_dat_get = *Math::GSL::Polyc::gsl_complex_float_dat_get;
261 *swig_dat_set = *Math::GSL::Polyc::gsl_complex_float_dat_set;
262 sub new {
263 my $pkg = shift;
264 my $self = Math::GSL::Polyc::new_gsl_complex_float(@_);
265 bless $self, $pkg if defined($self);
266 }
267  
268 sub DESTROY {
269 return unless $_[0]->isa('HASH');
270 my $self = tied(%{$_[0]});
271 return unless defined $self;
272 delete $ITERATORS{$self};
273 if (exists $OWNER{$self}) {
274 Math::GSL::Polyc::delete_gsl_complex_float($self);
275 delete $OWNER{$self};
276 }
277 }
278  
279 sub DISOWN {
280 my $self = shift;
281 my $ptr = tied(%$self);
282 delete $OWNER{$ptr};
283 }
284  
285 sub ACQUIRE {
286 my $self = shift;
287 my $ptr = tied(%$self);
288 $OWNER{$ptr} = 1;
289 }
290  
291  
292 # ------- VARIABLE STUBS --------
293  
294 package Math::GSL::Poly;
295  
296 *GSL_VERSION = *Math::GSL::Polyc::GSL_VERSION;
297 *GSL_MAJOR_VERSION = *Math::GSL::Polyc::GSL_MAJOR_VERSION;
298 *GSL_MINOR_VERSION = *Math::GSL::Polyc::GSL_MINOR_VERSION;
299 *GSL_POSZERO = *Math::GSL::Polyc::GSL_POSZERO;
300 *GSL_NEGZERO = *Math::GSL::Polyc::GSL_NEGZERO;
301 *GSL_SUCCESS = *Math::GSL::Polyc::GSL_SUCCESS;
302 *GSL_FAILURE = *Math::GSL::Polyc::GSL_FAILURE;
303 *GSL_CONTINUE = *Math::GSL::Polyc::GSL_CONTINUE;
304 *GSL_EDOM = *Math::GSL::Polyc::GSL_EDOM;
305 *GSL_ERANGE = *Math::GSL::Polyc::GSL_ERANGE;
306 *GSL_EFAULT = *Math::GSL::Polyc::GSL_EFAULT;
307 *GSL_EINVAL = *Math::GSL::Polyc::GSL_EINVAL;
308 *GSL_EFAILED = *Math::GSL::Polyc::GSL_EFAILED;
309 *GSL_EFACTOR = *Math::GSL::Polyc::GSL_EFACTOR;
310 *GSL_ESANITY = *Math::GSL::Polyc::GSL_ESANITY;
311 *GSL_ENOMEM = *Math::GSL::Polyc::GSL_ENOMEM;
312 *GSL_EBADFUNC = *Math::GSL::Polyc::GSL_EBADFUNC;
313 *GSL_ERUNAWAY = *Math::GSL::Polyc::GSL_ERUNAWAY;
314 *GSL_EMAXITER = *Math::GSL::Polyc::GSL_EMAXITER;
315 *GSL_EZERODIV = *Math::GSL::Polyc::GSL_EZERODIV;
316 *GSL_EBADTOL = *Math::GSL::Polyc::GSL_EBADTOL;
317 *GSL_ETOL = *Math::GSL::Polyc::GSL_ETOL;
318 *GSL_EUNDRFLW = *Math::GSL::Polyc::GSL_EUNDRFLW;
319 *GSL_EOVRFLW = *Math::GSL::Polyc::GSL_EOVRFLW;
320 *GSL_ELOSS = *Math::GSL::Polyc::GSL_ELOSS;
321 *GSL_EROUND = *Math::GSL::Polyc::GSL_EROUND;
322 *GSL_EBADLEN = *Math::GSL::Polyc::GSL_EBADLEN;
323 *GSL_ENOTSQR = *Math::GSL::Polyc::GSL_ENOTSQR;
324 *GSL_ESING = *Math::GSL::Polyc::GSL_ESING;
325 *GSL_EDIVERGE = *Math::GSL::Polyc::GSL_EDIVERGE;
326 *GSL_EUNSUP = *Math::GSL::Polyc::GSL_EUNSUP;
327 *GSL_EUNIMPL = *Math::GSL::Polyc::GSL_EUNIMPL;
328 *GSL_ECACHE = *Math::GSL::Polyc::GSL_ECACHE;
329 *GSL_ETABLE = *Math::GSL::Polyc::GSL_ETABLE;
330 *GSL_ENOPROG = *Math::GSL::Polyc::GSL_ENOPROG;
331 *GSL_ENOPROGJ = *Math::GSL::Polyc::GSL_ENOPROGJ;
332 *GSL_ETOLF = *Math::GSL::Polyc::GSL_ETOLF;
333 *GSL_ETOLX = *Math::GSL::Polyc::GSL_ETOLX;
334 *GSL_ETOLG = *Math::GSL::Polyc::GSL_ETOLG;
335 *GSL_EOF = *Math::GSL::Polyc::GSL_EOF;
336  
337  
338 @EXPORT_OK = qw/
339 gsl_poly_eval
340 gsl_poly_complex_eval
341 gsl_complex_poly_complex_eval
342 gsl_poly_dd_init
343 gsl_poly_dd_eval
344 gsl_poly_dd_taylor
345 gsl_poly_solve_quadratic
346 gsl_poly_complex_solve_quadratic
347 gsl_poly_solve_cubic
348 gsl_poly_complex_solve_cubic
349 gsl_poly_complex_workspace_alloc
350 gsl_poly_complex_workspace_free
351 gsl_poly_complex_solve
352 $GSL_POSZERO $GSL_NEGZERO $GSL_NAN
353 /;
354  
355 %EXPORT_TAGS = ( all => \@EXPORT_OK );
356  
357 __END__