![]() |
Bachelor's degree final project
v1.0
Faculty of Mathematics, University of Barcelona
|
The act of permuting objects or values is called permutation and we implement a permutation to a vector. More...
Defines | |
#define | _OPENMP_PERMUTATION_DIMENSION 1e2 |
Minimum value for using the openmp library in permutation. | |
Functions | |
void | permutation_init (size_t n, size_t *const p) |
Initialize a identity vector permutation. | |
void | permutation_vector (size_t n, size_t *const p, double *const x, double *const px) |
Permute the values of the vector x into px based on the vector permutation p. |
The act of permuting objects or values is called permutation and we implement a permutation to a vector.
A permutation of
elements is a bijection of
from that set onto itself and with the composition is a non-commutative group. The Cauchy's two-line notation is
In one-line notation, one gives only the second row of this array. In this functions, one-line notation will be used.
#define _OPENMP_PERMUTATION_DIMENSION 1e2 |
Minimum value for using the openmp library in permutation.
void permutation_init | ( | size_t | n, |
size_t *const | p | ||
) |
Initialize a identity vector permutation.
[in] | n | Dimension of vector |
[out] | p | Vector permutation |
void permutation_vector | ( | size_t | n, |
size_t *const | p, | ||
double *const | x, | ||
double *const | px | ||
) |
Permute the values of the vector x into px based on the vector permutation p.
[in] | n | Dimension of vectors |
[in] | p | Vector permutation |
[in] | x | Vector n-dimensional where will be read the data |
[out] | px | Vector n-dimensional where will be saved the permutations by the vector permutation |