big speedup after algorithm change. Still slower than J for large matrices