New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

extreme value distribution's mean/std fail for location=0 #139

Closed
jzmaddock opened this Issue Jul 31, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@jzmaddock
Copy link
Collaborator

jzmaddock commented Jul 31, 2018

Extreme value distribution's mean and standard_deviation use both detail::check_scale for location parameter a, which seems wrong, as there's no limitation for location parameter a (besides being finite).

This causes even a standard extreme value distribution to fail:

BOOST_AUTO_TEST_CASE(checkScaleIssueMean)
{
	boost::math::extreme_value_distribution<> G;

	boost::math::mean(G);
}

BOOST_AUTO_TEST_CASE(checkScaleIssueStd)
{
	boost::math::extreme_value_distribution<> G;

	boost::math::standard_deviation(G);
}

with

std::domain_error: Error in function boost::math::mean(const extreme_value_distribution<double>&): Scale parameter is 0, but must be > 0 !

std::domain_error: Error in function boost::math::standard_deviation(const extreme_value

Moved from Trac.

@jzmaddock jzmaddock closed this in d7d6b1a Aug 19, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment