Go to the documentation of this file.
35 #ifndef TTA_MATH_TOOLS_HH
36 #define TTA_MATH_TOOLS_HH
44 static unsigned int bitLength(
long unsigned int number);
46 unsigned enc1,
unsigned pos1,
47 unsigned enc2,
unsigned pos2,
50 long unsigned int msbBitField,
unsigned msbWidth,
51 long unsigned int lsbBitField,
unsigned lsbWidth);
52 static int ceil_log2(
long unsigned int number);
53 template<
typename NumberType>
54 static int ceil_div(NumberType dividee, NumberType diveder);
67 template<
class IntegerType>
69 IntegerType& bits,
unsigned int index,
bool bitState =
true);
71 static int random(
int,
int);
76 template<
typename ResultNumberTypeS,
typename ResultNumberTypeU=ResultNumberTypeS>
78 unsigned bitWidth,
bool signExtending);