32#if defined(__cpp_lib_gcd_lcm) || !defined(NUMCPP_NO_USE_BOOST)
37#ifndef NUMCPP_NO_USE_BOOST
38#include "boost/integer/common_factor_rt.hpp"
55 template<
typename dtype>
56 dtype
gcd(dtype inValue1, dtype inValue2)
noexcept
60#ifdef __cpp_lib_gcd_lcm
61 return std::gcd(inValue1, inValue2);
63 return boost::integer::gcd(inValue1, inValue2);
67#ifndef NUMCPP_NO_USE_BOOST
79 template<
typename dtype>
83 return boost::integer::gcd_range(inArray.
cbegin(), inArray.
cend()).first;
#define STATIC_ASSERT_INTEGER(dtype)
Definition StaticAsserts.hpp:43
Holds 1D and 2D arrays, the main work horse of the NumCpp library.
Definition NdArrayCore.hpp:135
const_iterator cbegin() const noexcept
Definition NdArrayCore.hpp:1361
const_iterator cend() const noexcept
Definition NdArrayCore.hpp:1669
Definition Cartesian.hpp:39
dtype gcd(dtype inValue1, dtype inValue2) noexcept
Definition gcd.hpp:56