Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Symbolic coefficient erroring due to factorization #2178

Closed
mloubout opened this issue Aug 3, 2023 · 0 comments · Fixed by #2179
Closed

Symbolic coefficient erroring due to factorization #2178

mloubout opened this issue Aug 3, 2023 · 0 comments · Fixed by #2179

Comments

@mloubout
Copy link
Contributor

mloubout commented Aug 3, 2023

Symbolic coefficient cannot be applied to p.dx2 + q.dx2 because it is factorized as (p+q).dx2.

MFE:

from devito import Eq, Grid, Operator, TimeFunction, Coefficient, Substitutions
import numpy as np
from sympy import finite_diff_weights

grid = Grid(shape=(100,100,100))
p = TimeFunction(name='p', grid=grid, #save=tt.num,
                        space_order=8, time_order=2,
                        coefficients='symbolic' )  # the customized coefficients

q = TimeFunction(name='q', grid=grid, #save=tt.num,
                        space_order=8, time_order=2,
                        coefficients='symbolic' )  # the customized coefficients

OP = Operator( [ Eq(p.forward, p.dx2 + q.dx2)] )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant