-
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
Some improvement in SolidModels #2160
Conversation
wenqing
commented
Jul 10, 2018
•
edited
Loading
edited
- Moved createNewtonRaphsonSolverParameters to new files to avoid code duplication.
- Introduced createConstitutiveRelation to remove code duplication.
- Removed three unnecessarily defined -impl.h files.
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.
Only minor things. I assume, the last commit only moves code.
BaseLib::ConfigTree const& config) | ||
{ | ||
// Constitutive relation. | ||
// read type; |
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.
not necessary.
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.
removed.
constitutive_relation_config.peekConfigParameter<std::string>("type"); | ||
|
||
std::unique_ptr<MaterialLib::Solids::MechanicsBase<DisplacementDim>> | ||
material = nullptr; |
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.
nullptr
as already the default.
material = nullptr; | ||
if (type == "Ehlers") | ||
{ | ||
material = MaterialLib::Solids::Ehlers::createEhlers<DisplacementDim>( |
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.
Minor: You could just return MaterialLib::Solids::Ehlers::createEhlers<DisplacementDim>(...
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.
Changed according by amending the second commit.
"Cannot construct constitutive relation of given type \'%s\'.", | ||
type.c_str()); | ||
} | ||
return nullptr; |
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.
That's never reached.
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.
@chleh Yes, the last commit just moves code and dumps three -impl.h files.
7549882
to
54c3419
Compare
@@ -0,0 +1,49 @@ | |||
/** | |||
* \copyright | |||
* Copyright (c) 2012-2017, OpenGeoSys Community (http://www.opengeosys.org) |
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.
2018
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.
Corrected by amending the 2nd commit.
@@ -0,0 +1,28 @@ | |||
/** | |||
* \copyright | |||
* Copyright (c) 2012-2017, OpenGeoSys Community (http://www.opengeosys.org) |
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.
18
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.
Corrected by amending the 1st commit
…avoid code duplication
fa8520f
to
fb0e86d
Compare
OpenGeoSys development has been moved to GitLab. |