1 %module
"Math::GSL::Deriv"
2 // Danger Will Robinson
, for realz
!
5 %include
"gsl_typemaps.i"
6 %typemap
(argout
) (const gsl_function
*f
,
8 double
*result
, double
*abserr
) {
12 sv
= hv_fetch
(Callbacks
, (char
*)&$input, sizeof($input), FALSE );
14 croak
("Math::GSL(argout) : Missing callback!\n");
18 // these are the arguments passed to the callback
19 XPUSHs
(sv_2mortal
(newSViv
((int
)$
2)));
22 /* This actually calls the perl subroutine
*/
23 call_sv
(*sv
, G_SCALAR
);
25 av_push
(av
, newSVnv
((double
) *$
4));
26 av_push
(av
, newSVnv
((double
) *$
5));
27 $result
= sv_2mortal
( newRV_noinc
( (SV
*) av
) );
36 $
1 = (double
*) $input
;
39 #include
"gsl/gsl_math.h"
40 #include
"gsl/gsl_deriv.h"
43 %include
"gsl/gsl_math.h"
44 %include
"gsl/gsl_deriv.h"
52 %EXPORT_TAGS
= ( all
=> [ @EXPORT_OK
] );
58 Math
::GSL
::Deriv
- Functions to compute numerical derivatives by finite differencing
62 This module is not yet implemented. Patches Welcome
!
64 use Math
::GSL
::Deriv qw
/:all
/;
68 Here is a list of all the functions in this module
:
72 =item
* C
<gsl_deriv_central
>
74 =item
* C
<gsl_deriv_backward
>
76 =item
* C
<gsl_deriv_forward
>
80 For more informations on the functions
, we refer you to the GSL offcial
81 documentation
: L
<http
://www.gnu.org
/software
/gsl
/manual
/html_node
/>
83 Tip
: search on google
: site
:http
://www.gnu.org
/software
/gsl
/manual
/html_node
/ name_of_the_function_you_want
88 Jonathan Leto
<jonathan@leto.net
> and Thierry Moisan
<thierry.moisan@gmail.com
>
90 =head1 COPYRIGHT
AND LICENSE
92 Copyright
(C
) 2008 Jonathan Leto and Thierry Moisan
94 This program is free software
; you can redistribute it and
/or modify it
95 under the same terms as Perl itself.