Classes | Defines | Functions

robomath.h File Reference

#include <math.h>
#include <stdlib.h>
Include dependency graph for robomath.h:
This graph shows which files directly or indirectly include this file:

Classes

struct  angles_freq

Defines

#define POWER(x)   ((x)*(x))
#define DEG2RAD(a)   ((a)/180.0*M_PI)
#define RAD2DEG(a)   ((a)*180.0/M_PI)
#define DEGREES(a)   RAD2DEG(a)
#define MIN(a, b)   (((a) < (b)) ? (a) : (b))
#define MAX(a, b)   (((a) > (b)) ? (a) : (b))

Functions

double gaussrand ()
 Math functions.
double gaussian_random (void)
float exprand (float lambda)
void angles_freq_sort (struct angles_freq *angles, int count)
int cmpi (const void *a, const void *b)
 Compare integers.
int cmpd (const void *a, const void *b)
 Compare doubles.

Define Documentation

#define DEG2RAD (   a  )     ((a)/180.0*M_PI)
#define DEGREES (   a  )     RAD2DEG(a)
#define MAX (   a,
  b 
)    (((a) > (b)) ? (a) : (b))
#define MIN (   a,
  b 
)    (((a) < (b)) ? (a) : (b))
#define POWER (   x  )     ((x)*(x))
#define RAD2DEG (   a  )     ((a)*180.0/M_PI)

Function Documentation

void angles_freq_sort ( struct angles_freq angles,
int  count 
)

Here is the call graph for this function:

int cmpd ( const void *  a,
const void *  b 
)

Compare doubles.

Used by qsort().

int cmpi ( const void *  a,
const void *  b 
)

Compare integers.

Used by qsort().

float exprand ( float  lambda  ) 

Here is the caller graph for this function:

double gaussian_random ( void   ) 
double gaussrand (  ) 

Math functions.

Random generation stuffs.

Here is the caller graph for this function: