Skip to content

Commit f0b7d99

Browse files
committed
misc: Remove dead code
1 parent a2f478c commit f0b7d99

1 file changed

Lines changed: 2 additions & 10 deletions

File tree

examples/timestepping/ic_superstep.py

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
''' Script that demonstrates the functionality of the superstep in 1D and 2D
1+
""" Script that demonstrates the functionality of the superstep in 1D and 2D
22
with an initial condition
33
In 1D: "Wave on a string"
44
In 2d: "Ripple on a pond"
5-
'''
5+
"""
66
from argparse import ArgumentParser
77
from dataclasses import dataclass
88
from functools import reduce
@@ -38,13 +38,6 @@ def gaussian_1d(x, mu=0, sigma_sq=1):
3838
return np.exp(-((x - mu)**2)/(2*sigma_sq))/(np.sqrt(2*np.pi*sigma_sq))
3939

4040

41-
def gaussian_2d(xx, yy, mu=0, sigma_sq=1):
42-
"""
43-
Generate a 2D Gaussian initial condition
44-
"""
45-
return np.exp(-((xx - mu)**2 + (yy - mu)**2)/(2*sigma_sq))/(2*np.pi*sigma_sq)
46-
47-
4841
def gaussian(dims, mu=0, sigma_sq=1):
4942
"""
5043
Generate an N-dimensional Gaussian initial condition
@@ -73,7 +66,6 @@ def simulate_ic(parameters, step=1, snapshots=-1):
7366
in zip(p.origin, p.extent, p.shape)
7467
])
7568
ic = gaussian(msh, mu=p.mu, sigma_sq=p.sigma_sq)
76-
ic = gaussian_2d(*msh, mu=p.mu, sigma_sq=p.sigma_sq)
7769

7870
# Stencil and operator
7971
if step == 1:

0 commit comments

Comments
 (0)