CMT + point force simulation at the same time.#1828
Merged
danielpeter merged 5 commits intoSPECFEM:develfrom Aug 28, 2025
Merged
CMT + point force simulation at the same time.#1828danielpeter merged 5 commits intoSPECFEM:develfrom
danielpeter merged 5 commits intoSPECFEM:develfrom
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## devel #1828 +/- ##
==========================================
- Coverage 48.82% 48.72% -0.10%
==========================================
Files 273 273
Lines 64785 65040 +255
==========================================
+ Hits 31629 31693 +64
- Misses 33156 33347 +191 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This change lets simulations include both CMT sources and point-force sources at the same time. Previously the runtime enforced a single-source-type restriction. Two new tags are added to
Par_file. If they do not exist, both will default to.false.Changes
Par_filetag:USE_CMT_AND_FORCE_SOURCE. When set to.true., the solver reads bothCMTSOLUTIONandFORCESOLUTION. Default is.false.(backwards compatible).USE_BINARY_SOURCE_FILE(default.false.). The binary file encapsulates all source metadata, including external source-time functions (if used). When enabled, the arrayuser_source_time_function(:,:)stores only the STFs local to the current MPI slice, rather than the full global set. This is implemented by first locating sources within each MPI slice, then reading the corresponding source time functions. SeeEXAMPLES/application/cmt_force_hybrid/write_binary_source.f90for the reference writer and format details.USE_BINARY_SOURCE_FILE.Example
see
EXAMPLES/application/cmt_force_hybrid/, run from step 1 to step 4.Performance
USE_BINARY_SOURCE_FILEsignificantly reduces memory usage when thousands of events use distinct external source time functions (e.g., in simulations that rely on representation theorem).