GenSVM
Functions
gensvm_simplex.h File Reference

Header file for gensvm_simplex.c. More...

#include "gensvm_base.h"
Include dependency graph for gensvm_simplex.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void gensvm_simplex (struct GenModel *model)
 Generate matrix of simplex vertex coordinates. More...
 
void gensvm_simplex_diff (struct GenModel *model)
 Generate the simplex difference matrix. More...
 

Detailed Description

Header file for gensvm_simplex.c.

Author
G.J.J. van den Burg
Date
2016-05-01

This file is part of GenSVM.

GenSVM is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

GenSVM is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with GenSVM. If not, see http://www.gnu.org/licenses/.

Definition in file gensvm_simplex.h.

Function Documentation

◆ gensvm_simplex()

void gensvm_simplex ( struct GenModel model)

Generate matrix of simplex vertex coordinates.

Generate the simplex matrix. Each row of the created matrix contains the coordinate vector of a single vertex of the K-simplex in K-1 dimensions. The simplex generated is a special simplex with edges of length 1. The simplex matrix U of the GenModel must already have been allocated.

Parameters
[in,out]modela GenModel structure

Definition at line 44 of file gensvm_simplex.c.

◆ gensvm_simplex_diff()

void gensvm_simplex_diff ( struct GenModel model)

Generate the simplex difference matrix.

The simplex difference matrix is a 2D block matrix which is constructed as follows. For each class i, we have a block of K rows and K-1 columns. Each row in the block for class i contains a row vector with the difference of the simplex matrix, U(i, :) - U(j, :).

In the paper the notation $\boldsymbol{\delta}_{kj}'$ is used for the difference vector of $\textbf{u}_k' - \textbf{u}_j'$, where $\textbf{u}_k'$ corresponds to row k of $\textbf{U}$. Due to the indexing in the paper being 1-based and C indexing is 0 based, the vector $\boldsymbol{\delta}_{kj}'$ corresponds to the row (k-1)*K+(j-1) in the UU matrix generated here.

Parameters
[in,out]modelthe corresponding GenModel

Definition at line 82 of file gensvm_simplex.c.