public static double getSimNaive(ItemNode a, ItemNode b) {
		double d = 0, m1 = 0, m2 = 0;
		Iterator<RateNode> it1 = a.getVector().iterator();
		Iterator<RateNode> it2 = b.getVector().iterator();
		RateNode t1 = null, t2 = null;
		while(it1.hasNext() && it2.hasNext()) {
			if (t1 == null) {
				t1 = it1.next();
				t2 = it2.next();
			} else if (t1.getUserID() > t2.getUserID()) {
				t2 = it2.next();
			} else if (t1.getUserID() < t2.getUserID()) {
				t1 = it1.next();
			} else if (t1.getUserID() == t2.getUserID()) {
				d += t1.getRate() * t2.getRate();
				m1 += t1.getRate() * t1.getRate();
				m2 += t2.getRate() * t2.getRate();
				t1 = it1.next();
				t2 = it2.next();
			}
		}
		if (m1 == 0 || m2 == 0) return 0;
		return d / (Math.sqrt(m1) * Math.sqrt(m2));
	}