Take most any example, say in src/ts/examples/tutorials/, and run with -ts_type beuler -snes_mf
The -snes_mf says to run the nonlinear solver (Newton by default) with an unpreconditioned Krylov method for which the action of the Jacobian is given by matrix-free finite differencing of the residual (which is nonlinear when the dynamical system is). Yuyun Yang <[email protected]> writes: > Hello team, > > I wanted to apply the Krylov subspace method to a matrix-free implementation > of a stencil, such that the iterative method acts on the operation without > ever constructing the matrix explicitly (for example, when doing backward > Euler). > > I'm not sure whether there is already an example for that somewhere. If so, > could you point me to a relevant example? > > Thank you! > > Best regards, > Yuyun
