25 #if defined (HAVE_CONFIG_H)
52 xelem (
i) =
static_cast<unsigned char> (
a(
i));
55 #if defined (HAVE_FFTW)
62 if (dim > dv.
ndims () || dim < 0)
68 for (
int i = 0;
i < dim;
i++)
72 howmany = (stride == 1 ? howmany : (howmany > stride ? stride : howmany));
83 n, howmany, stride, dist);
93 if (dim > dv.
ndims () || dim < 0)
99 for (
int i = 0;
i < dim;
i++)
103 howmany = (stride == 1 ? howmany : (howmany > stride ? stride : howmany));
113 n, howmany, stride, dist);
161 int rank = dv.
ndims ();
176 int rank = dv.
ndims ();
197 if (dim > dv.
ndims () || dim < 0)
210 for (
int i = 0;
i < dim;
i++)
214 howmany = (stride == 1 ? howmany : (howmany > stride ? stride : howmany));
244 if (dim > dv.
ndims () || dim < 0)
257 for (
int i = 0;
i < dim;
i++)
261 howmany = (stride == 1 ? howmany : (howmany > stride ? stride : howmany));
280 static_cast<float> (npts);
296 for (
int i = 0;
i < rank;
i++)
306 howmany = (stride == 1 ? howmany :
307 (howmany > stride ? stride : howmany));
320 prow[l] =
retval((l +
k*npts)*stride + j*dist);
325 retval((l +
k*npts)*stride + j*dist) = prow[l];
344 for (
int i = 0;
i < rank;
i++)
354 howmany = (stride == 1 ? howmany :
355 (howmany > stride ? stride : howmany));
368 prow[l] =
retval((l +
k*npts)*stride + j*dist);
373 retval((l +
k*npts)*stride + j*dist) =
374 prow[l] / static_cast<float> (npts);
388 int rank = dv.
ndims ();
392 for (
int i = 0;
i < rank;
i++)
402 howmany = (stride == 1 ? howmany :
403 (howmany > stride ? stride : howmany));
416 prow[l] =
retval((l +
k*npts)*stride + j*dist);
421 retval((l +
k*npts)*stride + j*dist) = prow[l];
435 int rank = dv.
ndims ();
439 for (
int i = 0;
i < rank;
i++)
449 howmany = (stride == 1 ? howmany :
450 (howmany > stride ? stride : howmany));
463 prow[l] =
retval((l +
k*npts)*stride + j*dist);
468 retval((l +
k*npts)*stride + j*dist) =
469 prow[l] / static_cast<float> (npts);
586 return do_mx_red_op<bool, float> (*
this, dim,
mx_inline_all);
592 return do_mx_red_op<bool, float> (*
this, dim,
mx_inline_any);
622 return do_mx_red_op<float, float> (*
this, dim,
mx_inline_sum);
646 return do_mx_minmax_op<float> (*
this, idx_arg, dim,
mx_inline_max);
658 return do_mx_minmax_op<float> (*
this, idx_arg, dim,
mx_inline_min);
706 retval.
insert (rb, ra_idx);
722 (*current_liboctave_error_handler)
723 (
"invalid conversion from NaN to character");
731 retval.
elem (
i) =
static_cast<char>(ival);
737 retval.
insert (rb, ra_idx);
772 return do_mx_unary_map<float, float, std::abs> (*this);
778 return do_mx_unary_map<bool, float, octave::math::isnan> (*this);
784 return do_mx_unary_map<bool, float, octave::math::isinf> (*this);
790 return do_mx_unary_map<bool, float, octave::math::finite> (*this);
845 tmp = octave_read_value<float> (
is);
octave_idx_type compute_index(octave_idx_type n, const dim_vector &dims)
FloatNDArray concat(const FloatNDArray &rb, const Array< octave_idx_type > &ra_idx)
FloatComplexNDArray fourier(int dim=1) const
NDArray dsum(int dim=-1) const
#define NDS_BOOL_OPS(ND, S)
#define NDS_CMP_OPS(ND, S)
bool is_empty(void) const
bool all_integers(void) const
bool all_elements_are_int_or_inf_or_nan(void) const
boolNDArray operator!(void) const
void mx_inline_cummax(const T *v, T *r, octave_idx_type n)
static int fft(const double *in, Complex *out, size_t npts, size_t nsamples=1, octave_idx_type stride=1, octave_idx_type dist=-1)
const octave_base_value const Array< octave_idx_type > & ra_idx
#define SND_CMP_OPS(S, ND)
FloatNDArray diff(octave_idx_type order=1, int dim=-1) const
#define BSXFUN_OP_DEF_MXLOOP(OP, ARRAY, LOOP)
FloatNDArray max(int dim=-1) const
octave_idx_type numel(void) const
Number of elements in the array.
identity matrix If supplied two scalar respectively For allows like xample val
static octave_idx_type nn
FloatNDArray cumsum(int dim=-1) const
void mx_inline_real(size_t n, T *r, const std::complex< T > *x)
bool mx_inline_all_finite(size_t n, const T *x)
#define MINMAX_FCNS(T, S)
FloatNDArray diag(octave_idx_type k=0) const
Array< T > diag(octave_idx_type k=0) const
Get the kth super or subdiagonal.
std::istream & operator>>(std::istream &is, FloatNDArray &a)
FloatNDArray sumsq(int dim=-1) const
bool any_element_is_nan(void) const
float & elem(octave_idx_type n)
FloatComplexNDArray ifourier(int dim=1) const
Template for N-dimensional array classes with like-type math operators.
T mx_inline_sumsq(const T *v, octave_idx_type n)
bool mx_inline_any_negative(size_t n, const T *x)
bool positive_sign(double x)
bool all_elements_are_zero(void) const
void mx_inline_max(const T *v, T *r, octave_idx_type n)
subroutine cfftb(n, c, wsave)
void err_nan_to_logical_conversion(void)
FloatComplexNDArray & insert(const NDArray &a, octave_idx_type r, octave_idx_type c)
bool mx_inline_any(const T *v, octave_idx_type n)
FloatNDArray abs(void) const
F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T const F77_REAL const F77_REAL F77_REAL &F77_RET_T const F77_DBLE const F77_DBLE F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T const F77_DBLE F77_DBLE &F77_RET_T const F77_REAL F77_REAL &F77_RET_T F77_REAL F77_REAL &F77_RET_T F77_DBLE F77_DBLE &F77_RET_T const F77_DBLE const F77_DBLE F77_DBLE * d
FloatNDArray sum(int dim=-1) const
static int fftNd(const double *, Complex *, const int, const dim_vector &)
FloatComplexNDArray ifourierNd(void) const
FloatComplexNDArray fourier2d(void) const
void mx_inline_imag(size_t n, T *r, const std::complex< T > *x)
boolNDArray any(int dim=-1) const
Array< T > & insert(const Array< T > &a, const Array< octave_idx_type > &idx)
Insert an array into another at a specified position.
calling an anonymous function involves an overhead quite comparable to the overhead of an m file function Passing a handle to a built in function is because the interpreter is not involved in the internal loop For a
const dim_vector & dims(void) const
Return a const-reference so that dims ()(i) works efficiently.
subroutine cffti(n, wsave)
FloatComplexNDArray ifourier2d(void) const
#define NDND_CMP_OPS(ND1, ND2)
static octave_idx_type compute_index(Array< octave_idx_type > &ra_idx, const dim_vector &dimensions)
#define NDND_BOOL_OPS(ND1, ND2)
bool any_element_is_positive(bool=false) const
nd deftypefn *octave_map m
subst_template_param< std::complex, T, double >::type mx_inline_dprod(const T *v, octave_idx_type n)
FloatNDArray real(const FloatComplexNDArray &a)
bool any_element_not_one_or_zero(void) const
static int ifft(const Complex *in, Complex *out, size_t npts, size_t nsamples=1, octave_idx_type stride=1, octave_idx_type dist=-1)
octave_int< T > pow(const octave_int< T > &a, const octave_int< T > &b)
subroutine cfftf(n, c, wsave)
#define SND_BOOL_OPS(S, ND)
F77_RET_T F77_FUNC(xstopx, XSTOPX) const
bool mx_inline_any_positive(size_t n, const T *x)
FloatNDArray prod(int dim=-1) const
FloatComplexNDArray fourierNd(void) const
FloatNDArray imag(const FloatComplexNDArray &a)
void mx_inline_cummin(const T *v, T *r, octave_idx_type n)
bool any_element_is_negative(bool=false) const
void mx_inline_pow(size_t n, R *r, const X *x, const Y *y)
the sparsity preserving column transformation such that that defines the pivoting threshold can be given in which case it defines the c
the exceeded dimensions are set to if fewer subscripts than dimensions are the exceeding dimensions are merged into the final requested dimension For consider the following dims
bool mx_inline_any_nan(size_t n, const T *x)
subst_template_param< std::complex, T, double >::type mx_inline_dsum(const T *v, octave_idx_type n)
static int ifftNd(const Complex *, Complex *, const int, const dim_vector &)
#define BSXFUN_STDREL_DEFS_MXLOOP(ARRAY)
float & xelem(octave_idx_type n)
bool any_element_is_inf_or_nan(void) const
T mx_inline_sum(const T *v, octave_idx_type n)
bool too_large_for_float(void) const
charNDArray & insert(const charNDArray &a, octave_idx_type r, octave_idx_type c)
bool test_all(F fcn) const
FloatNDArray max(float d, const FloatNDArray &m)
FloatNDArray cumprod(int dim=-1) const
void mx_inline_cumprod(const T *v, T *r, octave_idx_type n)
boolNDArray isnan(void) const
void octave_write_float(std::ostream &os, float d)
boolNDArray all(int dim=-1) const
void mx_inline_cumsum(const T *v, T *r, octave_idx_type n)
=val(i)}if ode{val(i)}occurs in table i
octave_idx_type nint_big(double x)
bool negative_sign(double x)
FloatNDArray cummin(int dim=-1) const
octave_idx_type ndims(void) const
Number of dimensions.
boolNDArray isinf(void) const
#define OCTAVE_LOCAL_BUFFER(T, buf, size)
#define BSXFUN_OP2_DEF_MXLOOP(OP, ARRAY, ARRAY1, ARRAY2, LOOP)
FloatNDArray & insert(const FloatNDArray &a, octave_idx_type r, octave_idx_type c)
std::complex< float > FloatComplex
FloatNDArray cummax(int dim=-1) const
std::ostream & operator<<(std::ostream &os, const FloatNDArray &a)
bool mx_inline_all(const T *v, octave_idx_type n)
#define BSXFUN_STDOP_DEFS_MXLOOP(ARRAY)
const float * fortran_vec(void) const
void mx_inline_not(size_t n, bool *r, const X *x)
static void increment_index(Array< octave_idx_type > &ra_idx, const dim_vector &dimensions, int start_dimension=0)
write the output to stdout if nargout is
FloatNDArray min(int dim=-1) const
Vector representing the dimensions (size) of an Array.
T mx_inline_prod(const T *v, octave_idx_type n)
bool xis_one_or_zero(double x)
NDArray dprod(int dim=-1) const
where the brackets indicate optional arguments and and character or cell array For character arrays the conversion is repeated for every row
void mx_inline_diff(const T *v, T *r, octave_idx_type n, octave_idx_type order)
bool xis_int_or_inf_or_nan(double x)
void mx_inline_min(const T *v, T *r, octave_idx_type n)
boolNDArray isfinite(void) const