Matrix  $Rev: 3071 $ at $LastChangedDate: 2015-03-26 15:35:47 +0100 (Thu, 26 Mar 2015) $
dgeMatrix.c File Reference
#include "dgeMatrix.h"
Include dependency graph for dgeMatrix.c:

Go to the source code of this file.

Macros

#define DGE_CROSS_1
 
#define DGE_CROSS_DO(_X_X_)
 
#define DGE_DGE_CROSS_1
 
#define DGE_DGE_CROSS_DO(_X_X_, _Y_Y_)
 
#define DGE_MAT_CROSS_1
 
#define DGE_MAT_CROSS_DO(_X_X_)
 
#define DGE_MAT_MM_1(N_PROT)
 
#define DGE_MAT_MM_DO(_A_X_, _B_X_)
 
#define geMatrix_getDiag_1
 
#define geMatrix_getDiag_2
 
#define geMatrix_setDiag_1
 
#define geMatrix_setDiag_2
 
#define RE_PERMUTE(I)
 
#define SWAP_COL(I, J)   F77_CALL(dswap)(&n, &v[(I)*n], &i1, &v[(J)*n], &i1)
 
#define SWAP_ROW(I, J)   F77_CALL(dswap)(&n, &v[(I)], &n, &v[(J)], &n)
 

Functions

SEXP _geMatrix__geMatrix_crossprod (SEXP x, SEXP y, SEXP trans)
 As dgeMatrix_dgeMatrix_crossprod(), but x and y can be [dln]geMatrix. More...
 
SEXP _geMatrix_crossprod (SEXP x, SEXP trans)
 As dgeMatrix_crossprod(), but x can be [dln]geMatrix. More...
 
SEXP _geMatrix_matrix_crossprod (SEXP x, SEXP y, SEXP trans)
 as dgeMatrix_matrix_crossprod() but x can be [dln]geMatrix More...
 
SEXP _geMatrix_matrix_mm (SEXP a, SEXP b, SEXP right)
 as dgeMatrix_matrix_mm() but a can be [dln]geMatrix More...
 
SEXP dgeMatrix_addDiag (SEXP x, SEXP d)
 
SEXP dgeMatrix_colsums (SEXP x, SEXP naRmP, SEXP cols, SEXP mean)
 
SEXP dgeMatrix_crossprod (SEXP x, SEXP trans)
 
SEXP dgeMatrix_determinant (SEXP x, SEXP logarithm)
 
SEXP dgeMatrix_dgeMatrix_crossprod (SEXP x, SEXP y, SEXP trans)
 
SEXP dgeMatrix_exp (SEXP x)
 Matrix exponential - based on the corrected code for Octave's expm function. More...
 
SEXP dgeMatrix_getDiag (SEXP x)
 
SEXP dgeMatrix_LU (SEXP x, SEXP warn_singularity)
 
SEXP dgeMatrix_LU_ (SEXP x, Rboolean warn_sing)
 
SEXP dgeMatrix_matrix_crossprod (SEXP x, SEXP y, SEXP trans)
 
SEXP dgeMatrix_matrix_mm (SEXP a, SEXP bP, SEXP right)
 
SEXP dgeMatrix_matrix_solve (SEXP a, SEXP b)
 
SEXP dgeMatrix_norm (SEXP obj, SEXP type)
 
SEXP dgeMatrix_rcond (SEXP obj, SEXP type)
 
SEXP dgeMatrix_Schur (SEXP x, SEXP vectors, SEXP isDGE)
 
SEXP dgeMatrix_setDiag (SEXP x, SEXP d)
 
SEXP dgeMatrix_solve (SEXP a)
 
SEXP dgeMatrix_svd (SEXP x, SEXP nnu, SEXP nnv)
 
SEXP dgeMatrix_validate (SEXP obj)
 
SEXP dMatrix_validate (SEXP obj)
 
SEXP geMatrix_crossprod (SEXP x, SEXP trans)
 
SEXP geMatrix_geMatrix_crossprod (SEXP x, SEXP y, SEXP trans)
 
SEXP geMatrix_matrix_crossprod (SEXP x, SEXP y, SEXP trans)
 
SEXP geMatrix_matrix_mm (SEXP a, SEXP b, SEXP right)
 %*% – generalized from dge to *ge(): More...
 
double * gematrix_real_x (SEXP x, int nn)
 
static double get_norm (SEXP obj, const char *typstr)
 
SEXP lgeMatrix_getDiag (SEXP x)
 
SEXP lgeMatrix_setDiag (SEXP x, SEXP d)
 

Variables

static const double padec []
 

Macro Definition Documentation

#define DGE_CROSS_1
Value:
int tr = asLogical(trans);/* trans=TRUE: tcrossprod(x) */ \
SEXP val = PROTECT(NEW_OBJECT(MAKE_CLASS("dpoMatrix"))), \
nms = VECTOR_ELT(GET_SLOT(x, Matrix_DimNamesSym), tr ? 0 : 1), \
vDnms = ALLOC_SLOT(val, Matrix_DimNamesSym, VECSXP, 2); \
int *Dims = INTEGER(GET_SLOT(x, Matrix_DimSym)), \
*vDims = INTEGER(ALLOC_SLOT(val, Matrix_DimSym, INTSXP, 2)); \
int k = tr ? Dims[1] : Dims[0], \
n = tr ? Dims[0] : Dims[1]; \
double *vx = REAL(ALLOC_SLOT(val, Matrix_xSym, REALSXP, n * n)), \
one = 1.0, zero = 0.0; \
Memzero(vx, n * n); \
SET_SLOT(val, Matrix_uploSym, mkString("U")); \
ALLOC_SLOT(val, Matrix_factorSym, VECSXP, 0); \
vDims[0] = vDims[1] = n; \
SET_VECTOR_ELT(vDnms, 0, duplicate(nms)); \
SET_VECTOR_ELT(vDnms, 1, duplicate(nms))
SEXP Matrix_DimSym
Definition: Syms.h:2
SEXP Matrix_xSym
Definition: Syms.h:2
SEXP Matrix_factorSym
Definition: Syms.h:2
SEXP Matrix_DimNamesSym
Definition: Syms.h:2
SEXP Matrix_uploSym
Definition: Syms.h:2
#define Memzero(p, n)
Definition: Mutils.h:142
static R_INLINE SEXP ALLOC_SLOT(SEXP obj, SEXP nm, SEXPTYPE type, int length)
Allocate an SEXP of given type and length, assign it as slot nm in the object, and return the SEXP...
Definition: Mutils.h:240

Referenced by _geMatrix_crossprod(), and dgeMatrix_crossprod().

#define DGE_CROSS_DO (   _X_X_)
Value:
if(n) \
F77_CALL(dsyrk)("U", tr ? "N" : "T", &n, &k, &one, \
_X_X_, Dims, &zero, vx, &n); \
UNPROTECT(1); \
return val

Referenced by _geMatrix_crossprod(), and dgeMatrix_crossprod().

#define DGE_DGE_CROSS_1
Value:
int tr = asLogical(trans);/* trans=TRUE: tcrossprod(x,y) */ \
SEXP val = PROTECT(NEW_OBJECT(MAKE_CLASS("dgeMatrix"))), \
dn = PROTECT(allocVector(VECSXP, 2)); \
int *xDims = INTEGER(GET_SLOT(x, Matrix_DimSym)), \
*yDims = INTEGER(GET_SLOT(y, Matrix_DimSym)), \
*vDims; \
int m = xDims[!tr], n = yDims[!tr];/* -> result dim */ \
int xd = xDims[ tr], yd = yDims[ tr];/* the conformable dims */ \
double one = 1.0, zero = 0.0; \
\
if (xd != yd) \
error(_("Dimensions of x and y are not compatible for %s"), \
tr ? "tcrossprod" : "crossprod"); \
SET_SLOT(val, Matrix_factorSym, allocVector(VECSXP, 0)); \
/* establish dimnames */ \
SET_VECTOR_ELT(dn, 0, \
duplicate(VECTOR_ELT(GET_SLOT(x, Matrix_DimNamesSym), \
tr ? 0 : 1))); \
SET_VECTOR_ELT(dn, 1, \
duplicate(VECTOR_ELT(GET_SLOT(y, Matrix_DimNamesSym), \
tr ? 0 : 1))); \
SET_SLOT(val, Matrix_DimNamesSym, dn); \
vDims = INTEGER(ALLOC_SLOT(val, Matrix_DimSym, INTSXP, 2)); \
vDims[0] = m; vDims[1] = n; \
double *v = REAL(ALLOC_SLOT(val, Matrix_xSym, REALSXP, m * n))
SEXP Matrix_DimSym
Definition: Syms.h:2
SEXP Matrix_xSym
Definition: Syms.h:2
SEXP Matrix_factorSym
Definition: Syms.h:2
SEXP Matrix_DimNamesSym
Definition: Syms.h:2
#define _(String)
Definition: Mutils.h:32
static R_INLINE SEXP ALLOC_SLOT(SEXP obj, SEXP nm, SEXPTYPE type, int length)
Allocate an SEXP of given type and length, assign it as slot nm in the object, and return the SEXP...
Definition: Mutils.h:240

Referenced by _geMatrix__geMatrix_crossprod(), and dgeMatrix_dgeMatrix_crossprod().

#define DGE_DGE_CROSS_DO (   _X_X_,
  _Y_Y_ 
)
Value:
if (xd > 0 && n > 0 && m > 0) \
F77_CALL(dgemm)(tr ? "N" : "T", tr ? "T" : "N", &m, &n, &xd, &one, \
_X_X_, xDims, \
_Y_Y_, yDims, &zero, v, &m); \
Memzero(v, m * n); \
UNPROTECT(2); \
return val
#define Memzero(p, n)
Definition: Mutils.h:142

Referenced by _geMatrix__geMatrix_crossprod(), and dgeMatrix_dgeMatrix_crossprod().

#define DGE_MAT_CROSS_1
#define DGE_MAT_CROSS_DO (   _X_X_)
Value:
if (xd > 0 && n > 0 && m > 0) \
F77_CALL(dgemm)(tr ? "N" : "T", tr ? "T" : "N", &m, &n, &xd, &one, \
_X_X_, xDims, REAL(y), yDims, \
&zero, v, &m); \
Memzero(v, m * n); \
UNPROTECT(nprot); \
return val
#define Memzero(p, n)
Definition: Mutils.h:142

Referenced by _geMatrix_matrix_crossprod(), and dgeMatrix_matrix_crossprod().

#define DGE_MAT_MM_1 (   N_PROT)
Value:
SEXP val= PROTECT(NEW_OBJECT(MAKE_CLASS("dgeMatrix"))), \
dn = PROTECT(allocVector(VECSXP, 2)); \
int nprot = N_PROT + 2, \
*adims = INTEGER(GET_SLOT(a, Matrix_DimSym)), \
*bdims = INTEGER(GET_SLOT(b, Matrix_DimSym)), \
*cdims = INTEGER(ALLOC_SLOT(val, Matrix_DimSym, INTSXP, 2)), \
Rt = asLogical(right), m, k, n; \
double one = 1., zero = 0.; \
\
if (Rt) { /* b %*% a : (m x k) (k x n) -> (m x n) */ \
m = bdims[0]; k = bdims[1]; n = adims[1]; \
if (adims[0] != k) \
error(_("Matrices are not conformable for multiplication")); \
} else { /* a %*% b : (m x k) (k x n) -> (m x n) */ \
m = adims[0]; k = adims[1]; n = bdims[1]; \
if (bdims[0] != k) \
error(_("Matrices are not conformable for multiplication")); \
} \
\
cdims[0] = m; cdims[1] = n; \
/* establish dimnames */ \
SET_VECTOR_ELT(dn, 0, duplicate( \
VECTOR_ELT(GET_SLOT(Rt ? b : a, \
SET_VECTOR_ELT(dn, 1, \
duplicate( \
VECTOR_ELT(GET_SLOT(Rt ? a : b, \
SET_SLOT(val, Matrix_DimNamesSym, dn); \
double *v = REAL(ALLOC_SLOT(val, Matrix_xSym, REALSXP, m * n))
SEXP Matrix_DimSym
Definition: Syms.h:2
SEXP Matrix_xSym
Definition: Syms.h:2
SEXP Matrix_DimNamesSym
Definition: Syms.h:2
#define _(String)
Definition: Mutils.h:32
static R_INLINE SEXP ALLOC_SLOT(SEXP obj, SEXP nm, SEXPTYPE type, int length)
Allocate an SEXP of given type and length, assign it as slot nm in the object, and return the SEXP...
Definition: Mutils.h:240

Referenced by _geMatrix_matrix_mm(), and dgeMatrix_matrix_mm().

#define DGE_MAT_MM_DO (   _A_X_,
  _B_X_ 
)
Value:
if (m < 1 || n < 1 || k < 1) {/* zero extent matrices should work */ \
Memzero(v, m * n); \
} else { \
if (Rt) { /* b %*% a */ \
F77_CALL(dgemm) ("N", "N", &m, &n, &k, &one, \
_B_X_, &m, _A_X_, &k, &zero, v, &m); \
} else { /* a %*% b */ \
F77_CALL(dgemm) ("N", "N", &m, &n, &k, &one, \
_A_X_, &m, _B_X_, &k, &zero, v, &m); \
} \
} \
UNPROTECT(nprot); \
return val
#define Memzero(p, n)
Definition: Mutils.h:142

Referenced by _geMatrix_matrix_mm(), and dgeMatrix_matrix_mm().

#define geMatrix_getDiag_1
Value:
int *dims = INTEGER(GET_SLOT(x, Matrix_DimSym)); \
int i, m = dims[0], nret = (m < dims[1]) ? m : dims[1]; \
SEXP x_x = GET_SLOT(x, Matrix_xSym)
SEXP Matrix_DimSym
Definition: Syms.h:2
SEXP Matrix_xSym
Definition: Syms.h:2

Referenced by dgeMatrix_getDiag(), and lgeMatrix_getDiag().

#define geMatrix_getDiag_2
Value:
for (i = 0; i < nret; i++) { \
rv[i] = xv[i * (m + 1)]; \
} \
UNPROTECT(1); \
return ret

Referenced by dgeMatrix_getDiag(), and lgeMatrix_getDiag().

#define geMatrix_setDiag_1
Value:
int *dims = INTEGER(GET_SLOT(x, Matrix_DimSym)); \
int m = dims[0], nret = (m < dims[1]) ? m : dims[1]; \
SEXP ret = PROTECT(duplicate(x)); \
SEXP r_x = GET_SLOT(ret, Matrix_xSym); \
int l_d = LENGTH(d); Rboolean d_full = (l_d == nret); \
if (!d_full && l_d != 1) \
error(_("replacement diagonal has wrong length"))
SEXP Matrix_DimSym
Definition: Syms.h:2
SEXP Matrix_xSym
Definition: Syms.h:2
#define _(String)
Definition: Mutils.h:32

Referenced by dgeMatrix_setDiag(), and lgeMatrix_setDiag().

#define geMatrix_setDiag_2
Value:
if(d_full) for (int i = 0; i < nret; i++) \
rv[i * (m + 1)] = dv[i]; \
else for (int i = 0; i < nret; i++) \
rv[i * (m + 1)] = *dv; \
UNPROTECT(1); \
return ret

Referenced by dgeMatrix_setDiag(), and lgeMatrix_setDiag().

#define RE_PERMUTE (   I)
Value:
int p_I = (int) (perm[I]) - 1; \
SWAP_COL(I, p_I); \
SWAP_ROW(I, p_I)
#define SWAP_ROW(I, J)
#define SWAP_COL(I, J)

Referenced by dgeMatrix_exp().

#define SWAP_COL (   I,
 
)    F77_CALL(dswap)(&n, &v[(I)*n], &i1, &v[(J)*n], &i1)
#define SWAP_ROW (   I,
 
)    F77_CALL(dswap)(&n, &v[(I)], &n, &v[(J)], &n)

Function Documentation

SEXP _geMatrix__geMatrix_crossprod ( SEXP  x,
SEXP  y,
SEXP  trans 
)

As dgeMatrix_dgeMatrix_crossprod(), but x and y can be [dln]geMatrix.

Definition at line 190 of file dgeMatrix.c.

References DGE_DGE_CROSS_1, DGE_DGE_CROSS_DO, and gematrix_real_x().

Referenced by geMatrix_geMatrix_crossprod().

Here is the call graph for this function:

Here is the caller graph for this function:

SEXP _geMatrix_crossprod ( SEXP  x,
SEXP  trans 
)

As dgeMatrix_crossprod(), but x can be [dln]geMatrix.

Definition at line 130 of file dgeMatrix.c.

References DGE_CROSS_1, DGE_CROSS_DO, and gematrix_real_x().

Referenced by geMatrix_crossprod().

Here is the call graph for this function:

Here is the caller graph for this function:

SEXP _geMatrix_matrix_crossprod ( SEXP  x,
SEXP  y,
SEXP  trans 
)

as dgeMatrix_matrix_crossprod() but x can be [dln]geMatrix

Definition at line 283 of file dgeMatrix.c.

References DGE_MAT_CROSS_1, DGE_MAT_CROSS_DO, and gematrix_real_x().

Referenced by geMatrix_matrix_crossprod().

Here is the call graph for this function:

Here is the caller graph for this function:

SEXP _geMatrix_matrix_mm ( SEXP  a,
SEXP  b,
SEXP  right 
)

as dgeMatrix_matrix_mm() but a can be [dln]geMatrix

Definition at line 355 of file dgeMatrix.c.

References DGE_MAT_MM_1, DGE_MAT_MM_DO, and gematrix_real_x().

Referenced by geMatrix_matrix_mm().

Here is the call graph for this function:

Here is the caller graph for this function:

SEXP dgeMatrix_addDiag ( SEXP  x,
SEXP  d 
)

Definition at line 447 of file dgeMatrix.c.

References _, Matrix_DimSym, and Matrix_xSym.

SEXP dgeMatrix_colsums ( SEXP  x,
SEXP  naRmP,
SEXP  cols,
SEXP  mean 
)

Definition at line 839 of file dgeMatrix.c.

References C_or_Alloca_TO, Matrix_DimNamesSym, Matrix_DimSym, Matrix_xSym, and SMALL_4_Alloca.

SEXP dgeMatrix_crossprod ( SEXP  x,
SEXP  trans 
)

Definition at line 76 of file dgeMatrix.c.

References DGE_CROSS_1, DGE_CROSS_DO, and Matrix_xSym.

SEXP dgeMatrix_determinant ( SEXP  x,
SEXP  logarithm 
)

Definition at line 502 of file dgeMatrix.c.

References _, as_det_obj(), dgeMatrix_LU_(), Matrix_DimSym, Matrix_permSym, and Matrix_xSym.

Here is the call graph for this function:

SEXP dgeMatrix_dgeMatrix_crossprod ( SEXP  x,
SEXP  y,
SEXP  trans 
)

Definition at line 145 of file dgeMatrix.c.

References DGE_DGE_CROSS_1, DGE_DGE_CROSS_DO, and Matrix_xSym.

SEXP dgeMatrix_exp ( SEXP  x)

Matrix exponential - based on the corrected code for Octave's expm function.

Parameters
xreal square matrix to exponentiate
Returns
matrix exponential of x

Definition at line 662 of file dgeMatrix.c.

References _, AZERO, Matrix_DimSym, Matrix_xSym, padec, and RE_PERMUTE.

SEXP dgeMatrix_getDiag ( SEXP  x)

Definition at line 374 of file dgeMatrix.c.

References geMatrix_getDiag_1, and geMatrix_getDiag_2.

SEXP dgeMatrix_LU ( SEXP  x,
SEXP  warn_singularity 
)

Definition at line 497 of file dgeMatrix.c.

References dgeMatrix_LU_().

Here is the call graph for this function:

SEXP dgeMatrix_LU_ ( SEXP  x,
Rboolean  warn_sing 
)

Definition at line 466 of file dgeMatrix.c.

References _, ALLOC_SLOT(), get_factors(), Matrix_DimNamesSym, Matrix_DimSym, Matrix_permSym, Matrix_xSym, set_factors(), and slot_dup.

Referenced by dgeMatrix_determinant(), dgeMatrix_LU(), dgeMatrix_matrix_solve(), dgeMatrix_rcond(), and dgeMatrix_solve().

Here is the call graph for this function:

Here is the caller graph for this function:

SEXP dgeMatrix_matrix_crossprod ( SEXP  x,
SEXP  y,
SEXP  trans 
)

Definition at line 211 of file dgeMatrix.c.

References DGE_MAT_CROSS_1, DGE_MAT_CROSS_DO, and Matrix_xSym.

SEXP dgeMatrix_matrix_mm ( SEXP  a,
SEXP  bP,
SEXP  right 
)

Definition at line 299 of file dgeMatrix.c.

References DGE_MAT_MM_1, DGE_MAT_MM_DO, Matrix_xSym, and mMatrix_as_dgeMatrix().

Here is the call graph for this function:

SEXP dgeMatrix_matrix_solve ( SEXP  a,
SEXP  b 
)

Definition at line 583 of file dgeMatrix.c.

References _, dgeMatrix_LU_(), dup_mMatrix_as_dgeMatrix(), Matrix_DimSym, Matrix_permSym, and Matrix_xSym.

Here is the call graph for this function:

SEXP dgeMatrix_norm ( SEXP  obj,
SEXP  type 
)

Definition at line 49 of file dgeMatrix.c.

References get_norm().

Here is the call graph for this function:

SEXP dgeMatrix_rcond ( SEXP  obj,
SEXP  type 
)

Definition at line 54 of file dgeMatrix.c.

References _, dgeMatrix_LU_(), get_norm(), La_rcond_type(), Matrix_DimSym, and Matrix_xSym.

Here is the call graph for this function:

SEXP dgeMatrix_Schur ( SEXP  x,
SEXP  vectors,
SEXP  isDGE 
)

Definition at line 792 of file dgeMatrix.c.

References _, C_or_Alloca_TO, Matrix_DimSym, Matrix_xSym, and SMALL_4_Alloca.

SEXP dgeMatrix_setDiag ( SEXP  x,
SEXP  d 
)

Definition at line 411 of file dgeMatrix.c.

References geMatrix_setDiag_1, and geMatrix_setDiag_2.

SEXP dgeMatrix_solve ( SEXP  a)

Definition at line 535 of file dgeMatrix.c.

References _, dgeMatrix_LU_(), get_norm(), Matrix_DimSym, Matrix_permSym, Matrix_xSym, and slot_dup.

Here is the call graph for this function:

SEXP dgeMatrix_svd ( SEXP  x,
SEXP  nnu,
SEXP  nnv 
)

Definition at line 604 of file dgeMatrix.c.

References C_or_Alloca_TO, dgesdd(), Matrix_DimSym, Matrix_xSym, and SMALL_4_Alloca.

Here is the call graph for this function:

SEXP dgeMatrix_validate ( SEXP  obj)

Definition at line 16 of file dgeMatrix.c.

References _, dense_nonpacked_validate(), dim_validate(), Matrix_DimSym, and Matrix_factorSym.

Here is the call graph for this function:

SEXP dMatrix_validate ( SEXP  obj)

Definition at line 4 of file dgeMatrix.c.

References _, dim_validate(), Matrix_DimSym, and Matrix_xSym.

Here is the call graph for this function:

SEXP geMatrix_crossprod ( SEXP  x,
SEXP  trans 
)

Definition at line 137 of file dgeMatrix.c.

References _geMatrix_crossprod(), and dup_mMatrix_as_geMatrix().

Here is the call graph for this function:

SEXP geMatrix_geMatrix_crossprod ( SEXP  x,
SEXP  y,
SEXP  trans 
)

Definition at line 202 of file dgeMatrix.c.

References _geMatrix__geMatrix_crossprod(), and dup_mMatrix_as_geMatrix().

Here is the call graph for this function:

SEXP geMatrix_matrix_crossprod ( SEXP  x,
SEXP  y,
SEXP  trans 
)

Definition at line 291 of file dgeMatrix.c.

References _geMatrix_matrix_crossprod(), and dup_mMatrix_as_geMatrix().

Here is the call graph for this function:

SEXP geMatrix_matrix_mm ( SEXP  a,
SEXP  b,
SEXP  right 
)

%*% – generalized from dge to *ge():

Definition at line 363 of file dgeMatrix.c.

References _geMatrix_matrix_mm(), and dup_mMatrix_as_geMatrix().

Here is the call graph for this function:

double* gematrix_real_x ( SEXP  x,
int  nn 
)

Definition at line 109 of file dgeMatrix.c.

References C_or_Alloca_TO, class_P, Matrix_xSym, and SMALL_4_Alloca.

Referenced by _geMatrix__geMatrix_crossprod(), _geMatrix_crossprod(), _geMatrix_matrix_crossprod(), and _geMatrix_matrix_mm().

Here is the caller graph for this function:

static double get_norm ( SEXP  obj,
const char *  typstr 
)
static

Definition at line 30 of file dgeMatrix.c.

References any_NA_in_x(), La_norm_type(), Matrix_DimSym, and Matrix_xSym.

Referenced by dgeMatrix_norm(), dgeMatrix_rcond(), and dgeMatrix_solve().

Here is the call graph for this function:

Here is the caller graph for this function:

SEXP lgeMatrix_getDiag ( SEXP  x)

Definition at line 396 of file dgeMatrix.c.

References geMatrix_getDiag_1, and geMatrix_getDiag_2.

SEXP lgeMatrix_setDiag ( SEXP  x,
SEXP  d 
)

Definition at line 436 of file dgeMatrix.c.

References geMatrix_setDiag_1, and geMatrix_setDiag_2.

Variable Documentation

const double padec[]
static
Initial value:
=
{
5.0000000000000000e-1,
1.1666666666666667e-1,
1.6666666666666667e-2,
1.6025641025641026e-3,
1.0683760683760684e-4,
4.8562548562548563e-6,
1.3875013875013875e-7,
1.9270852604185938e-9,
}

Definition at line 643 of file dgeMatrix.c.

Referenced by dgeMatrix_exp().