An algebraic determination of closed orientable 3-manifolds