Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F91905296
cohesive_element.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, Nov 15, 15:14
Size
3 KB
Mime Type
text/x-c++
Expires
Sun, Nov 17, 15:14 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22344743
Attached To
rAKA akantu
cohesive_element.hh
View Options
/**
* @file cohesive_element.hh
*
* @author Marco Vocialta <marco.vocialta@epfl.ch>
* @author Nicolas Richart <nicolas.richart@epfl.ch>
*
* @date Fri Feb 03 16:28:03 2012
*
* @brief Cohesive element class
*
* @section LICENSE
*
* Copyright (©) 2010-2011 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/>.
*
*/
/* -------------------------------------------------------------------------- */
#include "element_class.hh"
/* -------------------------------------------------------------------------- */
#ifndef __AKANTU_COHESIVE_ELEMENT_HH__
#define __AKANTU_COHESIVE_ELEMENT_HH__
__BEGIN_AKANTU__
/* -------------------------------------------------------------------------- */
template
<
ElementType
t
>
struct
CohesiveElementSubElementType
{
enum
{
value
=
_not_defined
};
};
template
<>
struct
CohesiveElementSubElementType
<
_cohesive_2d_4
>
{
enum
{
value
=
_segment_2
};
};
template
<>
struct
CohesiveElementSubElementType
<
_cohesive_2d_6
>
{
enum
{
value
=
_segment_3
};
};
/* -------------------------------------------------------------------------- */
template
<
ElementType
ct
>
class
CohesiveElement
:
public
ElementClass
<
ElementType
(
CohesiveElementSubElementType
<
ct
>::
value
)
>
{
typedef
ElementClass
<
ElementType
(
CohesiveElementSubElementType
<
ct
>::
value
)
>
Parent
;
/// function to print the containt of the class
virtual
void
printself
(
std
::
ostream
&
stream
,
int
indent
=
0
)
const
{};
/* ------------------------------------------------------------------------ */
/* Accessors */
/* ------------------------------------------------------------------------ */
public
:
static
UInt
getNbNodesPerElement
()
{
return
2
*
Parent
::
getNbNodesPerElement
();
}
static
UInt
getNbQuadraturePoints
()
{
return
Parent
::
getNbQuadraturePoints
();
}
static
UInt
getSpatialDimension
()
{
return
Parent
::
getSpatialDimension
()
+
1
;
}
static
UInt
getNbShapeFunctions
()
{
return
Parent
::
getNbShapeFunctions
();
}
static
inline
Real
*
getQuadraturePoints
()
{
return
Parent
::
getQuadraturePoints
();
}
static
inline
UInt
getShapeSize
()
{
return
Parent
::
getShapeSize
();
}
static
inline
UInt
getShapeDerivativesSize
(){
return
Parent
::
getShapeDerivativesSize
();
}
/// compute the in-radius
static
inline
Real
getInradius
(
const
Real
*
coord
)
{
return
Parent
::
getInradius
(
coord
);
}
static
inline
Real
*
getGaussIntegrationWeights
()
{
return
Parent
::
getGaussIntegrationWeights
();
}
static
inline
ElementType
getFacetElementType
()
{
return
ElementType
(
CohesiveElementSubElementType
<
ct
>::
value
);
}
static
inline
UInt
getNbFacetsPerElement
()
{
return
2
;
}
static
AKANTU_GET_MACRO_NOT_CONST
(
FacetLocalConnectivityPerElement
,
facet_connectivity
,
UInt
**
);
/* ------------------------------------------------------------------------ */
/* Class Members */
/* ------------------------------------------------------------------------ */
private
:
/// local connectivity of facets
static
UInt
*
facet_connectivity
[];
/// vectorial connectivity of facets
static
UInt
vec_facet_connectivity
[];
};
__END_AKANTU__
#endif
/* __AKANTU_COHESIVE_ELEMENT_HH__ */
Event Timeline
Log In to Comment