Defines | Functions
mPCA.c File Reference
#include <stdio.h>
#include <math.h>
#include <AR/matrix.h>
Include dependency graph for backup/lib/SRC/AR/mPCA.c:

Go to the source code of this file.

Defines

#define EPS   1e-6
#define MAX_ITER   100
#define VZERO   1e-16
#define xmalloc(V, T, S)

Functions

int arMatrixPCA (ARMat *input, ARMat *evec, ARVec *ev, ARVec *mean)
 compute the PCA of a matrix.
int arMatrixPCA2 (ARMat *input, ARMat *evec, ARVec *ev)
 compute the PCA of a matrix.
static int CENTER (ARMat *inout, ARVec *mean)
static int EV_create (ARMat *input, ARMat *u, ARMat *output, ARVec *ev)
static int EX (ARMat *input, ARVec *mean)
static int PCA (ARMat *input, ARMat *output, ARVec *ev)
static int QRM (ARMat *u, ARVec *ev)
static int x_by_xt (ARMat *input, ARMat *output)
static int xt_by_x (ARMat *input, ARMat *output)

Define Documentation

#define EPS   1e-6

Definition at line 6 of file backup/lib/SRC/AR/mPCA.c.

#define MAX_ITER   100

Definition at line 7 of file backup/lib/SRC/AR/mPCA.c.

#define VZERO   1e-16

Definition at line 5 of file backup/lib/SRC/AR/mPCA.c.

#define xmalloc (   V,
  T,
 
)
Value:
{ if( ((V) = (T *)malloc( sizeof(T) * (S) ))\
                               == NULL ) {printf("malloc error\n"); exit(1);} }

Definition at line 8 of file backup/lib/SRC/AR/mPCA.c.


Function Documentation

int arMatrixPCA ( ARMat input,
ARMat evec,
ARVec ev,
ARVec mean 
)

compute the PCA of a matrix.

Compute the Principal Component Analysis (PCA) of a matrix.

Parameters:
inputsource matrix
eveceigen vector computed
eveigen value computed
meanmean computed
Returns:
0 if success to compute, -1 otherwise

Definition at line 49 of file backup/lib/SRC/AR/mPCA.c.

int arMatrixPCA2 ( ARMat input,
ARMat evec,
ARVec ev 
)

compute the PCA of a matrix.

Compute the Principal Component Analysis (PCA) of a matrix.

Parameters:
inputsource matrix
evecresult matrix
evegein value computed
Returns:
0 if success to compute, -1 otherwise

Definition at line 89 of file backup/lib/SRC/AR/mPCA.c.

static int CENTER ( ARMat inout,
ARVec mean 
) [static]

Definition at line 197 of file backup/lib/SRC/AR/mPCA.c.

static int EV_create ( ARMat input,
ARMat u,
ARMat output,
ARVec ev 
) [static]

Definition at line 280 of file backup/lib/SRC/AR/mPCA.c.

static int EX ( ARMat input,
ARVec mean 
) [static]

Definition at line 173 of file backup/lib/SRC/AR/mPCA.c.

static int PCA ( ARMat input,
ARMat output,
ARVec ev 
) [static]

Definition at line 123 of file backup/lib/SRC/AR/mPCA.c.

static int QRM ( ARMat u,
ARVec ev 
) [static]

Definition at line 318 of file backup/lib/SRC/AR/mPCA.c.

static int x_by_xt ( ARMat input,
ARMat output 
) [static]

Definition at line 216 of file backup/lib/SRC/AR/mPCA.c.

static int xt_by_x ( ARMat input,
ARMat output 
) [static]

Definition at line 247 of file backup/lib/SRC/AR/mPCA.c.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines


ar_recog
Author(s): Graylin Trevor Jay and Christopher Crick
autogenerated on Fri Jan 25 2013 12:15:01