Add vector methods to fix #2431 and move functions for general matrices to dense.jl from factorizations.jl.