diff --git a/devito/finite_differences/differentiable.py b/devito/finite_differences/differentiable.py index 23152053b84..a10c3932d80 100644 --- a/devito/finite_differences/differentiable.py +++ b/devito/finite_differences/differentiable.py @@ -109,7 +109,8 @@ def _fd(self): fd_args = [] for f in self._args_diff: try: - if f.space_order <= self.space_order and f.time_order <= self.time_order: + if f.space_order <= self.space_order and \ + (not f.is_TimeDependent or f.time_order <= self.time_order): fd_args.append(f) except AttributeError: pass diff --git a/devito/ir/clusters/cluster.py b/devito/ir/clusters/cluster.py index 887793e8e7e..69ee00c6c5b 100644 --- a/devito/ir/clusters/cluster.py +++ b/devito/ir/clusters/cluster.py @@ -483,7 +483,7 @@ def dtype(self): If two Clusters perform calculations with different precision, the data type with highest precision is returned. """ - dtypes = {i.dtype for i in self} + dtypes = {i.dtype for i in self} - {None} return infer_dtype(dtypes)