diff --git a/fipy/terms/implicitSourceTerm.py b/fipy/terms/implicitSourceTerm.py index f45e1c48c7..2e515dc956 100644 --- a/fipy/terms/implicitSourceTerm.py +++ b/fipy/terms/implicitSourceTerm.py @@ -20,6 +20,19 @@ class ImplicitSourceTerm(SourceTerm): where :math:`S` is the `coeff` value. """ + def __init__(self, coeff=1., var=None): + r""" + Parameters + ---------- + coeff : float or ~fipy.variables.cellVariable.CellVariable + Proportionality coefficient :math:`S` (default: 1) + var : ~fipy.variables.cellVariable.CellVariable + Variable :math:`\phi` that + :class:`~fipy.terms.implicitSourceTerm.ImplicitSourceTerm` is + implicit in. + """ + super(ImplicitSourceTerm, self).__init__(coeff=coeff, var=var) + def _getWeight(self, var, transientGeomCoeff=None, diffusionGeomCoeff=None): """ Test for a bug due to the sign operator not being updating diff --git a/fipy/terms/sourceTerm.py b/fipy/terms/sourceTerm.py index 53b4bd77fd..4b10cb1112 100644 --- a/fipy/terms/sourceTerm.py +++ b/fipy/terms/sourceTerm.py @@ -15,9 +15,18 @@ class SourceTerm(CellTerm): .. attention:: This class is abstract. Always create one of its subclasses. """ def __init__(self, coeff=0., var=None): + r""" + Parameters + ---------- + coeff : float or ~fipy.variables.cellVariable.CellVariable + Coefficient of source (default: 0) + var : ~fipy.variables.cellVariable.CellVariable + Variable :math:`\phi` that + :class:`~fipy.terms.sourceTerm.SourceTerm` is implicit in. + """ if self.__class__ is SourceTerm: raise AbstractBaseClassError - CellTerm.__init__(self, coeff=coeff, var=var) + super(SourceTerm, self).__init__(coeff=coeff, var=var) def _calcGeomCoeff(self, var): self._checkCoeff(var)