Changed array to double