Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F91950107
symmetric_disk_engine.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
Sat, Nov 16, 01:26
Size
549 B
Mime Type
text/x-python
Expires
Mon, Nov 18, 01:26 (2 d)
Engine
blob
Format
Raw Data
Handle
22351272
Attached To
R6746 RationalROMPy
symmetric_disk_engine.py
View Options
import
fenics
as
fen
import
mshr
from
rrompy.hfengines.linear_problem
import
HelmholtzProblemEngine
class
SymmetricDiskEngine
(
HelmholtzProblemEngine
):
def
__init__
(
self
,
k0
:
float
,
n
:
int
):
super
()
.
__init__
(
mu0
=
[
k0
])
mesh
=
mshr
.
generate_mesh
(
mshr
.
Circle
(
fen
.
Point
(
0.
,
0.
),
1.
),
n
)
self
.
V
=
fen
.
FunctionSpace
(
mesh
,
"P"
,
1
)
x
,
y
=
fen
.
SpatialCoordinate
(
self
.
V
.
mesh
())[:]
self
.
forcingTerm
=
[
fen
.
exp
(
x
+
y
)
*
(
1.
-
x
**
2.
-
y
**
2.
),
fen
.
exp
(
x
-
y
)
*
(
1.
-
x
**
2.
-
y
**
2.
)]
Event Timeline
Log In to Comment