0
我正在嘗試使用Boost 1.5中的Gamma分佈。 現在我想要k和theta的值分別爲4和.5。 但我得到一個編譯錯誤,每當我設置THETA < 1.使用boost設置gamma_distribution的參數
/usr/local/include/boost/random/gamma_distribution.hpp:118: boost::random::gamma_distribution<RealType>::gamma_distribution(const RealType&, const RealType&) [with RealType = double]: Assertion `_beta > result_type(0)' failed.
有什麼辦法來解決相同的價值?
沒有發佈一個小型自包含示例代碼片段,這是很難調試您的問題。 – mavam 2012-08-15 19:22:54