[petsc-users] using '-snes_type test' to test my coded Jacobian

Zou (Non-US), Ling ling.zou at inl.gov
Wed Sep 5 12:24:34 CDT 2012


Dear All,

I am trying to use the option '-snes_type test' to test my coded
Jacobian. I tested with different snes options and it gives me
different answers. I wonder if someone could give me a hint what is
wrong with my settings.

The command line looks like this:
./my-code-opt -i test.i -snes_type test -snes_test_display

1), when using 'petsc_option = -snes' in my input file, it says the
Finite difference Jacobian is very different than the Hand-coded
Jacobian
2), when using 'petsc_option = -snes_fd' in my input file, it says the
Finite difference Jacobian is idential to the Hand-coded Jacobian
3), when using 'petsc_option = -snes_mf_operator', it gives error messages like:
"Invalid argument! Cannot test with alternative preconditioner!"

Thanks in advance.

Ling


More information about the petsc-users mailing list