BitPunch McEliece  v0.0.4
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
perm.h
Go to the documentation of this file.
1 /*
2 This file is part of BitPunch
3 Copyright (C) 2013-2015 Frantisek Uhrecky <frantisek.uhrecky[what here]gmail.com>
4 Copyright (C) 2013-2014 Andrej Gulyas <andrej.guly[what here]gmail.com>
5 Copyright (C) 2013-2014 Marek Klein <kleinmrk[what here]gmail.com>
6 Copyright (C) 2013-2014 Filip Machovec <filipmachovec[what here]yahoo.com>
7 Copyright (C) 2013-2014 Jozef Kudlac <jozef[what here]kudlac.sk>
8 
9 This program is free software: you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation, either version 3 of the License, or
12 (at your option) any later version.
13 
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License for more details.
18 
19 You should have received a copy of the GNU General Public License
20 along with this program. If not, see <http://www.gnu.org/licenses/>.
21 */
22 #ifndef BPU_PERM_H
23 #define BPU_PERM_H
24 
25 #include <bitpunch/config.h>
26 
27 #include "permtypes.h"
28 
29 #ifdef BPU_CONF_PRINT
30 
34 void BPU_printPerm(const BPU_T_Perm_Vector *permutation);
35 #endif // BPU_CONF_PRINT
36 
42 int BPU_permRandomize(BPU_T_Perm_Vector* permutation);
43 
50 
58 
65 int BPU_permPermute(BPU_T_Perm_Vector *to_permute, const BPU_T_Perm_Vector *permutation);
66 
73 
74 #endif // BPU_PERM_H
int BPU_permRandomize(BPU_T_Perm_Vector *permutation)
Definition: perm.c:43
int BPU_permGetInv(BPU_T_Perm_Vector *out, const BPU_T_Perm_Vector *in)
Definition: perm.c:64
int BPU_permPermute(BPU_T_Perm_Vector *to_permute, const BPU_T_Perm_Vector *permutation)
Definition: perm.c:79
int BPU_permIsValid(const BPU_T_Perm_Vector *p)
BPU_permIsValid Check wheter is permutaion valid.
Definition: perm.c:104
void BPU_printPerm(const BPU_T_Perm_Vector *permutation)
Definition: perm.c:32
void BPU_permSwap(BPU_T_Perm_Element *a, BPU_T_Perm_Element *b)
BPU_swap.
Definition: perm.c:57
uint16_t BPU_T_Perm_Element
Definition of permutation element type.
Definition: permtypes.h:24