You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix Devito examples, Picard solver, and add Pint unit checks
Fix README Devito snippet; align first PDE narrative; correct elliptic L1 criterion; make Picard solver implicit via Jacobi iteration with regression+NumPy reference tests; add Pint-based unit checks for book snippets and include pint in dev extras.
Copy file name to clipboardExpand all lines: README.md
+15-5Lines changed: 15 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,20 +16,30 @@ Based on *Finite Difference Computing with Partial Differential Equations* by Ha
16
16
Devito is a domain-specific language (DSL) embedded in Python for solving PDEs using finite differences. Instead of manually implementing stencil operations, you write mathematical expressions symbolically and Devito generates optimized C code:
17
17
18
18
```python
19
-
from devito import Grid, TimeFunction, Eq, Operator
19
+
import numpy as np
20
+
from devito import Constant, Eq, Grid, Operator, TimeFunction, solve
20
21
21
22
# Define computational grid
22
23
grid = Grid(shape=(101,), extent=(1.0,))
23
24
24
25
# Create field with time derivative capability
25
26
u = TimeFunction(name='u', grid=grid, time_order=2, space_order=2)
0 commit comments