Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Carly
Beginner
153 Views

Undefined RNG method in MKL VSL

Hello,

I have a C++ program that produces random numbers from various distributions. I am using multiple generators: vdRngGaussian, vdRngUniform, etc. The one generator that throws an error upon compilation is the vdRngChiSquare generator.

Here is the error:

main.cpp(31): error: identifier "VSL_RNG_METHOD_CHISQUARE_CHI2GAMMA" is undefined
vdRngChiSquare(VSL_RNG_METHOD_CHISQUARE_CHI2GAMMA, stream, 1, &r, nu);

main.cpp(31): error: identifier "vdRngChiSquare" is undefined
vdRngChiSquare(VSL_RNG_METHOD_CHISQUARE_CHI2GAMMA, stream, 1, &r, nu);

 

I don't see a syntax error in my call to the generator. Any ideas what might be going on here?

Thanks in advance.

Tags (4)
0 Kudos
4 Replies
mecej4
Black Belt
142 Views

The symbolic constant in question is declared in mkl_vsl_defines.h . Did you #include this file, either directly or through one of the other mkl_vsl*.h files?

Gennady_F_Intel
Moderator
130 Views

#include "mkl_vsl.h"

You may check the vdrngchisquare.c example ( mklroot\vslc\source\ ) .

Carly
Beginner
116 Views

Thank you both for your responses. It turns out I am using an outdated version of MKL, and that is why I do not have access to the Chi Square RNG.

Gennady_F_Intel
Moderator
114 Views

You are welcome to contact us with any further questions. 


Reply