Skip to content

basic/prob-utils.cc:8:37: error: ‘M_PI’ was not declared in this scope #22

@hammad26

Description

@hammad26

I am using Cygwin on windows and trying to run this code. On the first step when running "make" command, getting following error.

basic/prob-utils.cc: In function ‘double rand_gaussian(double, double)’:
basic/prob-utils.cc:8:37: error: ‘M_PI’ was not declared in this scope
double z = sqrt(-2log(x1))cos(2M_PIx2);
^~~~
make: *** [Makefile:13: basic/prob-utils.o] Error 1

Can you guide in this regard?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions