Java BigDecimal from toBigDecimal(double[][] a)

Here you can find the source of toBigDecimal(double[][] a)

Description

to Big Decimal

License

LGPL

Declaration

private static BigDecimal[][] toBigDecimal(double[][] a) 

Method Source Code

//package com.java2s;
//License from project: LGPL 

import java.math.BigDecimal;

public class Main {
    private static BigDecimal[][] toBigDecimal(double[][] a) {
        int n = a.length;
        BigDecimal[][] b = new BigDecimal[n][n];
        for (int i = 0; i < n; i++) {
            for (int j = 0; j < n; j++) {
                b[i][j] = BigDecimal.valueOf(a[i][j]);
            }/*  ww  w . ja v  a 2  s  .  co  m*/
        }
        return b;
    }
}

Related

  1. numberToBigDecimal(Object obj)
  2. toBigDecimal(byte[] bytes)
  3. toBigDecimal(Double d)
  4. toBigDecimal(Double d)
  5. toBigDecimal(double val)
  6. toBigDecimal(final byte value)
  7. toBigDecimal(final Double d)
  8. toBigDecimal(final Number n)
  9. toBigDecimal(final Number number)