Here you can find the source of add(Vector
public static Vector<BigDecimal> add(Vector<BigDecimal> a, Vector<BigDecimal> b)
//package com.java2s; //License from project: Open Source License import java.math.BigDecimal; import java.util.Vector; public class Main { /*** ***/ // w ww . j a va 2 s.c o m // TODO: write vector class that incorporates most vector operations public static Vector<BigDecimal> add(Vector<BigDecimal> a, Vector<BigDecimal> b) { int m = a.size(); Vector<BigDecimal> c = new Vector(m); for (int i = 0; i < m; i++) { BigDecimal value = ((BigDecimal) a.elementAt(i)).add((BigDecimal) b.elementAt(i)); c.add(value); } return c; } }