mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Initial implementation of igamma and igammac.
This commit is contained in:
@@ -116,6 +116,24 @@ double2 perfc<double2>(const double2& a)
|
||||
return make_double2(erfc(a.x), erfc(a.y));
|
||||
}
|
||||
|
||||
template<> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
|
||||
float4 pigamma<float4>(const float4& a, const float4& x)
|
||||
{
|
||||
using numext::pigamma;
|
||||
return make_float4(
|
||||
pigamma(a.x, x.x),
|
||||
pigamma(a.y, x.y),
|
||||
pigamma(a.z, x.z),
|
||||
pigamma(a.w, x.w));
|
||||
}
|
||||
|
||||
template<> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
|
||||
double2 pigammac<double2>(const double2& a, const double& x)
|
||||
{
|
||||
using numext::pigammac;
|
||||
return make_double2(pigammac(a.x, x.x), pigammac(a.y, x.y));
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -43,6 +43,8 @@ template<> struct packet_traits<float> : default_packet_traits
|
||||
HasDiGamma = 1,
|
||||
HasErf = 1,
|
||||
HasErfc = 1,
|
||||
HasIgamma = 1,
|
||||
HasIGammac = 1,
|
||||
|
||||
HasBlend = 0,
|
||||
};
|
||||
@@ -67,6 +69,8 @@ template<> struct packet_traits<double> : default_packet_traits
|
||||
HasDiGamma = 1,
|
||||
HasErf = 1,
|
||||
HasErfc = 1,
|
||||
HasIGamma = 1,
|
||||
HasIGammac = 1,
|
||||
|
||||
HasBlend = 0,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user