FilterGen  1.0.0
A library to design digital filters in embedded systems.
dh_complex.h File Reference

Contains code to handle complex numbers in C, as MSVC does not support C99 complex types. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define COMPLEX   double _Complex
 
#define MAKE_COMPLEX_NUMER(re, im)   ((re) + (im) * I)
 
#define COMPLEX_ADD(x, y)   ((x)+(y))
 
#define COMPLEX_SUB(x, y)   ((x)-(y))
 
#define COMPLEX_MUL(x, y)   ((x)*(y))
 
#define COMPLEX_DIV(x, y)   ((x)/(y))
 
#define COMPLEX_INV(x)   (1.0/(x))
 
#define COMPLEX_NEG(x)   (-(x))
 

Functions

COMPLEX complex_unit_circle (double phi)
 

Detailed Description

Contains code to handle complex numbers in C, as MSVC does not support C99 complex types.

Macro Definition Documentation

◆ COMPLEX

#define COMPLEX   double _Complex

The complex data type for the computations.

Function Documentation

◆ complex_unit_circle()

COMPLEX complex_unit_circle ( double  phi)

Returns a complex number on the complex unit circle located at the angle [phi].