[3deeb5]: oct / comp_pgauss.cc  Maximize  Restore  History

Download this file

30 lines (24 with data), 637 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include <octave/oct.h>
#include "config.h"
#include "ltfat.h"
DEFUN_DLD (comp_pgauss, args, ,
"This function calls the C-library\n\
c=comp_pgauss(L,w,c_t,c_f);\n")
{
const int L = args(0).int_value();
const double w = args(1).double_value();
const double c_t = args(2).double_value();
const double c_f = args(3).double_value();
if (c_f==0.0)
{
Matrix g(L,1);
pgauss_d(L, w, c_t, g.fortran_vec());
return octave_value (g);
}
else
{
ComplexMatrix g(L,1);
pgauss_cmplx_d(L, w, c_t, c_f, (double _Complex*)g.fortran_vec());
return octave_value (g);
}
}

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks