Skip to content
Snippets Groups Projects
Commit 870f6e7e authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Start from zero again

Since truncation works properly now, this hack is no longer necessary;
it actually does more harm than good
parent 4a3d5ce8
No related branches found
No related tags found
No related merge requests found
...@@ -342,29 +342,6 @@ int main(int argc, char *argv[]) { ...@@ -342,29 +342,6 @@ int main(int argc, char *argv[]) {
MyConvexProblemType myConvexProblem(stiffnessMatrix, MyConvexProblemType myConvexProblem(stiffnessMatrix,
*myGlobalNonlinearity, b4, u4_diff); *myGlobalNonlinearity, b4, u4_diff);
// FIXME: This is sort of nasty
// Choose an initial iterate that is admissable
// and non-zero in as many places as possible
if (run == 1)
for (size_t i = 0; i < ignoreNodes.size(); ++i) {
size_t const count = ignoreNodes[i].count();
if (count == dim)
continue;
if (count == 0) {
u4_diff[i] = 1e-4;
continue;
}
assert(count == 1);
assert(ignoreNodes[i][1]); // Only the y coordinate is allowed to be
// fixed
for (int j = 0; j < dim; ++j)
if (j != 1)
u4_diff[i][j] = 1e-4;
}
MyBlockProblemType myBlockProblem(parset, myConvexProblem); MyBlockProblemType myBlockProblem(parset, myConvexProblem);
multigridStep.setProblem(u4_diff, myBlockProblem); multigridStep.setProblem(u4_diff, myBlockProblem);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment