-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding DMStag functions as well as testing and documentation #119
Conversation
The SNES_ex2b example also illustrates how the automatic differentiation tools of julia (as provided in ForwardDiff.jl) can be employed to automatically generate the jacobian, so only a residual routine is required in this case
* added a few more routines
- DMStagGetCorners
…caused a crash previously)
- added setting coordinates in 1/2/3D
- help comments added - only valid for mpi_comm_self (problem?)
…into feature-DMSTAG * 'feature-DMSTAG' of https://github.com/boriskaus/PETSc.jl: Correction output DOF (taking dim into account) DMStagGetDOF added DMStagCreateCompatibleDMStag added DMStagCreate3d added (+correction description 2d)) DMStagCreate2D added and adapted added DMStageCreate2d # Conflicts: # test/test_dmstag.jl
… from the DMSTAG object
…s in julia style for PetscVec objects, example: X = rand(10) V = PETSc.VecSeq(X) V[1:2] = 2:3; V[9:10] .= 99; V[1:2] = V[8:9] .* V[1:2]
…into feature-DMSTAG * 'feature-DMSTAG' of https://github.com/boriskaus/PETSc.jl: Little git mismanipulation, back again to for_libpetsc Clean up + links Petsc Manual in doc Revert "Corrected typo (for_petsc instead of for_libpetsc))" Fix dependency on SparseArrays Corrected typo (for_petsc instead of for_libpetsc))
So I got most of the work done on my side, and I am starting to fold some of the routines that you all call from I still need to fold in:
Concerning |
Thanks! Yes, putting the |
Some decisions to be discussed: - having a user context associated to the snes structure - the transmission of vectors vs arrays into the formfunction !fn()
All the tests now work. I reverted back on SNES to give back the vectors' pointers to use in the residual function as I thought it would be more explicit to transform it to an array in the personal code rather than the package itself (especially if it's associated to a dm). I also added a user context to the snes structure as it can be useful to carry some information in it. We can discuss those points if you want. All the other changes were fixes. I know there is more changes that could be added but, at this point and knowing @jkozdon is working on an automatically generated wrapper, could we add this to the code and eventually add subsequent pull requests? Enjoy your holiday, in the mean time I'll have a look at the structure |
All tests work fine now so in principle this could be merged now. |
DMStag is intended to work with complex numbers, but some of the tests that I currently have in PETSc (notably in |
That's true I also had troubles with other petsc libraries so I came back to the one we had before in the startup file, maybe we can discuss it Jeremy?
…________________________________
De : Boris Kaus ***@***.***>
Envoyé : mardi 27 juillet 2021 16:58:29
À : JuliaParallel/PETSc.jl
Cc : Berlie, Nicolas; Author
Objet : Re: [JuliaParallel/PETSc.jl] Adding DMStag functions as well as testing and documentation (#119)
All tests work fine now so in principle this could be merged now.
Yet, compared to different parts of the package, we are only doing the test for one PETSc library. Perhaps it is worth adding a loop over libraries here so we test all combinations? I am not sure whether DMSTAG is even supposed to work with complex numbers, though.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#119 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AT5VXZ7WKYPYJNDHWOYSVG3TZ3CRLANCNFSM472I5SAA>.
|
Sure we can discuss next week. I'll be back in the office Monday and can chat then. |
Thanks, I'll have a couple questions on that matter.
Nico
…________________________________
De : Jeremy E Kozdon ***@***.***>
Envoyé : mercredi 28 juillet 2021 04:51:28
À : JuliaParallel/PETSc.jl
Cc : Berlie, Nicolas; Author
Objet : Re: [JuliaParallel/PETSc.jl] Adding DMStag functions as well as testing and documentation (#119)
That's true I also had troubles with other petsc libraries so I came back to the one we had before in the startup file, maybe we can discuss it Jeremy?
Sure we can discuss next week. I'll be back in the office Monday and can chat then.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#119 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AT5VXZ3D6WUBDQZZ7EG6GRTTZ5WDBANCNFSM472I5SAA>.
|
…t to how DMDA was implemented.
…are now within dm.jl. I commented those (for now) and changed a few routines such they have now a similar input/output to their DMDA counterparts. 1D tests are ok now, rest needs to be added
…eper changed in SNES and Mat routines. I'm not sure it makes sense to do that @ this time as @jkozdon has done much of that already in the branch that generates Clang bindings. Therefore I have deactivated testing of most of the DMSTAG examples for now.
PETSc.jl