Here you can find the source of toDouble(int[] array)
public static double[] toDouble(int[] array)
//package com.java2s; public class Main { /**/*from w ww.j a v a 2 s.co m*/ * Casts to a double array */ public static double[] toDouble(float[] a) { double[] d = new double[a.length]; for (int i = 0; i < a.length; i++) { d[i] = a[i]; } return d; } /** * Casts to a double array. */ public static double[] toDouble(int[] array) { double[] rv = new double[array.length]; for (int i = 0; i < array.length; i++) { rv[i] = array[i]; } return rv; } }