diff --git a/Source/lsmrBase.cxx b/Source/lsmrBase.cxx index 6306d8c..88758c8 100755 --- a/Source/lsmrBase.cxx +++ b/Source/lsmrBase.cxx @@ -321,6 +321,8 @@ Solve( unsigned int m, unsigned int n, const double * b, double * x ) std::copy( b, b+m, u ); std::fill( v, v+n, zero); std::fill( w, v+n, zero); + std::fill( x, x+n, zero); + this->Scale( m, (-1.0), u ); this->Aprod1( m, n, x, u ); this->Scale( m, (-1.0), u );