Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F74191587
material_python.hh
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Jul 26, 09:40
Size
3 KB
Mime Type
text/x-c++
Expires
Sun, Jul 28, 09:40 (2 d)
Engine
blob
Format
Raw Data
Handle
19343804
Attached To
rAKA akantu
material_python.hh
View Options
/**
* @file material_python.hh
*
* @author Guillaume Anciaux <guillaume.anciaux@epfl.ch>
*
* @date creation: Fri Nov 13 2015
* @date last modification: Fri Nov 13 2015
*
* @brief Python material
*
* @section LICENSE
*
* Copyright (©) 2015 EPFL (Ecole Polytechnique Fédérale de Lausanne) Laboratory
* (LSMS - Laboratoire de Simulation en Mécanique des Solides)
*
* Akantu is free software: you can redistribute it and/or modify it under the
* terms of the GNU Lesser General Public License as published by the Free
* Software Foundation, either version 3 of the License, or (at your option) any
* later version.
*
* Akantu is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
* A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
* details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with Akantu. If not, see <http://www.gnu.org/licenses/>.
*
*/
/**
* @file material_python.hh
*
* @author Guillaume Anciaux <guillaume.anciaux@epfl.ch>
*
*/
/* -------------------------------------------------------------------------- */
#include "python_functor.hh"
/* -------------------------------------------------------------------------- */
#include "material.hh"
/* -------------------------------------------------------------------------- */
#ifndef __AKANTU_MATERIAL_PYTHON_HH__
#define __AKANTU_MATERIAL_PYTHON_HH__
/* -------------------------------------------------------------------------- */
namespace
akantu
{
class
MaterialPython
:
public
Material
,
PythonFunctor
{
/* ------------------------------------------------------------------------ */
/* Constructors/Destructors */
/* ------------------------------------------------------------------------ */
public
:
MaterialPython
(
SolidMechanicsModel
&
model
,
PyObject
*
obj
,
const
ID
&
id
=
""
);
~
MaterialPython
()
override
=
default
;
/* ------------------------------------------------------------------------ */
/* Methods */
/* ------------------------------------------------------------------------ */
public
:
void
registerInternals
();
void
initMaterial
()
override
;
/// constitutive law for all element of a type
void
computeStress
(
ElementType
el_type
,
GhostType
ghost_type
=
_not_ghost
)
override
;
/// compute the tangent stiffness matrix for an element type
void
computeTangentModuli
(
const
ElementType
&
el_type
,
Array
<
Real
>
&
tangent_matrix
,
GhostType
ghost_type
=
_not_ghost
)
override
;
/// compute the push wave speed of the material
Real
getPushWaveSpeed
(
const
Element
&
element
)
const
override
;
/// compute an energy of the material
Real
getEnergy
(
const
std
::
string
&
type
)
override
;
/// compute an energy of the material
Real
getEnergyForType
(
const
std
::
string
&
type
,
ElementType
el_type
);
/* ------------------------------------------------------------------------ */
/* Class Members */
/* ------------------------------------------------------------------------ */
protected
:
std
::
map
<
std
::
string
,
Real
>
local_params
;
std
::
map
<
std
::
string
,
std
::
unique_ptr
<
InternalField
<
Real
>>>
internals
;
};
}
// akantu
#endif
/* __AKANTU_MATERIAL_PYTHON_HH__ */
Event Timeline
Log In to Comment