Compare commits

...
Author SHA1 Message Date
Socratis Petrides d322228504 testing dpg residual with cholesky factors 2022-03-22 14:13:56 -07:00
Socratis Petrides 2cc8c18250 fix repo check 2022-03-22 12:08:56 -07:00
Socratis Petrides 44fb213658 Merge branch 'master' into densemat-cholesky 2022-03-22 12:05:57 -07:00
Socratis Petrides 48c54c0bbc fix repo-check 2022-03-22 12:05:22 -07:00
Socratis Petrides aa9a4887f7 change to 2022 2022-03-22 10:24:38 -07:00
Socratis Petrides 757369beb3 Merge branch 'master' into dpg-dev 2022-03-22 10:19:35 -07:00
Tzanio Kolev a1f6902ed7 Merge pull request #2839 from mfem/mfem-4.4-dev
Final changes for mfem-4.4
2022-03-21 16:19:37 -07:00
Veselin Dobrev 9d7684c850 Fix a warning 2022-03-21 14:36:38 -07:00
Veselin Dobrev a7925eeb28 Address 'FIXME' comments in hypre.cpp related to bigint 2022-03-21 14:27:01 -07:00
Tzanio 98f846f006 Small adjustments in CHANGELOG 2022-03-21 12:54:17 -07:00
Veselin Dobrev 72e1c98c39 Remove byte order marks (BOMs) from files 2022-03-21 10:37:51 -07:00
Veselin Dobrev ec9e8fb0b8 In 'make style', include headers in tests/unit, excluding the
Catch2 header.
2022-03-21 10:23:37 -07:00
Tzanio c39ba9381f More small adjustments before the release 2022-03-21 10:16:50 -07:00
Tzanio 370ff589e7 Final small adjustments before the release 2022-03-20 22:57:55 -07:00
Tzanio e7f669a6ad Some fixes for hypre mixedint 2022-03-19 21:57:02 -07:00
Veselin Dobrev 4cbfc173ef Update the version requirement for HYPRE+HIP to 2.23.0 2022-03-18 17:43:53 -07:00
Tzanio Kolev d40ca7db38 Merge pull request #2904 from mfem/yohann/remove-tmp-ir
Remove `tmp` `IntegrationRule` in `SegmentIntegrationRule`.
2022-03-18 17:41:50 -07:00
Tzanio Kolev 69ce7de396 Merge pull request #2903 from mfem/tmop-raja-hip
[TMOP] RAJA & HIP out-of-registers-during-register-allocation error workaround
2022-03-18 12:38:46 -07:00
Yohann Dudouit 7017c2df46 Remove tmp IntegrationRule. 2022-03-18 11:50:07 -07:00
camierjs c678206f42 Workaround to avoid out-of-registers-during-register-allocation error with RAJA & HIP 2022-03-18 11:15:45 -07:00
Tzanio 6d017e33f9 Added const to the arguments of several copy assignments 2022-03-18 08:20:34 -07:00
Tzanio 6c7a00d278 Match versions of HYPRE_Init and HYPRE_Finalize 2022-03-17 20:16:43 -07:00
Ketan Mittal c7c4e7ce3a bugfix hypre version for init and specify ordering in SetCurvature 2022-03-17 18:15:53 -07:00
Veselin Dobrev d06e506644 In class DeviceTensor, remove MFEM_HOST_DEVICE from '= default'
methods to suppress nvcc warnings.
2022-03-17 16:40:15 -07:00
Tzanio 4d282733a5 Merge branch 'master' into mfem-4.4-dev
Conflicts:
	fem/ceed/coefficient.hpp
2022-03-17 16:30:33 -07:00
Tzanio Kolev e7be9bb959 Merge pull request #2569 from mfem/yohann/libceed/091
Update the integration of libCEED to work with current main (libCEEDv0.10).
2022-03-17 16:29:17 -07:00
Tzanio Kolev 987d2e043b Merge pull request #2898 from mfem/bugfix-vecpa
Bug fixes for PA in H(curl)
2022-03-17 16:26:28 -07:00
Veselin Dobrev 6da8389992 In class DeviceTensor, use '= default' for both, the copy
constructor and the copy assignment.
2022-03-17 16:03:47 -07:00
Veselin Dobrev 48a5c3667c Additional changes to support latest libCEED and the upcoming
release, v0.10.

Uses libCEED PR 921 which should be merged soon, before the
v0.10 release.
2022-03-17 12:26:24 -07:00
Dylan Copeland 637849387f Fixing some Smem PA kernels. 2022-03-17 10:33:30 -07:00
Tzanio e8357b8bd5 Bugfix 2022-03-17 07:46:18 -07:00
Tzanio f814dbbbf4 Bugfix 2022-03-16 20:32:51 -07:00
Tzanio cc03f9eecb Merge branch 'master' into mfem-4.4-dev
Conflicts:
	CHANGELOG
	examples/ex10p.cpp
	miniapps/adjoint/adjoint_advection_diffusion.cpp
2022-03-16 20:14:45 -07:00
Tzanio Kolev dccaa399f6 Merge pull request #2648 from mfem/domain-marker-fix
Fix for linear/bilinear form domain integrators with markers
2022-03-16 20:07:00 -07:00
Tzanio Kolev cb92bd3aba Merge pull request #2883 from mfem/yohann/fix-dgtrace
Fix indices of face with in `SmemPADGTraceApply3D` and `SmemPADGTraceApplyTranspose3D`.
2022-03-16 20:06:30 -07:00
Tzanio Kolev c07ade6995 Merge pull request #2873 from mfem/hypre_init-dev
Support HYPRE_Init/Finalize
2022-03-16 20:06:04 -07:00
Tzanio Kolev 28b6d1503d Merge pull request #2895 from mfem/bugfix/mixed-integ-vdim
Changing expected size of gradient [bugfix/mixed-integ-vdim]
2022-03-16 20:05:29 -07:00
Tzanio 39e08e57e0 Fixes from Lassen 2022-03-16 14:38:12 -07:00
Tzanio 247de1cf04 Fixed a bug introduced in 7eb93bfb21 2022-03-16 14:29:57 -07:00
Vladimir Z Tomov 1e111b7fe4 Merge branch 'mfem-4.4-dev' of github.com:mfem/mfem into mfem-4.4-dev 2022-03-16 14:10:01 -07:00
Vladimir Z Tomov 7eb93bfb21 Fixed warning. 2022-03-16 14:09:25 -07:00
Tzanio 4631185065 Fix compiler warnings on Lassen 2022-03-16 14:06:28 -07:00
Tzanio bd8d5ed246 Fix a warning 2022-03-16 13:53:33 -07:00
Dylan Copeland 524aff1156 Fixed some bugs in PA for vector spaces. Generalized PA unit tests to use meshes not aligned with axes. 2022-03-16 13:21:59 -07:00
Ketan Mittal 1ec2c6f18a Update CHANGELOG 2022-03-15 20:57:37 -07:00
Dylan Copeland 8302f4e2bc Small bug fix for a PA kernel. 2022-03-15 19:42:57 -07:00
YohannandVeselin Dobrev b705a3aaa4 reformulates libCEED version requirement.
Co-authored-by: Veselin Dobrev <v-dobrev@users.noreply.github.com>
2022-03-15 17:08:05 -07:00
Tzanio d13d86e642 Adressed a couple of review comments 2022-03-15 15:34:14 -07:00
Stowell, Mark L c41acae99e Changing gradient size in physical space to match space dimension 2022-03-15 14:28:35 -07:00
Stowell, Mark L 8a0987d76e Adding checks which ensure the integration loop can succeed 2022-03-15 14:27:47 -07:00
Tzanio Kolev c0a413804e Merge branch 'master' into hypre_init-dev 2022-03-15 13:15:18 -07:00
Tzanio 786edfdee8 Take out an extra Hypre::Init() in examples/pumi/ex2.cpp 2022-03-15 13:14:26 -07:00
Yohann Dudouit 6fdc847fa3 Update libCEED version requirement. 2022-03-15 12:03:14 -07:00
Yohann Dudouit 4196d3a8e1 Run Convection kernels on CUDA devices. 2022-03-15 11:28:45 -07:00
Tzanio 297e1c1a30 Resolving a number of 'Rule of Two' warnings from LGTM 2022-03-15 10:56:54 -07:00
Tzanio a87b90e1f5 Small LGTM fix 2022-03-15 08:23:29 -07:00
Tzanio dda1dec150 Merge branch 'master' into mfem-4.4-dev
Conflicts:
	CHANGELOG
2022-03-15 08:18:23 -07:00
Tzanio Kolev a8b5004ee9 Merge pull request #2825 from mfem/tmop-surfit-formulation
Update surface fitting formulation
2022-03-15 08:11:26 -07:00
Tzanio 434c90fb14 Resolving LGTM errors 2022-03-14 19:48:56 -07:00
Veselin Dobrev 8e5dcd5c10 Updates to get this branch to work with libCEED/main as
of 2022-03-14.
2022-03-14 17:37:20 -07:00
Veselin Dobrev 270d60019c Merge branch 'master' into yohann/libceed/091 2022-03-14 14:43:12 -07:00
Will Pazner 9e116af874 Merge pull request #2885 from mfem/misc-4.4
Minor miscellaneous fixes for v4.4
2022-03-14 11:56:37 -07:00
Will Pazner ac831d4434 Use MFEM_DOXYGEN_FLAGS instead of MFEM_DOXY_FLAGS 2022-03-14 11:54:34 -07:00
Tzanio eb2594cbad Small final adjustments 2022-03-14 11:24:59 -07:00
Socratis Petrides caa58f05b9 fixing spd check 2022-03-14 11:08:12 -07:00
Socratis Petrides a57df29aac cleanup 2022-03-14 10:57:48 -07:00
Tzanio bd30a776d0 Merge branch 'master' into hypre_init-dev 2022-03-14 10:51:35 -07:00
Tzanio e33570d148 Updated CHANGELOG 2022-03-14 10:46:51 -07:00
Stowell, Mark L f5fb6ef471 Adding using FiniteElement::Project to R1D and R2D classes 2022-03-14 10:40:25 -07:00
Tzanio accf20a2d0 Merge branch 'master' into mfem-4.4-dev 2022-03-14 10:40:14 -07:00
Socratis Petrides 2b5b85596d resolving more conflicts 2022-03-14 10:27:53 -07:00
Socratis Petrides d98d8ea5ea resolving conflicts with master 2022-03-14 10:21:27 -07:00
Ketan Mittal 9c85ca395b fix broken autotest run 2022-03-14 08:43:34 -07:00
Tzanio Kolev d6f752e6e0 Merge pull request #2844 from mfem/lapack-generalized-eig
Lapack generalized eigenvalue systems
2022-03-13 12:29:47 -07:00
Tzanio Kolev 3ed3327364 Merge branch 'master' into tmop-surfit-formulation 2022-03-12 16:28:11 -08:00
Veselin Dobrev 7497e74bc3 Use version number 4.4.0 instead of 4.4 in a couple of
places to be consistent with previous releases.
2022-03-12 15:29:47 -08:00
Will Pazner 23b2d3cec6 plor_solvers miniapp: print device config only once in parallel 2022-03-12 15:29:44 -08:00
Will Pazner 892d896c06 Remove unneeded UseDevice call 2022-03-12 15:29:44 -08:00
Will Pazner cc41ae0cfc Fix branch-history script in case of merge commit with renames 2022-03-12 15:29:44 -08:00
Will Pazner fcc5f5d6f1 Allow command line configuration of Doxygen docs 2022-03-12 15:29:44 -08:00
Veselin Dobrev 0790949263 Fix the FunctionSpace test for RT_WedgeElement 2022-03-12 14:49:04 -08:00
psocratis af4cc0dd50 fix destructor 2022-03-12 11:01:57 -08:00
Will Pazner 778205ec30 Add Hypre::Finalize and check to make sure we don't finalize twice 2022-03-12 09:40:00 -08:00
Socratis Petrides 7c0de58f32 additional unit tests for Cholesky factors 2022-03-11 19:43:00 -08:00
Socratis Petrides 3681dd769d introducing Factors base class for LU and Cholesky factors 2022-03-11 19:42:32 -08:00
Will Pazner 3c80422d66 Small fix 2022-03-11 19:40:33 -08:00
Will Pazner 73ad5ba25d Small fix 2022-03-11 18:07:13 -08:00
Will Pazner 6ac671baa7 Use Mpi class instead of MPI_Init and MPI_Finalize 2022-03-11 17:58:01 -08:00
Will Pazner 4ace41773d Remove Mpi::Session, access directly using static member functions 2022-03-11 15:41:07 -08:00
Tzanio 1cb2839a20 Merge branch 'master' into hypre_init-dev
Conflicts:
	CHANGELOG
2022-03-11 13:43:43 -08:00
Will Pazner 8d812ec8c3 Rename MPI class to Mpi to avoid conflict with (deprecated) C++ MPI namespace 2022-03-11 13:43:14 -08:00
Tzanio Kolev a4504c3c08 Merge pull request #2880 from mfem/bugfix/nd-tri-doftrans-p1
Order 1 DofTransformation bug fix
2022-03-11 12:50:02 -08:00
Veselin Dobrev 50cd7da165 Merge pull request #1989 from mfem/lo-dim-em-dev
Custom basis for 3D HCurl and HDiv in 1D or 2D [lo-dim-em-dev]
2022-03-11 11:58:59 -08:00
Veselin Dobrev 7e9b167dd7 Adjust the FunctionSpace for a few FiniteElements 2022-03-11 11:06:38 -08:00
Yohann Dudouit 3ee4653506 Fix indices of face with MFEM_FORALL_2D. 2022-03-11 10:56:26 -08:00
Veselin Dobrev def8aee025 Merge pull request #2875 from mfem/shadow-macos-dev
Enable -Wshadow for debug build on MacOS
2022-03-11 10:15:42 -08:00
Tzanio Kolev befc4b7b38 Merge pull request #2881 from mfem/osc_sample_runs
Updated sample runs in ex30 to remove warnings
2022-03-11 08:49:18 -08:00
Socratis Petrides b45424c2bb lapack get inverse matrix 2022-03-10 21:06:38 -08:00
Tzanio db49e89346 minor 2022-03-10 15:31:54 -08:00
Keith 1361b99933 removed no-vis and added visualization if statement 2022-03-10 12:51:13 -08:00
Keith 931d7f32e5 updated sample runs to remove warnings 2022-03-10 10:32:26 -08:00
Stowell, Mark L 2ac3b1f12e Return immediately from certain DofTrans methods when no face DoFs are present 2022-03-10 09:48:20 -08:00
Socratis Petrides 795e5b047a cholesky factors w/wo lapack 2022-03-09 20:01:21 -08:00
Vladimir Z Tomov a8f52ff2c2 style 2022-03-09 17:16:28 -08:00
Vladimir Z Tomov e30517a4a7 Minor. 2022-03-09 17:12:06 -08:00
Vladimir Z Tomov 56ed1dffd8 Minor. 2022-03-09 16:26:54 -08:00
Socratis Petrides 8a1e3265bc adding function signatures 2022-03-09 11:23:57 -08:00
camierjs ae3c79a493 Fix mpi sedov w/o device test 2022-03-09 08:53:48 -08:00
Will Pazner 6602fdd255 Remove GlobalMPISession in TMOP unit tests 2022-03-09 08:34:23 -08:00
Veselin Dobrev 3755315939 Fix some additional shadow-variable-warnings 2022-03-09 01:09:34 -08:00
Veselin Dobrev 6643225225 Fix shadow-variable-warnings that are new in this branch 2022-03-09 01:00:29 -08:00
Tzanio 800c12291d Forgot a headher 2022-03-08 19:47:56 -08:00
Tzanio f2cad1e55b MPI_Session -> MPI singleton in examples, miniapps and tests 2022-03-08 19:29:45 -08:00
Tzanio 493f0fd8ce Switch to a singleton MPI class. Keep MPI_Session for backward compatibility. 2022-03-08 18:26:33 -08:00
Tzanio 8f7cb0b3db Switch to a singleton for the hypre session object: 'HYPRE_Session hypre;' -> 'Hypre::Init();' 2022-03-08 18:06:43 -08:00
Stowell, Mark L 603bc1b9b7 Updating changelog and example list documentation 2022-03-08 15:20:41 -08:00
Stowell, Mark L 16c183df36 Adding a few missed vdim vs spaceDim instances 2022-03-08 15:20:05 -08:00
Tzanio f543b5e51d Updates after discussion with hypre team 2022-03-08 13:37:16 -08:00
Stowell, Mark L ebedbb6b90 Changing name of github-action branch 2022-03-08 12:08:01 -08:00
Stowell, Mark L 0e2136f1c1 Fixing shadow variable which appears when MFEM_USE_LAPACK is off 2022-03-08 11:34:23 -08:00
Stowell, Mark L 8af5dcf5a4 Fixing a few missed or new shadow variables 2022-03-08 11:27:09 -08:00
Stowell, Mark L 4a9c90ae09 Changing GitHub workflow to enable -Wshadow for debug build on MacOS 2022-03-08 10:48:29 -08:00
Tzanio 6fa650fef5 Fix some warnings from https://lgtm.com/projects/g/mfem/mfem 2022-03-08 10:26:23 -08:00
Yohann 6c91c63107 Minor. 2022-03-08 10:19:35 -08:00
Yohann 6594a35a9a Add PA and EA DG AMR to CHANGELOG 2022-03-08 10:17:04 -08:00
Tzanio 0f40b6a975 Fix some recommendations from https://lgtm.com/projects/g/mfem/mfem 2022-03-08 09:57:58 -08:00
Will Pazner 3abef6e67c Update CHANGELOG 2022-03-08 08:16:47 -08:00
Tzanio 1378774bef Fix a bug in ParMesh::HasBoundaryElements() 2022-03-07 20:57:29 -08:00
Tzanio a3c6cddab3 Added ├── benchmarks to the source tree in CONTRIBUTING.md 2022-03-07 20:49:37 -08:00
Tzanio 6f0d0a09ab Few changes related to docs.mfem.org 2022-03-07 20:45:05 -08:00
Tzanio 30bec7d06e Organized CHANGELOG for mfem-4.4 2022-03-07 18:55:18 -08:00
Tzanio 5393b1dc34 Version is 4.4 2022-03-07 18:54:33 -08:00
Tzanio c024518633 Merge branch 'master' into mfem-4.4-dev 2022-03-07 18:33:26 -08:00
Tzanio fc7f7d11f4 minor 2022-03-07 18:32:56 -08:00
Ketan Mittal ec331485be minor update to adaptive weight 2022-03-07 17:57:39 -08:00
Tzanio 7fa9f1b221 Check for hypre's version in HYPRE_Session 2022-03-07 14:49:56 -08:00
Tzanio 447f00d80b Added a HYPRE_Session class to hypre.?pp and examples/miniapps 2022-03-07 14:22:22 -08:00
Tzanio Kolev 49213fab85 Merge pull request #2864 from mfem/bugfix/askinner/conduit-mesh-to-blueprint
Conduit Blueprint Bugfix
2022-03-07 14:05:46 -08:00
Tzanio Kolev 34408ebacb Merge pull request #2800 from mfem/rezgar/typo-in-test
Typo in `test_matrix_rectangular.cpp`
2022-03-07 14:02:58 -08:00
Veselin Dobrev e363cc08cb Add new examples to config/sample-runs.sh 2022-03-07 12:34:34 -08:00
Tzanio f866e77660 Merge branch 'master' into mfem-4.4-dev 2022-03-07 12:11:44 -08:00
Tzanio 4744ad2872 Merge branch 'master' into bugfix/askinner/conduit-mesh-to-blueprint 2022-03-04 16:47:34 -08:00
Tzanio ba1d7640f0 Moved HasBoundaryElements() to a virtual method of Mesh/ParMesh 2022-03-04 16:46:41 -08:00
Ketan Mittal b3b3c0f805 reviewer comments 2022-03-04 15:25:37 -08:00
Stowell, Mark L fa8be935c9 Using max of space dim and new vector dim to fix support for ND and RT on surfaces 2022-03-04 13:55:38 -08:00
Vladimir Z Tomov f5265f4a4c Minor. 2022-03-04 11:55:17 -08:00
Stowell, Mark L 8c775bcb25 Reverting VectorFiniteElement constructor and overriding defaults in new classes only 2022-03-03 19:06:06 -08:00
Socratis Petrides 6967342813 minor 2022-03-03 13:06:29 -08:00
Tzanio Kolev baf9090c88 Merge pull request #2861 from mfem/diffusion_pa_ker_revert
Diffusion PA kernel fix [diffusion_pa_ker_revert]
2022-03-03 12:27:32 -08:00
Tzanio Kolev ce3192db6d Merge pull request #2856 from mfem/pa-curl2d
PA for some more H(curl) integrators
2022-03-03 08:23:43 -08:00
Tzanio Kolev a5ed6466f4 Merge pull request #2860 from mfem/minor-correction-test-var-order-convergence
Var-order-transfer-unit-test and non-uniform ConvergenceStudy rates
2022-03-03 08:23:18 -08:00
Dylan Copeland 6ced945849 Documenting that future work is remaining, to optimize the PA kernels. 2022-03-02 15:06:10 -08:00
Tom Stitt 0ab2a5be53 lower MAX_{Q,D}1D for amdhip build 2022-03-02 14:38:24 -08:00
camierjs 986059bcac Move cmath up for WIN32 in tests/unit/fem/test_pa_kernels 2022-03-02 12:01:03 -08:00
camierjs bb5b308b0a Add default integration rules for test_assembly_levels and test_pa_kernels 2022-03-02 11:14:54 -08:00
Aaron Skinner 2ec0f32eda Merge branch 'master' of github.com:mfem/mfem into bugfix/askinner/conduit-mesh-to-blueprint 2022-03-02 09:09:11 -08:00
Aaron Skinner fc4fa7b611 make style 2022-03-02 09:08:24 -08:00
Dylan Copeland da9a167be9 CHANGELOG 2022-03-01 19:33:40 -08:00
Socratis Petrides ba94547c4d fixing residual computation 2022-03-01 19:20:44 -08:00
Tzanio 90a8e7bbf5 Copyright 2022 2022-03-01 17:52:08 -08:00
Tzanio 27e4b547c4 Merge branch 'master' into lo-dim-em-dev 2022-03-01 17:48:01 -08:00
Tzanio 4b09c8a98e Merge branch 'master' into mfem-4.4-dev 2022-03-01 17:46:49 -08:00
Aaron Skinner 21e07b6831 This fixes a bug in ConduitDataCollection::MeshToBlueprintMesh() wherein boundary topology is missing if a rank happens not to have any boundary elements (i.e., is purely internal). First, I cribbed a function from SidreDataCollection to determine whether any rank has any boundary elements (an all-periodic mesh might have none), then I initialized a few geometry-related fields to unimportant data in case there are no boundary elements to use. This technically gives the wrong answer for some ranks, and it assumes all boundary elements are of the same type, but that's probably okay for now since it's never used. 2022-03-01 16:42:27 -08:00
camierjs 4e7c068e01 WIN32 cmath header for tests/unit/fem/test_pa_kernels 2022-03-01 13:42:33 -08:00
Tzanio 2e8f5d366e Merge branch 'master' into pa-curl2d 2022-03-01 12:34:11 -08:00
Yohann Dudouit 1ec268dd78 fix #ifdef name for nlconvection. 2022-03-01 12:24:47 -08:00
camierjs 2d6e0584a6 Merge master in diffusion_pa_ker_revert 2022-03-01 12:01:05 -08:00
camierjs 91580de43a Revert syncs 2022-03-01 11:48:54 -08:00
camierjs bff8b7e295 Add unit tests with qorders 2022-03-01 11:33:24 -08:00
Socratis Petrides c4c4e6950e fixing ConvergenveStudy to support non-uniform rfinements 2022-03-01 11:29:32 -08:00
Socratis Petrides 8efe5c4077 fixing var-order-pref test 2022-03-01 11:29:01 -08:00
camierjs b98568cfb5 Fix bilininteg_diffusion_pa and upgrade tests/unit/fem/test_assembly_levels 2022-03-01 10:51:45 -08:00
Dylan Copeland 43051d1cfa Implementing MixedVectorGradientIntegrator::AddMultTransposePA. 2022-03-01 09:56:11 -08:00
Julian Andrej 3f310ff72b mention new documentation history page in release checklist 2022-03-01 09:52:58 -08:00
Tzanio Kolev 5308d285f7 Merge pull request #2855 from mfem/copyright-2022
Extended copyright to 2022
2022-03-01 07:41:29 -08:00
Tzanio dc4c12e816 Fix a memory leak in AdamsBashforthSolver 2022-02-28 21:43:04 -08:00
Tzanio abd0d30b4f Fix a memory leak in AdamsBashforthSolver 2022-02-28 21:07:23 -08:00
Tzanio af5ff55d74 Merge branch 'master' into mfem-4.4-dev 2022-02-28 20:47:39 -08:00
Dylan Copeland 0c570272c2 Implementing MixedScalarCurlIntegrator::AddMultTransposePA. 2022-02-28 18:57:00 -08:00
Will Pazner a00c82d0aa Merge pull request #2794 from mfem/yohann/device-verify+assert
Add MFEM_VERIFY_KERNEL and MFEM_ASSERT_KERNEL.
2022-02-28 16:35:52 -08:00
Tzanio Kolev 8554fcfa9c Merge pull request #2840 from mfem/yohann/pa-convection-transpose
Add `ConvectionIntegrator::AddMultTransposePA`.
2022-02-28 16:35:31 -08:00
Will Pazner a8387e04bf Merge remote-tracking branch 'origin/master' into yohann/device-verify+assert
# Conflicts:
#	fem/restriction.cpp
2022-02-28 12:21:59 -08:00
Will Pazner 5fe211e3ae Merge pull request #2738 from mfem/shadow-mesh-dev
Fixing shadow variables in mesh classes [shadow-mesh-dev]
2022-02-28 12:12:51 -08:00
Stowell, Mark L ac002e7ca3 make style 2022-02-28 09:55:53 -08:00
Stowell, Mark L aa8c181706 Specifying vector and curl dimensions in new wedge elements 2022-02-28 09:55:40 -08:00
Stowell, Mark L 5fa73ccc17 Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	fem/bilininteg.cpp
#	fem/fe/fe_base.hpp
#	fem/fe/fe_nd.cpp
#	fem/fe/fe_nd.hpp
#	fem/fe/fe_rt.cpp
#	fem/fe/fe_rt.hpp
2022-02-28 09:49:07 -08:00
Yohann Dudouit 5de22c21f9 Add early return when nf==0. 2022-02-25 17:54:47 -08:00
Socratis Petrides 58f7aacce9 fix acoustics graph norm 2022-02-25 17:45:49 -08:00
Yohann Dudouit 8e164f52c7 Test MultTranspose. 2022-02-25 16:22:59 -08:00
Yohann Dudouit 8b2fe2be41 Fix a potential bug in EABilinearFormExtension::MultTranspose
When using libCEED `useRestrict` was evaluated to the wrong value.
2022-02-25 16:22:25 -08:00
Yohann Dudouit f2da5e3675 Add getString for AssemblyLevel. 2022-02-25 16:04:01 -08:00
Yohann Dudouit df2cb518d0 Fix a bug in EABilinearFormExtension::MultTranspose.
The "face" blocks were not inverted when transposing.
2022-02-25 16:03:01 -08:00
Yohann Dudouit 50aa3d7a94 Simplify test_pa_kernels.cpp. 2022-02-25 14:41:12 -08:00
Yohann Dudouit 94a1400dc7 Remove dg in H1 tests. 2022-02-25 14:36:03 -08:00
Yohann Dudouit 2ead91a68e Clean test_assembly_levels.cpp. 2022-02-25 14:30:18 -08:00
Yohann Dudouit 6f50866137 Reorganize test_assembly_levels.cpp.
Add tests for DG Element Assembly on NCMesh.
2022-02-25 14:10:31 -08:00
Yohann Dudouit 9d4515319b Modify factorize_face_terms to make DG EA work with NCMesh. 2022-02-25 13:53:03 -08:00
Yohann Dudouit e24efa4959 Remove conforming test for EA (it actually works). 2022-02-25 12:58:34 -08:00
Dylan Copeland 24278e18ec Adding support for H1. 2022-02-25 12:27:58 -08:00
Yohann Dudouit a08f805f09 Fix a bug in SmemPAConvectionApply3D and SmemPAConvectionApplyT3D.
These functions were setting `=` instead of adding `+=`.
2022-02-25 12:12:03 -08:00
Yohann Dudouit 4e77bad9dd Last trial_fes->Conforming(). 2022-02-25 11:35:07 -08:00
Yohann Dudouit 985d40a47a faceIntX -> int_face_X , faceIntY -> int_face_Y, faceBdrX -> bdr_face_X, faceBdrY -> bdr_face_Y. 2022-02-25 11:32:58 -08:00
Yohann Dudouit a84b74d625 Use trial_fes->Conforming(). 2022-02-25 11:20:39 -08:00
Yohann Dudouit 7cf4685f2b trialFes -> trial_fes, testFes -> test_fes 2022-02-25 11:20:01 -08:00
Yohann Dudouit 342b03f029 Merge branch 'yohann/pa-convection-transpose' of https://github.com/mfem/mfem into yohann/pa-convection-transpose 2022-02-25 11:05:06 -08:00
Yohann Dudouit 45ac64129e Avoid running tests multiple times... 2022-02-25 11:04:58 -08:00
YohannandWill Pazner 83d741ea38 Update fem/bilinearform.cpp
Co-authored-by: Will Pazner <11493037+pazner@users.noreply.github.com>
2022-02-25 11:02:23 -08:00
Dylan Copeland 1498a50367 Adding PA for (Q curl u, v) in 2D. 2022-02-25 10:29:40 -08:00
Tzanio 6d2530775b Extended copyright to 2022 2022-02-25 10:24:50 -08:00
Tzanio Kolev 9a016d8565 Merge pull request #2733 from mfem/shadow-fe-dev
Fixing shadowed variables in fem/fe classes [shadow-fe-dev]
2022-02-25 10:04:21 -08:00
Tzanio c18a8b4b55 Merge branch 'master' into yohann/pa-convection-transpose 2022-02-24 19:03:59 -08:00
Veselin Dobrev 0e24fce7d8 Merge pull request #2788 from mfem/yohann/fix-GPU-kernel-warnings
Fix issue #2723
2022-02-24 15:59:19 -08:00
Veselin Dobrev f6e8028ea1 Merge pull request #2786 from mfem/lbfgs-on-device
Device support for LBFGS
2022-02-24 15:57:44 -08:00
Yohann Dudouit 53ec318455 Modify BilinearForm::MultTranspose to work with ext. 2022-02-24 12:34:14 -08:00
Yohann Dudouit 8e73bc2f2e Split Convection tests. 2022-02-24 12:33:33 -08:00
Yohann Dudouit 0166cf9cef Remove dead code. 2022-02-24 11:58:55 -08:00
Tzanio Kolev bac1842db2 Merge pull request #2741 from mfem/shadow-pa-dev
Fixing shadow variables in PA-related classes [shadow-pa-dev]
2022-02-24 08:51:07 -08:00
Tzanio Kolev 935d3f6df0 Merge pull request #2737 from mfem/shadow-linalg-dev
Fixing shadow variables in linalg classes [shadow-linalg-dev]
2022-02-24 08:50:38 -08:00
Tzanio Kolev 27a2383bb1 Merge pull request #2851 from mfem/bugfix/wedge-bdr-attr
Fix boundary attribute number for wedges in Mesh::Make3D
2022-02-24 08:50:00 -08:00
Will Pazner 58530b2215 Merge remote-tracking branch 'origin/master' into shadow-mesh-dev 2022-02-23 11:57:04 -08:00
Tzanio Kolev 232d46ac77 Merge pull request #2731 from mfem/shadow-out-dev
Fixing shadow warnings about "out/err" globals [shadow-out-dev]
2022-02-23 11:55:25 -08:00
Tzanio Kolev 72d0ba2b30 Merge pull request #1051 from mfem/nd-prism-dev
Arbitrary order ND and RT bases on Prisms [nd-prism-dev]
2022-02-23 11:52:54 -08:00
Tzanio Kolev 839fe32fd0 Merge pull request #2837 from mfem/reduce-test-times
Reduce some unit test runtimes
2022-02-23 11:51:57 -08:00
Tzanio Kolev b243da16a1 Merge pull request #2843 from mfem/det1d
Simple kernels for Det1D and Values1D
2022-02-23 11:51:15 -08:00
Stowell, Mark L 2e414980d0 Fix boundary attribute number for wedges in Mesh::Make3D 2022-02-23 09:34:17 -08:00
Yohann Dudouit 35a7334389 Fix a bug in SmemPAConvectionApplyT2D. 2022-02-22 17:31:14 -08:00
Yohann Dudouit c7bd052e0c Add MFEM_VERIFY to prevent silent bugs. 2022-02-22 16:55:24 -08:00
Stowell, Mark L 042ec3fab2 Trying to avoid merge conflicts with shadow-out-dev 2022-02-22 12:53:40 -08:00
Tzanio f8c75fac32 Merge branch 'master' into nd-prism-dev
Conflicts:
	CHANGELOG
2022-02-22 12:40:27 -08:00
Tzanio fa27a78358 minor 2022-02-22 12:39:05 -08:00
Stowell, Mark L 936b27b2c8 Adding CHANGELOG entry 2022-02-22 12:34:18 -08:00
Will Pazner 722d8fa575 Merge pull request #2739 from mfem/shadow-fem-dev
Fixing shadow variables in fem classes [shadow-fem-dev]
2022-02-22 11:55:30 -08:00
Will Pazner 9db1dc3198 Revert "Add AMR-DG Assembly Level tests"
This reverts commit 4a717f356b.
2022-02-22 11:11:02 -08:00
Will Pazner 4a717f356b Add AMR-DG Assembly Level tests 2022-02-22 10:29:12 -08:00
Will Pazner 30d5dca58c Merge remote-tracking branch 'origin/master' into shadow-mesh-dev 2022-02-22 09:25:27 -08:00
Will Pazner 225a1f9326 Minor variable name adjustment 2022-02-22 09:19:29 -08:00
Tzanio 4f37593ef8 Fix compiler error with old HYPRE 2022-02-20 15:01:14 -08:00
Socratis Petrides ec491dda4e minor 2022-02-20 14:48:50 -08:00
Socratis Petrides 52e79fb7de restructuring LAPACK preprocessor directives 2022-02-20 14:31:20 -08:00
Socratis Petrides 229c1da109 adding unit tests for LAPACK Generalized EigenSystem for GE matrices 2022-02-20 13:35:18 -08:00
Tzanio Kolev ec0dac2392 Merge pull request #2833 from mfem/release-pa-mem-dev
Optional copy_to_host for ReleasePADeviceMemory
2022-02-19 16:36:11 -08:00
Socratis Petrides 2bf1f0df14 adding unit tests for Generalized EigSystem and SVDs 2022-02-18 20:17:06 -08:00
Vladimir Z Tomov 5cc9e54e63 bad alignment 2022-02-18 18:09:18 -08:00
Vladimir Z Tomov c7273d76fd Det1D and Values1D. 2022-02-18 18:07:05 -08:00
Socratis Petrides db20f7a0ee adding LAPACK generalized eig-system for general matrices 2022-02-18 17:05:47 -08:00
Stowell, Mark L 61a6c27ebb To prevent merge conflict with shadow-fem-dev branch 2022-02-18 15:09:49 -08:00
Socratis Petrides 648e96655c adding option to return singular vectors in DenseMatrixSVD 2022-02-18 14:58:55 -08:00
Stowell, Mark L 93c4885230 Merge remote-tracking branch 'origin/master' into shadow-pa-dev 2022-02-18 10:35:29 -08:00
Stowell, Mark L 4736553365 Fixing new shadowed variables in face restriction classes 2022-02-18 09:57:28 -08:00
Stowell, Mark L f07e137d89 Merge remote-tracking branch 'origin/master' into shadow-fem-dev
# Conflicts:
#	fem/prestriction.cpp
#	fem/restriction.cpp
2022-02-18 09:55:58 -08:00
Will Pazner e52546e9d4 Don't run same Assembly Level tests twice 2022-02-18 09:48:57 -08:00
Stowell, Mark L 31c5f85560 Merge remote-tracking branch 'origin/master' into shadow-mesh-dev 2022-02-18 09:17:31 -08:00
Stowell, Mark L 53e4896385 Merge remote-tracking branch 'origin/master' into shadow-linalg-dev 2022-02-18 09:16:27 -08:00
Stowell, Mark L 1720dac641 Merge remote-tracking branch 'origin/master' into shadow-fe-dev
# Conflicts:
#	fem/fe/fe_base.cpp
2022-02-18 09:14:00 -08:00
Will Pazner 8d971054ee Replace out with os in VTK code 2022-02-18 08:25:48 -08:00
Will Pazner 14b48da4d2 Merge remote-tracking branch 'origin/master' into shadow-out-dev 2022-02-18 08:20:52 -08:00
Tzanio Kolev 56d092df0e Merge pull request #2822 from mfem/var-order-BuildConformingProlongation-fix
bug-fix in BuildConformingProlongation
2022-02-18 08:03:46 -08:00
Tzanio Kolev 9e442b4c22 Merge pull request #2826 from mfem/stefanozampini/ex2p-bddc
Stefanozampini/ex2p bddc
2022-02-18 08:02:24 -08:00
Stowell, Mark L 853d845682 Changes suggested by @YohannDudouit 2022-02-17 17:14:10 -08:00
Stowell, Mark L c6bce36318 Changes suggested by @pazner 2022-02-17 16:57:05 -08:00
Stowell, Mark L e5558895dc Suggestions made by @YohannDudouit 2022-02-17 16:02:57 -08:00
Tzanio 41b88b9db6 minor 2022-02-17 15:50:04 -08:00
Stowell, Mark L d1d2127484 Fixing one thread safety concern 2022-02-17 15:43:28 -08:00
Stowell, Mark L 0ee82397de Following suggestions from @pazner 2022-02-17 15:02:18 -08:00
Yohann Dudouit 7285436cbe Add ConvectionIntegrator::AddMultTransposePA. 2022-02-17 14:43:49 -08:00
Tzanio dd6e59f9cc 4.3.1 -> 4.4 2022-02-17 14:41:44 -08:00
Stowell, Mark L f1aac89a3c Merge remote-tracking branch 'origin/master' into lo-dim-em-dev 2022-02-17 14:35:18 -08:00
Will Pazner e12c5ee7f5 Reduce some of the longer unit test run times 2022-02-17 13:31:53 -08:00
Will Pazner 957a514da3 Merge pull request #2829 from mfem/variable-order-transfer-op
Refactor transfer operator unit tests
2022-02-16 14:39:22 -08:00
Veselin Dobrev 88cca21c90 Merge pull request #2195 from mfem/yohann/pa-dg-ncmesh
Add Discontinuous Galerkin Partial Assembly support for NCMesh.
2022-02-16 10:11:05 -08:00
Socratis Petrides 51cab29634 return null P/R in case of a DG space 2022-02-16 09:49:22 -08:00
Veselin Dobrev e08b2beb23 Merge branch 'master' into yohann/pa-dg-ncmesh
Resolved conflict:
   general/hash.hpp
2022-02-15 20:30:04 -08:00
Tzanio Kolev 5bf8d8a5d1 Merge pull request #2816 from mfem/device-memory-fixes
Fix device+debug runtime errors
2022-02-15 15:46:20 -08:00
Stowell, Mark L 309aed7c26 Cleanup suggested by @acfisher 2022-02-15 14:25:37 -08:00
Mark L. Stowell edabdac542 Merge pull request #2753 from mfem/lor-scale-integrated
Scale LOR integrated basis if using map type VALUE [lor-scale-integrated]
2022-02-15 13:57:48 -08:00
Mark L. Stowell 9bc340d88d Merge pull request #2752 from mfem/l2-mass-integral-map-type
Change PA mass kernels to work with map type INTEGRAL [l2-mass-integral-map-type]
2022-02-15 13:57:02 -08:00
Tom Stitt 88f185bdab add optional copy_to_host (true by default) option to ReleasePADeviceMemory 2022-02-15 13:47:44 -08:00
Yohann Dudouit 70fb6d1c66 Remove most Convection DG PA tests. 2022-02-15 13:26:04 -08:00
Veselin Dobrev 910fd79c19 Merge branch 'master' into device-memory-fixes
Resolved conflict:
   fem/transfer.cpp
2022-02-15 12:45:46 -08:00
Will Pazner 4ea60b1dec Use CAPTURE Catch2 macro instead of INFO 2022-02-15 09:32:47 -08:00
Ketan Mittal 6f127b0f09 increase tolerance for adaptive weight 2022-02-15 09:08:38 -08:00
Tzanio Kolev c62be8d181 Merge pull request #2781 from mfem/hash-resize-fix
Fix hash table resize on NCMesh load [hash-resize-fix]
2022-02-15 09:06:20 -08:00
Ketan Mittal 58819d698b update how surf_fit_multiplier is set 2022-02-14 19:32:00 -08:00
Will Pazner d7b8ed1a5b Fix end of non-void function error 2022-02-14 16:42:12 -08:00
Will Pazner fdac3fd03c Refactor transfer operator unit tests, reduce runtime 2022-02-14 16:30:51 -08:00
Ketan Mittal 9c9be89452 Resolve conflict with master 2022-02-14 09:34:36 -08:00
Ketan Mittal 4415dfa2b8 update CHANGELOG 2022-02-14 09:33:38 -08:00
Ketan Mittal 70b07cbc89 added comments 2022-02-14 09:31:31 -08:00
Stefano Zampini 4ae682b2d3 PETSc ex2p: add BDDC example 2022-02-14 13:14:24 +03:00
Stefano Zampini c31ded06c2 BDDC: attach RBMs to the global matrix 2022-02-14 12:46:02 +03:00
Jakub Červený 17dcec0590 Corrected some of the new docs. 2022-02-13 13:45:48 +01:00
Veselin Dobrev d82def8b0d Fix various warnings 2022-02-11 21:23:46 -08:00
Yohann Dudouit a09afff6c5 Add documentation for Unlink. 2022-02-11 18:55:03 -08:00
Yohann Dudouit 5c200cb54a Some typos. 2022-02-11 18:30:34 -08:00
Yohann Dudouit e490a474c9 Add documentation to HashTable. 2022-02-11 18:19:16 -08:00
Veselin Dobrev 28704ec657 Merge branch 'master' into yohann/fix-GPU-kernel-warnings 2022-02-11 15:32:53 -08:00
Ketan Mittal 57edcb68e0 remove timers 2022-02-11 12:27:59 -08:00
Ketan Mittal ae53aae9bb update sample runs 2022-02-11 12:24:51 -08:00
Ketan Mittal 0e571fd8cb minor fixes to tmop_tools 2022-02-11 12:20:41 -08:00
Ketan Mittal 7365219dd1 clean up 2022-02-11 12:18:07 -08:00
Ketan Mittal cdb51d6d7f remove scalar kernels 2022-02-11 12:07:08 -08:00
Ketan Mittal c25e633276 remove PA and timing components 2022-02-11 12:02:52 -08:00
Yohann Dudouit e848c67ec5 Make some methods public to make nvcc happy. 2022-02-11 11:22:07 -08:00
Aaron Fisher f6ffbae4a1 Update hash.hpp 2022-02-11 11:05:59 -08:00
Ketan Mittal 1698556809 skip gradient and hessian calculation for elements with no marked dofs for surface fitting 2022-02-11 11:01:32 -08:00
psocratis 66e0c79b3f small valgrind fix in the parallel case 2022-02-11 09:50:52 -08:00
Socratis Petrides e65dc1ed36 bug-fix in BuildConformingProlongation 2022-02-10 17:28:25 -08:00
Veselin Dobrev e3585a53ae Fix a doxygen warning 2022-02-10 17:26:03 -08:00
Veselin Dobrev bb34d35459 Small updates in the doxygen documentation for SparseMatrix,
methods BuildTranspose() and EnsureMultTranspose().
2022-02-10 16:47:44 -08:00
Yohann Dudouit f4a2077c8b Same for ex9p. 2022-02-10 16:09:50 -08:00
Yohann Dudouit 20e40f5778 Replace device sample run with a better one. 2022-02-10 16:06:29 -08:00
Will Pazner 6990897b29 Replace occurrences of BuildTranspose with EnsureMultTranspose
Also slightly improve the Doxygen comments for those two functions.
2022-02-10 15:53:58 -08:00
Yohann Dudouit 63f9463d93 Update CHANGELOG. 2022-02-10 15:35:23 -08:00
Will Pazner b8a3e423fd Update condition in SparseMatrix::MultTranspose to match EnsureMultTranspose 2022-02-10 15:09:33 -08:00
Yohann Dudouit 7d84029fc8 Remove FaceInfoTag::Invalid. 2022-02-10 14:54:46 -08:00
Yohann Dudouit d6e160753f Slightly improve FaceInfoTag enum. 2022-02-10 14:53:49 -08:00
Veselin Dobrev 8328b3d220 Extend a little some of the doxygen comments related to the
struct Mesh::FaceInformation.
2022-02-10 14:28:03 -08:00
Will Pazner 5bd76ca866 Add SparseMatrix::EnsureMultTranspose 2022-02-10 11:19:32 -08:00
Jakub Červený cc024ce5c2 Fix bug in HashTable::BinSize. 2022-02-10 19:47:21 +01:00
Tom Stitt 7ecd331a0b Merge remote-tracking branch 'origin/master' into device-memory-fixes 2022-02-10 10:16:24 -08:00
Jakub Červený 8402306443 Document HashTable::BinSize() 2022-02-10 18:49:02 +01:00
Jakub Červený b942f9966f HashTable::PrintStats: improved docs 2022-02-10 11:20:05 +01:00
psocratis 8b5f9f7720 resolving conflicts 2022-02-09 19:50:00 -08:00
psocratis 98739f8c09 fix valgrind complaints in the serial case 2022-02-09 19:41:48 -08:00
Yohann a461f7258e Merge pull request #2797 from mfem/yohann/face-interface2
Second proposal for a human readable face information
2022-02-09 17:48:03 -08:00
Socratis Petrides 84129a1f83 finished Block-sc in the parallel case, uw_dpgp passes initial tests 2022-02-09 17:04:01 -08:00
Ketan Mittal 3b96981769 minor updates to adaptive 2022-02-09 15:24:56 -08:00
Ketan Mittal 2ec35e4beb add surface fitting threshold and clean up adaptive weight 2022-02-09 11:58:28 -08:00
Yohann Dudouit 33a015aede non-conforming -> nonconforming. 2022-02-08 14:04:20 -08:00
Yohann Dudouit 6ed2314eec NonConforming -> Nonconforming. 2022-02-08 13:57:43 -08:00
Tom Stitt 0c4d7aa085 don't want to check trueness of a function pointer... 2022-02-08 13:20:05 -08:00
Ketan Mittal 53bbd197f0 Merge branch 'master' of https://github.com/mfem/mfem into lbfgs-on-device 2022-02-08 11:34:21 -08:00
Ketan Mittal d05f5e0f36 reviewer comments 2022-02-08 11:30:35 -08:00
Yohann Dudouit 27ef8740d6 Use MFEM_USE_HIP instead of __HIP_DEVICE_COMPILE__ 2022-02-08 10:53:13 -08:00
Yohann Dudouit adeed85a67 Try something else. 2022-02-08 09:44:38 -08:00
Tom Stitt 80a3df260c only BuildTranspose on device 2022-02-07 18:26:52 -08:00
Yohann Dudouit 915b044b14 Minor 2022-02-07 17:06:55 -08:00
Yohann Dudouit 01caa8dcb7 Remove unsused methods. 2022-02-07 16:50:43 -08:00
Tom Stitt 07ab64b635 minor device memory fixes seen during debug run 2022-02-07 10:52:36 -08:00
Ketan Mittal 953c6833ae Merge branch 'tmop-surffit-profile' of https://github.com/mfem/mfem into tmop-surffit-profile 2022-02-04 11:12:16 -08:00
Ketan Mittal cfb094e591 diagonal prec 2022-02-04 11:12:02 -08:00
Ketan Mittal 72811c944f symmetric hessian 2022-02-04 11:11:27 -08:00
Will Pazner 7669ab002a Whitespace 2022-02-03 11:05:04 -08:00
Yohann Dudouit 076f0fbd29 Use MFEM_ASSERT_KERNEL. 2022-02-03 09:54:57 -08:00
Yohann Dudouit a78d206931 NonConforming -> Nonconforming 2022-02-03 09:24:38 -08:00
Socratis Petrides b6ea025795 cleanup, started on par sc case 2022-02-02 20:18:19 -08:00
Ketan Mittal ff554275ed optimization for memory access 2022-02-02 17:03:47 -08:00
Ketan Mittal 23fb153cb9 remove unused vars 2022-02-02 14:42:58 -08:00
Ketan Mittal 7b054295e3 pa for surf-fit [WIP] 2022-02-02 14:04:29 -08:00
Yohann Dudouit 0bc28bca46 Fix new struct. 2022-02-02 10:06:44 -08:00
Yohann Dudouit 265b6a59c1 Use struct for each element on a face. 2022-02-02 09:56:53 -08:00
Yohann Dudouit 5e5a2c66a4 Remove tautological documentation. 2022-02-01 14:47:51 -08:00
Yohann Dudouit b67d03f0ad NonConforming -> Nonconforming 2022-02-01 13:03:45 -08:00
Yohann Dudouit df528c10f1 Apply Will's suggestions:
- Conforming -> Coincident
- Coarse -> Superset
- Fine -> Subset
- Shared -> FaceNbr
2022-02-01 12:57:04 -08:00
Yohann Dudouit 81386ed445 More of the same. 2022-02-01 10:20:24 -08:00
Socratis Petrides d528e9d63e filling blockstaticcond destructor 2022-02-01 10:19:19 -08:00
Yohann Dudouit 4404a4dbca Replace coarse-fine and fine-coarse with coarse and fine. 2022-02-01 10:19:03 -08:00
Yohann Dudouit cf4acf95a6 Fix semantic of GhostSlave faces. 2022-02-01 10:14:38 -08:00
rezgarshakeri 10447fe402 test/unit/linalg: fixed the typo 2022-02-01 10:03:39 -07:00
Socratis Petrides d18f11e6c7 blockstatic-cond passes tests for primal-dpg 2022-01-31 17:56:37 -08:00
Yohann Dudouit b7d7338dca Draft for second proposal for FaceInformation 2022-01-31 16:24:54 -08:00
Socratis Petrides efeb400b27 Block sc FormSystemMatrix. Started on ReduceSystem 2022-01-28 20:01:07 -08:00
Yohann Dudouit ba83d3f4f5 Add MFEM_VERIFY_KERNEL and MFEM_ASSERT_KERNEL. 2022-01-28 12:56:03 -08:00
Yohann Dudouit 01c3cb32fa Move MFEM_DEVICE_COMPILE insde MFEM_FORALL 2022-01-28 12:52:43 -08:00
Ketan Mittal d613d83c80 Merge branch 'tmop-surffit-profile' of https://github.com/mfem/mfem into tmop-surffit-profile 2022-01-28 11:21:57 -08:00
Ketan Mittal 671c5e8b2c add adaptive surf fitting 2022-01-28 11:21:42 -08:00
Ketan Mittal 35304b0467 add more timers 2022-01-28 11:20:55 -08:00
Socratis Petrides 1451c3c483 small bug-fix in assembly if doftrans is not null 2022-01-27 17:33:04 -08:00
Socratis Petrides f12d46bdf9 Shur complement assembly and conforming assembly 2022-01-27 17:31:55 -08:00
Socratis Petrides 6dfb809f97 changing GetSubMatrix to const 2022-01-27 17:30:38 -08:00
Socratis Petrides ef8785b852 computing indices for interior/interface local dofs for block-static-cond 2022-01-26 18:24:56 -08:00
Socratis Petrides efd182ec4c visualize mesh in amr for the l-shape problem 2022-01-26 18:23:12 -08:00
Socratis Petrides e7856b982a style 2022-01-26 10:59:38 -08:00
Socratis Petrides 4f4d1f9d2d adding function signatures in blockstaticcond 2022-01-26 10:59:19 -08:00
Stowell, Mark L b2744cefef Merge remote-tracking branch 'origin/master' into nd-prism-dev
# Conflicts:
#	fem/doftrans.cpp
#	fem/fe.cpp
#	fem/fe.hpp
#	fem/fe_coll.cpp
#	tests/unit/CMakeLists.txt
2022-01-25 20:36:23 -08:00
Socratis Petrides 1a89d5af02 started on static condensation for DPG (block) systems 2022-01-25 19:45:40 -08:00
Yohann Dudouit 7f10cab0c1 Add MFEM_DEVICE_COMPILE to backends.hpp 2022-01-25 13:25:30 -08:00
Yohann Dudouit a8633ddd95 Use #ifdef MFEM_DEVICE_COMPILE in bilininteg_hcurl.cpp. 2022-01-25 13:24:33 -08:00
Yohann Dudouit fcbf5c5f3b Try to mute warnings. 2022-01-25 13:24:21 -08:00
Yohann Dudouit 0eb0d82bda Remove Elem1 from function names in favor of CoarseFine and FineCoarse. 2022-01-24 17:39:19 -08:00
Yohann Dudouit 88ffc396c3 Remove inaccurate documentation. 2022-01-24 17:22:56 -08:00
Ketan Mittal 267eef5ef0 modify lbfgs to work on gpus 2022-01-24 12:43:08 -08:00
Ketan Mittal a255e3ab91 minor 2022-01-24 11:47:53 -08:00
Ketan Mittal ac3a0c2d37 restore print_options 2022-01-24 11:46:53 -08:00
Ketan Mittal 573ad2fda7 LBFGS on device 2022-01-24 11:43:10 -08:00
Ketan Mittal 62c99405a3 modify LBFGS for profiling 2022-01-24 10:38:47 -08:00
Ketan Mittal f34028f9da add timers 2022-01-24 10:17:24 -08:00
Ketan Mittal fea9733fdf fix adapt_lim_eval -> adapt_eval in DiscreteTC 2022-01-24 09:59:56 -08:00
Jakub Červený 5da4d3afc7 Add HashTable::PrintStats to dump hash table statistics. 2022-01-23 11:53:04 +01:00
Jakub Červený 40fb41470b Fix missing hash table resize in HashTable::Alloc() (used in NCMesh load). 2022-01-23 11:51:21 +01:00
Socratis Petrides c71b02a915 fix print format 2022-01-21 14:37:21 -08:00
Socratis Petrides 5576f3653e style 2022-01-21 13:45:29 -08:00
Socratis Petrides 7f316dd07b changing strong_dpg to use vdim>1 test space 2022-01-21 13:45:00 -08:00
Socratis Petrides 19b5ae6b9a parallel examples acoustics uw_dpg 2022-01-21 13:44:17 -08:00
Socratis Petrides 94cd8859b2 adding adjoint graphnorm in uw_dpg for acoustics 2022-01-21 13:43:56 -08:00
Socratis Petrides 8ea8b97fc8 adding vdim>1 for test spaces in normalequations 2022-01-21 13:43:00 -08:00
Socratis Petrides f9abc77026 clean up 2022-01-20 16:45:43 -08:00
Socratis Petrides 68e3f9aeb9 adding traditional fosls formulation for acoustics (real) 2022-01-20 16:34:51 -08:00
Socratis Petrides 08f018c299 adding uw dpg formulation for acoustics (real) 2022-01-20 16:33:58 -08:00
Socratis Petrides 69e57546d4 adding 'strong' dpg formulation for acoustics 2022-01-20 16:33:35 -08:00
Socratis Petrides 433a29c9e3 fixing comment in diffusion fosls 2022-01-20 16:32:47 -08:00
Yohann Dudouit 5e03149861 Make function names more explicit. 2022-01-19 20:59:13 -08:00
Veselin Dobrev 581c46d394 Resolve bad automatic merge 2022-01-19 15:44:16 -08:00
Veselin Dobrev f640103e26 Merge branch 'yohann/pa-dg-ncmesh' into yohann/shared-master-slave 2022-01-19 15:37:15 -08:00
Yohann Dudouit 88695cefff Refactor FaceInformation to associate location and conformity to both elem1 and elem2. 2022-01-19 11:13:41 -08:00
Socratis Petrides 92ee7099a4 reorganizing examples 2022-01-19 11:05:16 -08:00
Socratis Petrides 808c9cd2c4 Merge branch 'master' into dpg-dev 2022-01-19 10:10:05 -08:00
Veselin Dobrev 27c4f22338 Small tweaks in the code and the documentation. 2022-01-18 19:48:38 -08:00
Stowell, Mark L dac5d56b1a Following @pazner's suggestion for ParaViewDataCollection methods which return strings 2022-01-18 15:41:59 -08:00
Stowell, Mark L 63381b366a Renaming ostream variables from out to os 2022-01-18 15:06:46 -08:00
Stowell, Mark L 2a78ddbb4b Merge remote-tracking branch 'origin/master' into shadow-out-dev
# Conflicts:
#	general/device.cpp
2022-01-18 14:12:52 -08:00
Socratis Petrides f3cd0a10e7 minor 2022-01-17 11:30:23 -08:00
Veselin Dobrev 3da0d9fc2f Merge branch 'master' into yohann/pa-dg-ncmesh (#2195) 2022-01-14 19:45:55 -08:00
Yohann Dudouit 70fba19635 Invert shared non-conforming slave and master. 2022-01-14 12:13:34 -08:00
Stowell, Mark L 453d51d358 Incorporating changes suggested by @pazner 2022-01-12 10:29:43 -08:00
Stowell, Mark L 2b1fe93c00 Adjusting variable names 2022-01-12 10:05:27 -08:00
Will Pazner 113423b423 Typos 2022-01-11 10:19:23 -08:00
Will Pazner 11ed189dec Add some Doxygen documentation for Poly_1D 2022-01-11 09:21:50 -08:00
Socratis Petrides e6bb8c8976 small bugfix in updating mesh dependent coefficient 2022-01-05 18:09:49 -08:00
Will Pazner 1cc284cd42 Add unit test for PA mass with INTEGRAL map type 2022-01-05 12:04:23 -08:00
Will Pazner c771e61f08 Scale LOR integrated basis if using map type VALUE 2022-01-05 09:41:39 -08:00
Will Pazner c7781e1dc7 Change PA mass kernels to work with map type INTEGRAL 2022-01-05 09:04:48 -08:00
Stowell, Mark L b49d3c5c23 Changing leading underscore to trailing underscore 2022-01-04 18:04:01 -08:00
Socratis Petrides 4718577810 bug-fix serial AMR in normalequations P/R Mult in RHS and Sol vector 2021-12-30 19:59:14 -08:00
Stowell, Mark L 785f54ae74 Fixing shadow variable in templated TAutoDiffVector class 2021-12-30 11:26:12 -08:00
Stowell, Mark L bc76377bda Changes based on feedback from @vladotomov 2021-12-30 10:57:05 -08:00
Socratis Petrides 9e520183c8 Merge branch 'master' into dpg-dev 2021-12-30 09:26:52 -08:00
Stowell, Mark L fa713ff7ea Fixing shadow variables in templates 2021-12-27 14:39:18 -08:00
Stowell, Mark L 6ca5532d71 Fixing documentation for new argument name 2021-12-23 16:39:21 -08:00
Stowell, Mark L 24de1b367a Fixing shadow variables in pa related classes 2021-12-23 16:34:48 -08:00
Stowell, Mark L 00622b78fc Fixing shadow variables in fem classes 2021-12-23 16:32:09 -08:00
Stowell, Mark L c1c1ecd90c Fixing shadow variables in mesh classes 2021-12-23 16:27:26 -08:00
Stowell, Mark L 61215468f3 Fixing shadow variables in linalg classes 2021-12-23 16:25:02 -08:00
Stowell, Mark L d2684bbab8 Changing name from en_err to error 2021-12-23 12:30:44 -08:00
Stowell, Mark L 83dfc17738 Fixing shadowed variables in fem/fe classes 2021-12-22 16:45:55 -08:00
Stowell, Mark L 512a889556 Missed two instances of "out" 2021-12-22 15:25:25 -08:00
Stowell, Mark L f7c9bdab17 Renaming "out" and "err" local variables to avoid globals 2021-12-22 15:19:20 -08:00
Socratis Petrides 95a40d7377 clean up convection-diffusion 2021-12-22 14:40:11 -08:00
Socratis Petrides 036846bcd6 adding parallel convection-diffusion with AMR example 2021-12-21 17:59:56 -08:00
Socratis Petrides 6c2968156f Merge branch 'master' into dpg-dev 2021-12-21 10:01:43 -08:00
Sebastian Grimberg cac8a64804 Fix for linear/bilinear form domain integrators with markers 2021-12-20 10:30:47 -05:00
Socratis Petrides 9ba650f2fd adding Erikson Johnson problem for convection-diffusion UW-DPG 2021-12-17 16:34:22 -08:00
Socratis Petrides ee6cb39ee0 Merge branch 'pncmesh-getessvdof-fix' into dpg-dev 2021-12-16 09:46:14 -08:00
Socratis Petrides 1701a6e84c Merge branch 'master' into dpg-dev 2021-12-16 09:45:02 -08:00
Socratis Petrides f500e5220a Parallel AMR for lshape 2021-12-15 18:28:31 -08:00
Socratis Petrides e078288ecb title fix 2021-12-15 12:40:42 -08:00
Socratis Petrides e46c7ac0e7 fix sample run and title in the example 2021-12-15 12:39:33 -08:00
Socratis Petrides c2b133f3c8 minor visualization edits 2021-12-15 12:37:46 -08:00
Socratis Petrides 373379fbdd lshape mesh 2021-12-15 12:20:41 -08:00
Socratis Petrides bfc3835a1d adding AMR l-shape example in diffusion_uwdpg 2021-12-15 12:20:08 -08:00
Socratis Petrides ab8578a728 add element residual computation to NormalEquations 2021-12-15 12:19:30 -08:00
Yohann Dudouit f54842b6a7 Use int variables to avoid comparison between signed and unsigned integers. 2021-12-14 12:13:43 -08:00
Yohann Dudouit 2214f65e20 Simplify InterpConfig based on @samuelpmishLLNL feedback. 2021-12-14 11:59:39 -08:00
Yohann Dudouit 094f032de5 Remove Mesh::GetNCFacesPtMat. 2021-12-14 10:37:57 -08:00
Socratis Petrides fdaaacfdf3 Started residual based error estimator. Done some refactoring 2021-12-13 17:36:52 -08:00
Socratis Petrides 5d7ebbb51a fixed small size bug in DenseMatrix::GetSubMatrix 2021-12-13 17:35:26 -08:00
Yohann a00c3fe39b Merge pull request #2704 from mfem/yohann/pa-dg-ncmhes-deduplicate
Remove duplicated code.
2021-12-13 17:22:24 -08:00
Yohann Dudouit 588e211f5a Improve variable names. 2021-12-13 16:15:41 -08:00
Yohann Dudouit 2659ee5f3f Make dgtrace more self-documented. 2021-12-13 16:06:01 -08:00
Yohann Dudouit ec176a6bf8 Fix: move height and width initialization outside MFEM_DEBUG. 2021-12-13 15:50:54 -08:00
Yohann Dudouit 84a1f1e343 Fix documentation. 2021-12-10 17:56:50 -08:00
Yohann Dudouit f64c3175c6 Have ParNCL2FaceRestriction inherit from both NCL2FaceRestriction and ParL2FaceRestriction. 2021-12-10 17:40:00 -08:00
Yohann Dudouit 63d2303a48 Add documentation. 2021-12-10 16:51:01 -08:00
Yohann Dudouit 01322ef72f Fix ParNCL2FaceRestriction::AddMultTranspose 2021-12-10 14:14:05 -08:00
Yohann Dudouit f086ff03f4 Fix typo. 2021-12-10 14:07:58 -08:00
Yohann Dudouit f811da79e4 Move verifications in CheckFESpace methods. 2021-12-10 14:05:30 -08:00
Yohann Dudouit 2bd1148127 Fix mfem_data_dir path. 2021-12-10 11:36:56 -08:00
Yohann Dudouit c37a187f9d Redesign protected constructor. 2021-12-10 10:53:02 -08:00
Yohann Dudouit d02545cc3e Initial refactor removing duplicated code in Mult and AddMultTranspose. 2021-12-09 15:56:08 -08:00
Socratis Petrides fe0821413a adding parallel test for uw diffusion 2021-12-09 15:16:49 -08:00
Socratis Petrides 695a5adcb2 ParNormalEquations cleanup 2021-12-09 15:16:15 -08:00
Socratis Petrides b2dfc76f1a minor changes in serial example 2021-12-09 15:13:54 -08:00
Socratis Petrides 76c700b41e adding BlockOperator and BlockMatrix in OpType 2021-12-09 15:13:05 -08:00
Socratis Petrides dc3f10fa63 Passing first tests in parallel for ParNormalEquations 2021-12-08 17:36:34 -08:00
Socratis Petrides 420bb73d6c minor change in normal equations constructor 2021-12-08 17:36:11 -08:00
Socratis Petrides 13648768ae removing unused code 2021-12-08 17:34:00 -08:00
Socratis Petrides 7bfda36bca Starting ParNormalEquations -> adding class methods signatures 2021-12-07 18:48:24 -08:00
Socratis Petrides 46fc3ce9c2 remove not used code 2021-12-07 18:47:20 -08:00
Stowell, Mark L 79ba228b34 Adding new unit tests to CMakeLists 2021-12-07 14:30:45 -08:00
Stowell, Mark L 0f621788c3 Renaming new example files 2021-12-07 14:27:10 -08:00
Socratis Petrides b3086ce754 Merge branch 'master' into dpg-dev 2021-12-07 13:05:01 -08:00
Socratis Petrides d1312d354a minor bug-fix in the adjoint graph norm 2021-12-03 20:04:49 -08:00
Socratis Petrides 16fcc3f970 Fixing P and R null diagonal blocks to act as Identity for L2 Space and AMR 2021-12-03 20:04:23 -08:00
Socratis Petrides a6caab3bed PartMult and AddPartMult for BlockMatrix 2021-12-03 19:53:27 -08:00
Socratis Petrides 172b5bdcc9 Modifying DPG examples to use block-diagonal preconditioners 2021-12-02 17:25:03 -08:00
Socratis Petrides 72f83c132d Changing normalequations to use only BlockMatrix 2021-12-02 17:24:25 -08:00
Socratis Petrides 911e394d80 adding EliminateRowCols with saving Ae to BlockMatrix class 2021-12-02 17:22:36 -08:00
Socratis Petrides 4ff29e40c9 Refactoring NormalEquations assemble to use BlockMatrix 2021-12-01 19:00:07 -08:00
Socratis Petrides dac7808875 style 2021-11-30 18:23:31 -08:00
Socratis Petrides 246fd8e6fe started element residual calculation for AMR 2021-11-30 18:23:09 -08:00
Socratis Petrides 5e243e01f8 clean up 2021-11-30 18:22:31 -08:00
Socratis Petrides 56b83ea538 UW-DPG with AMR: fixing Block Prolongation/Restriction Operators 2021-11-30 16:41:21 -08:00
Socratis Petrides cd7371896a removing no longer needed test 2021-11-29 17:30:01 -08:00
Socratis Petrides 3fdd3e2450 style 2021-11-29 17:28:42 -08:00
Socratis Petrides 303ccefd83 completing the descructor 2021-11-29 17:28:17 -08:00
Socratis Petrides 48bcc332f7 fix piola map bug in NormalTraceIntegrator 2021-11-29 17:19:05 -08:00
Socratis Petrides 0c23d23874 new diffusion uw-dpg with adjoint graph norm 2021-11-29 17:17:54 -08:00
Socratis Petrides e76cef225d UW-DPG for diffusion works on quad meshes 2021-11-28 15:03:34 -08:00
Socratis Petrides 6f49201e62 Ultraweak-DPG for poisson prototype 2021-11-27 14:23:24 -08:00
Socratis Petrides 1cb75f7730 adding diffusion UW-DPG 2021-11-24 16:56:15 -08:00
Socratis Petrides ef14d682c5 bug-fix ElementTrasformation 2021-11-24 16:55:45 -08:00
Socratis Petrides 54eb78e0df adding block primal test 2021-11-23 17:13:22 -08:00
Socratis Petrides cd1a3a4fc7 fixing minor bug in B^T G^-1 l 2021-11-23 17:12:02 -08:00
Socratis Petrides ffb50c2416 example tests cleanup 2021-11-23 10:05:44 -08:00
Socratis Petrides f568ca3c6e bug fix on accumulating domain integrators 2021-11-23 10:03:13 -08:00
Socratis Petrides c7fb058051 adding NormalTraceIntegrator and AssembleElementMatrix2 for DivDivIntegrator 2021-11-23 09:58:11 -08:00
Socratis Petrides a4d87d936b Adding NormalEquations Assembly for multiple spaces and integrators. Tested succesfully for primal DPG 2021-11-19 19:52:27 -08:00
Socratis Petrides f26bd4bea1 generalizing NormalEquations assembly for multiple fespaces and integrators 2021-11-18 17:20:30 -08:00
Socratis Petrides 6c001c3f9a adding example test for primal DPG 2021-11-15 17:57:09 -08:00
Socratis Petrides 82573af316 new Primal DPG reproduces ex8 2021-11-15 17:56:16 -08:00
Socratis Petrides 4bfb2d62d9 first primal dpg test runs 2021-11-15 13:41:57 -08:00
Socratis Petrides 0bf7a715db minor cleanup 2021-11-12 20:04:01 -08:00
Socratis Petrides ad68c8f245 Fixing doc complaints 2021-11-12 18:52:48 -08:00
Socratis Petrides 0b430fa5f6 Started NormalEquationsWeakFormulation::Assemble 2021-11-12 18:49:06 -08:00
Socratis Petrides 238d1921c7 adding TraceIntegrator and AssembleTraceFaceMatrix 2021-11-12 18:48:05 -08:00
Yohann 301d0c3b39 Merge branch 'master' into yohann/pa-dg-ncmesh 2021-11-11 19:12:32 -08:00
Yohann Dudouit f30ab6b09b Fix GetFaceInformation. Thanks @camierjs 2021-11-11 18:57:45 -08:00
Yohann Dudouit 8bee3a173d Fix AddMultTranspose 2021-11-11 10:51:38 -08:00
Yohann Dudouit 797194af84 Avoid overflow with hash functions. 2021-11-11 10:50:45 -08:00
Yohann Dudouit 8afc72f6dc Removing dead code 2021-11-10 13:39:59 -08:00
Stowell, Mark L 60f5eecb6c Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	.gitignore
#	examples/CMakeLists.txt
#	examples/makefile
2021-11-09 08:37:54 -08:00
Socratis Petrides a25783e3b4 Simplifying P and R in BlockBilinearForm 2021-11-04 09:43:40 -07:00
Socratis Petrides 3aa8d49ca8 started implementation of trace_elem_integrators for DPG 2021-11-03 18:29:08 -07:00
Socratis Petrides 4ed6a4a014 fixing minor bug in reference BlockFOSLS case 2021-11-03 15:11:20 -07:00
Socratis Petrides 08f910343b AMR for reference Block FOSLS 2021-11-03 11:16:59 -07:00
Socratis Petrides 9fb0340206 fixing minor bug in P/R for AMR with blockforms 2021-11-03 09:03:18 -07:00
Socratis Petrides db40e8125e Setting Prolongation/Restriction for BlockBilinearForm. Tested for 2D AMR 2021-11-02 18:56:07 -07:00
Socratis Petrides 3e46fce65f simplifying BlockBilinearFrom::Assembly() 2021-11-02 17:53:50 -07:00
Socratis Petrides f649ed6b62 investigating possible bug in high order 3D runs wrt to essential BC elimination (example 1 hexa mesh) 2021-11-01 17:34:59 -07:00
Socratis Petrides a1a3a51d86 simplifying offset calculation wrt neg orientation 2021-11-01 17:34:05 -07:00
Socratis Petrides 6728fc7eda make style 2021-11-01 16:44:38 -07:00
Socratis Petrides 71e9d4e1d9 poisson_fosls - reference implementation 2021-11-01 16:44:00 -07:00
Socratis Petrides 7feb560f9b testing blockbilinearform with FOSLS poisson 2021-11-01 16:43:28 -07:00
Socratis Petrides aa9eadfcdf fixing orientation (sign) bug in blockbilinearform assemble 2021-11-01 16:42:59 -07:00
Socratis Petrides 82122f05cf testing block integrator by borrowing (bi)linearIntegrators 2021-11-01 16:42:20 -07:00
Socratis Petrides 2d64fa2162 fix bug in blocklinearform assemble 2021-11-01 16:41:21 -07:00
Socratis Petrides 8041734755 adding DenseMatrix::SetSubMatrix functions 2021-11-01 16:40:24 -07:00
Socratis Petrides 523891f05f adding BlockLinearForm (assemble) with testblocklinearinteg 2021-10-29 18:32:31 -07:00
Socratis Petrides b3fc46b6f2 Merge branch 'master' into dpg-dev 2021-10-29 16:43:38 -07:00
Yohann Dudouit 9f554c8b42 Add tests on Bernstein basis for PA DG AMR. 2021-10-29 11:38:18 -07:00
Yohann Dudouit 84f6acaeac Flip point matrix in 2D. 2021-10-29 10:41:01 -07:00
Yohann Dudouit 5113b1a8ed Use GetLocalInterpolation in GetCoarseToFineInterpolation. 2021-10-28 18:01:24 -07:00
Socratis Petrides 9271494723 Merge branch 'master' into dpg-dev 2021-10-27 08:45:53 -07:00
Socratis Petrides f2dbcecb92 debugging BlockBilinearForm::Assemble() 2021-10-25 16:47:32 -07:00
Socratis Petrides f2af9748c4 fixing offset computation in BlockBilinearForm::Assemble() 2021-10-22 19:39:51 -07:00
Socratis Petrides 9813dd7722 fix doxygen complaint 2021-10-22 19:28:52 -07:00
Socratis Petrides 3806e68ed1 adding new classes (block(bi)linearForms(integ) in support for DPG methods 2021-10-22 17:58:52 -07:00
Yohann Dudouit 6fe9c25cf3 Add comment for magic number. 2021-10-18 14:03:44 -07:00
Yohann Dudouit 3c0b64a2d6 Check that ExchangeFaceNbrData has been called before GetNFbyType in parallel. 2021-10-12 18:47:43 -07:00
Yohann Dudouit b1cfab5f5f Merge branch 'master' into yohann/pa-dg-ncmesh 2021-10-12 17:12:03 -07:00
Yohann Dudouit d9ba858f6f Merge branch 'yohann/pa-dg-ncmesh' of github.com:mfem/mfem into yohann/pa-dg-ncmesh 2021-10-12 17:11:33 -07:00
Yohann Dudouit f8c5f3e925 Use mesh from mfem/data. 2021-10-11 14:25:09 -07:00
Yohann Dudouit b9e3b3c20a Change camel case to snake case for more variables. 2021-10-07 17:30:53 -07:00
Yohann Dudouit cae40473f7 Add documentation to GetSharedFaceTransformations. 2021-10-07 15:44:06 -07:00
Yohann Dudouit e0e91ce0ee Copy the doc for GetFaceElementTransformations from mesh to pmesh. 2021-10-07 15:40:20 -07:00
Yohann Dudouit f4ca1e3e60 Fix unwanted rename. 2021-10-07 15:22:15 -07:00
Yohann Dudouit dd77aa8eb7 More dofs->dof_values. 2021-10-07 15:14:57 -07:00
Yohann Dudouit e0cac54513 Rename dofValue->dof_value, nextOffset->next_offset, dofIn->dof_in, dofOut->dof_out. 2021-10-07 15:10:26 -07:00
Yohann Dudouit 0ce2bc6275 Rename nd to nface_dofs. 2021-10-07 14:56:54 -07:00
Yohann Dudouit 3e66449ad2 make style in test_pa_kernels.cpp 2021-10-07 14:34:04 -07:00
Yohann Dudouit 24a162f0ef Refactor test_pa_convection to run on NCMesh. 2021-10-07 14:28:24 -07:00
Yohann Dudouit ce38dbbca6 Fix name typo. 2021-10-07 14:03:05 -07:00
Yohann Dudouit 7f6cc5580d Add unstructured-quad-square.msh and unstructured-hex-cube.msh. 2021-10-07 14:01:41 -07:00
Yohann Dudouit 4f74e10f30 Improve interpolators map key. 2021-10-07 13:56:03 -07:00
Yohann Dudouit 170f9a5ff5 Add return false to silence warnings. 2021-10-07 11:50:26 -07:00
Yohann Dudouit 0467b670b7 Use more self-documented variable names. 2021-10-06 17:05:33 -07:00
Yohann Dudouit e3788a948f Reorganize class attributes. 2021-10-06 16:34:56 -07:00
Yohann Dudouit b15998374d Rename offsets -> gather_offsets. 2021-10-06 16:27:52 -07:00
Yohann Dudouit 0bcbc0235a Rename dof to face_dofs. 2021-10-06 16:18:44 -07:00
Yohann Dudouit 46e21def4e Merge branch 'master' into yohann/pa-dg-ncmesh 2021-10-06 15:29:42 -07:00
Yohann Dudouit 9b5f87398c Remove unused protected methods and simplify code. 2021-10-06 14:35:47 -07:00
Yohann Dudouit 05ed290c34 Take into account the native ordering of H1 for the interpolator.
Always use PermuteAndSet for Elem2.
2021-10-06 14:18:48 -07:00
Yohann Dudouit 80a59acf5f Fix a bug in InterpConfig. 2021-10-05 20:00:51 -07:00
Yohann Dudouit a41c0d4a0c Remove nc_faces_orientation. 2021-10-05 12:36:33 -07:00
Yohann Dudouit 45c7ce02f8 Fix ParNCL2FaceRestriction. 2021-10-05 12:20:36 -07:00
Stowell, Mark L 0ece212d4a Removing deprecated method calls 2021-10-04 16:01:18 -07:00
Stowell, Mark L 881ee96d34 Fixing typo previously caught in master 2021-10-04 13:51:44 -07:00
Stowell, Mark L 4c25cfb50b Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	fem/fe.cpp
#	fem/fe.hpp
#	fem/gridfunc.cpp
#	tests/unit/fem/test_lin_interp.cpp
2021-10-04 11:44:27 -07:00
Yohann Dudouit ede2efd9c3 Improve documentation. 2021-10-01 16:07:08 -07:00
Yohann Dudouit 5c21a35c1a make style. 2021-09-24 15:43:08 -07:00
Yohann Dudouit b8589c2ed0 Add minimum libCEED version requirement. 2021-09-24 15:35:15 -07:00
Yohann Dudouit f2a93308b4 Initial commit to support new libCEED. 2021-09-24 14:05:07 -07:00
Yohann Dudouit ba27c951d1 Use temporary vector to interpolate. 2021-09-20 11:08:33 -07:00
Yohann Dudouit 4b213c4a30 Use default constructor for compatibility with Array. 2021-09-14 17:18:36 -07:00
Yohann Dudouit 04062029de Documentation. 2021-09-14 16:29:55 -07:00
Yohann Dudouit 889d0355bc make style. 2021-09-14 15:35:01 -07:00
Yohann Dudouit f153972fc1 Skip local non-conforming master in H1FaceRestriction. 2021-09-14 15:30:44 -07:00
Yohann Dudouit 223387e0fb Skip local non-conforming master faces in NCL2FaceRestriction. 2021-09-14 15:24:44 -07:00
Yohann Dudouit a7f6abd48c Minor. 2021-09-14 14:34:38 -07:00
Yohann Dudouit f148cdf20c Remove Ghost concept from FaceInformation. 2021-09-14 12:31:14 -07:00
Yohann Dudouit 8b5eee5a7a Remove notes on ghost faces. 2021-09-14 12:16:55 -07:00
Yohann Dudouit 41f63281bc Change orientation in ghost faces. 2021-09-14 12:00:38 -07:00
Yohann Dudouit c7f6a45001 Improve GetFaceInformation. 2021-09-14 11:56:04 -07:00
Yohann Dudouit 2edc9c3d20 Add some doc to Mesh::FaceInfo. 2021-09-14 11:54:50 -07:00
Yohann Dudouit 1e16d9a4fd Skip local non-conforming master faces in DGTrace. 2021-09-08 17:04:18 -07:00
Yohann Dudouit 7a274ad4fc Refine logic to treat ghost non-conforming master faces. 2021-09-08 17:02:47 -07:00
Yohann Dudouit ea1280f8ef Skip local non-conforming master faces in GetSigns. 2021-09-08 17:00:18 -07:00
Yohann Dudouit d54ab59b1d Take into account master side in GetCoarseToFineInterpolation. 2021-09-08 16:59:25 -07:00
Yohann Dudouit 910c309181 Improve restrictions debugging assertions. 2021-09-08 16:58:22 -07:00
Yohann Dudouit 06ed4029d5 Tag most ghost non-conforming master faces as trash. 2021-09-08 16:53:02 -07:00
Yohann Dudouit b8f4c85fca Skip local non-conforming master faces in face count. 2021-09-08 16:51:43 -07:00
Yohann Dudouit c651b027a2 Improve FaceInformation to tag trash faces. 2021-09-08 16:50:55 -07:00
Yohann Dudouit 3e716fb5ac Improve FaceInfo documentation. 2021-09-08 16:49:52 -07:00
Yohann Dudouit 19f8f85021 Add ParNCL2FaceRestriction::AddMultTranspose. 2021-09-07 16:49:34 -07:00
Yohann Dudouit 50d83bd8b6 Fix omitted DoubleValued filter for boundaries. 2021-09-07 15:23:55 -07:00
Yohann Dudouit 2699ceb23d Fix typo in ParNCL2FaceRestriction::Mult. 2021-09-07 15:23:02 -07:00
Yohann Dudouit 7a4a46c93f Remove is_trivial check until solution. 2021-09-02 19:29:51 -07:00
Yohann Dudouit cb003387b2 Little bit more style. 2021-09-02 19:26:48 -07:00
Yohann Dudouit 7f169fd7df make style. 2021-09-02 19:25:29 -07:00
Yohann Dudouit f524854baf Rename faceMap into face_map. 2021-09-02 19:11:27 -07:00
Yohann Dudouit 98efd8b6cb Doc imprv. 2021-09-02 19:11:00 -07:00
Yohann Dudouit c5b0129377 Replace static constexpr int with enum. 2021-09-02 19:04:47 -07:00
Yohann Dudouit 2dffe400aa Change InterpConfig default constructor. 2021-09-02 19:01:38 -07:00
Yohann Dudouit 46cf70049b some style in restriction.cpp. 2021-09-02 18:58:49 -07:00
Yohann Dudouit c07f50c71a Remove InterpolationManager::GetKey. 2021-09-02 18:40:36 -07:00
Yohann Dudouit 5fb5a9ee5b Rename info into face in mesh.cpp. 2021-09-02 18:22:04 -07:00
Yohann Dudouit dc3f16701f Remove dead code in mesh.cpp. 2021-09-02 18:18:14 -07:00
Yohann Dudouit c7ce2bb3d6 Don't invert signs yet. 2021-09-02 18:10:52 -07:00
Yohann Dudouit 24dde29cb0 Invert normal sign on ghost faces. 2021-09-02 18:09:06 -07:00
Yohann Dudouit e30eaaf4bf Doc imprv. 2021-09-02 18:07:20 -07:00
Yohann Dudouit 47aa908825 Refactor DGTrace. 2021-09-02 17:59:11 -07:00
Yohann Dudouit 64e95743a9 Minor fix. 2021-09-02 17:47:23 -07:00
Yohann Dudouit 4c3757dc44 Rewrite ParNCL2FaceRestriction::ComputeGatherIndices. 2021-09-02 17:44:01 -07:00
Yohann Dudouit 1e22977079 Rewrite ParNCL2FaceRestriction::ComputeScatterIndicesAndOffsets. 2021-09-02 17:42:29 -07:00
Yohann Dudouit f4a83b021c Rewrite ParNCL2FaceRestriction::Mult. 2021-09-02 17:40:50 -07:00
Yohann Dudouit 6eeabb3f6d Rename nc_side to master_side. 2021-09-02 17:18:44 -07:00
Yohann Dudouit 18df4d9a31 Add class ParNCH1FaceRestriction. 2021-09-02 16:56:58 -07:00
Yohann Dudouit d636a287e6 Add documentation to FaceInformation. 2021-09-02 15:39:56 -07:00
Yohann Dudouit 9c6c6d972a Rename FaceLocation::Interior into Local. 2021-09-02 15:02:47 -07:00
Yohann Dudouit 645c288fc3 Refactor ParNCL2FaceRestriction to use an InterpolationManager. 2021-09-02 14:14:20 -07:00
Yohann Dudouit 1b272bcfce Introduce InterpolationManager class. 2021-09-02 14:09:28 -07:00
Yohann Dudouit 4698aa2aad Rename info iinto face. 2021-09-02 11:27:49 -07:00
Yohann Dudouit a34fcc4beb Merge branch 'master' into yohann/pa-dg-ncmesh 2021-08-30 13:12:11 -07:00
Yohann Dudouit 51ab9a5201 Partial refactor of ParNCL2FaceRestriction. 2021-08-30 12:19:51 -07:00
Yohann Dudouit 57f6fa5e31 Add FaceInformation::IsShared. 2021-08-30 11:52:29 -07:00
Yohann Dudouit 10f94bd3d8 Minor refactoring. 2021-08-26 18:45:11 -07:00
Yohann Dudouit a0ff5b224e Refactor ParL2FaceRestriction. 2021-08-26 17:46:39 -07:00
Yohann Dudouit 6d0ec00469 Rename info into face. 2021-08-26 16:53:19 -07:00
Yohann Dudouit d687efa75e Refactor NCL2FaceRestriction. 2021-08-26 16:27:10 -07:00
Yohann Dudouit 19c00aa755 Refactor L2FaceRestriction. 2021-08-26 12:46:49 -07:00
Yohann Dudouit 0e5b2fae45 Improve code readability in NCMesh. 2021-08-26 10:03:17 -07:00
Yohann Dudouit 2573feaa77 Improve documentation of NCMesh. 2021-08-25 15:48:52 -07:00
Yohann Dudouit 51afd9c351 Fix a bug in NCMesh. 2021-08-25 15:46:01 -07:00
Yohann Dudouit 00fe120a12 Use enum type instead of magic numbers for refinements. 2021-08-25 15:45:38 -07:00
Yohann Dudouit c9fa398939 Take into account Ghost faces in FaceInformation. 2021-08-25 15:42:08 -07:00
Yohann Dudouit ceee771885 Add IsConforming in FaceInformation. 2021-08-25 15:41:21 -07:00
Yohann Dudouit 385e97341e Refactor NCL2FaceRestriction. 2021-08-25 15:40:02 -07:00
Yohann Dudouit 7125a6b086 Refactor of H1FaceRestriction. 2021-08-25 15:32:45 -07:00
Stowell, Mark L 96e05a1cbb Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	examples/makefile
#	linalg/hypre.cpp
2021-07-30 10:54:02 -07:00
Stowell, Mark L ef54c605a3 Bugfix 2021-07-24 10:08:37 -07:00
Stowell, Mark L 87747f0658 Post merge bugfix 2021-07-24 09:42:32 -07:00
Stowell, Mark L b1727831bc Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	fem/fe.cpp
2021-07-24 09:42:06 -07:00
Stowell, Mark L 53a874849d Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev
# Conflicts:
#	fem/doftrans.cpp
2021-07-07 13:35:06 -07:00
Stowell, Mark L 81392a988b Merge remote-tracking branch 'origin/master' into lo-dim-em-dev 2021-06-29 16:18:15 -07:00
Stowell, Mark L d5ef458b34 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-06-29 13:36:46 -07:00
Yohann Dudouit 4a75d3d064 Make GetFaceElementTransformations virtual.
- Make GetFaceElementTransformations virtual
- Add pmesh::GetFaceElementTransformations
- Add GetSharedFaceTransformationsByLocalIndex
2021-06-23 16:18:05 -07:00
Yohann Dudouit bca3c7d6c0 Add GetNumFacesWithGhost and IsOfFaceType. 2021-06-23 16:15:35 -07:00
Yohann Dudouit 893dab63a7 Improve ghost faces documentation. 2021-06-23 15:40:55 -07:00
Yohann Dudouit aebec64808 Change virtual for override in pmesh. 2021-06-23 15:40:36 -07:00
Stowell, Mark L 6671e10b05 Fixing copyright statements in unit tests 2021-06-15 14:18:48 -07:00
Stowell, Mark L babb985609 Merge remote-tracking branch 'origin/master' into lo-dim-em-dev 2021-06-15 13:48:02 -07:00
Stowell, Mark L 8af106a9cd Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-06-15 13:26:27 -07:00
Stowell, Mark L 0a3788ae2a Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-06-15 13:24:57 -07:00
Stowell, Mark L 46456a122e Renaming GetCDim to GetCurlDim 2021-06-10 15:55:57 -07:00
Yohann Dudouit 199cc085cf Make FaceInformation printable. 2021-06-03 15:19:29 -07:00
Yohann Dudouit c233928f99 Add more documentation for the face information. 2021-06-03 15:19:03 -07:00
Yohann Dudouit c567c02cee make style 2021-06-01 14:53:10 -07:00
Yohann Dudouit 826f962006 Add coumentation and asserts. 2021-06-01 14:40:30 -07:00
Yohann Dudouit 1b1a805d70 Refactor face retrictions. 2021-06-01 14:02:40 -07:00
Yohann Dudouit eb845c118c Add IsInterior and IsBoundary in FaceInformation 2021-06-01 13:51:47 -07:00
Stowell, Mark L 14bbb5a588 Updating copyright statements in unit tests 2021-06-01 13:38:05 -07:00
Stowell, Mark L 2b0eab7177 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-06-01 13:33:46 -07:00
Stowell, Mark L df25a261f5 merging with no-tet-reorder-dev 2021-06-01 10:57:05 -07:00
Yohann Dudouit 2ba909fa53 Better documentation for PointMatrix 2021-05-28 17:48:50 -07:00
Yohann Dudouit 64dd08320a Fix parenthesis issue. 2021-05-28 15:24:11 -07:00
Yohann Dudouit f87ce9723b Skip NonConformingMaster. 2021-05-28 15:17:51 -07:00
Yohann Dudouit 7d3e7db6b2 Don't count NonConformingMaster... 2021-05-28 14:18:17 -07:00
Yohann Dudouit 2a1805c8cd Fix silly copy/paste. 2021-05-28 13:41:29 -07:00
Yohann Dudouit 328fef8289 Update GetNFByType with GetFaceInformation. 2021-05-28 13:33:00 -07:00
Yohann Dudouit 13d280478b Update GetSigns with GetFaceInformation. 2021-05-28 13:29:28 -07:00
Yohann Dudouit 0cf01aa0c5 Update DGTrace with new GetFaceInformation. 2021-05-28 13:26:08 -07:00
Yohann Dudouit a2ab9fef67 Move GetNCFacesPtMat in public. 2021-05-28 13:17:30 -07:00
Yohann Dudouit 826a4406ed Minor edit to mesh. 2021-05-28 13:12:40 -07:00
Yohann Dudouit df3e3989c2 Update interface. 2021-05-28 12:57:48 -07:00
Yohann Dudouit a4ea8a28e1 Remove white spaces. 2021-05-28 12:52:06 -07:00
Yohann Dudouit 0db14e6db7 Fix some typos. 2021-05-28 12:49:53 -07:00
Yohann Dudouit 2117ec17c7 Add more documentation. 2021-05-28 12:34:17 -07:00
Yohann Dudouit ff0bce510d make style 2021-05-27 18:11:14 -07:00
Yohann Dudouit 03cbfdf2aa Remove test examples. 2021-05-27 18:05:08 -07:00
Yohann Dudouit 3cc0016704 Add ComputeCoarseToFineInterpolation to avoid some code duplication. 2021-05-27 16:19:31 -07:00
Yohann Dudouit 92ea168f68 Add coumentation. 2021-05-27 14:22:03 -07:00
Yohann Dudouit 4e6e99764d Add some documentation to PointMatrix. 2021-05-27 11:03:10 -07:00
Yohann Dudouit 8b57087e5c Propagate bugfix to ParNCL2FaceRestriction. 2021-05-26 17:31:50 -07:00
Stowell, Mark L f5448be3ec Resubmitting repo-check 2021-05-26 10:05:09 -07:00
Stowell, Mark L 6f6bed529c Partial copyright statement fix for testing 2021-05-26 09:58:55 -07:00
Stowell, Mark L f0265e61d6 Testing workflow 2021-05-26 09:54:45 -07:00
Yohann Dudouit 952dd5a3ed Fix another bug in the gather indices. 2021-05-24 16:30:52 -07:00
Yohann Dudouit 1be9a05195 make style. 2021-05-24 15:31:29 -07:00
Yohann Dudouit b00b5a8e63 Change GetFaceInformation's interface. 2021-05-24 15:15:50 -07:00
Yohann Dudouit 62fc2a997d Add ex9pa and ex9rotated to test pa dg on NCMesh. 2021-05-24 14:37:36 -07:00
Yohann Dudouit bebdb155fa Reorganize code 2021-05-24 14:36:50 -07:00
Yohann Dudouit 67888de8a3 Fix 2D and 3D orientation bugs. 2021-05-24 12:36:09 -07:00
Stowell, Mark L 768d645c62 Fixing cut-n-paste error 2021-05-23 11:16:01 -07:00
Stowell, Mark L 4b6d57dd28 Splitting into separate checks 2021-05-23 11:08:33 -07:00
Stowell, Mark L 258a322118 Adding intentionally incorrect copyright statements for testing 2021-05-23 10:44:38 -07:00
Stowell, Mark L 136928ca9d Adding C++ //-style comment to regex 2021-05-23 10:44:08 -07:00
Stowell, Mark L 871c2777a2 Testing copyright check 2021-05-23 10:39:42 -07:00
Stowell, Mark L 982d67e97a Testing copyright check 2021-05-23 10:37:11 -07:00
Stowell, Mark L 7aa59c4647 Testing new copyright check 2021-05-23 10:34:35 -07:00
Stowell, Mark L 0fbb94cbbc Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-05-21 18:13:33 -07:00
Stowell, Mark L 55c2e9d4c6 Reverting Joule 2021-05-21 16:14:55 -07:00
Stowell, Mark L 5e9357656e Reverting ex4 and ex4p 2021-05-21 16:12:20 -07:00
Stowell, Mark L b9a093b23c Removing temporary example 2021-05-21 16:08:55 -07:00
Stowell, Mark L b2508849f9 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev
# Conflicts:
#	examples/test_eigs_nd.cpp
2021-05-21 16:08:14 -07:00
Stowell, Mark L 204cec75c6 More test mesh removals 2021-05-21 16:04:16 -07:00
Stowell, Mark L ea53a26043 Removing test meshes 2021-05-21 16:03:21 -07:00
Stowell, Mark L c70ce7376a Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-05-21 11:50:03 -07:00
Stowell, Mark L d4a11d59ec Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	fem/fe.cpp
#	fem/fe.hpp
2021-05-19 09:33:51 -07:00
Stowell, Mark L d2a80c6a5d Adding new examples to cmakelists 2021-05-19 09:28:38 -07:00
Stowell, Mark L 752677c120 Adding new examples and output files to gitignore and makefile 2021-05-19 09:26:48 -07:00
Stowell, Mark L 974e86013d Adjusting sample run in ex31p 2021-05-19 09:04:24 -07:00
Stowell, Mark L 3193ddd74b Switching to temporary example name in makefile 2021-05-17 16:19:42 -07:00
Stowell, Mark L 8d475d14bf Cleaning up visualization in ex31p 2021-05-07 18:32:52 -07:00
Stowell, Mark L 481c6e2c2c Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	examples/makefile
2021-05-05 18:55:47 -07:00
Stowell, Mark L c9a55cd900 Adding serial version of ex30 2021-05-05 18:53:59 -07:00
Stowell, Mark L bde68eadbe Removing AMR example from makefile 2021-05-05 18:24:04 -07:00
Stowell, Mark L c2428156d5 Adjusting examples 2021-05-05 18:18:14 -07:00
Stowell, Mark L 974de079a0 Implementing GetTransferMatrix in R2D classes 2021-05-05 16:40:27 -07:00
Yohann Dudouit 6a8a33467f More tweaks on sample runs. 2021-05-05 12:34:18 -07:00
Yohann Dudouit a4d9f61114 Tweak sample runs 2021-05-05 12:32:52 -07:00
Yohann Dudouit d1486d8026 Add device sample runs on NCMesh. 2021-05-05 12:16:42 -07:00
Yohann Dudouit d97ce04481 Remove outdated comment. 2021-05-05 12:11:59 -07:00
Yohann Dudouit 917f9e0620 Fix a bug in coefficient evaluation. 2021-05-05 12:01:22 -07:00
Yohann Dudouit ab60ce3e2d Activate DG tests for NCMesh. 2021-05-05 12:01:03 -07:00
Yohann Dudouit 49a1cc415e Merge branch 'master' into yohann/pa-dg-ncmesh 2021-05-05 11:32:45 -07:00
Stowell, Mark L 7269a8cf40 Adding dummy implementations to avoid inheriting invalid functions 2021-05-02 21:30:05 -07:00
Stowell, Mark L c35b202656 Merge branch 'lo-dim-em-dev' of github.com:mfem/mfem into lo-dim-em-dev 2021-05-02 17:18:21 -07:00
Stowell, Mark L ab4ba8f4ec Implementing GetRestriction and GetTransferMatrix for R2D classes 2021-05-02 17:17:46 -07:00
Stowell, Mark L 5866cb1b85 Cleaning memcheck errors 2021-05-01 11:06:00 -07:00
Stowell, Mark L f705fafce4 More removing of mfem::out from new examples 2021-04-30 14:13:18 -07:00
Stowell, Mark L aeab5ace82 More renumbering of examples 2021-04-30 14:12:52 -07:00
Stowell, Mark L af0841a5b6 Shifting new examples 2021-04-30 13:52:26 -07:00
Stowell, Mark L 60f2f52241 Removing mfem::out from new example 2021-04-30 13:51:59 -07:00
Stowell, Mark L c0bf3c1a0d Shifting new examples 2021-04-30 13:51:25 -07:00
Stowell, Mark L 17ddd98630 Shifting new examples 2021-04-30 13:50:58 -07:00
Stowell, Mark L 1e09987fde Clarifying comments 2021-04-30 13:32:50 -07:00
Stowell, Mark L a794917770 Fixing issues found during @dylan-copeland's review 2021-04-29 20:36:19 -07:00
Yohann Dudouit 14725937f9 More of the same. 2021-04-28 11:44:56 -07:00
Yohann Dudouit 42bb97c1a4 Fix a bug with MFEM_SYNC_THREAD. 2021-04-28 11:38:57 -07:00
Yohann Dudouit 82bc1e8bfc Remove unused methods. 2021-04-28 11:38:35 -07:00
Yohann Dudouit 69de37ddb6 make style 2021-04-27 18:43:07 -07:00
Yohann Dudouit baa3ca223d Fix a bug introduced with the new FaceInformation
- Forgot to skip non-conforming master faces.
2021-04-27 18:40:01 -07:00
Yohann Dudouit 1c34e76c1f Fix ommited if conditions... 2021-04-27 17:55:22 -07:00
Yohann Dudouit 39cd66e5e8 Optimize Mult and MultTranspose for GPUs. 2021-04-27 17:25:34 -07:00
Yohann Dudouit 2d4316a42c More small fixes 2021-04-27 16:25:39 -07:00
Yohann Dudouit e799a999fe Small fix. 2021-04-27 16:21:09 -07:00
Yohann Dudouit af0dbf487d more style 2021-04-27 16:12:25 -07:00
Yohann Dudouit e1d453899f make style 2021-04-27 16:09:22 -07:00
Yohann b265d83286 Merge branch 'master' into yohann/pa-dg-ncmesh 2021-04-27 15:56:16 -07:00
Yohann Dudouit 4768b45dee Use GetFaceInformation in prestriction.cpp 2021-04-27 15:53:45 -07:00
Yohann Dudouit bcd2dc2e39 Use GetFaceInformation in restriction.cpp 2021-04-27 15:53:22 -07:00
Yohann Dudouit 8b8925b134 Add improve interface for face information.
- Add FaceLocation enum class
- Add FaceConformity enum class
- Add FaceInformation struct
- Add GetFaceInformation method
2021-04-27 15:52:55 -07:00
Yohann Dudouit 864521344e Add documentation to FaceInfo. 2021-04-27 15:50:13 -07:00
Yohann Dudouit 4fe70877cd Add some doc for nc_faces_orientation. 2021-04-26 14:21:38 -07:00
Yohann Dudouit 3fd61eecd4 Fix a bug in ParNCL2FaceRestriction. 2021-04-12 16:10:17 -07:00
Yohann Dudouit 2078e7fce3 Activate ParNCL2FaceRestriction. 2021-04-12 16:09:53 -07:00
Yohann Dudouit 91d5c78813 Add parallel support for NCMesh. 2021-04-08 18:26:14 -07:00
Stowell, Mark L c8162b996a Replacing deprecated mesh c'tors 2021-04-07 15:50:02 -07:00
Stowell, Mark L 343d0d635d Adjusting example numbers in comments 2021-04-07 15:29:46 -07:00
Stowell, Mark L 83848a4773 Renumbering ex28p -> ex29p 2021-04-07 15:21:04 -07:00
Stowell, Mark L be90dfd995 Renumbering ex29p -> ex30p 2021-04-07 15:19:41 -07:00
Stowell, Mark L a079b84981 Renumbering ex30p -> ex31p 2021-04-07 15:18:32 -07:00
Stowell, Mark L a5b96cc951 Expanding tests of R1D classes 2021-04-07 15:14:33 -07:00
Stowell, Mark L 450e23fdcc Updating FE_Collection order 2021-04-07 15:09:28 -07:00
Yohann Dudouit 4a1f4d4223 Some doc. 2021-04-07 12:29:00 -07:00
Yohann Dudouit 7284dc3824 Some cleaning 2021-04-07 12:16:46 -07:00
Yohann Dudouit 7f6d23730e Add a hack in mesh and ncmesh to store the nc face orientation. 2021-04-07 11:44:49 -07:00
Stowell, Mark L 157dbc7c33 Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	examples/makefile
#	tests/unit/fem/test_2d_bilininteg.cpp
#	tests/unit/fem/test_lin_interp.cpp
2021-04-07 11:26:48 -07:00
Yohann Dudouit 495bc95d50 Minor 2021-04-02 15:06:33 -07:00
Yohann Dudouit 0cca55a3b4 Update interface. 2021-04-02 13:55:14 -07:00
Yohann Dudouit 213a3a793a Merge branch 'master' into yohann/pa-dg-ncmesh 2021-04-02 13:29:57 -07:00
Yohann Dudouit f182378fbb Merge branch 'master' into yohann/pa-dg-ncmesh 2021-04-02 13:29:00 -07:00
Yohann Dudouit 583bc2ad32 Minor 2021-04-02 13:27:11 -07:00
Yohann Dudouit f385f975fa Add orientation in NCMesh. 2021-04-01 11:09:31 -07:00
Yohann Dudouit d2364caddd Prepare code for 3D... 2021-03-29 12:53:17 -07:00
Yohann Dudouit 0d384b6248 2D seems to be finally working! 2021-03-11 15:17:38 -08:00
Yohann Dudouit 2869972f15 Minor 2021-03-08 11:11:25 -08:00
Stowell, Mark L 7c6d1098d1 Small correction in a comment 2021-02-25 11:06:00 -08:00
Stowell, Mark L 8cd2508e2c Switching function space to obtain higher integration order 2021-02-23 21:14:11 -08:00
Stowell, Mark L 4a58ca8c22 Removing old code 2021-02-23 21:13:22 -08:00
Stowell, Mark L 0c047b1140 Changing shared face lookups 2021-02-23 20:49:58 -08:00
Stowell, Mark L 0ddffa9391 Removing deprecated function call 2021-02-23 17:02:31 -08:00
Stowell, Mark L 8f15924abb Moving commonly used variables to class definition 2021-02-23 17:02:15 -08:00
Stowell, Mark L d36b02f69e Expanding unit tests to include ND prisms 2021-02-23 14:22:26 -08:00
Mark L. Stowell 9771012264 Merge pull request #2064 from mfem/rt-prism-dev
Small changes for Raviart-Thomas Prisms [rt-prism-dev]
2021-02-22 15:19:12 -08:00
Stowell, Mark L b4def90bbd Merge remote-tracking branch 'origin/nd-prism-dev' into rt-prism-dev 2021-02-22 15:03:43 -08:00
Stowell, Mark L ba3322fe4d Adding mixed cube example meshes 2021-02-22 14:41:08 -08:00
Stowell, Mark L 1597ed2fe3 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-02-22 14:01:53 -08:00
Stowell, Mark L 57e9696056 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-02-22 13:36:20 -08:00
Yohann Dudouit 277112253c Fix indices in interpolators. 2021-02-17 16:38:56 -08:00
Yohann Dudouit b24ac45dc3 Handle non-conforming faces in H1FaceRestriction. 2021-02-17 16:20:23 -08:00
Yohann Dudouit e9cff9edad Add NCL2FaceRestriction. 2021-02-17 16:19:43 -08:00
Yohann Dudouit 365070ad88 Handle non-conforming faces for DGTrace Coefficient. 2021-02-17 16:17:44 -08:00
Yohann Dudouit 9cd7b94c2f Make GetSign handle non-conforming meshes. 2021-02-17 16:16:53 -08:00
Stowell, Mark L b55d8dbe2e Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2021-02-09 15:59:41 -08:00
Yohann Dudouit ad8c7967d3 Add documentation to L2FaceRestriction. 2021-02-09 15:33:04 -08:00
Stowell, Mark L 2a2f450bd8 Merge remote-tracking branch 'origin/master' into lo-dim-em-dev 2021-02-09 14:07:17 -08:00
Yohann Dudouit 77b16c1101 Compute gather indices/ 2021-02-09 11:23:56 -08:00
Yohann Dudouit 03ab1e50f6 Introduce NCL2FaceRestriction class. 2021-02-05 11:14:07 -08:00
Yohann Dudouit a0a0a8132a Support NCMesh for GetNFByType 2021-02-05 11:13:35 -08:00
Yohann Dudouit 5253b7c9ab Add NCMesh data accessor. 2021-02-05 11:13:08 -08:00
Stowell, Mark L ed22bc7034 Closing sockets 2021-02-04 14:29:11 -08:00
Stowell, Mark L 055640006f User control of max AMR iterations 2021-02-04 12:59:37 -08:00
Stowell, Mark L 05996d956c Fixing a nameclash 2021-02-04 12:56:42 -08:00
Stowell, Mark L 9c9048960f Removing superfluous MPI_Finalize 2021-02-04 09:52:23 -08:00
Stowell, Mark L b0187ee0ae Adding another temporary line to .gitignore for new example 2021-02-03 16:05:51 -08:00
Stowell, Mark L f5be7b02b4 Adding an AMR example using the R2D finite elements 2021-02-03 15:45:16 -08:00
Stowell, Mark L 35f6566fb4 make style 2021-02-02 15:38:36 -08:00
Stowell, Mark L 474d0deb3d Adding GetLocalInterpolation methods to R2D classes 2021-02-02 15:38:03 -08:00
Stowell, Mark L fa9532905f Cleaning up new examples 2021-02-02 15:37:36 -08:00
Stowell, Mark L 1322966a1c Temporarily adding line to gitignore for proposed examples 2021-02-02 10:30:05 -08:00
Stowell, Mark L 77ff2de329 Fixing typo 2021-02-02 10:10:33 -08:00
Stowell, Mark L fd1063553b Cleaning up new example 2021-02-01 19:10:36 -08:00
Stowell, Mark L bd15948f5d make style 2021-02-01 19:08:34 -08:00
Stowell, Mark L 1cfee26360 Removing outdated example 2021-02-01 18:53:32 -08:00
Stowell, Mark L 803302cace Adding R2D classes to IdentityInterpolator unit tests 2021-02-01 18:49:23 -08:00
Stowell, Mark L 7882302a48 Fixing sizes of internal vectors in InnerProductCoefficient 2021-02-01 18:48:39 -08:00
Stowell, Mark L c55950c7b9 Switching to CalcPhysCurlShape in GridFunction::GetCurl 2021-02-01 18:48:09 -08:00
Stowell, Mark L 9942cdda1d Supporting lo dim Nedelec spaces in HypreAMS 2021-02-01 18:47:27 -08:00
Stowell, Mark L 4acd294ac7 Fixing Project methods on R2D classes 2021-02-01 18:46:58 -08:00
Stowell, Mark L 48a1aae5e1 Adding Project (fe version) to RT_R2D_FiniteElement class 2021-02-01 14:36:29 -08:00
Stowell, Mark L d91d5bcee4 Merge remote-tracking branch 'origin/master' into lo-dim-em-dev 2021-02-01 12:52:34 -08:00
Stowell, Mark L 685f467c15 Adding new examples to makefile 2021-02-01 12:51:58 -08:00
Stowell, Mark L de701f25c6 make style 2021-02-01 12:51:31 -08:00
Stowell, Mark L 74c68fce84 Using GridFunction::CurlDim in CurlGridFunctionCoefficient 2021-02-01 12:51:10 -08:00
Stowell, Mark L e1d7732596 Adding Project (fe version) to ND_R2D_FiniteElement 2021-02-01 12:49:59 -08:00
Stowell, Mark L a8d334e496 Adding convenience method to determine dimension of curl in GridFunction 2021-02-01 12:48:54 -08:00
Stowell, Mark L aa5fbe1ec7 Adding anisotropic version of ex3p which supports 1d and 2D meshes 2021-01-31 13:42:10 -08:00
Stowell, Mark L 6e13fa1728 Renaming new eigenmode example 2021-01-31 13:38:53 -08:00
Stowell, Mark L 096d9d311e Adding 1D visualization 2021-01-31 13:36:12 -08:00
Stowell, Mark L 15490cc022 Adding shift in 1D case to handle singular curl curl operator 2021-01-31 13:35:32 -08:00
Stowell, Mark L ed487167ec Adding 1D prototype example 2021-01-29 10:38:55 -08:00
Stowell, Mark L c709f08e4d Avoiding a compiler warning 2021-01-28 21:31:07 -08:00
Stowell, Mark L 4046548876 Fixing boundary issues in R1D unit tests 2021-01-28 17:51:55 -08:00
Stowell, Mark L e8d9a44ff5 Adding constants to test functions to catch boundary issues 2021-01-28 17:51:09 -08:00
Stowell, Mark L 048dcea3e9 Fixing BC normal issue in 1D element unit tests 2021-01-28 17:23:13 -08:00
Stowell, Mark L 4dbe64199b Handling possible cross product cases in MixedVectorIntegrator 2021-01-28 17:22:31 -08:00
Stowell, Mark L 572ec937f6 Experimenting with lo-dim curl integrators 2021-01-28 14:56:58 -08:00
Stowell, Mark L f4a5b560b8 Fixing DenseMatrix size in unit test 2021-01-28 14:15:15 -08:00
Stowell, Mark L f162a4d423 make style 2021-01-28 11:20:51 -08:00
Stowell, Mark L 08142464a8 Adding 0D case to VectorFEBoundaryTangentLFIntegrator 2021-01-28 11:20:22 -08:00
Stowell, Mark L 76c80d0e00 Adding point elements to R1D FECollections 2021-01-28 11:19:41 -08:00
Stowell, Mark L 76146f02ec Adding ND_R1D_PointElement 2021-01-28 11:19:14 -08:00
Stowell, Mark L a12c1088a6 Adding unit test for R1D finite elements 2021-01-28 10:10:41 -08:00
Stowell, Mark L eb71c5aa43 Fixing test function 2021-01-28 09:59:58 -08:00
Stowell, Mark L bde9cf899a Adding error message 2021-01-28 09:59:37 -08:00
Stowell, Mark L 192bf06859 Handling 1D case in BoundaryNormalLFIntegrator 2021-01-28 09:59:16 -08:00
Stowell, Mark L faed953387 Overriding default map types in ND_RnD classes 2021-01-28 09:58:17 -08:00
Stowell, Mark L 5a5b4485ec Implementing specialized project method for RT_R1D_SegmentElement 2021-01-28 09:57:41 -08:00
Stowell, Mark L 330ce1c208 Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	fem/fe.cpp
2021-01-26 13:38:12 -08:00
Stowell, Mark L 3f51364980 Fixing 1D elements 2021-01-20 14:15:15 -08:00
Stowell, Mark L a1566e670b Adding R2D example 2021-01-08 21:40:39 -08:00
Stowell, Mark L b210044a62 make style 2021-01-08 21:40:05 -08:00
Stowell, Mark L 0bee53d2e7 Implementing ProjectCurl for RT_R2D finite elements 2021-01-08 21:39:51 -08:00
Stowell, Mark L 062d920648 Fixing vector dimension in MixedScalarVectorIntegrator 2021-01-08 20:28:57 -08:00
Stowell, Mark L aa675c468e Merge remote-tracking branch 'origin/master' into lo-dim-em-dev
# Conflicts:
#	fem/bilininteg.cpp
2021-01-08 20:10:28 -08:00
Stowell, Mark L 09a2baa1e9 Expanding 2D integrator unit tests for comparison with R2D classes 2021-01-08 19:48:45 -08:00
Stowell, Mark L 4d00ff7d4e Adding unit tests for R2D classes 2021-01-08 19:48:03 -08:00
Stowell, Mark L d4d5ff2681 Using vdim in integrators 2021-01-08 19:47:39 -08:00
Stowell, Mark L dfe996845c Cleaning up trace finite elements for R2D classes 2021-01-08 19:46:00 -08:00
Stowell, Mark L b32c5465cb Implementing ProjectGrad in ND_R2D finite elements 2021-01-08 19:45:10 -08:00
Stowell, Mark L fff25b5884 Bugfix in RT_R2D finite elements 2021-01-08 19:43:59 -08:00
Stowell, Mark L a1bd0afdad Adding MatrixProductCoefficient 2021-01-08 19:42:50 -08:00
Stowell, Mark L d2afb6b21c Adding initial unit tests for new FiniteElement classes 2020-12-03 15:57:35 -08:00
Stowell, Mark L 3c084ea464 Changing names from P2D to R2D 2020-12-03 15:56:33 -08:00
Stowell, Mark L e70c58e529 Implementing triangular finite elements for P2D cases 2020-12-03 15:44:11 -08:00
Stowell, Mark L 0779827483 Fixing fe.cpp which was broken by merge conflicts 2020-12-01 10:40:59 -08:00
Stowell, Mark L ae3a2d224e Merge remote-tracking branch 'origin/nd-prism-dev' into rt-prism-dev
# Conflicts:
#	fem/doftrans.hpp
#	fem/fe.cpp
2020-12-01 10:30:39 -08:00
Stowell, Mark L 9635fcb308 Removing redundant cases due to merge 2020-12-01 09:41:21 -08:00
Stowell, Mark L df20a2ec8f Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2020-12-01 09:27:32 -08:00
Stowell, Mark L 24183ff650 Moving common methods to new base class for P2D FEs 2020-11-12 10:19:55 -08:00
Stowell, Mark L cd409c19c1 Switching to new FiniteElement::GetVDim() in GridFunction::GetVectorValue 2020-11-09 15:02:33 -08:00
Stowell, Mark L e68d718dfc Fixing compiler warning 2020-11-09 15:00:23 -08:00
Stowell, Mark L af0c434003 Adding trace collections for P2D finite elements 2020-11-09 15:00:02 -08:00
Stowell, Mark L 7f2735fa42 Replacing CalcVShape for ND_P2D_Quads 2020-11-09 14:58:47 -08:00
Stowell, Mark L 0331947f8e Fixed an ordering issue on high order z-directed edge dofs 2020-11-09 14:58:06 -08:00
Stowell, Mark L ff5cb20a6b Adding FE_Collections for ND_P2D elements 2020-11-07 14:50:30 -08:00
Stowell, Mark L 9c4445542e Adding ND_P2D_SegmentElement 2020-11-07 14:49:30 -08:00
Stowell, Mark L 785a7a178e Correcting comment on RT_P2D_QuadrilateralElement 2020-11-07 14:03:04 -08:00
Stowell, Mark L 7060cb1f3b Adding RT_P2D_QuadrilateralElement 2020-11-07 14:01:45 -08:00
Stowell, Mark L d81befc803 Adding ND_P2D_QuadrilateralElement basis 2020-11-07 11:09:08 -08:00
Stowell, Mark L 9ef1a6c410 Adding RT basis restricted to 1D 2020-11-01 11:39:17 -08:00
Stowell, Mark L a1eae79725 Using vdim and cdim in CurlCurl and VectorFEMass integrators 2020-11-01 10:57:26 -08:00
Stowell, Mark L 4e02c55c2f Cleaning up ND_P1D classes 2020-11-01 10:53:29 -08:00
Stowell, Mark L 4d9c013572 Adding vector and curl dimensions to FE classes 2020-11-01 10:52:57 -08:00
Stowell, Mark L d0c7070864 Adding FE Collection for ND_P1D class 2020-10-31 11:37:14 -07:00
Stowell, Mark L c8a4398cc4 make style 2020-10-31 11:36:45 -07:00
Stowell, Mark L 2aeee46c43 Adding vector and curl dimension member functions to FiniteElement 2020-10-31 11:36:11 -07:00
Stowell, Mark L 3962d6fe3f Adding prototype 1D ND basis 2020-10-30 13:23:19 -07:00
Stowell, Mark L 9669d77b58 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2020-10-22 09:30:18 -07:00
Stowell, Mark L 9c9a1ae0f5 Adding a new mixed mesh to test code 2020-10-22 09:27:14 -07:00
Stowell, Mark L 8d3f9e4250 Changing member data name in new FE classes 2020-10-22 09:26:53 -07:00
Stowell, Mark L 3830d2bac7 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2020-10-21 16:20:35 -07:00
Stowell, Mark L 9ae6c02639 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev
# Conflicts:
#	.travis.yml
#	fem/fe.hpp
#	fem/pfespace.cpp
#	tests/unit/fem/test_calcshape.cpp
2020-10-14 20:14:05 -07:00
Stowell, Mark L 99cef31e00 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-08-29 14:54:38 -07:00
Stowell, Mark L c0b7ec980b Adding comments to debug a Travis run 2019-08-29 12:55:36 -07:00
Stowell, Mark L e18230b9e6 Testing build order in Travis 2019-08-29 11:29:22 -07:00
Stowell, Mark L 38d07ed155 Experimenting with order of Travis runs 2019-08-29 11:02:52 -07:00
Stowell, Mark L a0b87ba7ac Forgot the return value in a test function 2019-08-29 10:58:57 -07:00
Stowell, Mark L b80deb1a41 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-08-29 10:28:24 -07:00
Stowell, Mark L 42f6acc0d6 Adding CalcCurlShape unit tests 2019-08-29 10:26:51 -07:00
Stowell, Mark L c5cb938b9b Adding new unit tests to CMakeLists 2019-08-29 10:21:12 -07:00
Stowell, Mark L 0c54fce28f make style 2019-08-29 09:52:05 -07:00
Stowell, Mark L 35277a2a22 Adjusting the order in test_calcdivshape to be more consistent with other tests 2019-08-29 09:51:48 -07:00
Stowell, Mark L a6b591f464 Fixing a small typo 2019-08-29 09:51:08 -07:00
Stowell, Mark L db4c4c5a55 Adding unit tests for CalcDShape 2019-08-29 09:50:29 -07:00
Stowell, Mark L da5e16d7de Setting Nodes in RT_WedgeElement to resolve errors in unit tests 2019-08-29 00:29:01 -07:00
Stowell, Mark L 94653c3bd1 Adding unit test for checking CalcDivShape on reference elements (currently fails for Prisms and Cubes) 2019-08-28 23:44:14 -07:00
Stowell, Mark L 72abd2d1fb Fixing RT_Wedge error found with CalcVShape unit test 2019-08-28 16:34:54 -07:00
Stowell, Mark L a13adce1bf Adding unit tests for RT basis (currently showing a failure on Prism elements) 2019-08-28 16:19:57 -07:00
Stowell, Mark L 5fa282281c Moving transformation setup into a separate function 2019-08-28 16:09:34 -07:00
Stowell, Mark L b337296976 Adding unit tests for H1 and L2 bases on Prisms 2019-08-28 15:52:31 -07:00
Stowell, Mark L fb509dcce9 Adding unit tests for Nedelec elements of various types including prisms 2019-08-28 15:51:11 -07:00
Stowell, Mark L 03024ae2d4 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-08-28 13:41:33 -07:00
Stowell, Mark L 34266f5813 Returning early from CheckNDSTriaDofs if possible (to avoid issue with NURBS_FECollection) 2019-05-23 10:52:10 -07:00
Stowell, Mark L 617641a076 Returning early from CheckNDSTriaDofs if possible (to avoid issue with NURBS_FECollection) 2019-05-23 10:51:48 -07:00
Stowell, Mark L ba7738dd08 Avoiding the use of VDoFTrans when vdim == 1 2019-05-21 10:46:21 -07:00
Stowell, Mark L 134e106f2f Avoiding the use of VDoFTrans when vdim == 1 2019-05-21 10:45:51 -07:00
Stowell, Mark L b08a06187e Adding explanation of the uses of the DofTransformation objects (so that I won't forget why it's designed the way it is). 2019-05-21 10:23:16 -07:00
Stowell, Mark L 7d9e96f375 Fixing a bug in DofTransformation that impacts the discrete curl operator and hence ex4p 2019-05-21 10:23:05 -07:00
Stowell, Mark L fa41117e0c Adding explanation of the uses of the DofTransformation objects (so that I won't forget why it's designed the way it is). 2019-05-21 10:22:18 -07:00
Stowell, Mark L b88bf26d20 Fixing a bug in DofTransformation that impacts the discrete curl operator and hence ex4p 2019-05-21 10:22:05 -07:00
Stowell, Mark L a832c32a5f Adding refinement controls to ex4 and ex4p 2019-05-19 17:28:22 -07:00
Stowell, Mark L 4a99ad399f Fixing orientation of DoFs on the base of a prism 2019-05-19 17:16:33 -07:00
Stowell, Mark L 9b801d1e19 Setting nodes in RT_Wedge 2019-05-19 17:15:56 -07:00
Stowell, Mark L a24f0d8210 Adding RT_Wedge to RT_FECollection 2019-05-19 17:15:01 -07:00
Stowell, Mark L 2d8454ca39 Replacing accidentally removed lines 2019-05-19 16:31:05 -07:00
Stowell, Mark L 8a960bfeb5 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev
# Conflicts:
#	examples/ex3p.cpp
#	fem/fe_coll.cpp
2019-05-19 14:07:55 -07:00
Stowell, Mark L a20467d44f Removing temporary test code 2019-05-19 14:05:00 -07:00
Stowell, Mark L 99483d9f61 Changing location of preprocessor macros to avoid issue with "make style" 2019-05-19 14:03:23 -07:00
Stowell, Mark L 73938c3f5c Fix error in the dof order of ND_WedgeElement 2019-05-17 16:16:34 -07:00
Stowell, Mark L 7a1ed06bdd Fix incorrect size of DenseMatrix for CalcCurlShape 2019-05-17 16:15:58 -07:00
Stowell, Mark L 46d9ac8b67 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-05-15 00:07:34 -07:00
Stowell, Mark L cd5d7a8698 Adding Prism support to RefinementOperator 2019-05-14 20:22:44 -07:00
Stowell, Mark L 200a028c5f Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-05-14 20:21:18 -07:00
Stowell, Mark L 55b44b6417 Adding simple tests for tets and prisms 2019-05-13 16:03:01 -07:00
Stowell, Mark L 444de83be3 merging in changes from no-tet-reorder-dev 2019-05-13 15:51:45 -07:00
Stowell, Mark L f5656d52b1 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-05-13 12:05:10 -07:00
Stowell, Mark L 6d32955f4f Adding meshes of the individual reference elements 2019-05-11 21:03:40 -07:00
Stowell, Mark L 3d972137bc Adding support for mixed meshes 2019-05-11 21:00:30 -07:00
Stowell, Mark L efe4ee553a Setting Nodes for new ND_Wedge elements 2019-05-11 20:45:40 -07:00
Stowell, Mark L 1527388bae make style 2019-05-11 17:03:59 -07:00
Stowell, Mark L bd6181b45f Adding refinement control to ex3p 2019-05-11 17:02:36 -07:00
Stowell, Mark L fa0cfe6b18 Adding temporary files for testing wedge elements 2019-05-11 12:10:36 -07:00
Stowell, Mark L 7f9eecbab9 Simplifying transformation of quad faces 2019-05-11 11:09:58 -07:00
Stowell, Mark L b1ccc9cd1a Moving old comment 2019-05-11 11:09:29 -07:00
Stowell, Mark L 0188f05bf6 Adding prism implementations to doftrans.cpp 2019-05-10 21:15:06 -07:00
Stowell, Mark L 49370af793 Merge remote-tracking branch 'origin/no-tet-reorder-dev' into nd-prism-dev 2019-05-10 20:47:42 -07:00
Stowell, Mark L 7c980a9d50 Merge remote-tracking branch 'origin/master' into nd-prism-dev
# Conflicts:
#	miniapps/tools/display-basis.cpp
2019-04-12 15:05:10 -07:00
Stowell, Mark L 15ec593bac Merge remote-tracking branch 'origin/master' into nd-prism-dev 2019-04-09 14:13:35 -07:00
Stowell, Mark L 4199956201 Adding GetLocalRestriction and GetTransferMatrix methods for RT and ND Wedge finite elements 2019-04-03 16:18:00 -07:00
Stowell, Mark L 8b1a046163 Merge remote-tracking branch 'origin/master' into nd-prism-dev 2019-04-01 11:12:03 -07:00
Stowell, Mark L 14b392115b Merge remote-tracking branch 'origin/master' into nd-prism-dev 2019-01-20 00:06:01 -08:00
Stowell, Mark L bfbcb831d6 Merge remote-tracking branch 'origin/master' into nd-prism-dev 2018-11-26 14:58:31 -08:00
Stowell, Mark L c81b0b4bdd Bugfix in RT_WedgeElement basis functions 2018-10-31 14:25:43 -07:00
Stowell, Mark L 64abdf642d Bugfix in high order ND_WedgeElement basis functions 2018-10-31 14:06:35 -07:00
Stowell, Mark L c7fd770262 Merge remote-tracking branch 'origin/master' into nd-prism-dev 2018-10-31 11:00:12 -07:00
Stowell, Mark L d003763420 make style 2018-10-31 10:58:09 -07:00
Stowell, Mark L 34fcc8080e Removing unneeded temporary variable 2018-10-31 10:57:59 -07:00
Stowell, Mark L 28f03531c4 Removing debugging code 2018-10-31 10:56:29 -07:00
Stowell, Mark L 6292ec03fa Adding first draft of RT_WedgeElement 2018-10-30 00:33:36 -07:00
Stowell, Mark L 931eac3432 Adding a name for the WEDGE element type in display-basis.cpp 2018-10-29 10:41:35 -07:00
Stowell, Mark L b4eed3e360 Adding support for displaying basis functions on Wedge elements 2018-10-26 21:51:32 -07:00
Stowell, Mark L 63cecd20a8 Merge remote-tracking branch 'origin/master' into nd-prism-dev 2018-10-26 21:30:41 -07:00
Stowell, Mark L 2a5e013187 Merge remote-tracking branch 'origin/master' into nd-prism-dev 2018-10-10 21:19:12 -07:00
Stowell, Mark L 956a18fa6b Merge remote-tracking branch 'origin/prism-dev' into nd-prism-dev 2018-09-25 13:28:36 -07:00
Stowell, Mark L e1fda1bb76 Changing "Prism" to "Wedge" in Nedelec basis 2018-08-31 13:52:22 -07:00
Stowell, Mark L 99c8c36161 Merge with prism-dev 2018-08-31 13:51:20 -07:00
Stowell, Mark L b1d750d4b6 Revert "Moving Nedelec prism code to a sub-branch"
This reverts commit 8d4948dc74.
2018-08-31 13:43:19 -07:00
825 changed files with 39711 additions and 7444 deletions
+1 -1
View File
@@ -5,7 +5,7 @@ channels:
dependencies:
- xeus-cling=0.13.0
- xwidgets=0.26.0
# NOTE: it's possible these aren't needed for the lab frontend
# NOTE: it is possible that these are not needed for the lab frontend
- widgetsnbextension=3.5.1
- pip
- pip:
+48
View File
@@ -0,0 +1,48 @@
Finite Element Discretization Library
__
_ __ ___ / _| ___ _ __ ___
| '_ ` _ \ | |_ / _ \| '_ ` _ \
| | | | | || _|| __/| | | | | |
|_| |_| |_||_| \___||_| |_| |_|
https://mfem.org
This directory contains the GitHub CI scripts for MFEM.
Note that some of these scripts use the shared MFEM GitHub Actions from the external mfem/github-actions repository:
https://github.com/mfem/github-actions
For a particular action, e.g. `mfem/github-actions/build-mfem@v2.1`, the `v2.1` suffix denotes the branch in the above from which the action is taken.
The current CI workflows are:
### `repo-check.yml`
Runs a number of static repository-level sanity checks.
- `file-headers-check` checks copyright date, license, etc. using the `--copyright`, `--license` and `--release` options of the `config/githooks/pre-push` script.
- `code-style` checks the code style using the `--style` option of the `config/githooks/pre-push` script.
- `documentation` checks the documentation build using the `tests/scripts/documentation` script.
- `branch-history` guards against accidental commits of large files using the `--history` option of the `config/githooks/pre-push` script.
### `mfem-analysis.yml` (`build-analysis`)
Checks if the code builds and satisfies minimal requirements.
- `gitignore` builds hypre, METIS, and MFEM using `mfem/github-actions/build-hypre`, `mfem/github-actions/build-metis`, and `mfem/github-actions/build-mfem` and checks for correct `.gitignore` settings by running the `tests/scripts/gitignore` script.
### `builds-and-tests.yml`
Runs a matrix of builds and tests runs with different compilers, OS, mfem/hypre settings, etc. Also processes and upload Codecov reports.
Uses the following GitHub Actions from https://github.com/mfem/github-actions:
- `mfem/github-actions/build-hypre`
- `mfem/github-actions/build-metis`
- `mfem/github-actions/build-mfem`
- `mfem/github-actions/upload-coverage`
+2 -2
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -166,7 +166,7 @@ jobs:
# MFEM build and test
- name: build
uses: mfem/github-actions/build-mfem@v2.0
uses: mfem/github-actions/build-mfem@v2.1
with:
os: ${{ matrix.os }}
target: ${{ matrix.target }}
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+3 -2
View File
@@ -51,8 +51,8 @@ examples/ex1[04-9]
examples/ex1[0-9]p
examples/ex2[0-9]
examples/ex2[0-9]p
examples/ex30
examples/ex30p
examples/ex3[0-9]
examples/ex3[0-9]p
examples/refined.mesh
examples/displaced.mesh
@@ -78,6 +78,7 @@ examples/deformed.*
examples/velocity.*
examples/elastic_energy.*
examples/mode_*
examples/mode_deriv_*
examples/ex5-p-*.bp
examples/ex9-p-*.bp
examples/ex12-p-*.bp
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+3 -3
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -18,14 +18,14 @@ variables:
- shell
- corona
rules:
# Dont run corona jobs if...
# Don't run corona jobs if...
# Note: This makes corona an "opt-in" machine. To activate builds on corona
# for a given GitLab clone of MFEM, go to Setting/CI-CD/variables, and set
# "ON_CORONA" to "ON". An LC account on for corona is required to trigger a
# pipeline there.
- if: '$CI_COMMIT_BRANCH =~ /_cnone/ || $ON_CORONA != "ON"'
when: never
# Dont run autotest update if...
# Don't run autotest update if...
- if: '$CI_JOB_NAME =~ /report/ && $AUTOTEST != "YES"'
when: never
# Report success on success status
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+7 -7
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -20,8 +20,8 @@
- |
(
date
echo "Waiting to aquire lock on '$PWD/autotest.lock' ..."
# try to get an excusive lock on fd 9 (autotest.lock) repeating the try
echo "Waiting to acquire lock on '$PWD/autotest.lock' ..."
# try to get an exclusive lock on fd 9 (autotest.lock) repeating the try
# every 5 seconds; simply using no timeout, i.e. 'flock 9', causes the
# command to hang indefinitely sometimes, so we use the timeout & retry
# as a workaround; we may want to add a counter for the number of
@@ -29,7 +29,7 @@
while ! flock -w 5 9; do
true
done
echo "Aquired lock on '$PWD/autotest.lock'"
echo "Acquired lock on '$PWD/autotest.lock'"
date
# Report SUCCESS while holding the file lock on 'autotest.lock'.
# The next script uses the following environment variables:
@@ -55,8 +55,8 @@
- |
(
date
echo "Waiting to aquire lock on '$PWD/autotest.lock' ..."
# try to get an excusive lock on fd 9 (autotest.lock) repeating the try
echo "Waiting to acquire lock on '$PWD/autotest.lock' ..."
# try to get an exclusive lock on fd 9 (autotest.lock) repeating the try
# every 5 seconds; simply using no timeout, i.e. 'flock 9', causes the
# command to hang indefinitely sometimes, so we use the timeout & retry
# as a workaround; we may want to add a counter for the number of
@@ -64,7 +64,7 @@
while ! flock -w 5 9; do
true
done
echo "Aquired lock on '$PWD/autotest.lock'"
echo "Acquired lock on '$PWD/autotest.lock'"
date
# Report FAILURE while holding the file lock on 'autotest.lock'.
# The next script uses the following environment variables:
+4 -4
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -45,8 +45,8 @@ setup_baseline:
- |
(
date
echo "Waiting to aquire lock on '$PWD/autotest.lock' ..."
# try to get an excusive lock on fd 9 (autotest.lock) repeating the try
echo "Waiting to acquire lock on '$PWD/autotest.lock' ..."
# try to get an exclusive lock on fd 9 (autotest.lock) repeating the try
# every 5 seconds; simply using no timeout, i.e. 'flock 9', causes the
# command to hang indefinitely sometimes, so we use the timeout & retry
# as a workaround; we may want to add a counter for the number of
@@ -54,7 +54,7 @@ setup_baseline:
while ! flock -w 5 9; do
true
done
echo "Aquired lock on '$PWD/autotest.lock'"
echo "Acquired lock on '$PWD/autotest.lock'"
date
# clone/update the autotest repo while holding the file lock on
# 'autotest.lock'
+7 -7
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -34,8 +34,8 @@ setup:
- |
(
date
echo "Waiting to aquire lock on '$PWD/mfem-data.lock' ..."
# try to get an excusive lock on fd 9 (mfem-data.lock) repeating the try
echo "Waiting to acquire lock on '$PWD/mfem-data.lock' ..."
# try to get an exclusive lock on fd 9 (mfem-data.lock) repeating the try
# every 5 seconds; simply using no timeout, i.e. 'flock 9', causes the
# command to hang indefinitely sometimes, so we use the timeout & retry
# as a workaround; we may want to add a counter for the number of
@@ -43,7 +43,7 @@ setup:
while ! flock -w 5 9; do
true
done
echo "Aquired lock on '$PWD/mfem-data.lock'"
echo "Acquired lock on '$PWD/mfem-data.lock'"
date
# clone/update the mfem/data repo while holding the file lock on
# 'mfem-data.lock'
@@ -67,8 +67,8 @@ setup:
- |
(
date
echo "Waiting to aquire lock on '$PWD/autotest.lock' ..."
# try to get an excusive lock on fd 9 (autotest.lock) repeating the try
echo "Waiting to acquire lock on '$PWD/autotest.lock' ..."
# try to get an exclusive lock on fd 9 (autotest.lock) repeating the try
# every 5 seconds; simply using no timeout, i.e. 'flock 9', causes the
# command to hang indefinitely sometimes, so we use the timeout & retry
# as a workaround; we may want to add a counter for the number of
@@ -76,7 +76,7 @@ setup:
while ! flock -w 5 9; do
true
done
echo "Aquired lock on '$PWD/autotest.lock'"
echo "Acquired lock on '$PWD/autotest.lock'"
date
# clone/update the autotest repo while holding the file lock on
# 'autotest.lock'
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+4 -4
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -64,8 +64,8 @@ report_baseline:
- |
(
date
echo "Waiting to aquire lock on '$PWD/autotest.lock' ..."
# try to get an excusive lock on fd 9 (autotest.lock) repeating the try
echo "Waiting to acquire lock on '$PWD/autotest.lock' ..."
# try to get an exclusive lock on fd 9 (autotest.lock) repeating the try
# every 5 seconds; simply using no timeout, i.e. 'flock 9', causes the
# command to hang indefinitely sometimes, so we use the timeout & retry
# as a workaround; we may want to add a counter for the number of
@@ -73,7 +73,7 @@ report_baseline:
while ! flock -w 5 9; do
true
done
echo "Aquired lock on '$PWD/autotest.lock'"
echo "Acquired lock on '$PWD/autotest.lock'"
date
# ----------------------
cd ${AUTOTEST_ROOT}/autotest || \
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+118 -71
View File
@@ -8,98 +8,145 @@
https://mfem.org
Version 4.3.1 (development)
===========================
Version 4.4, released on March 21, 2022
=======================================
- Add hipSPARSE support for sparse mat-vec multiplications.
Linear and nonlinear solvers
----------------------------
- Added support for using the hypre library built with HIP support. Similar to
the existing hypre + CUDA support, most of the MFEM examples and miniapps work
transparently with hypre + HIP builds. This includes the BoomerAMG, AMS, and
ADS solvers.
- Added support for using the HYPRE library built with HIP support. Similar to
the HYPRE + CUDA support added earlier, most of the MFEM examples and miniapps
work transparently with HYPRE + HIP builds. This includes the BoomerAMG, AMS,
and ADS solvers.
- Added a simple singleton class, Hypre, to automatically set hypre's global
parameters, particularly GPU-relevant options. Updated parallel example codes
and miniapps to call Hypre::Init() where appropriate.
- More explicit and consistent formating of the output of iterative solvers
- Added hipSPARSE support for sparse matrix-vector multiplications.
- More explicit and consistent formatting of the output of iterative solvers
with the new IterativeSolver::PrintLevel options. See linalg/solvers.hpp.
- Added a miniapp for PDE-based extrapolation of finite element functions. See
miniapps/shifted/extrapolate.cpp.
- Added support for automatic differentiation. Users can select between native
implementation and external library implementation during configuration. One
parallel and two serial examples are implemented in the miniapps/autodiff/
directory.
- GridFunctionCoefficient (and the related vector, gradient, divergence, and
curl classes) now work properly with LORDiscretization and LORSolver.
- Added support for mesh preprocessing to resolve fine scale problem data
before simulation. This feature uses adaptive mesh refinement to control the
associated data oscillation error. See the new Example 30/30p.
- Switched from Artistic Style (astyle) version 2.05.1 to version 3.1 for code
formatting. See the "make style" target.
- Split the fem/fe.?pp files into separate files in the new fem/fe/ directory
to simplify and clarify the organization of FiniteElement classes.
- Added support for hr-adaptivity using TMOP-based error estimator.
- Coefficient::SetTime now propagates the new time into internally stored
Coefficient objects.
- Added initial support for google-benchmarks in the tests/benchmarks directory.
It can be enabled with MFEM_USE_BENCHMARK=YES.
- Added Binder (mybinder.org) configuration files for C++ MFEM Jupyter Notebooks
with inline GLVis visualization as well as a new examples/jupyter/ directory
with a sample notebook based on Example 1. Implementation based on xeus-cling,
github.com/jupyter-xeus/xeus-cling + xeus-glvis, github.com/GLVis/xeus-glvis.
- Added 'double' atomicAdd implementation for previous versions of CUDA.
- Adding lowest order Nedelec and Raviart-Thomas basis functions on wedge
shaped elements.
Meshing improvements
--------------------
- New TMOP-based methods for hr-adaptivity, interface fitting, and tangential
relaxation of high-order meshes.
- Added initial support for meshes with pyramidal elements, including several
pyramidal meshes in the data/ directory and support for the lowest order H1,
Nedelec, Raviart-Thomas, and L2 basis functions on pyramids.
- Updated the hypre interface according to changes in hypre-2.22.1. The ADS
solver is now fully working on GPUs.
- Added a simpler interface to access mesh face information, see FaceInformation
and GetFaceInformation in the Mesh class.
- Tetrahedral meshes no longer need to be reordered to support high order
Nedelec basis functions. This will allow future support for Nedelec basis
functions on wedges and pyramids which are not amenable to reordering. The
ReorientTetMesh method of the Mesh and ParMesh classes has been deprecated.
- Gmsh meshes where all elements have zero physical tag (the default Gmsh output
format if no physical groups are defined) are now successfully loaded, and
elements are reassigned attribute number 1.
- Gmsh meshes where all elements have zero physical tag (the default Gmsh
output format if no physical groups are defined) are now successfully loaded,
and elements are reassigned attribute number 1.
- Added ParMesh adjacency set (adjset) creation support to the Conduit Mesh
Blueprint MFEM wrapper functions in ConduitDataCollection.
- Added new miniapps that use the ParELAG library, its hybrid smoothers, and the
Discretization improvements
---------------------------
- Added general dof transformation to support high order Nedelec basis functions
on tetrahedral meshes without reordering. The ReorientTetMesh method of the
Mesh and ParMesh classes has been deprecated. See the new DofTransformation
class in fem/doftrans.hpp.
- GPU-enabled partial (PA) and element (EA) assembly for discontinuous Galerkin
methods on nonconforming AMR meshes.
- Support for arbitrary order Nedelec and Raviart-Thomas elements on wedges.
- Added special Nedelec and Raviart-Thomas basis functions for modeling three
dimensional vector fields in 1D and 2D domains, see the new Example 31/31p.
- GridFunctionCoefficient (and the related vector, gradient, divergence, and
curl classes) now work properly with LORDiscretization and LORSolver.
- Added PA support for the action of MixedScalarCurlIntegrator in 2D and
MixedVectorGradientIntegrator in 2D and 3D, as well as their transposes.
- Coefficient::SetTime now propagates the new time into internally stored
Coefficient objects.
- Split the fem/fe.?pp files into separate files in the new fem/fe/ directory to
simplify and clarify the organization of FiniteElement classes.
New and updated examples and miniapps
-------------------------------------
- Added two new miniapps with initial support for automatic differentiation (AD)
in the miniapps/autodiff/ directory. Users can select between external library
and native implementation during configuration. The support for AD will be
extended in future releases of MFEM.
- Added Binder (mybinder.org) configuration files for C++ MFEM Jupyter Notebooks
with inline GLVis visualization in the new examples/jupyter/ directory with a
sample notebook based on Example 1. The implementation is based on xeus-cling,
see github.com/jupyter-xeus/xeus-cling and github.com/GLVis/xeus-glvis.
- Added a new miniapp (Extrapolation) for PDE-based extrapolation of finite
element functions from known values in a set of elements to the rest of the
computational domain. See miniapps/shifted/extrapolate.cpp.
- Added new miniapp that uses the ParELAG library, its hybrid smoothers, and the
hierarchy of spaces created by the element-based AMG (AMGe) methodology in
ParELAG to build multigrid solvers for H(curl) and H(div) forms. See the
miniapps/parelag directory for more details.
- Added a new Example 30/30p demonstrating support for mesh preprocessing to
resolve fine scale problem data before simulation. This feature uses adaptive
mesh refinement to control the associated data oscillation error.
- Added new Examples 31, 31p and 32p showing anisotropic definite Maxwell
serial/parallel solver and parallel eigensolver 1D, 2D, or 3D.
- Updated the mesh-optimizer and pmesh-optimizer miniapps to demonstrate the
hr-adaptivity and interface fitting capability.
- The HPC versions of ex1 and ex1p (in miniapps/performance) now support runtime
selection of either 2D or 3D meshes.
Integrations, testing and documentation
---------------------------------------
- Doxygen documentation for all releases is now available at docs.mfem.org.
- The following integrations have updated minimum version requirements:
* HIOP >= 0.4.6
* HYPRE >= 2.23.0 for HIP support
* libCEED >= 0.10
* PUMI >= 2.2.6
* RAJA >= 0.14.0
* Umpire >= 3.0.0
see INSTALL for more details.
- Added new optional integrations with ParELAG and CoDiPack (version >= 1.9.3+).
- Added initial support for Google Benchmark (version >= 1.5.6) in the
tests/benchmarks directory. It can be enabled with MFEM_USE_BENCHMARK=YES.
- Switched from Artistic Style (astyle) version 2.05.1 to version 3.1 for code
formatting. See the "make style" target.
Miscellaneous
-------------
- Added a simple singleton class, Mpi, as a replacement for MPI_Session. New
code should use Mpi::Init() and other Mpi methods instead of MPI_Session.
- Added ParaView visualization of QuadratureFunction fields, through both
QuadratureFunction::SaveVTU and ParaViewDataCollection::RegisterQField.
- Fixed several MinGW build issues on Windows.
- Remove the 'u' flag in the ar command, to update all files in the archive,
- Added 'double' atomicAdd implementation for previous versions of CUDA.
- HypreParVector and Vector now support C++ move semantics, and the copy
constructor for HypreParVector now copies the local vector data.
- Removed the 'u' flag in the ar command, to update all files in the archive,
avoiding file name collisions from different subdirectories.
- Added initial TMOP-based capabilities for surface fitting and tangential
relaxation in the mesh-optimizer and pmesh-optimizer miniapps.
- Added ParMesh Adjaceny Set (adjset) creation support to the Conduit Mesh
Blueprint MFEM wrapper functions in ConduitDataCollection.
- `HypreParVector` and `Vector` now support move semantics, and the copy
constructor for `HypreParVector` now copies the local vector data.
- The HPC versions of ex1 and ex1p (in miniapps/performance) now support
runtime selection of either 2D or 3D meshes.
- Added ParaView visualization of `QuadratureFunction` fields, through both
`QuadratureFunction::SaveVTU` and `ParaViewDataCollection::RegisterQField`.
- Various other simplifications, extensions, and bugfixes in the code.
Version 4.3, released on July 29, 2021
+2 -2
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -51,7 +51,7 @@ project(mfem NONE)
# Current version of MFEM, see also `makefile`.
# mfem_VERSION = (string)
# MFEM_VERSION = (int) [automatically derived from mfem_VERSION]
set(${PROJECT_NAME}_VERSION 4.3.1)
set(${PROJECT_NAME}_VERSION 4.4.0)
# Prohibit in-source build
if (${PROJECT_SOURCE_DIR} STREQUAL ${PROJECT_BINARY_DIR})
+33 -33
View File
@@ -8,7 +8,7 @@
<a href="https://github.com/mfem/mfem/actions?query=workflow%3Abuild-analysis+branch%3Amaster"><img alt="Build Analysis" src="https://github.com/mfem/mfem/actions/workflows/mfem-analysis.yml/badge.svg?branch=master"></a>
<a href="https://github.com/mfem/mfem/actions?query=workflow%3Abuilds-and-tests+branch%3Amaster"><img alt="Builds and Tests" src="https://github.com/mfem/mfem/actions/workflows/builds-and-tests.yml/badge.svg?branch=master"></a>
<a href="https://ci.appveyor.com/project/mfem/mfem"><img alt="Build Status" src="https://ci.appveyor.com/api/projects/status/19non9sqm6msi2wy?svg=true"></a>
<a href="https://mfem.github.io/doxygen/html/index.html"><img alt="Doxygen" src="https://img.shields.io/badge/code-documented-brightgreen.svg"></a>
<a href="https://docs.mfem.org/html/index.html"><img alt="Doxygen" src="https://img.shields.io/badge/code-documented-brightgreen.svg"></a>
</p>
@@ -141,6 +141,7 @@ The MFEM source code has the following structure:
│ ├── tools
│ └── toys
└── tests
├── benchmarks
├── convergence
├── gitlab
├── mem_manager
@@ -156,24 +157,24 @@ classes implementing the finite element, mesh and linear algebra concepts
respectively.
- The main mesh classes are:
+ [`Mesh`](https://mfem.github.io/doxygen/html/classmfem_1_1Mesh.html)
+ [`NCMesh`](https://mfem.github.io/doxygen/html/classmfem_1_1NCMesh.html)
+ [`Element`](https://mfem.github.io/doxygen/html/classmfem_1_1Element.html)
+ [`ElementTransformation`](https://mfem.github.io/doxygen/html/classmfem_1_1ElementTransformation.html)
+ [`Mesh`](https://docs.mfem.org/html/classmfem_1_1Mesh.html)
+ [`NCMesh`](https://docs.mfem.org/html/classmfem_1_1NCMesh.html)
+ [`Element`](https://docs.mfem.org/html/classmfem_1_1Element.html)
+ [`ElementTransformation`](https://docs.mfem.org/html/classmfem_1_1ElementTransformation.html)
- The main finite element classes are:
+ [`FiniteElement`](https://mfem.github.io/doxygen/html/classmfem_1_1FiniteElement.html)
+ [`FiniteElementCollection`](https://mfem.github.io/doxygen/html/classmfem_1_1FiniteElement.html)
+ [`FiniteElementSpace`](https://mfem.github.io/doxygen/html/classmfem_1_1FiniteElementSpace.html)
+ [`GridFunction`](https://mfem.github.io/doxygen/html/classmfem_1_1GridFunction.html)
+ [`BilinearFormIntegrator`](https://mfem.github.io/doxygen/html/classmfem_1_1BilinearFormIntegrator.html) and [`LinearFormIntegrator`](https://mfem.github.io/doxygen/html/classmfem_1_1LinearFormIntegrator.html)
+ [`LinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1LinearFormIntegrator.html), [`BilinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1BilinearForm.html) and [`MixedBilinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1MixedBilinearForm.html)
+ [`FiniteElement`](https://docs.mfem.org/html/classmfem_1_1FiniteElement.html)
+ [`FiniteElementCollection`](https://docs.mfem.org/html/classmfem_1_1FiniteElement.html)
+ [`FiniteElementSpace`](https://docs.mfem.org/html/classmfem_1_1FiniteElementSpace.html)
+ [`GridFunction`](https://docs.mfem.org/html/classmfem_1_1GridFunction.html)
+ [`BilinearFormIntegrator`](https://docs.mfem.org/html/classmfem_1_1BilinearFormIntegrator.html) and [`LinearFormIntegrator`](https://docs.mfem.org/html/classmfem_1_1LinearFormIntegrator.html)
+ [`LinearForm`](https://docs.mfem.org/html/classmfem_1_1LinearFormIntegrator.html), [`BilinearForm`](https://docs.mfem.org/html/classmfem_1_1BilinearForm.html) and [`MixedBilinearForm`](https://docs.mfem.org/html/classmfem_1_1MixedBilinearForm.html)
- The main linear algebra classes and sources are
+ [`Operator`](https://mfem.github.io/doxygen/html/classmfem_1_1Operator.html) and [`BilinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1BilinearForm.html)
+ [`Vector`](https://mfem.github.io/doxygen/html/classmfem_1_1BilinearForm.html) and [`LinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1LinearForm.html)
+ [`DenseMatrix`](https://mfem.github.io/doxygen/html/classmfem_1_1DenseMatrix.html) and [`SparseMatrix`](https://mfem.github.io/doxygen/html/classmfem_1_1SparseMatrix.html)
+ Sparse [smoothers](https://mfem.github.io/doxygen/html/sparsesmoothers_8hpp.html) and linear [solvers](https://mfem.github.io/doxygen/html/solvers_8hpp.html)
+ [`Operator`](https://docs.mfem.org/html/classmfem_1_1Operator.html) and [`BilinearForm`](https://docs.mfem.org/html/classmfem_1_1BilinearForm.html)
+ [`Vector`](https://docs.mfem.org/html/classmfem_1_1BilinearForm.html) and [`LinearForm`](https://docs.mfem.org/html/classmfem_1_1LinearForm.html)
+ [`DenseMatrix`](https://docs.mfem.org/html/classmfem_1_1DenseMatrix.html) and [`SparseMatrix`](https://docs.mfem.org/html/classmfem_1_1SparseMatrix.html)
+ Sparse [smoothers](https://docs.mfem.org/html/sparsesmoothers_8hpp.html) and linear [solvers](https://docs.mfem.org/html/solvers_8hpp.html)
#### Parallel implementation
@@ -183,13 +184,13 @@ shared geometric entities between different tasks. The parallel source files
have a `p` prefix, e.g. `pmesh.cpp` vs. the serial `mesh.cpp`.
- The main parallel classes are
+ [`ParMesh`](https://mfem.github.io/doxygen/html/solvers_8hpp.html)
+ [`ParNCMesh`](https://mfem.github.io/doxygen/html/classmfem_1_1ParMesh.html)
+ [`ParFiniteElementSpace`](https://mfem.github.io/doxygen/html/classmfem_1_1ParFiniteElementSpace.html)
+ [`ParGridFunction`](https://mfem.github.io/doxygen/html/classmfem_1_1ParGridFunction.html)
+ [`ParBilinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1ParBilinearForm.html) and [`ParLinearForm`](https://mfem.github.io/doxygen/html/classmfem_1_1ParLinearForm.html)
+ [`HypreParMatrix`](https://mfem.github.io/doxygen/html/classmfem_1_1HypreParMatrix.html) and [`HypreParVector`](https://mfem.github.io/doxygen/html/classmfem_1_1HypreParVector.html)
+ [`HypreSolver`](https://mfem.github.io/doxygen/html/classmfem_1_1HypreSolver.html) and other [hypre classes](https://mfem.github.io/doxygen/html/hypre_8hpp.html)
+ [`ParMesh`](https://docs.mfem.org/html/solvers_8hpp.html)
+ [`ParNCMesh`](https://docs.mfem.org/html/classmfem_1_1ParMesh.html)
+ [`ParFiniteElementSpace`](https://docs.mfem.org/html/classmfem_1_1ParFiniteElementSpace.html)
+ [`ParGridFunction`](https://docs.mfem.org/html/classmfem_1_1ParGridFunction.html)
+ [`ParBilinearForm`](https://docs.mfem.org/html/classmfem_1_1ParBilinearForm.html) and [`ParLinearForm`](https://docs.mfem.org/html/classmfem_1_1ParLinearForm.html)
+ [`HypreParMatrix`](https://docs.mfem.org/html/classmfem_1_1HypreParMatrix.html) and [`HypreParVector`](https://docs.mfem.org/html/classmfem_1_1HypreParVector.html)
+ [`HypreSolver`](https://docs.mfem.org/html/classmfem_1_1HypreSolver.html) and other [hypre classes](https://docs.mfem.org/html/hypre_8hpp.html)
#### GPU and general device support
@@ -198,10 +199,10 @@ backends (CUDA, OCCA, RAJA, OpenMP, etc.) and an internal lightweight
device/host memory manager.
- The main device-relevant classes and sources are:
+ [`Device`](https://mfem.github.io/doxygen/html/device_8hpp.html)
+ [`MemoryManager`](https://mfem.github.io/doxygen/html/mem_manager_8hpp.html)
+ the [`MFEM_FORALL`](https://mfem.github.io/doxygen/html/forall_8hpp.html) macro
+ the [`cuda.hpp`](https://mfem.github.io/doxygen/html/cuda_8hpp.html) and [`occa.hpp`](https://mfem.github.io/doxygen/html/occa_8hpp.html) files
+ [`Device`](https://docs.mfem.org/html/device_8hpp.html)
+ [`MemoryManager`](https://docs.mfem.org/html/mem_manager_8hpp.html)
+ the [`MFEM_FORALL`](https://docs.mfem.org/html/forall_8hpp.html) macro
+ the [`cuda.hpp`](https://docs.mfem.org/html/cuda_8hpp.html) and [`occa.hpp`](https://docs.mfem.org/html/occa_8hpp.html) files
#### Utilities, building and documentation
- The `general/` directory contains C++ classes that serve as utilities for
@@ -209,8 +210,7 @@ device/host memory manager.
- The `config/` directory contains build-related files, both for the plain
Makefile and the CMake build options.
- The `doc/` directory contains configuration for the Doxygen code documentation
that can either be built locally or browsed online at
https://mfem.github.io/doxygen/html/index.html.
that can either be built locally or browsed online at https://docs.mfem.org.
#### Examples and tests
- `examples` and `miniapps` respectively gather simple and more fully-featured
@@ -430,10 +430,10 @@ The Pull Request (PR) approval process in MFEM is similar to the approval of pap
The current list of MFEM editors is:
- @v-dobrev (Veselin Dobrev)
- @tzanio (Tzanio Kolev)
- @pazner (Will Pazner)
- @mlstowell (Mark Stowell)
- [@v-dobrev](https://github.com/v-dobrev) (Veselin Dobrev)
- [@tzanio](https://github.com/tzanio) (Tzanio Kolev)
- [@pazner](https://github.com/pazner) (Will Pazner)
- [@mlstowell](https://github.com/mlstowell) (Mark Stowell)
**The responsibilities of the editors are:**
@@ -639,7 +639,7 @@ MFEM uses a `master`/`next`-branch workflow as described below:
```
- [ ] Create the release tarball and push to `mfem/releases`.
- [ ] Recreate the `next` branch as described in previous section.
- [ ] Update and push documentation to `mfem/doxygen`.
- [ ] Update and push documentation to `mfem/doxygen`. Update the `README.md` file and the `html` link in the `mfem/doxygen` repo.
- [ ] Update URL shortlinks:
- [ ] Create a shortlink at [http://bit.ly/](http://bit.ly/) for the release tarball, e.g. https://mfem.github.io/releases/mfem-3.1.tgz.
- [ ] (LLNL only) Add and commit the new shortlink in the `links` and `links-mfem` files of the internal `mfem/downloads` repo.
+6 -6
View File
@@ -19,10 +19,10 @@ requires an MPI C++ compiler, as well as the following external libraries:
http://glaros.dtc.umn.edu/gkhome/metis/metis/overview
The hypre dependency can be downloaded as a tarball from GitHub or from the
project webpage https://www.llnl.gov/casc/hypre. For example, the 2.20.0 release
project webpage https://www.llnl.gov/casc/hypre. For example, the 2.24.0 release
of hypre is available at
https://github.com/hypre-space/hypre/archive/v2.20.0.tar.gz
https://github.com/hypre-space/hypre/archive/v2.24.0.tar.gz
The METIS dependency can be disabled but that is not generally recommended, see
the option MFEM_USE_METIS.
@@ -60,7 +60,6 @@ following package managers:
- OpenHPC, http://openhpc.community
- Conda-forge, https://conda-forge.org (pre-built binaries linked with
OpenMPI/MPICH, hypre, and METIS)
- Homebrew/Science, https://github.com/Homebrew/homebrew-science (deprecated)
We also recommend downloading and building the MFEM-based GLVis visualization
tool which can be used to visualize the meshes and solution in MFEM's examples
@@ -567,7 +566,8 @@ The specific libraries and their options are:
Options: HYPRE_OPT, HYPRE_LIB.
Versions: HYPRE >= 2.10.0b (HYPRE built without CUDA)
HYPRE >= 2.20.0 (HYPRE built with '--enable-mixedint')
HYPRE >= 2.22.1 (HYPRE built with CUDA or HIP)
HYPRE >= 2.22.1 (HYPRE built with CUDA)
HYPRE >= 2.23.0 (HYPRE built with HIP)
- METIS, used when MFEM_USE_METIS = YES. If using METIS 5, set
MFEM_USE_METIS_5 = YES (default is to use METIS 4).
@@ -713,7 +713,7 @@ The specific libraries and their options are:
Options: HIOP_OPT, HIOP_LIB.
Versions: HIOP >= 0.4.6.
- CoDiPack (optiobal), used with MFEM_USE_CODIPACK = YES
- CoDiPack (optional), used with MFEM_USE_CODIPACK = YES
URL: https://www.scicomp.uni-kl.de/codi/
Options: CODIPACK_OPT
Versions: 1.9.3
@@ -751,7 +751,7 @@ The specific libraries and their options are:
URL: https://github.com/CEED/libCEED
https://ceed.exascaleproject.org/libceed
Options: CEED_DIR, CEED_OPT, CEED_LIB.
Versions: libCEED >= 0.8.
Versions: libCEED >= 0.10.
- RAJA (optional), used when MFEM_USE_RAJA = YES.
Beginning with MFEM v4.3, only RAJA v0.14.0+ is supported.
+1 -1
View File
@@ -1,6 +1,6 @@
BSD 3-Clause License
Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC
Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC
All rights reserved.
Redistribution and use in source and binary forms, with or without
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
// Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
// Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
+1 -1
View File
@@ -1,4 +1,4 @@
// Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
// Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
+1 -1
View File
@@ -1,4 +1,4 @@
// Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
+3 -3
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -35,8 +35,8 @@ cd $(git rev-parse --show-toplevel)
# copyright check
copyright=true
if [[ "${option}" == "--copyright" || "${option}" == "" ]]; then
if git grep -l "^\(#\|//\).*\(\-2020\|\ 2010,\)" > matches.txt; then
echo "Please update the following files to Copyright (c) 2010-2021:"
if git grep -l "^\(#\|//\).*\(\-2021\|\ 2010,\)" > matches.txt; then
echo "Please update the following files to Copyright (c) 2010-2022:"
cat matches.txt
copyright=false
fi
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+14 -9
View File
@@ -1,6 +1,6 @@
#!/bin/bash
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -32,7 +32,7 @@ groups_serial=(
'"examples"
"Examples:"
"examples"
"ex{,1,2}[0-9].cpp"'
"ex{,1,2,3}[0-9].cpp"'
# "ex1.cpp"'
'"sundials"
"SUNDIALS examples:"
@@ -83,11 +83,13 @@ groups_serial=(
'"tools"
"Tools miniapps:"
"miniapps/tools"
"convert-dc.cpp display-basis.cpp get-values.cpp load-dc.cpp lor-transfer.cpp"'
"convert-dc.cpp display-basis.cpp get-values.cpp load-dc.cpp
lor-transfer.cpp"'
'"toys"
"Toys miniapps:"
"miniapps/toys"
"automata.cpp life.cpp lissajous.cpp mandel.cpp mondrian.cpp rubik.cpp snake.cpp"'
"automata.cpp life.cpp lissajous.cpp mandel.cpp mondrian.cpp rubik.cpp
snake.cpp"'
'"convergence"
"Convergence tests:"
"tests/convergence"
@@ -98,7 +100,7 @@ groups_parallel=(
'"examples"
"Examples:"
"examples"
"ex{,1,2}[0-9]p.cpp"'
"ex{,1,2,3}[0-9]p.cpp"'
# "ex1p.cpp"'
'"sundials"
"SUNDIALS examples:"
@@ -184,7 +186,7 @@ groups_all=(
'"examples"
"Examples:"
"examples"
"ex\"{,1,2}[0-9]\"{,p}.cpp"'
"ex\"{,1,2,3}[0-9]\"{,p}.cpp"'
'"sundials"
"SUNDIALS examples:"
"examples/sundials"
@@ -238,7 +240,8 @@ groups_all=(
'"gslib"
"GSLIB miniapps:"
"miniapps/gslib"
"field-diff.cpp field-interp.cpp findpts.cpp schwarz_ex1.cpp pfindpts.cpp schwarz_ex1p.cpp"'
"field-diff.cpp field-interp.cpp findpts.cpp schwarz_ex1.cpp pfindpts.cpp
schwarz_ex1p.cpp"'
'"navier"
"Navier miniapps:"
"miniapps/navier"
@@ -258,11 +261,13 @@ groups_all=(
'"tools"
"Tools miniapps:"
"miniapps/tools"
"convert-dc.cpp display-basis.cpp get-values.cpp load-dc.cpp lor-transfer.cpp"'
"convert-dc.cpp display-basis.cpp get-values.cpp load-dc.cpp
lor-transfer.cpp"'
'"toys"
"Toys miniapps:"
"miniapps/toys"
"automata.cpp life.cpp lissajous.cpp mandel.cpp mondrian.cpp rubik.cpp snake.cpp"'
"automata.cpp life.cpp lissajous.cpp mandel.cpp mondrian.cpp rubik.cpp
snake.cpp"'
'"convergence"
"Convergence tests:"
"tests/convergence"
+1 -1
View File
@@ -1,4 +1,4 @@
// Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
// LICENSE and NOTICE for details. LLNL-CODE-806117.
//
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+43
View File
@@ -0,0 +1,43 @@
MFEM mesh v1.0
#
# MFEM Geometry Types (see mesh/geom.hpp):
#
# POINT = 0
# SEGMENT = 1
# TRIANGLE = 2
# SQUARE = 3
# TETRAHEDRON = 4
# CUBE = 5
#
dimension
2
# format: <attribute> <geometry type> <vertex 0> <vertex 1> ...
elements
3
1 3 0 1 2 3
2 3 0 3 4 5
3 3 0 5 6 1
boundary
6
1 1 1 2
2 1 2 3
3 1 3 4
4 1 4 5
5 1 5 6
6 1 6 1
vertices
7
2
0.0 0.0
-0.50 -0.8660254037844386
0.50 -0.8660254037844386
1.0 0.0
0.50 0.8660254037844386
-0.50 0.8660254037844386
-1.0 0.0
+198 -198
View File
@@ -15,146 +15,146 @@ DataCollection/Fields/0/NumberOfVectorComponents: 2
DataCollection/Fields/0/FieldDescriptorName: CoordsDescriptor
DataCollection/Fields/0/Data/Size: 422
DataCollection/Fields/0/Data/Type: FMS_DOUBLE
DataCollection/Fields/0/Data/Values: [-0.016886, 1.000000, 0.309017,
1.309020, -0.809017, -0.500000,
-0.809017, -1.618030, 0.309017,
-0.500000, 1.309020, 0.519420,
1.154510, 0.809019, 0.147680,
-0.095492, -0.654508, -0.415586,
-1.213520, -1.213520, -0.392210,
-0.654508, -0.095492, 0.139949,
0.809019, 1.154510, 0.660184,
-0.264063, -0.800064, -0.231060,
0.663691, 0.183114, 0.317639,
0.543082, 0.598483, 0.345112,
0.478298, 0.027703, 0.095229,
0.012368, -0.092534, -0.334412,
-0.313767, -0.140526, -0.293881,
-0.534056, -0.660290, -0.537646,
-0.655590, -0.121396, -0.274504,
-0.346497, -0.296570, 0.004737,
-0.098835, 0.069287, 0.082675,
0.318799, 0.467183, 0.564505,
0.595190, 0.846237, 0.671735,
1.051500, 1.103010, 0.964008,
0.821603, 1.257520, 1.206010,
1.142350, 0.975686, 0.781273,
0.717257, 0.475684, 0.642352,
0.268930, 0.211049, 0.174181,
0.039345, -0.147746, -0.177481,
-0.365164, -0.230328, -0.551503,
-0.603005, -0.497587, -0.389864,
-0.757514, -0.706011, -0.675487,
-0.528946, -0.943851, -1.078690,
-1.087600, -0.955467, -1.483190,
-1.348360, -1.483190, -1.348360,
-1.085930, -0.938010, -0.943851,
-1.078690, -0.681476, -0.540944,
-0.757514, -0.706011, -0.540614,
-0.367058, -0.551503, -0.603005,
-0.365164, -0.230328, -0.138552,
-0.206896, 0.174181, 0.039345,
0.268468, 0.222269, 0.475684,
0.642352, 0.759791, 0.719381,
1.142350, 0.975686, 1.257520,
1.206010, 0.972837, 0.836119,
1.051500, 1.103010, 0.214572,
0.407449, 0.288323, 0.449827,
-0.086700, -0.027358, -0.200560,
-0.166595, -0.271802, -0.418426,
-0.426131, -0.551441, -0.096117,
-0.206969, -0.027946, -0.184969,
0.211136, 0.260131, 0.407172,
0.430781, 0.718277, 0.885068,
0.753103, 0.957692, 0.866273,
1.024530, 0.934099, 1.093820,
0.348422, 0.524463, 0.404903,
0.587376, 0.054525, 0.146431,
-0.078026, -0.007795, -0.329488,
-0.302967, -0.488115, -0.439332,
-0.498515, -0.453527, -0.633059,
-0.570251, -0.655787, -0.791132,
-0.802013, -0.956872, -1.094720,
-1.208560, -1.207720, -1.339910,
-0.693371, -0.795404, -0.803594,
-0.945068, -0.464668, -0.631721,
-0.458968, -0.547876, -0.332878,
-0.485696, -0.286385, -0.408481,
0.053021, -0.058200, 0.110846,
-0.002086, 0.381384, 0.416784,
0.551133, 0.613261, 0.872474,
0.901208, 1.038300, 1.084660,
0.737459, 0.751250, 0.890002,
0.915210, 0.010915, 0.000000,
0.951057, 0.951057, 0.587785,
1.538840, -0.587785, 0.000000,
-0.951057, -1.538840, -0.951057,
-0.015847, 0.475529, 0.951057,
0.492248, 1.244950, 1.063310,
0.274399, 0.293893, -0.293892,
-0.296404, -1.063310, -1.244950,
-0.453865, -0.951057, -0.475529,
0.466620, 0.792932, -0.013913,
-0.748783, -0.497528, 0.021382,
-0.017158, 0.172591, 0.330125,
0.458568, 0.457971, 0.137740,
0.299049, 0.588394, 0.667324,
0.432341, 0.634346, 0.117322,
0.193603, 0.211702, 0.098278,
-0.199438, -0.077304, -0.082243,
-0.216296, -0.458634, -0.592374,
-0.563926, -0.680404, -0.135751,
-0.302942, -0.469005, -0.453640,
-0.182727, -0.314240, 0.024270,
0.021546, 0.158510, 0.317019,
0.485799, 0.492951, 0.792548,
0.634038, 0.951057, 0.951057,
0.777915, 0.613430, 0.951057,
0.951057, 0.793994, 0.635800,
1.049020, 1.146990, 1.084480,
0.924310, 1.440880, 1.342910,
1.380330, 1.221820, 0.948209,
0.856297, 0.746293, 0.904802,
0.476242, 0.393234, 0.489821,
0.391857, 0.194471, 0.075751,
0.097964, 0.195929, -0.097964,
-0.195928, -0.173234, -0.078922,
-0.489821, -0.391856, -0.467007,
-0.397859, -0.746293, -0.904802,
-0.945206, -0.849559, -1.380330,
-1.221820, -1.440880, -1.342910,
-1.100830, -0.923191, -1.049020,
-1.146990, -0.774515, -0.621542,
-0.951057, -0.951057, -0.803055,
-0.635255, -0.951057, -0.951057,
-0.792548, -0.634038, -0.454301,
-0.479369, -0.158510, -0.317019,
0.149331, 0.178643, 0.295860,
0.306275, 0.246225, 0.406610,
0.367954, 0.498458, -0.014929,
0.084917, -0.094272, -0.000726,
-0.245374, -0.340755, -0.435351,
-0.490564, -0.176355, -0.294974,
-0.148010, -0.328246, 0.136248,
0.182883, 0.328957, 0.309903,
0.646446, 0.622546, 0.800859,
0.801803, 0.643087, 0.654473,
0.796963, 0.816799, 0.748189,
0.898148, 0.819092, 0.970033,
1.049540, 1.162660, 1.115310,
1.266700, 0.539960, 0.728396,
0.656318, 0.783152, 0.302716,
0.403858, 0.219006, 0.309252,
0.009667, 0.107161, -0.118211,
0.011786, -0.284704, -0.179858,
-0.411567, -0.296676, -0.570168,
-0.635348, -0.726784, -0.793211,
-1.016860, -1.112970, -1.170910,
-1.281530, -0.737860, -0.851723,
-0.883732, -0.995070, -0.653153,
-0.769939, -0.631918, -0.797688,
-0.616289, -0.806819, -0.638485,
-0.790356, -0.136399, -0.322769,
DataCollection/Fields/0/Data/Values: [-0.016886, 1.000000, 0.309017,
1.309020, -0.809017, -0.500000,
-0.809017, -1.618030, 0.309017,
-0.500000, 1.309020, 0.519420,
1.154510, 0.809019, 0.147680,
-0.095492, -0.654508, -0.415586,
-1.213520, -1.213520, -0.392210,
-0.654508, -0.095492, 0.139949,
0.809019, 1.154510, 0.660184,
-0.264063, -0.800064, -0.231060,
0.663691, 0.183114, 0.317639,
0.543082, 0.598483, 0.345112,
0.478298, 0.027703, 0.095229,
0.012368, -0.092534, -0.334412,
-0.313767, -0.140526, -0.293881,
-0.534056, -0.660290, -0.537646,
-0.655590, -0.121396, -0.274504,
-0.346497, -0.296570, 0.004737,
-0.098835, 0.069287, 0.082675,
0.318799, 0.467183, 0.564505,
0.595190, 0.846237, 0.671735,
1.051500, 1.103010, 0.964008,
0.821603, 1.257520, 1.206010,
1.142350, 0.975686, 0.781273,
0.717257, 0.475684, 0.642352,
0.268930, 0.211049, 0.174181,
0.039345, -0.147746, -0.177481,
-0.365164, -0.230328, -0.551503,
-0.603005, -0.497587, -0.389864,
-0.757514, -0.706011, -0.675487,
-0.528946, -0.943851, -1.078690,
-1.087600, -0.955467, -1.483190,
-1.348360, -1.483190, -1.348360,
-1.085930, -0.938010, -0.943851,
-1.078690, -0.681476, -0.540944,
-0.757514, -0.706011, -0.540614,
-0.367058, -0.551503, -0.603005,
-0.365164, -0.230328, -0.138552,
-0.206896, 0.174181, 0.039345,
0.268468, 0.222269, 0.475684,
0.642352, 0.759791, 0.719381,
1.142350, 0.975686, 1.257520,
1.206010, 0.972837, 0.836119,
1.051500, 1.103010, 0.214572,
0.407449, 0.288323, 0.449827,
-0.086700, -0.027358, -0.200560,
-0.166595, -0.271802, -0.418426,
-0.426131, -0.551441, -0.096117,
-0.206969, -0.027946, -0.184969,
0.211136, 0.260131, 0.407172,
0.430781, 0.718277, 0.885068,
0.753103, 0.957692, 0.866273,
1.024530, 0.934099, 1.093820,
0.348422, 0.524463, 0.404903,
0.587376, 0.054525, 0.146431,
-0.078026, -0.007795, -0.329488,
-0.302967, -0.488115, -0.439332,
-0.498515, -0.453527, -0.633059,
-0.570251, -0.655787, -0.791132,
-0.802013, -0.956872, -1.094720,
-1.208560, -1.207720, -1.339910,
-0.693371, -0.795404, -0.803594,
-0.945068, -0.464668, -0.631721,
-0.458968, -0.547876, -0.332878,
-0.485696, -0.286385, -0.408481,
0.053021, -0.058200, 0.110846,
-0.002086, 0.381384, 0.416784,
0.551133, 0.613261, 0.872474,
0.901208, 1.038300, 1.084660,
0.737459, 0.751250, 0.890002,
0.915210, 0.010915, 0.000000,
0.951057, 0.951057, 0.587785,
1.538840, -0.587785, 0.000000,
-0.951057, -1.538840, -0.951057,
-0.015847, 0.475529, 0.951057,
0.492248, 1.244950, 1.063310,
0.274399, 0.293893, -0.293892,
-0.296404, -1.063310, -1.244950,
-0.453865, -0.951057, -0.475529,
0.466620, 0.792932, -0.013913,
-0.748783, -0.497528, 0.021382,
-0.017158, 0.172591, 0.330125,
0.458568, 0.457971, 0.137740,
0.299049, 0.588394, 0.667324,
0.432341, 0.634346, 0.117322,
0.193603, 0.211702, 0.098278,
-0.199438, -0.077304, -0.082243,
-0.216296, -0.458634, -0.592374,
-0.563926, -0.680404, -0.135751,
-0.302942, -0.469005, -0.453640,
-0.182727, -0.314240, 0.024270,
0.021546, 0.158510, 0.317019,
0.485799, 0.492951, 0.792548,
0.634038, 0.951057, 0.951057,
0.777915, 0.613430, 0.951057,
0.951057, 0.793994, 0.635800,
1.049020, 1.146990, 1.084480,
0.924310, 1.440880, 1.342910,
1.380330, 1.221820, 0.948209,
0.856297, 0.746293, 0.904802,
0.476242, 0.393234, 0.489821,
0.391857, 0.194471, 0.075751,
0.097964, 0.195929, -0.097964,
-0.195928, -0.173234, -0.078922,
-0.489821, -0.391856, -0.467007,
-0.397859, -0.746293, -0.904802,
-0.945206, -0.849559, -1.380330,
-1.221820, -1.440880, -1.342910,
-1.100830, -0.923191, -1.049020,
-1.146990, -0.774515, -0.621542,
-0.951057, -0.951057, -0.803055,
-0.635255, -0.951057, -0.951057,
-0.792548, -0.634038, -0.454301,
-0.479369, -0.158510, -0.317019,
0.149331, 0.178643, 0.295860,
0.306275, 0.246225, 0.406610,
0.367954, 0.498458, -0.014929,
0.084917, -0.094272, -0.000726,
-0.245374, -0.340755, -0.435351,
-0.490564, -0.176355, -0.294974,
-0.148010, -0.328246, 0.136248,
0.182883, 0.328957, 0.309903,
0.646446, 0.622546, 0.800859,
0.801803, 0.643087, 0.654473,
0.796963, 0.816799, 0.748189,
0.898148, 0.819092, 0.970033,
1.049540, 1.162660, 1.115310,
1.266700, 0.539960, 0.728396,
0.656318, 0.783152, 0.302716,
0.403858, 0.219006, 0.309252,
0.009667, 0.107161, -0.118211,
0.011786, -0.284704, -0.179858,
-0.411567, -0.296676, -0.570168,
-0.635348, -0.726784, -0.793211,
-1.016860, -1.112970, -1.170910,
-1.281530, -0.737860, -0.851723,
-0.883732, -0.995070, -0.653153,
-0.769939, -0.631918, -0.797688,
-0.616289, -0.806819, -0.638485,
-0.790356, -0.136399, -0.322769,
-0.165339, -0.309622]
DataCollection/Mesh/PartitionInfo/Size: 2
DataCollection/Mesh/PartitionInfo/Type: FMS_UINT64
@@ -170,69 +170,69 @@ DataCollection/Mesh/DomainNames/0/Domains/0/Entities/0/EntityType: FMS_EDGE
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/0/NumEntities: 50
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/0/Size: 100
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/0/Type: FMS_INT32
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/0/Values: [11, 0, 26,
11, 26, 14,
14, 0, 27,
14, 27, 17,
17, 0, 28,
17, 28, 20,
20, 0, 29,
20, 29, 23,
23, 0, 30,
23, 30, 11,
11, 1, 12,
1, 26, 12,
12, 3, 13,
3, 26, 13,
13, 2, 14,
2, 15, 2,
27, 15, 15,
5, 16, 5,
27, 16, 16,
4, 17, 4,
18, 4, 28,
18, 18, 7,
19, 7, 28,
19, 19, 6,
20, 6, 21,
6, 29, 21,
21, 9, 22,
9, 29, 22,
22, 8, 23,
8, 24, 8,
30, 24, 24,
10, 25, 10,
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/0/Values: [11, 0, 26,
11, 26, 14,
14, 0, 27,
14, 27, 17,
17, 0, 28,
17, 28, 20,
20, 0, 29,
20, 29, 23,
23, 0, 30,
23, 30, 11,
11, 1, 12,
1, 26, 12,
12, 3, 13,
3, 26, 13,
13, 2, 14,
2, 15, 2,
27, 15, 15,
5, 16, 5,
27, 16, 16,
4, 17, 4,
18, 4, 28,
18, 18, 7,
19, 7, 28,
19, 19, 6,
20, 6, 21,
6, 29, 21,
21, 9, 22,
9, 29, 22,
22, 8, 23,
8, 24, 8,
30, 24, 24,
10, 25, 10,
30, 25, 25, 1]
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/1/EntityType: FMS_QUADRILATERAL
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/1/NumEntities: 20
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/1/Size: 80
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/1/Type: FMS_INT32
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/1/Values: [0, 1, 2,
3, 3, 4,
5, 6, 6,
7, 8, 9,
9, 10, 11,
12, 12, 13,
14, 0, 15,
16, 17, 1,
17, 18, 19,
20, 2, 20,
21, 22, 22,
23, 24, 4,
24, 25, 26,
27, 5, 27,
28, 29, 29,
30, 31, 7,
31, 32, 33,
34, 8, 34,
35, 36, 36,
37, 38, 10,
38, 39, 40,
41, 11, 41,
42, 43, 43,
44, 45, 13,
45, 46, 47,
48, 14, 48,
DataCollection/Mesh/DomainNames/0/Domains/0/Entities/1/Values: [0, 1, 2,
3, 3, 4,
5, 6, 6,
7, 8, 9,
9, 10, 11,
12, 12, 13,
14, 0, 15,
16, 17, 1,
17, 18, 19,
20, 2, 20,
21, 22, 22,
23, 24, 4,
24, 25, 26,
27, 5, 27,
28, 29, 29,
30, 31, 7,
31, 32, 33,
34, 8, 34,
35, 36, 36,
37, 38, 10,
38, 39, 40,
41, 11, 41,
42, 43, 43,
44, 45, 13,
45, 46, 47,
48, 14, 48,
49, 15]
DataCollection/Mesh/Components/0/Name: volume
DataCollection/Mesh/Components/0/Dimension: 2
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -38,7 +38,7 @@ PROJECT_NAME = "MFEM"
# could be handy for archiving the generated documentation or if some version
# control system is used.
PROJECT_NUMBER = v4.3.1
PROJECT_NUMBER = v4.4.0
# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
+8 -2
View File
@@ -98,6 +98,11 @@ namespace mfem {
* - <a class="el" href="ex28p_8cpp_source.html">Example 28p</a>: parallel sliding contact in elasticity
* - <a class="el" href="ex29_8cpp_source.html">Example 29</a>: Laplace solve on a 3D-embedded surface
* - <a class="el" href="ex29p_8cpp_source.html">Example 29p</a>: parallel Laplace solve on a 3D-embedded surface
* - <a class="el" href="ex30_8cpp_source.html">Example 30</a>: mesh preprocessing to resolve problem data
* - <a class="el" href="ex30p_8cpp_source.html">Example 30p</a>: parallel mesh preprocessing to resolve problem data
* - <a class="el" href="ex31_8cpp_source.html">Example 31</a>: Nedelec H(curl) FEM for the definite anisotropic Maxwell problem
* - <a class="el" href="ex31p_8cpp_source.html">Example 31p</a>: parallel Nedelec H(curl) FEM for the definite anisotropic Maxwell problem
* - <a class="el" href="ex32p_8cpp_source.html">Example 32p</a>: parallel anisotropic Maxwell eigensolver
*
* <H4>AmgX Examples</H4>
* - Variants of Examples
@@ -190,12 +195,13 @@ namespace mfem {
* - <a class="el" href="field-interp_8cpp_source.html">Field Interp</a>: transfer a grid functions between meshes
* - <a class="el" href="distance_8cpp_source.html">Distance</a>: finite element distance function solver
* - <a class="el" href="diffusion_8cpp_source.html">Shifted Diffusion</a>: shifted boundary diffusion solver
* - <a class="el" href="extrapolate_8cpp_source.html">Extrapolation</a>: PDE-based extrapolation of finite element functions
* - <a class="el" href="distance_8cpp_source.html">Block Solvers</a>: comparison of saddle point system solvers
* - <a class="el" href="parheat_8cpp_source.html">Optimization gradients</a>: Gradients of PDE-constrained function
* - <a class="el" href="par__example_8cpp_source.html">Parallel AD</a>: Parallel p-Laplacian example
* - <a class="el" href="seq__example_8cpp_source.html">Serial AD</a>: Serial p-Laplacian example
* - <a class="el" href="miniapps_2performance_2ex1_8cpp_source.html">HPC Example 1</a>: high-performance nodal H1 FEM for the Laplace problem
* - <a class="el" href="miniapps_2performance_2ex1p_8cpp_source.html">HPC Example 1p</a>: high-performance parallel nodal H1 FEM for the Laplace problem
* - <a class="el" href="par__example_8cpp_source.html">Parallel pLaplacian example using AD</a>: Parallel pLaplacian example
* - <a class="el" href="seq__example_8cpp_source.html">Serial pLaplacian example using AD</a>: Serial pLaplacian example
*
* See also the <a class="el" href="https://mfem.org/examples/">examples documentation</a> online.
*/
+1 -2
View File
@@ -21,8 +21,7 @@ create the file CodeDocumentation.html, which can be viewed in any web browser.
Alternatively, the (pre-build) documentation can be browsed directly online at
https://mfem.github.io/doxygen/html/index.html
https://docs.mfem.org
Some building considerations:
+2 -3
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -16,7 +16,7 @@ DOXYGEN_CONF = CodeDocumentation.conf
# doxygen uses: graphviz, latex
html: $(DOXYGEN_CONF)
@# Generate the html documentation
@doxygen $(DOXYGEN_CONF)
@( cat $(DOXYGEN_CONF) ; echo "$(MFEM_DOXYGEN_FLAGS)" ) | doxygen -
@echo "<meta http-equiv=\"REFRESH\" content=\"0;URL=CodeDocumentation/html/index.html\">" > CodeDocumentation.html
@cat warnings.log 1>&2
@# Generate the log of undocumented methods
@@ -29,4 +29,3 @@ clean:
$(DOXYGEN_CONF): $(MFEM_DIR)/doc/$(DOXYGEN_CONF).in
@sed -e 's%@MFEM_SOURCE_DIR@%$(MFEM_DIR)%g' $(<) \
> $(DOXYGEN_CONF)
+4 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
@@ -38,6 +38,7 @@ list(APPEND ALL_EXE_SRCS
ex28.cpp
ex29.cpp
ex30.cpp
ex31.cpp
)
if (MFEM_USE_MPI)
@@ -72,6 +73,8 @@ if (MFEM_USE_MPI)
ex28p.cpp
ex29p.cpp
ex30p.cpp
ex31p.cpp
ex32p.cpp
)
endif()
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+5 -7
View File
@@ -37,11 +37,11 @@ using namespace mfem;
int main(int argc, char *argv[])
{
// 1. Initialize MPI.
int num_procs, myid;
MPI_Init(&argc, &argv);
MPI_Comm_size(MPI_COMM_WORLD, &num_procs);
MPI_Comm_rank(MPI_COMM_WORLD, &myid);
// 1. Initialize MPI and HYPRE.
Mpi::Init(argc, argv);
int num_procs = Mpi::WorldSize();
int myid = Mpi::WorldRank();
Hypre::Init();
// 2. Parse command-line options.
const char *mesh_file = "../../data/star.mesh";
@@ -87,7 +87,6 @@ int main(int argc, char *argv[])
{
args.PrintUsage(cout);
}
MPI_Finalize();
return 1;
}
if (myid == 0)
@@ -320,7 +319,6 @@ int main(int argc, char *argv[])
{
delete fec;
}
MPI_Finalize();
return 0;
}
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+5 -7
View File
@@ -58,11 +58,11 @@ using namespace mfem;
int main(int argc, char *argv[])
{
// 1. Initialize MPI.
int num_procs, myid;
MPI_Init(&argc, &argv);
MPI_Comm_size(MPI_COMM_WORLD, &num_procs);
MPI_Comm_rank(MPI_COMM_WORLD, &myid);
// 1. Initialize MPI and HYPRE.
Mpi::Init(argc, argv);
int num_procs = Mpi::WorldSize();
int myid = Mpi::WorldRank();
Hypre::Init();
// Define Caliper ConfigManager
cali::ConfigManager mgr;
// Caliper instrumentation
@@ -101,7 +101,6 @@ int main(int argc, char *argv[])
{
args.PrintUsage(cout);
}
MPI_Finalize();
return 1;
}
if (myid == 0)
@@ -293,7 +292,6 @@ int main(int argc, char *argv[])
}
// Flush output before MPI_finalize
mgr.flush();
MPI_Finalize();
return 0;
}
+1 -1
View File
@@ -1,4 +1,4 @@
# Copyright (c) 2010-2021, Lawrence Livermore National Security, LLC. Produced
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
+294
View File
@@ -0,0 +1,294 @@
// MFEM FOSLS acoustics Example
//
// Compile with: make fosls
//
// Definite/Indefinite Helmholtz
// - Δ p ± ω^2 p = f̃ , in Ω
// p = p_0, on ∂Ω
// First Order System
// ∇ p - ω u = 0, in Ω
// - ∇⋅u ± ω p = f, in Ω
// p = p_0, in ∂Ω
// where f:=f̃/ω
// FOSLS:
// minimize 1/2(||∇p - ω u||^2 + ||-∇⋅u ± ω p - f||^2)
// (p,u) ∈ H^1(Ω) × H(div,Ω)
// -------------------------------------------------------------------
// | | p | u | RHS |
// -------------------------------------------------------------------
// | q | (∇ p,∇ q) + ω^2(p,q) | ∓ ω (∇⋅u,q) - ω (u, ∇ q) | ± ω(f,q) |
// | | | | |
// | v | ∓ ω (p,∇⋅v) - ω (∇ p,v)| (∇⋅u,∇⋅v) + ω^2 (u,v) | -(f,∇⋅v) |
// where (q,v) ∈ H^1(Ω) × H(div,Ω)
#include "mfem.hpp"
#include <fstream>
#include <iostream>
using namespace std;
using namespace mfem;
// #define DEFINITE
double p_exact(const Vector &x);
void u_exact(const Vector &x, Vector & u);
double rhs_func(const Vector &x);
void gradp_exact(const Vector &x, Vector &gradu);
double divu_exact(const Vector &x);
double d2_exact(const Vector &x);
int dim;
double omega;
int main(int argc, char *argv[])
{
// 1. Parse command-line options.
const char *mesh_file = "../../../data/inline-quad.mesh";
int order = 1;
bool visualization = true;
double rnum=1.0;
int sr = 1;
OptionsParser args(argc, argv);
args.AddOption(&mesh_file, "-m", "--mesh",
"Mesh file to use.");
args.AddOption(&order, "-o", "--order",
"Finite element order (polynomial degree)");
args.AddOption(&visualization, "-vis", "--visualization", "-no-vis",
"--no-visualization",
"Enable or disable GLVis visualization.");
args.AddOption(&rnum, "-rnum", "--number_of_wavelenths",
"Number of wavelengths");
args.AddOption(&sr, "-sr", "--serial_ref",
"Number of serial refinements.");
args.Parse();
if (!args.Good())
{
args.PrintUsage(cout);
return 1;
}
args.PrintOptions(cout);
omega = 2.0 * M_PI * rnum;
Mesh mesh(mesh_file, 1, 1);
dim = mesh.Dimension();
for (int i = 0; i < sr; i++ )
{
mesh.UniformRefinement();
}
FiniteElementCollection *H1fec = new H1_FECollection(order, dim);
FiniteElementCollection *RTfec = new RT_FECollection(order-1, dim);
FiniteElementSpace * H1fes = new FiniteElementSpace(&mesh, H1fec);
FiniteElementSpace * RTfes = new FiniteElementSpace(&mesh, RTfec);
Array<FiniteElementSpace *> fespaces(2);
fespaces[0] = H1fes;
fespaces[1] = RTfes;
Array<int> ess_bdr;
Array<int> ess_tdof_list;
if (mesh.bdr_attributes.Size())
{
ess_bdr.SetSize(mesh.bdr_attributes.Max());
ess_bdr = 1;
fespaces[0]->GetEssentialTrueDofs(ess_bdr, ess_tdof_list);
}
BlockBilinearForm a(fespaces);
a.SetDiagonalPolicy(mfem::Operator::DIAG_KEEP);
cout << "H1 fespace = " << H1fes->GetTrueVSize() << endl;
cout << "RT fespace = " << RTfes->GetTrueVSize() << endl;
ConstantCoefficient one(1.0);
ConstantCoefficient negone(-1.0);
ConstantCoefficient omeg(omega);
ConstantCoefficient negomeg(-omega);
ConstantCoefficient omeg2(omega*omega);
Array2D<BilinearFormIntegrator * > blfi(2,2);
// blfi(0,0) = (∇ p,∇ q) + ω^2(p,q)
SumIntegrator * integ00 = new SumIntegrator();
integ00->AddIntegrator(new DiffusionIntegrator(one));
integ00->AddIntegrator(new MassIntegrator(omeg2));
blfi(0,0) = integ00;
// blfi(0,1) = ∓ ω (∇⋅u,q) - ω (u, ∇ q)
SumIntegrator * integ01 = new SumIntegrator();
#ifdef DEFINITE
// -ω (∇⋅u,q)
integ01->AddIntegrator(new MixedScalarDivergenceIntegrator(negomeg));
#else
// ω (∇⋅u,q)
integ01->AddIntegrator(new MixedScalarDivergenceIntegrator(omeg));
#endif
// - ω (u, ∇ q)
integ01->AddIntegrator(new MixedVectorWeakDivergenceIntegrator(omeg));
blfi(0,1) = integ01;
// blfi(1,0) = ∓ ω (p,∇⋅v) - ω (∇ p,v)
SumIntegrator * integ10 = new SumIntegrator();
#ifdef DEFINITE
// - ω (p,∇⋅v)
integ10->AddIntegrator(new MixedScalarWeakGradientIntegrator(omeg));
#else
// ω (p,∇⋅v)
integ10->AddIntegrator(new MixedScalarWeakGradientIntegrator(negomeg));
#endif
// - ω (∇ p,v)
integ10->AddIntegrator(new MixedVectorGradientIntegrator(negomeg));
blfi(1,0) = integ10;
// blfi(1,1) = (∇⋅u,∇⋅v) + ω^2 (u,v)
SumIntegrator * integ11 = new SumIntegrator();
integ11->AddIntegrator(new DivDivIntegrator(one));
integ11->AddIntegrator(new VectorFEMassIntegrator(omeg2));
blfi(1,1) = integ11;
BlockLinearForm b(fespaces);
Array<LinearFormIntegrator * > lfi(2);
// ± ω (f,q)
FunctionCoefficient f_rhs(rhs_func);
#ifdef DEFINITE
ProductCoefficient w_f(omeg,f_rhs);
#else
ProductCoefficient w_f(negomeg,f_rhs);
#endif
// lfi[0] = new DomainLFIntegrator(w_f);
lfi[0] = new DomainLFIntegrator(w_f);
// -(f,∇⋅v)
ProductCoefficient neg_f(negone,f_rhs);
// lfi[1] = new VectorFEDomainLFDivIntegrator(f_rhs);
lfi[1] = new VectorFEDomainLFDivIntegrator(neg_f);
TestBlockBilinearFormIntegrator * integ = new TestBlockBilinearFormIntegrator();
integ->SetIntegrators(blfi);
a.AddDomainIntegrator(integ);
a.Assemble();
TestBlockLinearFormIntegrator * lininteg = new TestBlockLinearFormIntegrator();
lininteg->SetIntegrators(lfi);
b.AddDomainIntegrator(lininteg);
b.Assemble();
int size = 0;
for (int i = 0; i<fespaces.Size(); i++)
{
size += fespaces[i]->GetVSize();
}
Vector x(size);
x = 0.0;
FunctionCoefficient p_ex(p_exact);
VectorFunctionCoefficient gradp_ex(dim,gradp_exact);
VectorFunctionCoefficient u_ex(dim,u_exact);
FunctionCoefficient divu_ex(divu_exact);
GridFunction p_gf, u_gf;
GridFunction pex_gf(H1fes);
p_gf.MakeRef(H1fes,x,0);
// p_gf.ProjectBdrCoefficient(p_ex,ess_bdr);
p_gf.ProjectCoefficient(p_ex);
pex_gf.ProjectCoefficient(p_ex);
u_gf.MakeRef(RTfes,x,H1fes->GetVSize());
u_gf = 0.;
OperatorPtr A;
Vector X,B;
a.FormLinearSystem(ess_tdof_list,x,b,A,X,B);
GSSmoother M((SparseMatrix&)(*A));
CGSolver cg;
cg.SetRelTol(1e-10);
cg.SetMaxIter(2000);
cg.SetPrintLevel(1);
cg.SetPreconditioner(M);
cg.SetOperator(*A);
cg.Mult(B, X);
a.RecoverFEMSolution(X,b,x);
p_gf.MakeRef(H1fes,x,0);
u_gf.MakeRef(RTfes,x,H1fes->GetVSize());
if (visualization)
{
char vishost[] = "localhost";
int visport = 19916;
socketstream solu_sock(vishost, visport);
solu_sock.precision(8);
solu_sock << "solution\n" << mesh << p_gf <<
"window_title 'Numerical p' "
<< flush;
// socketstream sols_sock(vishost, visport);
// sols_sock.precision(8);
// sols_sock << "solution\n" << mesh << u_gf <<
// "window_title 'Numerical sigma' "
// << flush;
socketstream solex_sock(vishost, visport);
solex_sock.precision(8);
solex_sock << "solution\n" << mesh << pex_gf <<
"window_title 'Exact p' "
<< flush;
}
return 0;
}
double rhs_func(const Vector &x)
{
double p = p_exact(x);
double divu = divu_exact(x);
// f = - ∇⋅u ± ω p,
#ifdef DEFINITE
return -divu + omega * p;
#else
return -divu - omega * p;
#endif
}
double p_exact(const Vector &x)
{
return sin(omega*x.Sum());
}
void gradp_exact(const Vector &x, Vector &grad)
{
grad.SetSize(x.Size());
grad = omega * cos(omega * x.Sum());
}
void u_exact(const Vector &x, Vector & u)
{
gradp_exact(x,u);
u *= 1./omega;
}
double divu_exact(const Vector &x)
{
return d2_exact(x)/omega;
}
double d2_exact(const Vector &x)
{
return -dim * omega * omega * sin(omega*x.Sum());
}
+59
View File
@@ -0,0 +1,59 @@
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
# This file is part of the MFEM library. For more information and source code
# availability visit https://mfem.org.
#
# MFEM is free software; you can redistribute it and/or modify it under the
# terms of the BSD-3 license. We welcome feedback and contributions, see file
# CONTRIBUTING.md for details.
# Use the MFEM build directory
MFEM_DIR ?= ../../..
MFEM_BUILD_DIR ?= ../../..
SRC = $(if $(MFEM_DIR:../../..=),$(MFEM_DIR)/examples/dpg_tests/acoustics,)
CONFIG_MK = $(MFEM_BUILD_DIR)/config/config.mk
MFEM_LIB_FILE = mfem_is_not_built
-include $(CONFIG_MK)
SEQ_EXAMPLES = fosls uw_dpg strong_dpg
PAR_EXAMPLES = uw_dpgp
ifeq ($(MFEM_USE_MPI),NO)
EXAMPLES = $(SEQ_EXAMPLES)
else
EXAMPLES = $(PAR_EXAMPLES) $(SEQ_EXAMPLES)
endif
.SUFFIXES:
.SUFFIXES: .o .cpp .mk
.PHONY: all clean clean-build clean-exec
# Remove built-in rule
%: %.cpp
# Replace the default implicit rule for *.cpp files
%: $(SRC)%.cpp $(MFEM_LIB_FILE) $(CONFIG_MK)
$(MFEM_CXX) $(MFEM_FLAGS) $< -o $@ $(MFEM_LIBS)
all: $(EXAMPLES)
MFEM_TESTS = EXAMPLES
include $(MFEM_TEST_MK)
# Testing: Parallel vs. serial runs
RUN_MPI = $(MFEM_MPIEXEC) $(MFEM_MPIEXEC_NP) $(MFEM_MPI_NP)
%-test-par: %
@$(call mfem-test,$<, $(RUN_MPI), Parallel example)
%-test-seq: %
@$(call mfem-test,$<,, Serial example)
clean: clean-build clean-exec
clean-build:
rm -f *.o *~ $(SEQ_EXAMPLES) $(PAR_EXAMPLES)
rm -rf *.dSYM *.TVD.*breakpoints
clean-exec:
+271
View File
@@ -0,0 +1,271 @@
// MFEM DPG_strong acoustics Example
//
// Compile with: make strong_dpg
//
// Definite/Indefinite Helmholtz
// - Δ p ± ω^2 p = f̃ , in Ω
// p = p_0, on ∂Ω
// First Order System
// ∇ p - ω u = 0, in Ω
// - ∇⋅u ± ω p = f, in Ω
// p = p_0, in ∂Ω
// where f:=f̃/ω
// Strong DPG formulation
// (p,u) ∈ H^1(Ω) × H(div,Ω)
//
// (∇ p, v) - ω (u,v) = 0, in Ω, ∀ v ∈ (L^2)^dim
// -(∇⋅u, q) ± ω (p,q) = (f,q), in Ω, ∀ q ∈ L^2
// p = p_0, in ∂Ω
//
// ------------------------------------
// | | p | u | RHS |
// ------------------------------------
// | q | ± ω (p,q) | -(∇⋅u,q) | (f,q) |
// | | | | |
// | v | (∇ p, v) | -ω (u,v) | |
// where (q,v) ∈ L^2 × (L^2)^dim
#include "mfem.hpp"
#include <fstream>
#include <iostream>
using namespace std;
using namespace mfem;
// #define DEFINITE
double p_exact(const Vector &x);
void u_exact(const Vector &x, Vector & u);
double rhs_func(const Vector &x);
void gradp_exact(const Vector &x, Vector &gradu);
double divu_exact(const Vector &x);
double d2_exact(const Vector &x);
int dim;
double omega;
int main(int argc, char *argv[])
{
// 1. Parse command-line options.
const char *mesh_file = "../../../data/inline-quad.mesh";
int order = 1;
int delta_order = 1;
bool visualization = true;
double rnum=1.0;
int ref = 1;
OptionsParser args(argc, argv);
args.AddOption(&mesh_file, "-m", "--mesh",
"Mesh file to use.");
args.AddOption(&order, "-o", "--order",
"Finite element order (polynomial degree)");
args.AddOption(&visualization, "-vis", "--visualization", "-no-vis",
"--no-visualization",
"Enable or disable GLVis visualization.");
args.AddOption(&rnum, "-rnum", "--number_of_wavelenths",
"Number of wavelengths");
args.AddOption(&delta_order, "-do", "--delta_order",
"Order enrichment for DPG test space.");
args.AddOption(&ref, "-ref", "--serial_ref",
"Number of serial refinements.");
args.Parse();
if (!args.Good())
{
args.PrintUsage(cout);
return 1;
}
args.PrintOptions(cout);
omega = 2.0 * M_PI * rnum;
Mesh mesh(mesh_file, 1, 1);
dim = mesh.Dimension();
for (int i = 0; i < ref; i++ )
{
mesh.UniformRefinement();
}
// Define spaces
// H1 space for p
FiniteElementCollection *p_fec = new H1_FECollection(order, dim);
FiniteElementSpace * p_fes = new FiniteElementSpace(&mesh, p_fec);
// H(div) for u
FiniteElementCollection *u_fec = new RT_FECollection(order-1, dim);
FiniteElementSpace * u_fes = new FiniteElementSpace(&mesh, u_fec);
// testspace fe collections
int test_order = order+delta_order;
FiniteElementCollection * q_fec = new L2_FECollection(test_order-1, dim);
FiniteElementCollection * v_fec = new L2_FECollection(test_order-1, dim);
ConstantCoefficient one(1.0);
ConstantCoefficient negone(-1.0);
ConstantCoefficient omeg(omega);
ConstantCoefficient negomeg(-omega);
// Normal equation weak formulation
Array<FiniteElementSpace * > trial_fes;
Array<FiniteElementCollection * > test_fec;
trial_fes.Append(p_fes);
trial_fes.Append(u_fes);
test_fec.Append(q_fec);
test_fec.Append(v_fec);
NormalEquations * a = new NormalEquations(trial_fes,test_fec);
a->SetTestFECollVdim(1,dim);
a->StoreMatrices(true);
// ± ω (p, q)
#ifdef DEFINITE
// ω (p, q)
a->AddTrialIntegrator(new MassIntegrator(omeg),0,0);
#else
// -ω (p, q)
a->AddTrialIntegrator(new MassIntegrator(negomeg),0,0);
#endif
// -(∇⋅u, q)
a->AddTrialIntegrator(new MixedScalarDivergenceIntegrator(negone),1,0);
// -ω (u,v)
a->AddTrialIntegrator(new VectorFEMassIntegrator(negomeg),1,1);
// (∇ p, v)
a->AddTrialIntegrator(new GradientIntegrator(one),0,1);
// (v,δv)
a->AddTestIntegrator(new VectorMassIntegrator(one),1,1);
// (q,δq)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
FunctionCoefficient f_rhs(rhs_func);
a->AddDomainLFIntegrator(new DomainLFIntegrator(f_rhs),0);
Array<int> ess_tdof_list;
Array<int> ess_bdr;
if (mesh.bdr_attributes.Size())
{
ess_bdr.SetSize(mesh.bdr_attributes.Max());
ess_bdr = 1;
p_fes->GetEssentialTrueDofs(ess_bdr, ess_tdof_list);
}
FunctionCoefficient p_ex(p_exact);
VectorFunctionCoefficient gradp_ex(dim,gradp_exact);
VectorFunctionCoefficient u_ex(dim,u_exact);
FunctionCoefficient divu_ex(divu_exact);
GridFunction p_gf, u_gf;
GridFunction pex_gf(p_fes);
Array<int> offsets(3);
offsets[0] = 0;
offsets[1] = p_fes->GetVSize();
offsets[2] = u_fes->GetVSize();
offsets.PartialSum();
BlockVector x(offsets);
x = 0.0;
p_gf.MakeRef(p_fes,x.GetBlock(0));
p_gf.ProjectBdrCoefficient(p_ex,ess_bdr);
u_gf.MakeRef(u_fes,x.GetBlock(1));
a->Assemble();
OperatorPtr Ah;
Vector X,B;
a->FormLinearSystem(ess_tdof_list,x,Ah,X,B);
BlockMatrix * A = Ah.As<BlockMatrix>();
BlockDiagonalPreconditioner * M = new BlockDiagonalPreconditioner(A->RowOffsets());
M->owns_blocks = 1;
for (int i=0; i<A->NumRowBlocks(); i++)
{
M->SetDiagonalBlock(i,new UMFPackSolver(A->GetBlock(i,i)));
}
CGSolver cg;
cg.SetRelTol(1e-12);
cg.SetMaxIter(2000);
cg.SetPrintLevel(3);
cg.SetPreconditioner(*M);
cg.SetOperator(*A);
cg.Mult(B, X);
delete M;
a->RecoverFEMSolution(X,x);
if (visualization)
{
char vishost[] = "localhost";
int visport = 19916;
socketstream p_out;
socketstream u_out;
p_out.open(vishost, visport);
u_out.open(vishost, visport);
p_out.precision(8);
p_out << "solution\n" << mesh << p_gf <<
"window_title 'Numerical p' "
<< flush;
u_out.precision(8);
u_out << "solution\n" << mesh << u_gf <<
"window_title 'Numerical flux' "
<< flush;
}
return 0;
}
double rhs_func(const Vector &x)
{
double p = p_exact(x);
double divu = divu_exact(x);
// f = - ∇⋅u ± ω p,
#ifdef DEFINITE
return -divu + omega * p;
#else
return -divu - omega * p;
#endif
}
double p_exact(const Vector &x)
{
return sin(omega*x.Sum());
}
void gradp_exact(const Vector &x, Vector &grad)
{
grad.SetSize(x.Size());
grad = omega * cos(omega * x.Sum());
}
void u_exact(const Vector &x, Vector & u)
{
gradp_exact(x,u);
u *= 1./omega;
}
double divu_exact(const Vector &x)
{
return d2_exact(x)/omega;
}
double d2_exact(const Vector &x)
{
return -dim * omega * omega * sin(omega*x.Sum());
}
+546
View File
@@ -0,0 +1,546 @@
// MFEM Ultraweak DPG acoustics example
//
// Compile with: make uw_dpg
//
// ./uw_dpg -m ../../../data/inline-quad.mesh -rnum 40 -theta 0.7 -prob 1 -graph-norm -ref 40 -o 3
// - Δ p ± ω^2 p = f̃ , in Ω
// p = p_0, on ∂Ω
// First Order System
// ∇ p - ω u = 0, in Ω
// - ∇⋅u ± ω p = f, in Ω
// p = p_0, in ∂Ω
// where f:=f̃/ω
// UW-DPG:
//
// p ∈ L^2(Ω), u ∈ (L^2(Ω))^dim
// p̂ ∈ H^1/2(Ω), û ∈ H^-1/2(Ω)
// -(p, ∇⋅v) - ω (u , v) + < p̂, v⋅n> = 0, ∀ v ∈ H(div,Ω)
// (u , ∇ q) ± ω (p , q) + < û, q > = (f,q) ∀ q ∈ H^1(Ω)
// p̂ = p_0 on ∂Ω
// Note:
// p̂ := p on Γ_h (skeleton)
// û := -u on Γ_h
// -------------------------------------------------------------
// | | p | u | p̂ | û | RHS |
// -------------------------------------------------------------
// | v | -(p, ∇⋅v) | - ω (u,v) | < p̂, v⋅n> | | |
// | | | | | | |
// | q | ± ω (p,q) | (u , ∇ q) | | < û,q > | (f,q) |
// where (q,v) ∈ H^1(Ω) × H(div,Ω)
#include "mfem.hpp"
#include <fstream>
#include <iostream>
using namespace std;
using namespace mfem;
// #define DEFINITE
void acoustics_solution(const Vector & X, double & p, Vector & dp, double & d2p);
double p_exact(const Vector &x);
void u_exact(const Vector &x, Vector & u);
double rhs_func(const Vector &x);
double divu_exact(const Vector &x);
double hatp_exact(const Vector & X);
void hatu_exact(const Vector & X, Vector & hatu);
int dim;
double omega;
enum prob_type
{
plane_wave,
gaussian_beam
};
prob_type prob;
int main(int argc, char *argv[])
{
const char *mesh_file = "../../../data/inline-quad.mesh";
int order = 1;
int delta_order = 1;
bool visualization = true;
double rnum=1.0;
int ref = 1;
double theta = 0.0;
bool adjoint_graph_norm = false;
int iprob = 0;
OptionsParser args(argc, argv);
args.AddOption(&mesh_file, "-m", "--mesh",
"Mesh file to use.");
args.AddOption(&order, "-o", "--order",
"Finite element order (polynomial degree)");
args.AddOption(&visualization, "-vis", "--visualization", "-no-vis",
"--no-visualization",
"Enable or disable GLVis visualization.");
args.AddOption(&rnum, "-rnum", "--number_of_wavelenths",
"Number of wavelengths");
args.AddOption(&delta_order, "-do", "--delta_order",
"Order enrichment for DPG test space.");
args.AddOption(&theta, "-theta", "--theta",
"Theta parameter for AMR");
args.AddOption(&iprob, "-prob", "--problem", "Problem case"
" 0: plane wave, 1: Gaussian beam");
args.AddOption(&adjoint_graph_norm, "-graph-norm", "--adjoint-graph-norm",
"-no-graph-norm", "--no-adjoint-graph-norm",
"Enable or disable Adjoint Graph Norm on the test space");
args.AddOption(&ref, "-ref", "--serial_ref",
"Number of serial refinements.");
args.Parse();
if (!args.Good())
{
args.PrintUsage(cout);
return 1;
}
args.PrintOptions(cout);
if (iprob > 1) { iprob = 0; }
prob = (prob_type)iprob;
omega = 2.0 * M_PI * rnum;
Mesh mesh(mesh_file, 1, 1);
dim = mesh.Dimension();
// Define spaces
// L2 space for p
FiniteElementCollection *p_fec = new L2_FECollection(order-1,dim);
FiniteElementSpace *p_fes = new FiniteElementSpace(&mesh,p_fec);
// Vector L2 space for u
FiniteElementCollection *u_fec = new L2_FECollection(order-1,dim);
FiniteElementSpace *u_fes = new FiniteElementSpace(&mesh,u_fec, dim);
// H^1/2 space for p̂
FiniteElementCollection * hatp_fec = new H1_Trace_FECollection(order,dim);
FiniteElementSpace *hatp_fes = new FiniteElementSpace(&mesh,hatp_fec);
// H^-1/2 space for û
FiniteElementCollection * hatu_fec = new RT_Trace_FECollection(order-1,dim);
FiniteElementSpace *hatu_fes = new FiniteElementSpace(&mesh,hatu_fec);
// testspace fe collections
int test_order = order+delta_order;
FiniteElementCollection * q_fec = new H1_FECollection(test_order, dim);
FiniteElementCollection * v_fec = new RT_FECollection(test_order-1, dim);
// Coefficients
ConstantCoefficient one(1.0);
ConstantCoefficient zero(0.0);
Vector vec0(dim); vec0 = 0.;
VectorConstantCoefficient vzero(vec0);
ConstantCoefficient negone(-1.0);
ConstantCoefficient omeg(omega);
ConstantCoefficient omeg2(omega*omega);
ConstantCoefficient negomeg(-omega);
// Normal equation weak formulation
Array<FiniteElementSpace * > trial_fes;
Array<FiniteElementCollection * > test_fec;
trial_fes.Append(p_fes);
trial_fes.Append(u_fes);
trial_fes.Append(hatp_fes);
trial_fes.Append(hatu_fes);
test_fec.Append(q_fec);
test_fec.Append(v_fec);
NormalEquations * a = new NormalEquations(trial_fes,test_fec);
a->StoreMatrices(true);
// ± ω (p,q)
#ifdef DEFINITE
a->AddTrialIntegrator(new MixedScalarMassIntegrator(omeg),0,0);
#else
a->AddTrialIntegrator(new MixedScalarMassIntegrator(negomeg),0,0);
#endif
// (u , ∇ q)
a->AddTrialIntegrator(new TransposeIntegrator(new GradientIntegrator(one)),1,0);
// -(p, ∇⋅v)
a->AddTrialIntegrator(new MixedScalarWeakGradientIntegrator(one),0,1);
// - ω (u,v)
a->AddTrialIntegrator(new TransposeIntegrator(new VectorFEMassIntegrator(negomeg)),1,1);
// < p̂, v⋅n>
a->AddTrialIntegrator(new NormalTraceIntegrator,2,1);
// < û,q >
a->AddTrialIntegrator(new TraceIntegrator,3,0);
// test integrators
//space-induced norm for H(div) × H1
// (∇q,∇δq)
a->AddTestIntegrator(new DiffusionIntegrator(one),0,0);
// (q,δq)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
// (∇⋅v,∇⋅δv)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
// (v,δv)
a->AddTestIntegrator(new VectorFEMassIntegrator(one),1,1);
// additional integrators for the adjoint graph norm
if (adjoint_graph_norm)
{
// -ω (∇q,δv)
a->AddTestIntegrator(new MixedVectorGradientIntegrator(negomeg),0,1);
// -ω (v,δq)
a->AddTestIntegrator(new MixedVectorWeakDivergenceIntegrator(omeg),1,0);
// ω^2 (v,δv)
a->AddTestIntegrator(new VectorFEMassIntegrator(omeg2),1,1);
#ifdef DEFINITE
// - ω (∇⋅v,δq)
a->AddTestIntegrator(new VectorFEDivergenceIntegrator(negomeg),1,0);
// - ω (q,∇⋅v)
a->AddTestIntegrator(new MixedScalarWeakGradientIntegrator(omeg),0,1);
#else
// ω (∇⋅v,δq)
a->AddTestIntegrator(new VectorFEDivergenceIntegrator(omeg),1,0);
// ω (q,∇⋅v)
a->AddTestIntegrator(new MixedScalarWeakGradientIntegrator(negomeg),0,1);
#endif
// ω^2 (q,δq)
a->AddTestIntegrator(new MassIntegrator(omeg2),0,0);
}
// RHS
FunctionCoefficient f_rhs(rhs_func);
a->AddDomainLFIntegrator(new DomainLFIntegrator(f_rhs),0);
FunctionCoefficient hatpex(hatp_exact);
FunctionCoefficient pex(p_exact);
VectorFunctionCoefficient uex(dim,u_exact);
Array<int> elements_to_refine;
GridFunction hatp_gf;
socketstream p_out;
// socketstream u_out;
if (visualization)
{
char vishost[] = "localhost";
int visport = 19916;
p_out.open(vishost, visport);
// u_out.open(vishost, visport);
}
double res0 = 0.;
double err0 = 0.;
int dof0;
mfem::out << " Refinement |"
<< " Dofs |"
<< " L2 Error |"
<< " Relative % |"
<< " Rate |"
<< " Residual |"
<< " Rate |" << endl;
mfem::out << " --------------------"
<< "-------------------"
<< "-------------------"
<< "-------------------" << endl;
for (int i = 0; i<ref; i++)
{
a->Assemble();
Array<int> ess_tdof_list;
Array<int> ess_bdr;
if (mesh.bdr_attributes.Size())
{
ess_bdr.SetSize(mesh.bdr_attributes.Max());
ess_bdr = 1;
hatp_fes->GetEssentialTrueDofs(ess_bdr, ess_tdof_list);
}
// shift the ess_tdofs
for (int i = 0; i < ess_tdof_list.Size(); i++)
{
ess_tdof_list[i] += p_fes->GetTrueVSize() + u_fes->GetTrueVSize();
}
Array<int> offsets(5);
offsets[0] = 0;
offsets[1] = p_fes->GetVSize();
offsets[2] = u_fes->GetVSize();
offsets[3] = hatp_fes->GetVSize();
offsets[4] = hatu_fes->GetVSize();
offsets.PartialSum();
BlockVector x(offsets);
x = 0.0;
hatp_gf.MakeRef(hatp_fes,x.GetBlock(2));
hatp_gf.ProjectBdrCoefficient(hatpex,ess_bdr);
OperatorPtr Ah;
Vector X,B;
a->FormLinearSystem(ess_tdof_list,x,Ah,X,B);
BlockMatrix * A = Ah.As<BlockMatrix>();
BlockDiagonalPreconditioner * M = new BlockDiagonalPreconditioner(A->RowOffsets());
M->owns_blocks = 1;
for (int i=0; i<A->NumRowBlocks(); i++)
{
M->SetDiagonalBlock(i,new UMFPackSolver(A->GetBlock(i,i)));
}
CGSolver cg;
cg.SetRelTol(1e-8);
cg.SetMaxIter(20000);
cg.SetPrintLevel(3);
cg.SetPreconditioner(*M);
cg.SetOperator(*A);
cg.Mult(B, X);
delete M;
a->RecoverFEMSolution(X,x);
Vector & residuals = a->ComputeResidual(x);
double residual = residuals.Norml2();
elements_to_refine.SetSize(0);
double max_resid = residuals.Max();
for (int iel = 0; iel<mesh.GetNE(); iel++)
{
if (residuals[iel] > theta * max_resid)
{
elements_to_refine.Append(iel);
}
}
GridFunction p_gf;
p_gf.MakeRef(p_fes,x.GetBlock(0));
GridFunction u_gf;
u_gf.MakeRef(u_fes,x.GetBlock(1));
GridFunction pex_gf(p_fes);
GridFunction uex_gf(u_fes);
pex_gf.ProjectCoefficient(pex);
uex_gf.ProjectCoefficient(uex);
// Error
int dofs = X.Size();
double p_err = p_gf.ComputeL2Error(pex);
double p_norm = uex_gf.ComputeL2Error(zero);
double u_err = u_gf.ComputeL2Error(uex);
double u_norm = u_gf.ComputeL2Error(vzero);
double L2Error = sqrt(p_err*p_err + u_err*u_err);
double L2norm = sqrt(p_norm * p_norm + u_norm * u_norm);
double rel_error = L2Error/L2norm;
double rate_err = (i) ? dim*log(err0/L2Error)/log((double)dof0/dofs) : 0.0;
double rate_res = (i) ? dim*log(res0/residual)/log((double)dof0/dofs) : 0.0;
err0 = L2Error;
res0 = residual;
dof0 = dofs;
mfem::out << std::right << std::setw(11) << i << " | "
<< std::setw(10) << dof0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << err0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::fixed << rel_error * 100. << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_err << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << res0 << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_res << " | "
<< std::resetiosflags(std::ios::showbase)
<< std::endl;
if (visualization)
{
p_out.precision(8);
p_out << "solution\n" << mesh << p_gf <<
"window_title 'Numerical presure' "
<< flush;
// u_out.precision(8);
// u_out << "solution\n" << mesh << u_gf <<
// "window_title 'Numerical velocity' "
// << flush;
}
if (i == ref)
break;
mesh.GeneralRefinement(elements_to_refine,1,1);
for (int i =0; i<trial_fes.Size(); i++)
{
trial_fes[i]->Update(false);
}
a->Update();
}
delete a;
delete q_fec;
delete v_fec;
delete hatp_fes;
delete hatp_fec;
delete hatu_fes;
delete hatu_fec;
delete u_fec;
delete p_fec;
delete u_fes;
delete p_fes;
return 0;
}
double rhs_func(const Vector &x)
{
double p = p_exact(x);
double divu = divu_exact(x);
// f = - ∇⋅u ± ω p,
#ifdef DEFINITE
return -divu + omega * p;
#else
return -divu - omega * p;
#endif
}
double p_exact(const Vector &x)
{
double p, d2p;
Vector dp;
acoustics_solution(x,p,dp,d2p);
return p;
}
void u_exact(const Vector &x, Vector & u)
{
double p, d2p;
acoustics_solution(x,p,u,d2p);
u *= 1./omega;
}
double divu_exact(const Vector &x)
{
double p, d2p;
Vector dp;
acoustics_solution(x,p,dp,d2p);
return d2p/omega;
}
double hatp_exact(const Vector & X)
{
return p_exact(X);
}
void hatu_exact(const Vector & X, Vector & hatu)
{
u_exact(X,hatu);
hatu *= -1.;
}
void acoustics_solution(const Vector & X, double & p, Vector & dp, double & d2p)
{
dp.SetSize(X.Size());
switch (prob)
{
case plane_wave:
{
p = sin(omega*X.Sum());
dp = omega * cos(omega * X.Sum());
d2p = -dim * omega * omega * sin(omega*X.Sum());
}
break;
default:
{
double rk = omega;
double alpha = 45 * M_PI/180.;
double sina = sin(alpha);
double cosa = cos(alpha);
// shift the origin
double xprim=X(0) + 0.1;
double yprim=X(1) + 0.1;
double x = xprim*sina - yprim*cosa;
double y = xprim*cosa + yprim*sina;
double dxdxprim = sina, dxdyprim = -cosa;
double dydxprim = cosa, dydyprim = sina;
//wavelength
double rl = 2.*M_PI/rk;
// beam waist radius
double w0 = 0.05;
// function w
double fact = rl/M_PI/(w0*w0);
double aux = 1. + (fact*y)*(fact*y);
double w = w0*sqrt(aux);
double dwdy = w0*fact*fact*y/sqrt(aux);
double d2wdydy = w0*fact*fact*(1. - (fact*y)*(fact*y)/aux)/sqrt(aux);
double phi0 = atan(fact*y);
double dphi0dy = cos(phi0)*cos(phi0)*fact;
double d2phi0dydy = -2.*cos(phi0)*sin(phi0)*fact*dphi0dy;
double r = y + 1./y/(fact*fact);
double drdy = 1. - 1./(y*y)/(fact*fact);
double d2rdydy = 2./(y*y*y)/(fact*fact);
// pressure
complex<double> zi = complex<double>(0., 1.);
complex<double> ze = - x*x/(w*w) - zi*rk*y - zi * M_PI * x * x/rl/r + zi*phi0/2.;
complex<double> zdedx = -2.*x/(w*w) - 2.*zi*M_PI*x/rl/r;
complex<double> zdedy = 2.*x*x/(w*w*w)*dwdy - zi*rk + zi*M_PI*x*x/rl/(r*r)*drdy + zi*dphi0dy/2.;
complex<double> zd2edxdx = -2./(w*w) - 2.*zi*M_PI/rl/r;
complex<double> zd2edxdy = 4.*x/(w*w*w)*dwdy + 2.*zi*M_PI*x/rl/(r*r)*drdy;
complex<double> zd2edydx = zd2edxdy;
complex<double> zd2edydy = -6.*x*x/(w*w*w*w)*dwdy*dwdy + 2.*x*x/(w*w*w)*d2wdydy - 2.*zi*M_PI*x*x/rl/(r*r*r)*drdy*drdy
+ zi*M_PI*x*x/rl/(r*r)*d2rdydy + zi/2.*d2phi0dydy;
double pf = pow(2.0/M_PI/(w*w),0.25);
double dpfdy = -pow(2./M_PI/(w*w),-0.75)/M_PI/(w*w*w)*dwdy;
double d2pfdydy = -1./M_PI*pow(2./M_PI,-0.75)*(-1.5*pow(w,-2.5)
*dwdy*dwdy + pow(w,-1.5)*d2wdydy);
complex<double> zp = pf*exp(ze);
complex<double> zdpdx = zp*zdedx;
complex<double> zdpdy = dpfdy*exp(ze)+zp*zdedy;
complex<double> zd2pdxdx = zdpdx*zdedx + zp*zd2edxdx;
complex<double> zd2pdxdy = zdpdy*zdedx + zp*zd2edxdy;
complex<double> zd2pdydx = dpfdy*exp(ze)*zdedx + zdpdx*zdedy + zp*zd2edydx;
complex<double> zd2pdydy = d2pfdydy*exp(ze) + dpfdy*exp(ze)*zdedy + zdpdy*zdedy + zp*zd2edydy;
p = zp.real();
dp[0] = (zdpdx*dxdxprim + zdpdy*dydxprim).real();
dp[1] = (zdpdx*dxdyprim + zdpdy*dydyprim).real();
d2p = ( (zd2pdxdx*dxdxprim + zd2pdydx*dydxprim)*dxdxprim + (zd2pdxdy*dxdxprim + zd2pdydy*dydxprim)*dydxprim
+ (zd2pdxdx*dxdyprim + zd2pdydx*dydyprim)*dxdyprim + (zd2pdxdy*dxdyprim + zd2pdydy*dydyprim)*dydyprim ).real();
}
break;
}
}
+507
View File
@@ -0,0 +1,507 @@
// MFEM Ultraweak DPG MPI acoustics (Helmholtz) example
//
// Compile with: make uw_dpgp
//
// - Δ p ± ω^2 p = f̃ , in Ω
// p = p_0, on ∂Ω
//
// First Order System
// ∇ p - ω u = 0, in Ω
// - ∇⋅u ± ω p = f, in Ω
// p = p_0, in ∂Ω
// where f:=f̃/ω
//
// UW-DPG:
//
// p ∈ L^2(Ω), u ∈ (L^2(Ω))^dim
// p̂ ∈ H^1/2(Ω), û ∈ H^-1/2(Ω)
// -(p, ∇⋅v) - ω (u , v) + < p̂, v⋅n> = 0, ∀ v ∈ H(div,Ω)
// (u , ∇ q) ± ω (p , q) + < û, q > = (f,q) ∀ q ∈ H^1(Ω)
// p̂ = p_0 on ∂Ω
// Note:
// p̂ := p on Γ_h (skeleton)
// û := -u on Γ_h
// -------------------------------------------------------------
// | | p | u | p̂ | û | RHS |
// -------------------------------------------------------------
// | v | -(p, ∇⋅v) | - ω (u,v) | < p̂, v⋅n> | | |
// | | | | | | |
// | q | ± ω (p,q) | (u , ∇ q) | | < û,q > | (f,q) |
// where (q,v) ∈ H^1(Ω) × H(div,Ω)
#include "mfem.hpp"
#include <fstream>
#include <iostream>
using namespace std;
using namespace mfem;
// #define DEFINITE
double p_exact(const Vector &x);
void u_exact(const Vector &x, Vector & u);
double rhs_func(const Vector &x);
void gradp_exact(const Vector &x, Vector &gradu);
double divu_exact(const Vector &x);
double d2_exact(const Vector &x);
double hatp_exact(const Vector & X);
void hatu_exact(const Vector & X, Vector & hatu);
int dim;
double omega;
int main(int argc, char *argv[])
{
MPI_Session mpi;
int num_procs = mpi.WorldSize();
int myid = mpi.WorldRank();
// 1. Parse command-line options.
const char *mesh_file = "../../../data/inline-quad.mesh";
int order = 1;
int delta_order = 1;
bool visualization = true;
double rnum=1.0;
int ref = 1;
double theta = 0.0;
bool adjoint_graph_norm = false;
OptionsParser args(argc, argv);
args.AddOption(&mesh_file, "-m", "--mesh",
"Mesh file to use.");
args.AddOption(&order, "-o", "--order",
"Finite element order (polynomial degree)");
args.AddOption(&visualization, "-vis", "--visualization", "-no-vis",
"--no-visualization",
"Enable or disable GLVis visualization.");
args.AddOption(&rnum, "-rnum", "--number_of_wavelenths",
"Number of wavelengths");
args.AddOption(&delta_order, "-do", "--delta_order",
"Order enrichment for DPG test space.");
args.AddOption(&theta, "-theta", "--theta",
"Theta parameter for AMR");
args.AddOption(&adjoint_graph_norm, "-graph-norm", "--adjoint-graph-norm",
"-no-graph-norm", "--no-adjoint-graph-norm",
"Enable or disable Adjoint Graph Norm on the test space");
args.AddOption(&ref, "-ref", "--serial_ref",
"Number of serial refinements.");
args.Parse();
if (!args.Good())
{
if (myid == 0)
{
args.PrintUsage(cout);
}
return 1;
}
if (myid == 0)
{
args.PrintOptions(cout);
}
omega = 2.0 * M_PI * rnum;
Mesh mesh(mesh_file, 1, 1);
dim = mesh.Dimension();
mesh.EnsureNCMesh();
ParMesh pmesh(MPI_COMM_WORLD, mesh);
mesh.Clear();
// Define spaces
// L2 space for p
FiniteElementCollection *p_fec = new L2_FECollection(order-1,dim);
ParFiniteElementSpace *p_fes = new ParFiniteElementSpace(&pmesh,p_fec);
// Vector L2 space for u
FiniteElementCollection *u_fec = new L2_FECollection(order-1,dim);
ParFiniteElementSpace *u_fes = new ParFiniteElementSpace(&pmesh,u_fec, dim);
// H^1/2 space for p̂
FiniteElementCollection * hatp_fec = new H1_Trace_FECollection(order,dim);
ParFiniteElementSpace *hatp_fes = new ParFiniteElementSpace(&pmesh,hatp_fec);
// H^-1/2 space for û
FiniteElementCollection * hatu_fec = new RT_Trace_FECollection(order-1,dim);
ParFiniteElementSpace *hatu_fes = new ParFiniteElementSpace(&pmesh,hatu_fec);
// testspace fe collections
int test_order = order+delta_order;
FiniteElementCollection * q_fec = new H1_FECollection(test_order, dim);
FiniteElementCollection * v_fec = new RT_FECollection(test_order-1, dim);
Array<ParFiniteElementSpace * > trial_fes;
trial_fes.Append(p_fes);
trial_fes.Append(u_fes);
trial_fes.Append(hatp_fes);
trial_fes.Append(hatu_fes);
Array<FiniteElementCollection * > test_fec;
test_fec.Append(q_fec);
test_fec.Append(v_fec);
ConstantCoefficient one(1.0);
ConstantCoefficient zero(0.0);
Vector vec0(dim); vec0 = 0.;
VectorConstantCoefficient vzero(vec0);
ConstantCoefficient negone(-1.0);
ConstantCoefficient omeg(omega);
ConstantCoefficient omeg2(omega*omega);
ConstantCoefficient negomeg(-omega);
ParNormalEquations * a = new ParNormalEquations(trial_fes,test_fec);
a->StoreMatrices(true);
// Integrators
// ± ω (p,q)
#ifdef DEFINITE
a->AddTrialIntegrator(new MixedScalarMassIntegrator(omeg),0,0);
#else
a->AddTrialIntegrator(new MixedScalarMassIntegrator(negomeg),0,0);
#endif
// (u , ∇ q)
a->AddTrialIntegrator(new TransposeIntegrator(new GradientIntegrator(one)),1,0);
// -(p, ∇⋅v)
a->AddTrialIntegrator(new MixedScalarWeakGradientIntegrator(one),0,1);
// - ω (u,v)
a->AddTrialIntegrator(new TransposeIntegrator(new VectorFEMassIntegrator(negomeg)),1,1);
// < p̂, v⋅n>
a->AddTrialIntegrator(new NormalTraceIntegrator,2,1);
// < û,q >
a->AddTrialIntegrator(new TraceIntegrator,3,0);
// test integrators
//space-induced norm for H(div) × H1
// (∇q,∇δq)
a->AddTestIntegrator(new DiffusionIntegrator(one),0,0);
// (q,δq)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
// (∇⋅v,∇⋅δv)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
// (v,δv)
a->AddTestIntegrator(new VectorFEMassIntegrator(one),1,1);
// additional integrators for the adjoint graph norm
if (adjoint_graph_norm)
{
// -ω (∇q,δv)
a->AddTestIntegrator(new MixedVectorGradientIntegrator(negomeg),0,1);
// -ω (v,δq)
a->AddTestIntegrator(new MixedVectorWeakDivergenceIntegrator(omeg),1,0);
// ω^2 (v,δv)
a->AddTestIntegrator(new VectorFEMassIntegrator(omeg2),1,1);
#ifdef DEFINITE
// - ω (∇⋅v,δq)
a->AddTestIntegrator(new VectorFEDivergenceIntegrator(negomeg),1,0);
// - ω (q,∇⋅v)
a->AddTestIntegrator(new MixedScalarWeakGradientIntegrator(omeg),0,1);
#else
// ω (∇⋅v,δq)
a->AddTestIntegrator(new VectorFEDivergenceIntegrator(omeg),1,0);
// ω (q,∇⋅v)
a->AddTestIntegrator(new MixedScalarWeakGradientIntegrator(negomeg),0,1);
#endif
// ω^2 (q,δq)
a->AddTestIntegrator(new MassIntegrator(omeg2),0,0);
}
// RHS
FunctionCoefficient f_rhs(rhs_func);
a->AddDomainLFIntegrator(new DomainLFIntegrator(f_rhs),0);
FunctionCoefficient hatpex(hatp_exact);
FunctionCoefficient pex(p_exact);
VectorFunctionCoefficient uex(dim,u_exact);
Array<int> elements_to_refine;
ParGridFunction hatp_gf;
socketstream p_out;
if (visualization)
{
char vishost[] = "localhost";
int visport = 19916;
p_out.open(vishost, visport);
}
double res0 = 0.;
double err0 = 0.;
int dof0;
if (myid == 0)
{
mfem::out << " Refinement |"
<< " Dofs |"
<< " L2 Error |"
<< " Relative % |"
<< " Rate |"
<< " Residual |"
<< " Rate |" << endl;
mfem::out << " --------------------"
<< "-------------------"
<< "-------------------"
<< "-------------------" << endl;
}
for (int i = 0; i<ref; i++)
{
a->Assemble();
Array<int> ess_tdof_list;
Array<int> ess_bdr;
if (pmesh.bdr_attributes.Size())
{
ess_bdr.SetSize(pmesh.bdr_attributes.Max());
ess_bdr = 1;
hatp_fes->GetEssentialTrueDofs(ess_bdr, ess_tdof_list);
}
// shift the ess_tdofs
for (int i = 0; i < ess_tdof_list.Size(); i++)
{
ess_tdof_list[i] += p_fes->GetTrueVSize() + u_fes->GetTrueVSize();
}
Array<int> offsets(5);
offsets[0] = 0;
offsets[1] = p_fes->GetVSize();
offsets[2] = u_fes->GetVSize();
offsets[3] = hatp_fes->GetVSize();
offsets[4] = hatu_fes->GetVSize();
offsets.PartialSum();
BlockVector x(offsets);
x = 0.0;
hatp_gf.MakeRef(hatp_fes,x.GetBlock(2));
hatp_gf.ProjectBdrCoefficient(hatpex,ess_bdr);
Vector X,B;
OperatorPtr Ah;
a->FormLinearSystem(ess_tdof_list,x,Ah,X,B);
BlockOperator * A = Ah.As<BlockOperator>();
BlockDiagonalPreconditioner * M = new BlockDiagonalPreconditioner(A->RowOffsets());
M->owns_blocks = 1;
HypreBoomerAMG * amg0 = new HypreBoomerAMG((HypreParMatrix &)A->GetBlock(0,0));
HypreBoomerAMG * amg1 = new HypreBoomerAMG((HypreParMatrix &)A->GetBlock(1,1));
HypreBoomerAMG * amg2 = new HypreBoomerAMG((HypreParMatrix &)A->GetBlock(2,2));
amg0->SetPrintLevel(0);
amg1->SetPrintLevel(0);
amg2->SetPrintLevel(0);
amg0->SetRelaxType(16);
amg1->SetRelaxType(16);
amg2->SetRelaxType(16);
M->SetDiagonalBlock(0,amg0);
M->SetDiagonalBlock(1,amg1);
M->SetDiagonalBlock(2,amg2);
// for (int i = 0; i < 3; i++)
// {
// MUMPSSolver * mumps = new MUMPSSolver;
// mumps->SetOperator(A->GetBlock(i,i));
// M->SetDiagonalBlock(i,mumps);
// }
HypreSolver * prec;
if (dim == 2)
{
prec = new HypreAMS((HypreParMatrix &)A->GetBlock(3,3), hatu_fes);
}
else
{
prec = new HypreADS((HypreParMatrix &)A->GetBlock(3,3), hatu_fes);
}
M->SetDiagonalBlock(3,prec);
CGSolver cg(MPI_COMM_WORLD);
cg.SetRelTol(1e-10);
cg.SetMaxIter(20000);
cg.SetPrintLevel(-1);
cg.SetPreconditioner(*M);
cg.SetOperator(*A);
cg.Mult(B, X);
delete M;
a->RecoverFEMSolution(X,x);
Vector & residuals = a->ComputeResidual(x);
double residual = residuals.Norml2();
double maxresidual = residuals.Max();
double globalresidual = residual * residual;
MPI_Allreduce(MPI_IN_PLACE,&maxresidual,1,MPI_DOUBLE,MPI_MAX,MPI_COMM_WORLD);
MPI_Allreduce(MPI_IN_PLACE,&globalresidual,1,MPI_DOUBLE,MPI_SUM,MPI_COMM_WORLD);
globalresidual = sqrt(globalresidual);
elements_to_refine.SetSize(0);
for (int iel = 0; iel<pmesh.GetNE(); iel++)
{
if (residuals[iel] > theta * maxresidual)
{
elements_to_refine.Append(iel);
}
}
ParGridFunction p_gf;
p_gf.MakeRef(p_fes,x.GetBlock(0));
ParGridFunction u_gf;
u_gf.MakeRef(u_fes,x.GetBlock(1));
ParGridFunction pex_gf(p_fes);
ParGridFunction uex_gf(u_fes);
pex_gf.ProjectCoefficient(pex);
uex_gf.ProjectCoefficient(uex);
int dofs = p_fes->GlobalTrueVSize()
+ u_fes->GlobalTrueVSize()
+ hatp_fes->GlobalTrueVSize()
+ hatu_fes->GlobalTrueVSize();
double p_err = p_gf.ComputeL2Error(pex);
double p_norm = pex_gf.ComputeL2Error(zero);
double u_err = u_gf.ComputeL2Error(uex);
double u_norm = uex_gf.ComputeL2Error(vzero);
double L2Error = sqrt(p_err*p_err + u_err*u_err);
double L2norm = sqrt(p_norm * p_norm + u_norm * u_norm);
double rel_error = L2Error/L2norm;
double rate_err = (i) ? dim*log(err0/L2Error)/log((double)dof0/dofs) : 0.0;
double rate_res = (i) ? dim*log(res0/globalresidual)/log((double)dof0/dofs) : 0.0;
err0 = L2Error;
res0 = globalresidual;
dof0 = dofs;
std::ios oldState(nullptr);
if (myid == 0)
{
mfem::out << std::right << std::setw(11) << i << " | "
<< std::setw(10) << dof0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << err0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::fixed << rel_error * 100. << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_err << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << res0 << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_res << " | "
<< std::setprecision(5)
<< std::scientific
<< std::endl;
}
if (visualization)
{
p_out << "parallel " << num_procs << " " << myid << "\n";
p_out.precision(8);
p_out << "solution\n" << pmesh << p_gf <<
"window_title 'Numerical pressure' "
<< flush;
}
if (i == ref)
break;
pmesh.GeneralRefinement(elements_to_refine,1,1);
for (int i =0; i<trial_fes.Size(); i++)
{
trial_fes[i]->Update(false);
}
a->Update();
}
delete a;
delete q_fec;
delete v_fec;
delete hatp_fes;
delete hatp_fec;
delete hatu_fes;
delete hatu_fec;
delete u_fec;
delete p_fec;
delete u_fes;
delete p_fes;
return 0;
}
double rhs_func(const Vector &x)
{
double p = p_exact(x);
double divu = divu_exact(x);
// f = - ∇⋅u ± ω p,
#ifdef DEFINITE
return -divu + omega * p;
#else
return -divu - omega * p;
#endif
}
double p_exact(const Vector &x)
{
return sin(omega*x.Sum());
}
void gradp_exact(const Vector &x, Vector &grad)
{
grad.SetSize(x.Size());
grad = omega * cos(omega * x.Sum());
}
void u_exact(const Vector &x, Vector & u)
{
gradp_exact(x,u);
u *= 1./omega;
}
double divu_exact(const Vector &x)
{
return d2_exact(x)/omega;
}
double d2_exact(const Vector &x)
{
return -dim * omega * omega * sin(omega*x.Sum());
}
double hatp_exact(const Vector & X)
{
return p_exact(X);
}
void hatu_exact(const Vector & X, Vector & hatu)
{
u_exact(X,hatu);
hatu *= -1.;
}
@@ -0,0 +1,59 @@
# Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced
# at the Lawrence Livermore National Laboratory. All Rights reserved. See files
# LICENSE and NOTICE for details. LLNL-CODE-806117.
#
# This file is part of the MFEM library. For more information and source code
# availability visit https://mfem.org.
#
# MFEM is free software; you can redistribute it and/or modify it under the
# terms of the BSD-3 license. We welcome feedback and contributions, see file
# CONTRIBUTING.md for details.
# Use the MFEM build directory
MFEM_DIR ?= ../../..
MFEM_BUILD_DIR ?= ../../..
SRC = $(if $(MFEM_DIR:../../..=),$(MFEM_DIR)/examples/dpg_tests/convection-diffusion,)
CONFIG_MK = $(MFEM_BUILD_DIR)/config/config.mk
MFEM_LIB_FILE = mfem_is_not_built
-include $(CONFIG_MK)
SEQ_EXAMPLES = uw_dpg
PAR_EXAMPLES = uw_dpgp
ifeq ($(MFEM_USE_MPI),NO)
EXAMPLES = $(SEQ_EXAMPLES)
else
EXAMPLES = $(PAR_EXAMPLES) $(SEQ_EXAMPLES)
endif
.SUFFIXES:
.SUFFIXES: .o .cpp .mk
.PHONY: all clean clean-build clean-exec
# Remove built-in rule
%: %.cpp
# Replace the default implicit rule for *.cpp files
%: $(SRC)%.cpp $(MFEM_LIB_FILE) $(CONFIG_MK)
$(MFEM_CXX) $(MFEM_FLAGS) $< -o $@ $(MFEM_LIBS)
all: $(EXAMPLES)
MFEM_TESTS = EXAMPLES
include $(MFEM_TEST_MK)
# Testing: Parallel vs. serial runs
RUN_MPI = $(MFEM_MPIEXEC) $(MFEM_MPIEXEC_NP) $(MFEM_MPI_NP)
%-test-par: %
@$(call mfem-test,$<, $(RUN_MPI), Parallel example)
%-test-seq: %
@$(call mfem-test,$<,, Serial example)
clean: clean-build clean-exec
clean-build:
rm -f *.o *~ $(SEQ_EXAMPLES) $(PAR_EXAMPLES)
rm -rf *.dSYM *.TVD.*breakpoints
clean-exec:
@@ -0,0 +1,649 @@
// MFEM Ultraweak DPG example
//
// Compile with: make uw_dpg
//
// sample runs
// ./uw_dpg -m ../../../data/inline-quad.mesh -o 3 -ref 10 -test-norm 2 -do 1 -prob 1 -eps 1e-4
// - εΔu + ∇⋅(βu) = f, in Ω
// u = u_0, on ∂Ω
// First Order System
// - ∇⋅σ + ∇⋅(βu) = f, in Ω
// 1/ε σ - ∇u = 0, in Ω
// u = u_0, on ∂Ω
// UW-DPG:
//
// u ∈ L^2(Ω), σ ∈ (L^2(Ω))^dim
// û ∈ H^1/2, σ̂ ∈ H^-1/2
// -(βu , ∇v) + (σ , ∇v) + < f̂ , v > = (f,v), ∀ v ∈ H^1(Ω)
// (u , ∇⋅τ) + 1/ε (σ , τ) + < û , τ⋅n > = 0, ∀ τ ∈ H(div,Ω)
// û = u_0 on ∂Ω
// Note:
// f̂ := βu - σ
// û := -u
// -------------------------------------------------------------
// | | u | σ | û | f̂ | RHS |
// -------------------------------------------------------------
// | v |-(βu , ∇v) | (σ , ∇v) | | < f̂ ,v > | (f,v) |
// | | | | | | |
// | τ | (u ,∇⋅τ) | 1/ε(σ , τ)| <û,τ⋅n> | | 0 |
// where (v,τ) ∈ H^1(Ω_h) × H(div,Ω_h)
#include "mfem.hpp"
#include <fstream>
#include <iostream>
using namespace std;
using namespace mfem;
enum prob_type
{
polynomial,
EJ,
general
};
enum test_norm_type
{
standard,
adjoint_graph,
robust
};
prob_type prob;
test_norm_type test_norm;
Vector beta;
double epsilon;
// Function returns the solution u, and gradient du and the Laplacian d2u
void solution(const Vector & x, double & u, Vector & du, double & d2u);
double exact_u(const Vector & X);
void exact_sigma(const Vector & X, Vector & sigma);
double exact_hatu(const Vector & X);
void exact_hatf(const Vector & X, Vector & hatf);
double f_exact(const Vector & X);
int main(int argc, char *argv[])
{
// 1. Parse command-line options.
const char *mesh_file = "../../../data/inline-quad.mesh";
int order = 1;
int delta_order = 1;
int ref = 1;
bool visualization = true;
int iprob = 0;
int itest_norm = 0;
double theta = 0.7;
epsilon = 1e0;
OptionsParser args(argc, argv);
args.AddOption(&mesh_file, "-m", "--mesh",
"Mesh file to use.");
args.AddOption(&order, "-o", "--order",
"Finite element order (polynomial degree).");
args.AddOption(&delta_order, "-do", "--delta_order",
"Order enrichment for DPG test space.");
args.AddOption(&epsilon, "-eps", "--epsilon",
"Epsilon coefficient");
args.AddOption(&ref, "-ref", "--num_refinements",
"Number of uniform refinements");
args.AddOption(&theta, "-theta", "--theta",
"Theta parameter for AMR");
args.AddOption(&iprob, "-prob", "--problem", "Problem case"
" 0: polynomial, 1: EJ ,2: General");
args.AddOption(&itest_norm, "-test-norm", "--test-norm", "Choice of test norm"
" 0: Standard, 1: Adjoint Graph, 2: Robust");
args.AddOption(&beta, "-beta", "--beta",
"Vector Coefficient beta");
args.AddOption(&visualization, "-vis", "--visualization", "-no-vis",
"--no-visualization",
"Enable or disable GLVis visualization.");
args.Parse();
if (!args.Good())
{
args.PrintUsage(cout);
return 1;
}
args.PrintOptions(cout);
if (iprob > 2) { iprob = 2; }
prob = (prob_type)iprob;
test_norm = (test_norm_type)itest_norm;
if (prob == prob_type::EJ)
{
mesh_file = "../../../data/inline-quad.mesh";
}
Mesh mesh(mesh_file, 1, 1);
int dim = mesh.Dimension();
if (beta.Size() == 0)
{
beta.SetSize(dim);
beta[0] = 1.;
beta[1] = 0.;
}
// Define spaces
// L2 space for u
FiniteElementCollection *u_fec = new L2_FECollection(order-1,dim);
FiniteElementSpace *u_fes = new FiniteElementSpace(&mesh,u_fec);
// Vector L2 space for σ
FiniteElementCollection *sigma_fec = new L2_FECollection(order-1,dim);
FiniteElementSpace *sigma_fes = new FiniteElementSpace(&mesh,sigma_fec, dim);
// H^1/2 space for û
FiniteElementCollection * hatu_fec = new H1_Trace_FECollection(order,dim);
FiniteElementSpace *hatu_fes = new FiniteElementSpace(&mesh,hatu_fec);
// H^-1/2 space for σ̂
FiniteElementCollection * hatf_fec = new RT_Trace_FECollection(order-1,dim);
FiniteElementSpace *hatf_fes = new FiniteElementSpace(&mesh,hatf_fec);
// testspace fe collections
int test_order = order+delta_order;
FiniteElementCollection * v_fec = new H1_FECollection(test_order, dim);
FiniteElementCollection * tau_fec = new RT_FECollection(test_order-1, dim);
// Coefficients
ConstantCoefficient one(1.0);
ConstantCoefficient negone(-1.0);
ConstantCoefficient eps(epsilon);
ConstantCoefficient eps1(1./epsilon);
ConstantCoefficient negeps1(-1./epsilon);
ConstantCoefficient eps2(1/(epsilon*epsilon));
ConstantCoefficient negeps(-epsilon);
VectorConstantCoefficient betacoeff(beta);
Vector negbeta = beta;
negbeta.Neg();
ConstantCoefficient zero(0.0);
Vector vec0(dim); vec0 = 0.;
VectorConstantCoefficient vzero(vec0);
DenseMatrix bbt(beta.Size());
MultVVt(beta, bbt);
MatrixConstantCoefficient bbtcoeff(bbt);
VectorConstantCoefficient negbetacoeff(negbeta);
// Normal equation weak formulation
Array<FiniteElementSpace * > trial_fes;
Array<FiniteElementCollection * > test_fec;
trial_fes.Append(u_fes);
trial_fes.Append(sigma_fes);
trial_fes.Append(hatu_fes);
trial_fes.Append(hatf_fes);
test_fec.Append(v_fec);
test_fec.Append(tau_fec);
FiniteElementCollection *coeff_fec = new L2_FECollection(0,dim);
FiniteElementSpace *coeff_fes = new FiniteElementSpace(&mesh,coeff_fec);
GridFunction c1_gf, c2_gf;
GridFunctionCoefficient c1_coeff(&c1_gf);
GridFunctionCoefficient c2_coeff(&c2_gf);
NormalEquations * a = new NormalEquations(trial_fes,test_fec);
a->StoreMatrices(true);
//-(βu , ∇v)
a->AddTrialIntegrator(new MixedScalarWeakDivergenceIntegrator(betacoeff),0,0);
// (σ,∇ v)
a->AddTrialIntegrator(new TransposeIntegrator(new GradientIntegrator(one)),1,0);
// (u ,∇⋅τ)
a->AddTrialIntegrator(new MixedScalarWeakGradientIntegrator(negone),0,1);
// 1/ε (σ,τ)
a->AddTrialIntegrator(new TransposeIntegrator(new VectorFEMassIntegrator(eps1)),1,1);
// <û,τ⋅n>
a->AddTrialIntegrator(new NormalTraceIntegrator,2,1);
// <f̂ ,v>
a->AddTrialIntegrator(new TraceIntegrator,3,0);
switch (test_norm)
{
case standard:
{
// (∇v,∇δv)
mfem::out << "\n Test norm: Standard" << endl;
a->AddTestIntegrator(new DiffusionIntegrator(one),0,0);
// (v,δv)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
// (∇⋅τ,∇⋅δτ)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
// (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(one),1,1);
}
break;
case adjoint_graph:
{
mfem::out << "\n Test norm: Adjoint Graph" << endl;
// (∇v,∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(one),0,0);
// (β⋅∇v, β⋅∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(bbtcoeff), 0,0);
// (v,δv)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
// (∇⋅τ,∇⋅δτ)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
// (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(one),1,1);
// 1/ε^2 (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(eps2),1,1);
// 1/ε (∇v, δτ)
a->AddTestIntegrator(new MixedVectorGradientIntegrator(eps1),0,1);
// - (β ⋅ ∇v,∇⋅δτ)
a->AddTestIntegrator(new MixedGradDivIntegrator(betacoeff),0,1);
// 1/ε (τ,∇δv)
a->AddTestIntegrator(new MixedVectorWeakDivergenceIntegrator(negeps1),1,0);
// -(β ∇⋅τ ,∇⋅δv)
a->AddTestIntegrator(new MixedDivGradIntegrator(betacoeff),1,0);
}
break;
default:
{
mfem::out << "\n Test norm: Robust" << endl;
c1_gf.SetSpace(coeff_fes);
c2_gf.SetSpace(coeff_fes);
Array<int> dofs;
for (int i =0; i < mesh.GetNE(); i++)
{
double volume = mesh.GetElementVolume(i);
double c1 = min(epsilon/volume, 1.);
double c2 = min(1./epsilon, 1./volume);
// double c2 = 1.;
coeff_fes->GetElementDofs(i,dofs);
c1_gf.SetSubVector(dofs,c1);
c2_gf.SetSubVector(dofs,c2);
}
// c1 (v,δv)
a->AddTestIntegrator(new MassIntegrator(c1_coeff),0,0);
// ε (∇v,∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(eps),0,0);
// (β⋅∇v, β⋅∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(bbtcoeff), 0,0);
// c2 (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(c2_coeff),1,1);
// (∇⋅τ,∇⋅δτ)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
}
break;
}
FunctionCoefficient f(f_exact);
// if (prob != prob_type::EJ)
// {
a->AddDomainLFIntegrator(new DomainLFIntegrator(f),0);
// }
FunctionCoefficient hatuex(exact_hatu);
VectorFunctionCoefficient hatfex(dim,exact_hatf);
Array<int> elements_to_refine;
FunctionCoefficient uex(exact_u);
VectorFunctionCoefficient sigmaex(dim,exact_sigma);
GridFunction hatu_gf;
GridFunction hatf_gf;
// socketstream uex_out;
socketstream u_out;
// socketstream sigma_out;
if (visualization)
{
char vishost[] = "localhost";
int visport = 19916;
u_out.open(vishost, visport);
// uex_out.open(vishost, visport);
// sigma_out.open(vishost, visport);
}
double res0 = 0.;
double err0 = 0.;
int dof0;
mfem::out << " Refinement |"
<< " Dofs |"
<< " L2 Error |"
<< " Relative % |"
<< " Rate |"
<< " Residual |"
<< " Rate |" << endl;
mfem::out << " --------------------"
<< "-------------------"
<< "-------------------"
<< "-------------------" << endl;
for (int i = 0; i<=ref; i++)
{
a->Assemble();
Array<int> ess_tdof_list_uhat;
Array<int> ess_tdof_list_fhat;
Array<int> ess_bdr_uhat;
Array<int> ess_bdr_fhat;
if (mesh.bdr_attributes.Size())
{
ess_bdr_uhat.SetSize(mesh.bdr_attributes.Max());
ess_bdr_fhat.SetSize(mesh.bdr_attributes.Max());
// ess_bdr_uhat = 1;
// ess_bdr_fhat = 0;
ess_bdr_uhat = 0;
ess_bdr_fhat = 1;
ess_bdr_uhat[1] = 1;
ess_bdr_fhat[1] = 0;
hatu_fes->GetEssentialTrueDofs(ess_bdr_uhat, ess_tdof_list_uhat);
hatf_fes->GetEssentialTrueDofs(ess_bdr_fhat, ess_tdof_list_fhat);
}
// shift the ess_tdofs
int n = ess_tdof_list_uhat.Size();
int m = ess_tdof_list_fhat.Size();
Array<int> ess_tdof_list(n+m);
for (int i = 0; i < n; i++)
{
ess_tdof_list[i] = ess_tdof_list_uhat[i]
+ u_fes->GetTrueVSize()
+ sigma_fes->GetTrueVSize();
}
for (int i = 0; i < m; i++)
{
ess_tdof_list[i+n] = ess_tdof_list_fhat[i]
+ u_fes->GetTrueVSize()
+ sigma_fes->GetTrueVSize()
+ hatu_fes->GetTrueVSize();
}
Array<int> offsets(5);
offsets[0] = 0;
offsets[1] = u_fes->GetVSize();
offsets[2] = sigma_fes->GetVSize();
offsets[3] = hatu_fes->GetVSize();
offsets[4] = hatf_fes->GetVSize();
offsets.PartialSum();
BlockVector x(offsets);
x = 0.0;
hatu_gf.MakeRef(hatu_fes,x.GetBlock(2));
hatf_gf.MakeRef(hatf_fes,x.GetBlock(3));
hatu_gf.ProjectBdrCoefficient(hatuex,ess_bdr_uhat);
hatf_gf.ProjectBdrCoefficientNormal(hatfex,ess_bdr_fhat);
OperatorPtr Ah;
Vector X,B;
a->FormLinearSystem(ess_tdof_list,x,Ah,X,B);
BlockMatrix * A = Ah.As<BlockMatrix>();
BlockDiagonalPreconditioner * M = new BlockDiagonalPreconditioner(A->RowOffsets());
M->owns_blocks = 1;
for (int i=0; i<A->NumRowBlocks(); i++)
{
M->SetDiagonalBlock(i,new UMFPackSolver(A->GetBlock(i,i)));
}
CGSolver cg;
cg.SetRelTol(1e-12);
cg.SetMaxIter(200000);
cg.SetPrintLevel(0);
cg.SetPreconditioner(*M);
cg.SetOperator(*A);
cg.Mult(B, X);
delete M;
a->RecoverFEMSolution(X,x);
Vector & residuals = a->ComputeResidual(x);
double residual = residuals.Norml2();
elements_to_refine.SetSize(0);
double max_resid = residuals.Max();
for (int iel = 0; iel<mesh.GetNE(); iel++)
{
if (residuals[iel] > theta * max_resid)
{
elements_to_refine.Append(iel);
}
}
GridFunction uex_gf(u_fes);
uex_gf.ProjectCoefficient(uex);
GridFunction sigmaex_gf(sigma_fes);
sigmaex_gf.ProjectCoefficient(sigmaex);
GridFunction u_gf;
u_gf.MakeRef(u_fes,x.GetBlock(0));
GridFunction sigma_gf;
sigma_gf.MakeRef(sigma_fes,x.GetBlock(1));
int dofs = X.Size();
double u_err = u_gf.ComputeL2Error(uex);
double u_norm = uex_gf.ComputeL2Error(zero);
// mfem::out << "u_err = " << u_err << endl;
double sigma_err = sigma_gf.ComputeL2Error(sigmaex);
double sigma_norm = sigmaex_gf.ComputeL2Error(vzero);
// mfem::out << "sigma_err = " << sigma_err << endl;
double L2Error = sqrt(u_err*u_err + sigma_err*sigma_err);
double L2norm = sqrt(u_norm * u_norm + sigma_norm * sigma_norm);
double rel_error = L2Error/L2norm;
double rate_err = (i) ? dim*log(err0/L2Error)/log((double)dof0/dofs) : 0.0;
double rate_res = (i) ? dim*log(res0/residual)/log((double)dof0/dofs) : 0.0;
err0 = L2Error;
res0 = residual;
dof0 = dofs;
mfem::out << std::right << std::setw(11) << i << " | "
<< std::setw(10) << dof0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << err0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::fixed << rel_error * 100. << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_err << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << res0 << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_res << " | "
<< std::resetiosflags(std::ios::showbase)
<< std::endl;
if (visualization)
{
// uex_out.precision(8);
// uex_out << "solution\n" << mesh << uex_gf <<
// "window_title 'Exact u' "
// << flush;
u_out.precision(8);
u_out << "solution\n" << mesh << u_gf <<
"window_title 'Numerical u' "
<< flush;
// sigma_out.precision(8);
// sigma_out << "solution\n" << mesh << sigma_gf <<
// "window_title 'Numerical flux' "
// << flush;
}
if (i == ref)
break;
mesh.GeneralRefinement(elements_to_refine,1,1);
for (int i =0; i<trial_fes.Size(); i++)
{
trial_fes[i]->Update(false);
}
a->Update();
if (test_norm == test_norm_type::robust)
{
coeff_fes->Update();
c1_gf.Update();
c2_gf.Update();
Array<int> dofs;
for (int i = 0; i < mesh.GetNE(); i++)
{
double volume = mesh.GetElementVolume(i);
double c1 = min(epsilon/volume, 1.);
double c2 = min(1./epsilon, 1./volume);
// double c2 = 1.;
coeff_fes->GetElementDofs(i,dofs);
c1_gf.SetSubVector(dofs,c1);
c2_gf.SetSubVector(dofs,c2);
}
}
}
delete a;
delete tau_fec;
delete v_fec;
delete hatf_fes;
delete hatf_fec;
delete hatu_fes;
delete hatu_fec;
delete sigma_fec;
delete u_fec;
delete u_fes;
return 0;
}
void solution(const Vector & X, double & u, Vector & du, double & d2u)
{
double x = X[0];
double y = X[1];
double z = 0.;
if (X.Size() == 3) z = X[2];
du.SetSize(X.Size());
du = 0.;
d2u = 0.;
switch(prob)
{
case polynomial:
{
int n=2;
int m=2;
u = pow(x,n)*pow(y,m);
du[0] = n * pow(x,n-1) * pow(y,m);
du[1] = m * pow(x,n) * pow(y,m-1);
d2u = n * (n-1) * pow(x,n-2) * pow(y,m)
+ m * (m-1) * pow(x,n) * pow(y,m-2);
}
break;
case EJ:
{
double alpha = sqrt(1. + 4. * epsilon * epsilon * M_PI * M_PI);
double r1 = (1. + alpha) / (2.*epsilon);
double r2 = (1. - alpha) / (2.*epsilon);
double denom = exp(-r2) - exp(-r1);
double g1 = exp(r2*(x-1.));
double g1_x = r2*g1;
double g1_xx = r2*g1_x;
double g2 = exp(r1*(x-1.));
double g2_x = r1*g2;
double g2_xx = r1*g2_x;
double g = g1-g2;
double g_x = g1_x - g2_x;
double g_xx = g1_xx - g2_xx;
u = g * cos(M_PI * y)/denom;
double u_x = g_x * cos(M_PI * y)/denom;
double u_xx = g_xx * cos(M_PI * y)/denom;
double u_y = -M_PI * g * sin(M_PI*y)/denom;
double u_yy = -M_PI * M_PI * u;
du[0] = u_x;
du[1] = u_y;
d2u = u_xx + u_yy;
}
break;
default:
{
double alpha = M_PI * (x + y + z);
u = sin(alpha);
du.SetSize(X.Size());
for (int i = 0; i<du.Size(); i++)
{
du[i] = M_PI * cos(alpha);
}
d2u = - M_PI*M_PI * u * du.Size();
}
break;
}
}
double exact_u(const Vector & X)
{
double u, d2u;
Vector du;
solution(X,u,du,d2u);
return u;
}
void exact_sigma(const Vector & X, Vector & sigma)
{
double u, d2u;
Vector du;
solution(X,u,du,d2u);
// σ = ε ∇ u
sigma = du;
sigma *= epsilon;
}
double exact_hatu(const Vector & X)
{
return -exact_u(X);
}
void exact_hatf(const Vector & X, Vector & hatf)
{
Vector sigma;
exact_sigma(X,sigma);
double u = exact_u(X);
hatf.SetSize(X.Size());
for (int i = 0; i<hatf.Size(); i++)
{
hatf[i] = beta[i] * u - sigma[i];
}
}
double f_exact(const Vector & X)
{
// f = - εΔu + ∇⋅(βu)
double u, d2u;
Vector du;
solution(X,u,du,d2u);
double s = 0;
for (int i = 0; i<du.Size(); i++)
{
s += beta[i] * du[i];
}
return -epsilon * d2u + s;
}
@@ -0,0 +1,698 @@
// MFEM Ultraweak DPG example
//
// Compile with: make uw_dpgp
//
// sample runs
// mpirun -np 6 ./uw_dpgp -m ../../../data/inline-quad.mesh -o 3 -ref 10 -test-norm 2 -do 1 -prob 1 -eps 1e-4
// - εΔu + ∇⋅(βu) = f, in Ω
// u = u_0, on ∂Ω
// First Order System
// - ∇⋅σ + ∇⋅(βu) = f, in Ω
// 1/ε σ - ∇u = 0, in Ω
// u = u_0, on ∂Ω
// UW-DPG:
//
// u ∈ L^2(Ω), σ ∈ (L^2(Ω))^dim
// û ∈ H^1/2, f̂ ∈ H^-1/2
// -(βu , ∇v) + (σ , ∇v) + < f̂ , v > = (f,v), ∀ v ∈ H^1(Ω)
// (u , ∇⋅τ) + 1/ε (σ , τ) + < û , τ⋅n > = 0, ∀ τ ∈ H(div,Ω)
// û = u_0 on ∂Ω
// Note:
// f̂ := βu - σ
// û := -u
// -------------------------------------------------------------
// | | u | σ | û | f̂ | RHS |
// -------------------------------------------------------------
// | v |-(βu , ∇v) | (σ , ∇v) | | < f̂ ,v > | (f,v) |
// | | | | | | |
// | τ | (u ,∇⋅τ) | 1/ε(σ , τ)| <û,τ⋅n> | | 0 |
// where (v,τ) ∈ H^1(Ω_h) × H(div,Ω_h)
#include "mfem.hpp"
#include <fstream>
#include <iostream>
using namespace std;
using namespace mfem;
enum prob_type
{
polynomial,
EJ,
general
};
enum test_norm_type
{
standard,
adjoint_graph,
robust
};
prob_type prob;
test_norm_type test_norm;
Vector beta;
double epsilon;
// Function returns the solution u, and gradient du and the Laplacian d2u
void solution(const Vector & x, double & u, Vector & du, double & d2u);
double exact_u(const Vector & X);
void exact_sigma(const Vector & X, Vector & sigma);
double exact_hatu(const Vector & X);
void exact_hatf(const Vector & X, Vector & hatf);
double f_exact(const Vector & X);
int main(int argc, char *argv[])
{
MPI_Session mpi;
int num_procs = mpi.WorldSize();
int myid = mpi.WorldRank();
// 1. Parse command-line options.
const char *mesh_file = "../../../data/inline-quad.mesh";
int order = 1;
int delta_order = 1;
int ref = 1;
bool visualization = true;
int iprob = 0;
int itest_norm = 0;
double theta = 0.7;
bool static_cond = false;
epsilon = 1e0;
OptionsParser args(argc, argv);
args.AddOption(&mesh_file, "-m", "--mesh",
"Mesh file to use.");
args.AddOption(&order, "-o", "--order",
"Finite element order (polynomial degree).");
args.AddOption(&delta_order, "-do", "--delta_order",
"Order enrichment for DPG test space.");
args.AddOption(&epsilon, "-eps", "--epsilon",
"Epsilon coefficient");
args.AddOption(&ref, "-ref", "--num_refinements",
"Number of uniform refinements");
args.AddOption(&theta, "-theta", "--theta",
"Theta parameter for AMR");
args.AddOption(&iprob, "-prob", "--problem", "Problem case"
" 0: lshape, 1: General");
args.AddOption(&itest_norm, "-test-norm", "--test-norm", "Choice of test norm"
" 0: Standard, 1: Adjoint Graph, 2: Robust");
args.AddOption(&beta, "-beta", "--beta",
"Vector Coefficient beta");
args.AddOption(&static_cond, "-sc", "--static-condensation", "-no-sc",
"--no-static-condensation", "Enable static condensation.");
args.AddOption(&visualization, "-vis", "--visualization", "-no-vis",
"--no-visualization",
"Enable or disable GLVis visualization.");
args.Parse();
if (!args.Good())
{
if (myid == 0)
{
args.PrintUsage(cout);
}
return 1;
}
if (myid == 0)
{
args.PrintOptions(cout);
}
if (iprob > 2) { iprob = 2; }
prob = (prob_type)iprob;
test_norm = (test_norm_type)itest_norm;
if (prob == prob_type::EJ)
{
mesh_file = "../../../data/inline-quad.mesh";
}
Mesh mesh(mesh_file, 1, 1);
int dim = mesh.Dimension();
if (beta.Size() == 0)
{
beta.SetSize(dim);
beta[0] = 1.;
beta[1] = 0.;
}
mesh.EnsureNCMesh();
ParMesh pmesh(MPI_COMM_WORLD, mesh);
mesh.Clear();
// Define spaces
// L2 space for u
FiniteElementCollection *u_fec = new L2_FECollection(order-1,dim);
ParFiniteElementSpace *u_fes = new ParFiniteElementSpace(&pmesh,u_fec);
// Vector L2 space for σ
FiniteElementCollection *sigma_fec = new L2_FECollection(order-1,dim);
ParFiniteElementSpace *sigma_fes = new ParFiniteElementSpace(&pmesh,sigma_fec, dim);
// H^1/2 space for û
FiniteElementCollection * hatu_fec = new H1_Trace_FECollection(order,dim);
ParFiniteElementSpace *hatu_fes = new ParFiniteElementSpace(&pmesh,hatu_fec);
// H^-1/2 space for σ̂
FiniteElementCollection * hatf_fec = new RT_Trace_FECollection(order-1,dim);
ParFiniteElementSpace *hatf_fes = new ParFiniteElementSpace(&pmesh,hatf_fec);
// testspace fe collections
int test_order = order+delta_order;
FiniteElementCollection * v_fec = new H1_FECollection(test_order, dim);
FiniteElementCollection * tau_fec = new RT_FECollection(test_order-1, dim);
// Coefficients
ConstantCoefficient one(1.0);
ConstantCoefficient negone(-1.0);
ConstantCoefficient eps(epsilon);
ConstantCoefficient eps1(1./epsilon);
ConstantCoefficient negeps1(-1./epsilon);
ConstantCoefficient eps2(1/(epsilon*epsilon));
ConstantCoefficient negeps(-epsilon);
VectorConstantCoefficient betacoeff(beta);
Vector negbeta = beta;
negbeta.Neg();
DenseMatrix bbt(beta.Size());
MultVVt(beta, bbt);
MatrixConstantCoefficient bbtcoeff(bbt);
VectorConstantCoefficient negbetacoeff(negbeta);
// Normal equation weak formulation
Array<ParFiniteElementSpace * > trial_fes;
Array<FiniteElementCollection * > test_fec;
trial_fes.Append(u_fes);
trial_fes.Append(sigma_fes);
trial_fes.Append(hatu_fes);
trial_fes.Append(hatf_fes);
test_fec.Append(v_fec);
test_fec.Append(tau_fec);
ParNormalEquations * a = new ParNormalEquations(trial_fes,test_fec);
a->StoreMatrices(true);
//-(βu , ∇v)
a->AddTrialIntegrator(new MixedScalarWeakDivergenceIntegrator(betacoeff),0,0);
// (σ,∇ v)
a->AddTrialIntegrator(new TransposeIntegrator(new GradientIntegrator(one)),1,0);
// (u ,∇⋅τ)
a->AddTrialIntegrator(new MixedScalarWeakGradientIntegrator(negone),0,1);
// 1/ε (σ,τ)
a->AddTrialIntegrator(new TransposeIntegrator(new VectorFEMassIntegrator(eps1)),1,1);
// <û,τ⋅n>
a->AddTrialIntegrator(new NormalTraceIntegrator,2,1);
// <f̂ ,v>
a->AddTrialIntegrator(new TraceIntegrator,3,0);
FiniteElementCollection *coeff_fec = new L2_FECollection(0,dim);
ParFiniteElementSpace *coeff_fes = new ParFiniteElementSpace(&pmesh,coeff_fec);
ParGridFunction c1_gf, c2_gf;
GridFunctionCoefficient c1_coeff(&c1_gf);
GridFunctionCoefficient c2_coeff(&c2_gf);
switch (test_norm)
{
case standard:
{
if (myid == 0)
{
mfem::out << "\n Test norm: Standard" << endl;
}
// (∇v,∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(one),0,0);
// (v,δv)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
// (∇⋅τ,∇⋅δτ)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
// (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(one),1,1);
}
break;
case adjoint_graph:
{
if (myid == 0)
{
mfem::out << "\n Test norm: Adjoint Graph" << endl;
}
// (∇v,∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(one),0,0);
// (β⋅∇v, β⋅∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(bbtcoeff), 0,0);
// (v,δv)
a->AddTestIntegrator(new MassIntegrator(one),0,0);
// (∇⋅τ,∇⋅δτ)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
// (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(one),1,1);
// 1/ε^2 (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(eps2),1,1);
// 1/ε (∇v, δτ)
a->AddTestIntegrator(new MixedVectorGradientIntegrator(eps1),0,1);
// - (β ⋅ ∇v,∇⋅δτ)
a->AddTestIntegrator(new MixedGradDivIntegrator(betacoeff),0,1);
// 1/ε (τ,∇δv)
a->AddTestIntegrator(new MixedVectorWeakDivergenceIntegrator(negeps1),1,0);
// -(β ∇⋅τ ,∇⋅δv)
a->AddTestIntegrator(new MixedDivGradIntegrator(betacoeff),1,0);
}
break;
default:
{
if (myid == 0)
{
mfem::out << "\n Test norm: Robust" << endl;
}
c1_gf.SetSpace(coeff_fes);
c2_gf.SetSpace(coeff_fes);
Array<int> dofs;
for (int i =0; i < pmesh.GetNE(); i++)
{
double volume = pmesh.GetElementVolume(i);
double c1 = min(epsilon/volume, 1.);
double c2 = min(1./epsilon, 1./volume);
coeff_fes->GetElementDofs(i,dofs);
c1_gf.SetSubVector(dofs,c1);
c2_gf.SetSubVector(dofs,c2);
}
// c1 (v,δv)
a->AddTestIntegrator(new MassIntegrator(c1_coeff),0,0);
// ε (∇v,∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(eps),0,0);
// (β⋅∇v, β⋅∇δv)
a->AddTestIntegrator(new DiffusionIntegrator(bbtcoeff), 0,0);
// c2 (τ,δτ)
a->AddTestIntegrator(new VectorFEMassIntegrator(c2_coeff),1,1);
// (∇⋅τ,∇⋅δτ)
a->AddTestIntegrator(new DivDivIntegrator(one),1,1);
}
break;
}
FunctionCoefficient f(f_exact);
// if (prob != prob_type::EJ)
// {
a->AddDomainLFIntegrator(new DomainLFIntegrator(f),0);
// }
FunctionCoefficient hatuex(exact_hatu);
VectorFunctionCoefficient hatfex(dim,exact_hatf);
Array<int> elements_to_refine;
FunctionCoefficient uex(exact_u);
VectorFunctionCoefficient sigmaex(dim,exact_sigma);
ParGridFunction hatu_gf;
ParGridFunction hatf_gf;
// socketstream uex_out;
socketstream u_out;
// socketstream sigma_out;
if (visualization)
{
char vishost[] = "localhost";
int visport = 19916;
u_out.open(vishost, visport);
// uex_out.open(vishost, visport);
// sigma_out.open(vishost, visport);
}
double res0 = 0.;
double err0 = 0.;
int dof0;
if (myid == 0)
{
mfem::out << " Refinement |"
<< " Dofs |"
<< " L2 Error |"
<< " Rate |"
<< " Residual |"
<< " Rate |" << endl;
mfem::out << " --------------------"
<< "-------------------"
<< "-------------------"
<< "-------------------" << endl;
}
for (int i = 0; i<=ref; i++)
{
if (static_cond) { a->EnableStaticCondensation(); }
a->Assemble();
Array<int> ess_tdof_list_uhat;
Array<int> ess_tdof_list_fhat;
Array<int> ess_bdr_uhat;
Array<int> ess_bdr_fhat;
if (pmesh.bdr_attributes.Size())
{
ess_bdr_uhat.SetSize(pmesh.bdr_attributes.Max());
ess_bdr_fhat.SetSize(pmesh.bdr_attributes.Max());
// ess_bdr_uhat = 1;
// ess_bdr_fhat = 0;
ess_bdr_uhat = 0;
ess_bdr_fhat = 1;
ess_bdr_uhat[1] = 1;
ess_bdr_fhat[1] = 0;
hatu_fes->GetEssentialTrueDofs(ess_bdr_uhat, ess_tdof_list_uhat);
hatf_fes->GetEssentialTrueDofs(ess_bdr_fhat, ess_tdof_list_fhat);
}
// shift the ess_tdofs
int n = ess_tdof_list_uhat.Size();
int m = ess_tdof_list_fhat.Size();
Array<int> ess_tdof_list(n+m);
for (int i = 0; i < n; i++)
{
ess_tdof_list[i] = ess_tdof_list_uhat[i]
+ u_fes->GetTrueVSize()
+ sigma_fes->GetTrueVSize();
}
for (int i = 0; i < m; i++)
{
ess_tdof_list[i+n] = ess_tdof_list_fhat[i]
+ u_fes->GetTrueVSize()
+ sigma_fes->GetTrueVSize()
+ hatu_fes->GetTrueVSize();
}
Array<int> offsets(5);
offsets[0] = 0;
offsets[1] = u_fes->GetVSize();
offsets[2] = sigma_fes->GetVSize();
offsets[3] = hatu_fes->GetVSize();
offsets[4] = hatf_fes->GetVSize();
offsets.PartialSum();
BlockVector x(offsets);
x = 0.0;
hatu_gf.MakeRef(hatu_fes,x.GetBlock(2));
hatu_gf.ProjectBdrCoefficient(hatuex,ess_bdr_uhat);
hatf_gf.MakeRef(hatf_fes,x.GetBlock(3));
hatf_gf.ProjectBdrCoefficientNormal(hatfex,ess_bdr_fhat);
OperatorPtr Ah;
Vector X,B;
a->FormLinearSystem(ess_tdof_list,x,Ah,X,B);
BlockOperator * A = Ah.As<BlockOperator>();
BlockDiagonalPreconditioner * M = new BlockDiagonalPreconditioner(A->RowOffsets());
M->owns_blocks = 1;
int skip = 0;
if (!static_cond)
{
HypreBoomerAMG * amg0 = new HypreBoomerAMG((HypreParMatrix &)A->GetBlock(0,0));
HypreBoomerAMG * amg1 = new HypreBoomerAMG((HypreParMatrix &)A->GetBlock(1,1));
amg0->SetPrintLevel(0);
amg1->SetPrintLevel(0);
M->SetDiagonalBlock(0,amg0);
M->SetDiagonalBlock(1,amg1);
skip = 2;
}
HypreBoomerAMG * amg2 = new HypreBoomerAMG((HypreParMatrix &)A->GetBlock(skip,skip));
amg2->SetPrintLevel(0);
M->SetDiagonalBlock(skip,amg2);
HypreSolver * prec;
if (dim == 2)
{
prec = new HypreAMS((HypreParMatrix &)A->GetBlock(skip+1,skip+1), hatf_fes);
}
else
{
prec = new HypreADS((HypreParMatrix &)A->GetBlock(skip+1,skip+1), hatf_fes);
}
M->SetDiagonalBlock(skip+1,prec);
CGSolver cg(MPI_COMM_WORLD);
cg.SetRelTol(1e-6);
cg.SetMaxIter(200000);
cg.SetPrintLevel(0);
cg.SetPreconditioner(*M);
cg.SetOperator(*A);
cg.Mult(B, X);
delete M;
a->RecoverFEMSolution(X,x);
Vector & residuals = a->ComputeResidual(x);
double residual = residuals.Norml2();
double maxresidual = residuals.Max();
double gresidual = residual * residual;
MPI_Allreduce(MPI_IN_PLACE,&maxresidual,1,MPI_DOUBLE,MPI_MAX,MPI_COMM_WORLD);
MPI_Allreduce(MPI_IN_PLACE,&gresidual,1,MPI_DOUBLE,MPI_SUM,MPI_COMM_WORLD);
gresidual = sqrt(gresidual);
elements_to_refine.SetSize(0);
for (int iel = 0; iel<pmesh.GetNE(); iel++)
{
if (residuals[iel] > theta * maxresidual)
{
elements_to_refine.Append(iel);
}
}
ParGridFunction u_gf;
u_gf.MakeRef(u_fes,x.GetBlock(0));
ParGridFunction sigma_gf;
sigma_gf.MakeRef(sigma_fes,x.GetBlock(1));
int dofs = u_fes->GlobalTrueVSize()
+ sigma_fes->GlobalTrueVSize()
+ hatu_fes->GlobalTrueVSize()
+ hatf_fes->GlobalTrueVSize();
double u_err = u_gf.ComputeL2Error(uex);
double sigma_err = sigma_gf.ComputeL2Error(sigmaex);
double L2Error = sqrt(u_err*u_err + sigma_err*sigma_err);
double rate_err = (i) ? dim*log(err0/L2Error)/log((double)dof0/dofs) : 0.0;
double rate_res = (i) ? dim*log(res0/gresidual)/log((double)dof0/dofs) : 0.0;
err0 = L2Error;
res0 = gresidual;
dof0 = dofs;
if (myid == 0)
{
mfem::out << std::right << std::setw(11) << i << " | "
<< std::setw(10) << dof0 << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << err0 << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_err << " | "
<< std::setprecision(3)
<< std::setw(10) << std::scientific << res0 << " | "
<< std::setprecision(2)
<< std::setw(6) << std::fixed << rate_res << " | "
<< std::resetiosflags(std::ios::showbase)
<< std::endl;
}
if (visualization)
{
// uex_out.precision(8);
// uex_out << "parallel " << num_procs << " " << myid << "\n";
// uex_out << "solution\n" << pmesh << uex_gf <<
// "window_title 'Exact u' "
// << flush;
u_out << "parallel " << num_procs << " " << myid << "\n";
u_out.precision(8);
u_out << "solution\n" << pmesh << u_gf <<
"window_title 'Numerical u' "
<< flush;
// sigma_out << "parallel " << num_procs << " " << myid << "\n";
// sigma_out.precision(8);
// sigma_out << "solution\n" << pmesh << sigma_gf <<
// "window_title 'Numerical flux' "
// << flush;
}
if (i == ref)
break;
pmesh.GeneralRefinement(elements_to_refine,1,1);
for (int i =0; i<trial_fes.Size(); i++)
{
trial_fes[i]->Update(false);
}
a->Update();
if (test_norm == test_norm_type::robust)
{
coeff_fes->Update();
c1_gf.Update();
c2_gf.Update();
Array<int> edofs;
for (int i = 0; i < pmesh.GetNE(); i++)
{
double volume = pmesh.GetElementVolume(i);
double c1 = min(epsilon/volume, 1.);
double c2 = min(1./epsilon, 1./volume);
coeff_fes->GetElementDofs(i,edofs);
c1_gf.SetSubVector(edofs,c1);
c2_gf.SetSubVector(edofs,c2);
}
}
}
delete a;
delete tau_fec;
delete v_fec;
delete hatf_fes;
delete hatf_fec;
delete hatu_fes;
delete hatu_fec;
delete sigma_fec;
delete u_fec;
delete u_fes;
return 0;
}
void solution(const Vector & X, double & u, Vector & du, double & d2u)
{
double x = X[0];
double y = X[1];
double z = 0.;
if (X.Size() == 3) z = X[2];
du.SetSize(X.Size());
du = 0.;
d2u = 0.;
switch(prob)
{
case polynomial:
{
int n=2;
int m=2;
u = pow(x,n)*pow(y,m);
du[0] = n * pow(x,n-1) * pow(y,m);
du[1] = m * pow(x,n) * pow(y,m-1);
d2u = n * (n-1) * pow(x,n-2) * pow(y,m)
+ m * (m-1) * pow(x,n) * pow(y,m-2);
}
break;
case EJ:
{
double alpha = sqrt(1. + 4. * epsilon * epsilon * M_PI * M_PI);
double r1 = (1. + alpha) / (2.*epsilon);
double r2 = (1. - alpha) / (2.*epsilon);
double denom = exp(-r2) - exp(-r1);
double g1 = exp(r2*(x-1.));
double g1_x = r2*g1;
double g1_xx = r2*g1_x;
double g2 = exp(r1*(x-1.));
double g2_x = r1*g2;
double g2_xx = r1*g2_x;
double g = g1-g2;
double g_x = g1_x - g2_x;
double g_xx = g1_xx - g2_xx;
u = g * cos(M_PI * y)/denom;
double u_x = g_x * cos(M_PI * y)/denom;
double u_xx = g_xx * cos(M_PI * y)/denom;
double u_y = -M_PI * g * sin(M_PI*y)/denom;
double u_yy = -M_PI * M_PI * u;
du[0] = u_x;
du[1] = u_y;
d2u = u_xx + u_yy;
}
break;
default:
{
double alpha = M_PI * (x + y + z);
u = sin(alpha);
du.SetSize(X.Size());
for (int i = 0; i<du.Size(); i++)
{
du[i] = M_PI * cos(alpha);
}
d2u = - M_PI*M_PI * u * du.Size();
}
break;
}
}
double exact_u(const Vector & X)
{
double u, d2u;
Vector du;
solution(X,u,du,d2u);
return u;
}
void exact_sigma(const Vector & X, Vector & sigma)
{
double u, d2u;
Vector du;
solution(X,u,du,d2u);
// σ = ε ∇ u
sigma = du;
sigma *= epsilon;
}
double exact_hatu(const Vector & X)
{
return -exact_u(X);
}
void exact_hatf(const Vector & X, Vector & hatf)
{
Vector sigma;
exact_sigma(X,sigma);
double u = exact_u(X);
hatf.SetSize(X.Size());
for (int i = 0; i<hatf.Size(); i++)
{
hatf[i] = beta[i] * u - sigma[i];
}
}
double f_exact(const Vector & X)
{
// f = - εΔu + ∇⋅(βu)
double u, d2u;
Vector du;
solution(X,u,du,d2u);
double s = 0;
for (int i = 0; i<du.Size(); i++)
{
s += beta[i] * du[i];
}
return -epsilon * d2u + s;
}

Some files were not shown because too many files have changed in this diff Show More