From cd841acc7b5b3eef92b10735572fc5cf383eb97f Mon Sep 17 00:00:00 2001 From: Danny Robson Date: Tue, 30 Jun 2015 22:02:39 +1000 Subject: [PATCH] maths: style --- maths.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/maths.hpp b/maths.hpp index dea45d54..94991d72 100644 --- a/maths.hpp +++ b/maths.hpp @@ -221,10 +221,13 @@ factorial [[gnu::pure]] (unsigned i) } +/// stirlings approximation of factorials constexpr uintmax_t stirling [[gnu::pure]] (unsigned n) { - return static_cast (std::sqrt (2 * PI * n) * std::pow (n / E, n)); + return static_cast ( + std::sqrt (2 * PI * n) * std::pow (n / E, n) + ); }