Liebe Gitlab-Nutzer, lieber Gitlab-Nutzer, es ist nun möglich sich mittels des ZIH-Logins/LDAP an unserem Dienst anzumelden. Die Konto der externen Nutzer:innen sind über den Reiter "Standard" erreichbar. Die Administratoren

Dear Gitlab user, it is now possible to log in to our service using the ZIH login/LDAP. The accounts of external users can be accessed via the "Standard" tab. The administrators

Commit ec36d60d authored by Thomas Witkowski's avatar Thomas Witkowski
Browse files

Changed augmented coarse grid problem to its transpose.

parent bc23a38c
......@@ -2036,7 +2036,29 @@ namespace AMDiS {
VecAXPY(tmp_primal0, -1.0, tmp_primal1);
}
KSPSolve(ksp_schur_primal, tmp_primal0, tmp_primal0);
if (augmentedLagrange == false) {
KSPSolve(ksp_schur_primal, tmp_primal0, tmp_primal0);
} else {
Vec tmp_mu;
MatGetVecs(mat_augmented_lagrange, PETSC_NULL, &tmp_mu);
MatMult(mat_lagrange, tmp_b1, tmp_lagrange);
MatMult(mat_augmented_lagrange, tmp_lagrange, tmp_mu);
VecScale(tmp_mu, -1.0);
Vec vec_array[2] = {tmp_primal0, tmp_mu};
Vec vec_nest;
VecCreateNest(PETSC_COMM_WORLD, 2, PETSC_NULL, vec_array, &vec_nest);
KSPSolve(ksp_schur_primal, vec_nest, vec_nest);
MatMultTranspose(mat_augmented_lagrange, tmp_mu, tmp_lagrange);
MatMultTranspose(mat_lagrange, tmp_lagrange, tmp_b1);
VecAXPY(tmp_b0, -1.0, tmp_b1);
VecDestroy(&tmp_mu);
VecDestroy(&vec_nest);
}
// === Solve for u_b. ===
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment