Another issue arising from the tighter type checking. I have fixed the issue in the branch, again I rebased the branch so you cannot just git pull it (sorry). Also you will now need to change PETSC_NULL_OBJECT with PETSC_NULL_MAT for the second
ZjQcmQRYFpfptBannerStart
This Message Is From an External Sender
This message came from outside your organization.
 
ZjQcmQRYFpfptBannerEnd
  Another issue arising from the tighter type checking. I have fixed the issue in the branch, again I rebased the branch so you cannot just git pull it (sorry).

  Also you will now need to change PETSC_NULL_OBJECT with PETSC_NULL_MAT for the second matrix argument for SNESGetJacobian().

   Barry


> On Jun 26, 2024, at 12:49 AM, Adrian Croucher <a.crouc...@auckland.ac.nz> wrote:
> 
> 
> On 24/06/24 1:39 pm, Adrian Croucher wrote:
>> 
>> If this kind of usage is no longer going to be supported I may be able to change it to something more like what ex1f.F90 does. My SNES_Jacobian() is basically just a wrapper for SNESComputeJacobianDefaultColor() now - I think it may have had some other things in it once but it doesn't now. However, this issue might cause trouble for other people as well.
> 
> I've just been experimenting with altering my code so that the SNESSetJacobian() works the same as in snes/tests/ex1f.F90, i.e. using something like:
> 
> call SNESSetJacobian(solver, J, J, SNESComputeJacobianDefaultColor, fd_coloring, ierr)
> 
> instead of using a custom Jacobian routine that calls SNESComputeJacobianDefaultColor(). That seems to build ok using your PETSc branch and I don't get a runtime error calling SNESComputeJacobianDefaultColor().
> 
> However I get one when another part of the code subsequently calls SNESGetJacobian(). I call it like this:
> 
> call SNESGetJacobian(solver, J, PETSC_NULL_MAT, PETSC_NULL_FUNCTION, &
>          PETSC_NULL_INTEGER, ierr)
> 
> and the error is below. This has worked up until now- is there something wrong with it?
> 
> I tried putting a similar line into snes/tests/ex1f.F90 and it gets the same error.
> 
> - Adrian
> 
> [0]PETSC ERROR: Corrupt argument: https://urldefense.us/v3/__https://petsc.org/release/faq/*valgrind__;Iw!!G_uCfscf7eWS!b1Gx5q-NMarPE0nExBMOr0s4mG_Z0OJaWf6V7NyRuywDwA4IJ75v2lgJRkc-mbZbytwXA1WY28Bf_8usFwBOWg$
> [0]PETSC ERROR: Fortran callback Id invalid
> [0]PETSC ERROR: See https://urldefense.us/v3/__https://petsc.org/release/faq/__;!!G_uCfscf7eWS!b1Gx5q-NMarPE0nExBMOr0s4mG_Z0OJaWf6V7NyRuywDwA4IJ75v2lgJRkc-mbZbytwXA1WY28Bf_8uqReGPEw$ for trouble shooting.
> [0]PETSC ERROR: Petsc Development GIT revision: v3.21.2-274-g55d8e0067c3  GIT Date: 2024-06-20 10:02:08 -0400
> [0]PETSC ERROR: /home/acro018/software/geothermal/waiwera/code/testing-debug-PETSc-main-barry/timestepper_test with PETSC_ARCH main-debug-barry on EN438880 by acro018 Wed Jun 26 16:30:51 2024
> [0]PETSC ERROR: Configure options: --with-x --download-hdf5 --download-zlib --download-netcdf --download-pnetcdf --download-exodusii --download-triangle --download-ptscotch --download-chaco --download-hypre
> [0]PETSC ERROR: #1 PetscObjectGetFortranCallback() at /home/acro018/software/PETSc/code/src/sys/objects/inherit.c:316
> [0]PETSC ERROR: #2 ../src/timestepper.F90:610
> 
> -- 
> Dr Adrian Croucher
> Senior Research Fellow
> Department of Engineering Science
> Waipapa Taumata Rau / University of Auckland, New Zealand
> email: a.crouc...@auckland.ac.nz
> tel: +64 (0)9 923 4611
> 

Reply via email to