Add mingwmath.h

Add mingwmath.h
Define M_PI if undefined (windows compatibility)