Skip to content
Snippets Groups Projects
Commit 0026ef4b authored by Elias Pipping's avatar Elias Pipping Committed by pipping
Browse files

Whitespace

[[Imported from SVN: r11715]]
parent 29fb4de1
Branches
Tags
No related merge requests found
......@@ -81,25 +81,25 @@ void CGSolver<MatrixType, VectorType>::solve()
// Perform one iteration step
// minimize in given search direction p
matrix_->mv(p,q); // q=Ap
alpha = p*q; // scalar product
lambda = rholast/alpha; // minimization
x_->axpy(lambda,p); // update solution
rhs_->axpy(-lambda,q); // update defect
matrix_->mv(p,q); // q=Ap
alpha = p*q; // scalar product
lambda = rholast/alpha; // minimization
x_->axpy(lambda,p); // update solution
rhs_->axpy(-lambda,q); // update defect
// determine new search direction
q = 0; // clear correction
q = 0; // clear correction
// apply preconditioner
// apply preconditioner
preconditioner_->setProblem(*matrix_,q,b);
preconditioner_->iterate();
q = preconditioner_->getSol();
rho = q*b; // orthogonalization
beta = rho/rholast; // scaling factor
p *= beta; // scale old search direction
p += q; // orthogonalization with correction
rholast = rho; // remember rho for recurrence
rho = q*b; // orthogonalization
beta = rho/rholast; // scaling factor
p *= beta; // scale old search direction
p += q; // orthogonalization with correction
rholast = rho; // remember rho for recurrence
// write iteration to file, if requested
if (this->historyBuffer_!="")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment