Change suggested by "FindBugs".
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1374071 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
02123844e8
commit
acaf4d9caa
|
@ -193,7 +193,7 @@ public class LegendreHighPrecisionRuleFactory extends BaseRuleFactory<BigDecimal
|
|||
weights[idx] = tmp2;
|
||||
}
|
||||
// If "numberOfPoints" is odd, 0 is a root.
|
||||
if (numberOfPoints % 2 == 1) {
|
||||
if (numberOfPoints % 2 != 0) {
|
||||
BigDecimal pmc = BigDecimal.ONE;
|
||||
for (int j = 1; j < numberOfPoints; j += 2) {
|
||||
final BigDecimal b_j = new BigDecimal(j, mContext);
|
||||
|
|
|
@ -129,7 +129,7 @@ public class LegendreRuleFactory extends BaseRuleFactory<Double> {
|
|||
weights[idx] = w;
|
||||
}
|
||||
// If "numberOfPoints" is odd, 0 is a root.
|
||||
if (numberOfPoints % 2 == 1) {
|
||||
if (numberOfPoints % 2 != 0) {
|
||||
double pmc = 1;
|
||||
for (int j = 1; j < numberOfPoints; j += 2) {
|
||||
pmc = -j * pmc / (j + 1);
|
||||
|
|
Loading…
Reference in New Issue