Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Tom Harke
pystencils
Commits
a2582a17
Commit
a2582a17
authored
Mar 29, 2019
by
Martin Bauer
Browse files
pystencils: old style FD are using fast_subs instead of subs
parent
1bd1c6d6
Changes
1
Hide whitespace changes
Inline
Side-by-side
pystencils/fd/finitedifferences.py
View file @
a2582a17
...
...
@@ -322,7 +322,7 @@ def discretize_center(term, symbols_to_field_dict, dx, dim=3):
for
d
in
range
(
dim
):
up
,
down
=
__up_down_offsets
(
d
,
dim
)
substitutions
.
update
({
g
[
d
][
i
]:
(
field
[
up
](
i
)
-
field
[
down
](
i
))
/
dx
/
2
for
i
in
range
(
len
(
symbols
))})
return
term
.
subs
(
substitutions
)
return
fast_subs
(
term
,
substitutions
)
def
discretize_staggered
(
term
,
symbols_to_field_dict
,
coordinate
,
coordinate_offset
,
dx
,
dim
=
3
):
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment