本文整理了Java中org.apache.commons.math3.special.Gamma.invGamma1pm1()
方法的一些代码示例,展示了Gamma.invGamma1pm1()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Gamma.invGamma1pm1()
方法的具体详情如下:
包路径:org.apache.commons.math3.special.Gamma
类名称:Gamma
方法名:invGamma1pm1
[英]Returns the value of 1 / Γ(1 + x) - 1 for -0.5 ≤ x ≤ 1.5. This implementation is based on the double precision implementation in the NSWC Library of Mathematics Subroutines, DGAM1.
[中]返回-0.5的值1/Γ(1+x)-1≤ 十、≤ 1.5. 此实现基于NSWC数学子程序库,DGAM1中的双精度实现。
代码示例来源:origin: org.apache.commons/commons-math3
/**
* Returns the value of log Γ(1 + x) for -0.5 ≤ x ≤ 1.5.
* This implementation is based on the double precision implementation in
* the <em>NSWC Library of Mathematics Subroutines</em>, {@code DGMLN1}.
*
* @param x Argument.
* @return The value of {@code log(Gamma(1 + x))}.
* @throws NumberIsTooSmallException if {@code x < -0.5}.
* @throws NumberIsTooLargeException if {@code x > 1.5}.
* @since 3.1
*/
public static double logGamma1p(final double x)
throws NumberIsTooSmallException, NumberIsTooLargeException {
if (x < -0.5) {
throw new NumberIsTooSmallException(x, -0.5, true);
}
if (x > 1.5) {
throw new NumberIsTooLargeException(x, 1.5, true);
}
return -FastMath.log1p(invGamma1pm1(x));
}
代码示例来源:origin: org.apache.commons/commons-math3
prod *= t;
ret = prod / (1.0 + invGamma1pm1(t - 1.0));
} else {
prod *= t;
ret = 1.0 / (prod * (1.0 + invGamma1pm1(t)));
代码示例来源:origin: geogebra/geogebra
prod *= t;
ret = prod / (1.0 + invGamma1pm1(t - 1.0));
} else {
prod *= t;
ret = 1.0 / (prod * (1.0 + invGamma1pm1(t)));
代码示例来源:origin: geogebra/geogebra
/**
* Returns the value of log Γ(1 + x) for -0.5 ≤ x ≤ 1.5.
* This implementation is based on the double precision implementation in
* the <em>NSWC Library of Mathematics Subroutines</em>, {@code DGMLN1}.
*
* @param x Argument.
* @return The value of {@code log(Gamma(1 + x))}.
* @throws NumberIsTooSmallException if {@code x < -0.5}.
* @throws NumberIsTooLargeException if {@code x > 1.5}.
* @since 3.1
*/
public static double logGamma1p(final double x)
throws NumberIsTooSmallException, NumberIsTooLargeException {
if (x < -0.5) {
throw new NumberIsTooSmallException(x, -0.5, true);
}
if (x > 1.5) {
throw new NumberIsTooLargeException(x, 1.5, true);
}
return -Math.log1p(invGamma1pm1(x));
}
代码示例来源:origin: io.virtdata/virtdata-lib-realer
/**
* Returns the value of log Γ(1 + x) for -0.5 ≤ x ≤ 1.5.
* This implementation is based on the double precision implementation in
* the <em>NSWC Library of Mathematics Subroutines</em>, {@code DGMLN1}.
*
* @param x Argument.
* @return The value of {@code log(Gamma(1 + x))}.
* @throws NumberIsTooSmallException if {@code x < -0.5}.
* @throws NumberIsTooLargeException if {@code x > 1.5}.
* @since 3.1
*/
public static double logGamma1p(final double x)
throws NumberIsTooSmallException, NumberIsTooLargeException {
if (x < -0.5) {
throw new NumberIsTooSmallException(x, -0.5, true);
}
if (x > 1.5) {
throw new NumberIsTooLargeException(x, 1.5, true);
}
return -FastMath.log1p(invGamma1pm1(x));
}
代码示例来源:origin: io.virtdata/virtdata-lib-realer
prod *= t;
ret = prod / (1.0 + invGamma1pm1(t - 1.0));
} else {
prod *= t;
ret = 1.0 / (prod * (1.0 + invGamma1pm1(t)));
内容来源于网络,如有侵权,请联系作者删除!