Dear developers,<br><br>In my code, the function "residual" used in SNESSetFunction() for calculating Nonlinear function is a member of a class called "solver". When compiling with Petsc, I received the error:<br>
<br>error: argument of type ‘PetscErrorCode (solver::)(_p_SNES*, _p_Vec*, _p_Vec*, void*)’ does not match ‘PetscErrorCode (*)(_p_SNES*, _p_Vec*, _p_Vec*, void*)’<br><br>How can I access that class member function is SNESSetFunction()?<br>
I need to keep my code structure as before.<br><br>Thanks, BB.<br>