I have implemented a V-Cycle multigrid solver using both a linear defect correction (LDC) and full approximation scheme (FAS).
My problem is the following: Using LDC the residual is reduced by a factor of ~0.03 per cycle. The FAS implementation does converge with a linear factor too, but the factor is only ~0.58. Thus FAS needs about 20 times the number of cycles.
Most of the code is shared, the only difference are the down/up calculations, LDC uses
down: $u_H:=0,\quad b_H:=I_h^H(b_h-L_hu_h)$
up: $u_h:=u_h+I_H^hu_H$
and FAS uses
down: $u_H:=I_h^Hu_h,\quad b_H:=I_h^Hb_h+L_HI_h^Hu_h-I_h^HL_hu_h$
up: $u_h:=u_h+I_H^h(u_H-I_h^Hu_h)$
My test setting is from Brigg's "A Multigrid Tutorial, Second Edition", p. 64, has the analytical solution
$u(x,y)=(x^2-x^4)(y^4-y^2) \quad$ with $x,y\in [0,1]^2$
and the equation is $Lv=\Delta u=:b$ using the typical linear 5-point stencil as the Laplace-Operator $L$. The initial guess is $v=0$.
Changing the test setting, e.g. to the trivial $u(x,y)=0$ using an initial guess of $v=1$ results in nearly the same convergence factors.
Since only the down/up code differs, the LDC results comply with the book and the FAS at least seems to work too, I have no Idea why it is so much slower in the same linear setting.
There is one odd behavior in both LDC and FAS that I cannot explain yet that only happens if the initial guess is bad (e.g. $=0$ but also in my full multigrid experiments where the interpolation to the new fine grid increases the residual from $10^{-15}$ to $10^{-1}$): If I increase to number of post correction relaxations to a very high number such that the solution is solved to machine precision on the coarse grid, it looses nearly all digits when going one step up to the next fine grid.
Since a picture says more than words:
// first cycle, levels 0-4
// DOWN
VCycle top 4, start res_norm 3.676520e+02 // initial residual
VCycle top 4, cycle 0, current 4, res_norm 3.676520e+02
VCycle top 4, cycle 0, current 4, res_norm 1.520312e+02 // relaxed (2 iterations)
VCycle tau_norm 2.148001e+01 (DEBUG calculation)
VCycle top 4, cycle 0, current 3, res_norm 1.049619e+02 // restricted
VCycle top 4, cycle 0, current 3, res_norm 5.050392e+01 // relaxed (2 iterations)
VCycle top 4, cycle 0, current 2, res_norm 3.518764e+01 // restricted
VCycle top 4, cycle 0, current 2, res_norm 1.759372e+01 // relaxed (2 iterations)
VCycle top 4, cycle 0, current 1, res_norm 1.234398e+01 // restricted
VCycle top 4, cycle 0, current 1, res_norm 4.728777e+00 // relaxed (2 iterations)
VCycle top 4, cycle 0, current 0, res_norm 3.343750e+00 // restricted
// coarsest grid
VCycle top 4, cycle 0, current 0, res_norm 0.000000e+00 // solved
// UP
VCycle top 4, cycle 0, current 1, res_norm 3.738426e+00 // prolonged
VCycle top 4, cycle 0, current 1, res_norm 0.000000e+00 // relaxed (many iterations)
VCycle top 4, cycle 0, current 2, res_norm 1.509429e+01 // prolonged (loosing digits)
VCycle top 4, cycle 0, current 2, res_norm 2.512148e-15 // relaxed (many iterations)
VCycle top 4, cycle 0, current 3, res_norm 4.695979e+01 // prolonged (loosing digits)
VCycle top 4, cycle 0, current 3, res_norm 0.000000e+00 // relaxed (many iterations)
VCycle top 4, cycle 0, current 4, res_norm 1.469312e+02 // prolonged (loosing digits)
VCycle top 4, cycle 0, current 4, res_norm 9.172812e-24 // relaxed (many iterations)
I'm not sure if there can be only a few digits gained per cycle or if this indicates an error during the interpolation to the fine grid. If it is the latter case, how can the LDC achieve the by-the-book residual ratios of ~0.03 when using always 2 relaxations?