-
Notifications
You must be signed in to change notification settings - Fork 239
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implementation of nodal source terms #1977
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
3280f04
[MGTL] inline createSearchLengthAlgorithm.
TomFischer 4e9ff82
[PL/SourceTerms] Impl. of NodalSourceTerm.
TomFischer 164dbee
[PL/SourceTerms] Impl. of createNodalSourceTerm.
TomFischer 57205b4
[PL/SourceTerms] Impl. of class SourceTermConfig.
TomFischer 71018e2
[PL/SourceTerms] Impl. of class SourceTermBuilder.
TomFischer fc36bb5
[PL/SourceTerms] Put SourceTerms in ProcessVars.
TomFischer c3c3bb0
[PL/SourceTerms] Process vars.: Create source terms.
TomFischer a90d44a
[PL/SourceTerms] Add tests for source term impl.
TomFischer 5258b08
[PL/SourceTerms] Documentation.
TomFischer a3e3bc1
[PL/BoundaryCondition] Fix spelling in docu.
TomFischer 1d621ca
[Documentation] Add docu for nodal source terms.
TomFischer 07743a6
Update test data.
TomFischer File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
...variables/process_variable/boundary_conditions/boundary_condition/t_geometry.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
The name of the on which the boundary condition is defined. | ||
The name of the geometry on which the boundary condition is defined. |
1 change: 1 addition & 0 deletions
1
...ojectFile/prj/process_variables/process_variable/source_terms/i_source_terms.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Contains source terms for the process variable. |
1 change: 1 addition & 0 deletions
1
...rj/process_variables/process_variable/source_terms/source_term/Nodal/c_Nodal.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Declares a source term to be associated to a node. |
1 change: 1 addition & 0 deletions
1
...rj/process_variables/process_variable/source_terms/source_term/Nodal/t_value.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
The value for the nodal source term. |
1 change: 1 addition & 0 deletions
1
...rj/process_variables/process_variable/source_terms/source_term/i_source_term.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Defines a source term for a process variable. |
3 changes: 3 additions & 0 deletions
3
.../prj/process_variables/process_variable/source_terms/source_term/t_component.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
For the multi-component process variables specifies the component of the | ||
source term. The component ids start with 0. For single-component | ||
variables this is optional and defaults to 0. |
4 changes: 4 additions & 0 deletions
4
...rocess_variables/process_variable/source_terms/source_term/t_geometrical_set.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
The name of the geometrical set (see \ref ogs_file_param__gml__name) in which | ||
the \ref | ||
ogs_file_param__prj__process_variables__process_variable__source_terms__source_term__geometry | ||
"geometry" is defined. |
1 change: 1 addition & 0 deletions
1
...e/prj/process_variables/process_variable/source_terms/source_term/t_geometry.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
The name of the geometry on which the source term is defined. |
1 change: 1 addition & 0 deletions
1
...tFile/prj/process_variables/process_variable/source_terms/source_term/t_type.md
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Sets the type of the source term. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
/** | ||
* @file | ||
* @copyright | ||
* Copyright (c) 2012-2017, OpenGeoSys Community (http://www.opengeosys.org) | ||
* Distributed under a Modified BSD License. | ||
* See accompanying file LICENSE.txt or | ||
* http://www.opengeosys.org/LICENSE.txt | ||
*/ | ||
|
||
#include "CreateSearchLength.h" | ||
|
||
#include "BaseLib/ConfigTree.h" | ||
#include "BaseLib/Error.h" | ||
|
||
#include "MeshGeoToolsLib/HeuristicSearchLength.h" | ||
#include "MeshGeoToolsLib/SearchLength.h" | ||
|
||
namespace MeshGeoToolsLib | ||
{ | ||
std::unique_ptr<MeshGeoToolsLib::SearchLength> createSearchLengthAlgorithm( | ||
BaseLib::ConfigTree const& external_config, MeshLib::Mesh const& mesh) | ||
{ | ||
boost::optional<BaseLib::ConfigTree> config = | ||
//! \ogs_file_param{prj__process_variables__process_variable__boundary_conditions__boundary_condition__search_length_algorithm} | ||
external_config.getConfigSubtreeOptional("search_length_algorithm"); | ||
|
||
if (!config) | ||
return std::unique_ptr<MeshGeoToolsLib::SearchLength>{ | ||
new MeshGeoToolsLib::SearchLength()}; | ||
|
||
//! \ogs_file_param{prj__process_variables__process_variable__boundary_conditions__boundary_condition__search_length_algorithm__type} | ||
std::string const type = config->getConfigParameter<std::string>("type"); | ||
|
||
if (type == "fixed") | ||
{ | ||
//! \ogs_file_param{prj__process_variables__process_variable__boundary_conditions__boundary_condition__search_length_algorithm__fixed__value} | ||
double const length = config->getConfigParameter<double>("value"); | ||
return std::unique_ptr<MeshGeoToolsLib::SearchLength>{ | ||
new MeshGeoToolsLib::SearchLength(length)}; | ||
} | ||
if (type == "heuristic") | ||
{ | ||
return std::unique_ptr<MeshGeoToolsLib::HeuristicSearchLength>{ | ||
new MeshGeoToolsLib::HeuristicSearchLength(mesh)}; | ||
} | ||
OGS_FATAL("Unknown search length algorithm type '%s'.", type.c_str()); | ||
} | ||
|
||
} // end namespace MeshGeoToolsLib |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. This is much nicer because of the removed includes and the fwd-decls.