Why is the error of gradient of solution of Poisson/0-Hodge-Laplace equation so large? #4800
-
|
I solved a Poisson equation on a unit sphere. The codes are as follows: It solves 0-Hodge-Laplace equation on surfaces.from firedrake import * mesh & coordinatesmesh = UnitIcosahedralSphereMesh(refinement_level=5) functionsF = FunctionSpace(mesh, "CG", 1) u = TrialFunction(F) source termf = Function(F) variational formulationa = (inner(grad(u), grad(v))) * dx solving systemnullspace = VectorSpaceBasis(constant=True) true solution & erroru_ = Function(F) error = sqrt(assemble(dot(u - u_, u - u_) * dx))/sqrt(assemble(dot(u_, u_) * dx)) du = Function(V) The error of the solution is good. But the error of the gradient is not as small as expected. What's wrong? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
Sorry, the true solution is wrong.... |
Beta Was this translation helpful? Give feedback.
Sorry, the true solution is wrong....