Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F91377751
fe.py
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
Sun, Nov 10, 12:37
Size
1 KB
Mime Type
text/x-python
Expires
Tue, Nov 12, 12:37 (2 d)
Engine
blob
Format
Raw Data
Handle
21369100
Attached To
rAKA akantu
fe.py
View Options
# ------------------------------------------------------------------------------
__author__
=
"Nicolas Richart"
__copyright__
=
"Copyright (C) 2016-2018, EPFL (Ecole Polytechnique Fédérale"
\
" de Lausanne) Laboratory (LSMS - Laboratoire de Simulation"
\
" en Mécanique des Solides)"
__credits__
=
[
"Nicolas Richart"
]
__license__
=
"L-GPLv3"
__maintainer__
=
"Nicolas Richart"
__email__
=
"nicolas.richart@epfl.ch"
# ------------------------------------------------------------------------------
import
abc
class
Solver
(
metaclass
=
abc
.
ABCMeta
):
@abc.abstractmethod
def
solveStep
(
self
):
pass
def
_zero_rows
(
self
,
A
,
rows
):
for
r
in
rows
:
diag
=
A
[
r
,
r
]
# zeros the lines defined in b
A
.
data
[
A
.
indptr
[
r
]:
A
.
indptr
[
r
+
1
]]
=
0.
A
[
r
,
r
]
=
diag
class
Model
(
metaclass
=
abc
.
ABCMeta
):
@abc.abstractmethod
def
applyDirichletBC
(
self
):
pass
@abc.abstractmethod
def
f_int
(
self
):
pass
@property
@abc.abstractmethod
def
f_ext
(
self
):
pass
@property
@abc.abstractmethod
def
K
(
self
):
pass
@property
@abc.abstractmethod
def
M
(
self
):
pass
@property
@abc.abstractmethod
def
C
(
self
):
pass
@property
@abc.abstractmethod
def
blocked
(
self
):
pass
Event Timeline
Log In to Comment