root/trunk/lib/cc3-ilp/cc3_math.h
| Revision 343, 399 bytes (checked in by anthony_rowe, 2 years ago) |
|---|
| Line | |
|---|---|
| 1 | #ifndef _CC3_MATH_H_ |
| 2 | #define _CC3_MATH_H_ |
| 3 | |
| 4 | #include <stdint.h> |
| 5 | |
| 6 | |
| 7 | typedef struct { |
| 8 | double r_sqr; // correlation squared |
| 9 | double b; // intercept |
| 10 | double m; // slope |
| 11 | } cc3_linear_reg_data_t; |
| 12 | |
| 13 | |
| 14 | |
| 15 | double cc3_mean( uint8_t data[], uint32_t size ); |
| 16 | void cc3_linear_reg(uint8_t x_data[], uint8_t y_data[], uint8_t size,cc3_linear_reg_data_t *reg_out ); |
| 17 | uint32_t cc3_isqrt (uint32_t n); |
| 18 | |
| 19 | #endif |
Note: See TracBrowser for help on using the browser.
