Here you can find the source of divide(Vector
public static Vector<BigDecimal> divide(Vector<BigDecimal> v, BigDecimal magnitude)
//package com.java2s; //License from project: Open Source License import java.math.BigDecimal; import java.math.MathContext; import java.util.Vector; public class Main { public static Vector<BigDecimal> divide(Vector<BigDecimal> v, BigDecimal magnitude) { Vector<BigDecimal> c = (Vector<BigDecimal>) v.clone(); for (int i = 0; i < c.size(); i++) { c.set(i, c.elementAt(i).divide(magnitude, MathContext.DECIMAL128)); }/*from w w w . ja v a 2 s .c o m*/ return c; } }