Java BigDecimal Power decimalPow(BigDecimal number, BigDecimal power)

Here you can find the source of decimalPow(BigDecimal number, BigDecimal power)

Description

Pow for two decimals

License

Open Source License

Declaration

public static BigDecimal decimalPow(BigDecimal number, BigDecimal power) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.math.BigDecimal;

public class Main {
    /**/*from w w w .j  a  v a  2  s  . com*/
     * Pow for two decimals
     */
    public static BigDecimal decimalPow(BigDecimal number, BigDecimal power) {
        return new BigDecimal(Math.pow(number.doubleValue(), power.doubleValue()));
    }
}

Related

  1. pow(BigDecimal arg0, BigDecimal arg1)
  2. pow(BigDecimal b, int p, int q)
  3. pow(BigDecimal base, BigDecimal exponent)
  4. pow(BigDecimal base, BigDecimal power)