00001 #ifndef _PFUTILITYFCT_H_
00002 #define _PFUTILITYFCT_H_
00003
00004 #include <stdlib.h>
00005 #include <math.h>
00006
00007 namespace RobotFlow {
00008
00009
00010
00011
00012 #define PFUTIL_FLOGLOOKUP2SIZE 256
00013 #define PFUTIL_FLOGLOOKUP2SHIFT 15
00014
00015 union PFUTIL_FloatManip {
00016 float f;
00017 unsigned int i;
00018 };
00019
00020 void PFUTIL_build_flog_table();
00021
00022 float PFUTIL_flog(const float in);
00023
00024 float PFUTIL_randn();
00025
00026 float PFUTIL_ran();
00027
00028 int PFUTIL_find_range(float i_x, const float *i_cumul, int i_cumulSize);
00029
00030 }
00031
00032 #endif