Home
last modified time | relevance | path

Searched refs:multiply (Results 1 – 14 of 14) sorted by relevance

/libcore/luni/src/main/java/java/math/
DMultiplication.java77 bigFivePows[i] = bigFivePows[i - 1].multiply(bigFivePows[1]);
78 bigTenPows[i] = bigTenPows[i - 1].multiply(BigInteger.TEN);
108 : val.multiply(powerOf10(exp))); in multiplyByTenPow()
150 res = res.multiply(powerOfFive); in powerOf10()
153 res = res.multiply(bigFivePows[1].pow(intExp)); in powerOf10()
182 return val.multiply(bigFivePows[exp]); in multiplyByFivePow()
184 return val.multiply(bigFivePows[1].pow(exp)); in multiplyByFivePow()
DBigDecimal.java932 public BigDecimal multiply(BigDecimal multiplicand) { in multiply() method in BigDecimal
943 return new BigDecimal(this.getUnscaledValue().multiply( in multiply()
960 public BigDecimal multiply(BigDecimal multiplicand, MathContext mc) { in multiply() method in BigDecimal
961 BigDecimal result = multiply(multiplicand); in multiply()
1291 quotAndRem[0] = getUnscaledValue().multiply( Multiplication.powerOf10(trailingZeros) ); in divide()
1301 integerQuot = integerQuot.multiply(BigInteger.TEN) in divide()
1361 … integralValue = getUnscaledValue().divide( divisor.getUnscaledValue().multiply(powerOfTen) ); in divideToIntegralValue()
1362 integralValue = integralValue.multiply(powerOfTen); in divideToIntegralValue()
1365 … integralValue = getUnscaledValue().multiply(powerOfTen).divide( divisor.getUnscaledValue() ); in divideToIntegralValue()
1432 divisor.getUnscaledValue().multiply(Multiplication.powerOf10(diffScale)) ); in divideToIntegralValue()
[all …]
DBigInteger.java894 public BigInteger multiply(BigInteger value) { in multiply() method in BigInteger
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/math/
DBigIntegerMultiplyTest.java42 BigInteger result = aNumber.multiply(bNumber); in testCase1()
63 BigInteger result = aNumber.multiply(bNumber); in testCase2()
85 BigInteger result = aNumber.multiply(bNumber); in testCase3()
107 BigInteger result = aNumber.multiply(bNumber); in testCase4()
130 BigInteger result = aNumber.multiply(bNumber); in testCase5()
153 BigInteger result = aNumber.multiply(bNumber); in testCase6()
173 BigInteger result = aNumber.multiply(bNumber); in testCase7()
191 BigInteger result = aNumber.multiply(bNumber); in testCase8()
209 BigInteger result = aNumber.multiply(bNumber); in testCase9()
227 BigInteger result = aNumber.multiply(bNumber); in testCase10()
[all …]
DBigIntegerTest.java195 bi = BigInteger.valueOf(rand.nextInt(1000000)).multiply( in test_isProbablePrimeI()
203 bi = new BigInteger(70, rand).multiply(new BigInteger(70, rand)); in test_isProbablePrimeI()
359 .multiply(two.pow(40)).equals(twoToTheSeventy)); in test_powI()
376 + " equals " + inv, one.equals(a.multiply(inv).mod( in test_modInverseLjava_math_BigInteger()
397 + " equals " + inv, one.equals(a.multiply(inv).mod( in test_modInverseLjava_math_BigInteger()
498 assertTrue("<<1 == *2", b.multiply(two).equals(a)); in test_shiftLeftI()
505 assertTrue("<<1 == *2 negative", d.multiply(two).equals(c)); in test_shiftLeftI()
517 aZillion.multiply(new BigInteger("3", 10)))); in test_multiplyLjava_math_BigInteger()
519 assertTrue("0*0", zero.multiply(zero).equals(zero)); in test_multiplyLjava_math_BigInteger()
520 assertTrue("0*1", zero.multiply(one).equals(zero)); in test_multiplyLjava_math_BigInteger()
[all …]
DOldBigIntegerTest.java147 bi = BigInteger.valueOf(rand.nextInt(1000000)).multiply( in test_isProbablePrimeI()
155 bi = new BigInteger(70, rand).multiply(new BigInteger(70, rand)); in test_isProbablePrimeI()
179 BigInteger c = a.multiply(b); in test_isProbablePrimeI()
205 BigInteger wp = a.multiply(b); in largePrimesProduct()
DBigIntegerHashCodeTest.java43 aNumber1.multiply(aNumber2).toByteArray(); in testSameObject()
DBigDecimalTest.java506 BigDecimal result = multi1.multiply(multi2); in test_multiplyLjava_math_BigDecimal()
512 result = multi1.multiply(multi2); in test_multiplyLjava_math_BigDecimal()
518 result = multi1.multiply(multi2); in test_multiplyLjava_math_BigDecimal()
524 result = multi1.multiply(multi2); in test_multiplyLjava_math_BigDecimal()
529 result = multi1.multiply(multi2); in test_multiplyLjava_math_BigDecimal()
DBigDecimalArithmeticTest.java307 BigDecimal result = aNumber.multiply(bNumber); in testMultiplyScalePosPos()
325 BigDecimal result = aNumber.multiply(bNumber, mc); in testMultiplyMathContextScalePosPos()
342 BigDecimal result = aNumber.multiply(bNumber); in testMultiplyEqualScaleNegNeg()
359 BigDecimal result = aNumber.multiply(bNumber); in testMultiplyDiffScalePosNeg()
377 BigDecimal result = aNumber.multiply(bNumber, mc); in testMultiplyMathContextDiffScalePosNeg()
394 BigDecimal result = aNumber.multiply(bNumber); in testMultiplyDiffScaleNegPos()
412 BigDecimal result = aNumber.multiply(bNumber, mc); in testMultiplyMathContextDiffScaleNegPos()
DBigDecimalCompareTest.java508 BigDecimal testInstance = BigDecimal.TEN.multiply(new BigDecimal("0.1")); in testApproxPrecision()
/libcore/luni/src/main/java/javax/xml/datatype/
DDuration.java633 public Duration multiply(int factor) { in multiply() method in Duration
634 return multiply(BigDecimal.valueOf(factor)); in multiply()
684 public abstract Duration multiply(final BigDecimal factor); in multiply() method in Duration
/libcore/benchmarks/src/benchmarks/regression/
DBigIntegerBenchmark.java48 x.multiply(y); in timeRandomMultiplication()
/libcore/luni/src/test/java/libcore/java/math/
DBigDecimalTest.java71 BigDecimal b = a.multiply(BigDecimal.ONE); in testPrecisionFromString()
DOldBigDecimalArithmeticTest.java83 res = a.round(mc).multiply(b.round(mc)); in testMultiplyMathContextNonTrivial()
87 res = a.multiply(b, mc); in testMultiplyMathContextNonTrivial()
346 res = a.multiply(b); in testDivideToIntegralValueMathContextNonTrivial()