Py2Cpp 1.6.7
Loading...
Searching...
No Matches
fractions.hpp File Reference
#include <type_traits>
#include <utility>
Include dependency graph for fractions.hpp:

Go to the source code of this file.

Classes

struct  fun::Fraction< Z >
 Fraction. More...

Namespaces

namespace  fun

Macros

#define CONSTEXPR14   inline

Functions

template<typename T>
CONSTEXPR14 auto fun::abs (const T &a) -> typename std::enable_if< std::is_unsigned< T >::value, T >::type
 Absolute value for unsigned types.
template<typename T>
CONSTEXPR14 auto fun::abs (const T &a) -> typename std::enable_if<!std::is_unsigned< T >::value, T >::type
template<typename Mn>
CONSTEXPR14 auto fun::gcd_recur (const Mn &_m, const Mn &_n) -> Mn
 Greatest common divisor (recursive).
template<typename Mn>
CONSTEXPR14 auto fun::gcd (const Mn &_m, const Mn &_n) -> Mn
 Greatest common divisor.
template<typename Mn>
CONSTEXPR14 auto fun::lcm (const Mn &_m, const Mn &_n) -> Mn
 Least common multiple.

Detailed Description

This is a C++ Library header.

Macro Definition Documentation

◆ CONSTEXPR14

#define CONSTEXPR14   inline