Example #1
0
    def __init__(self, coeff=1., var=None):
        if self.__class__ is CellTerm:
            raise AbstractBaseClassError

        from fipy.variables.variable import Variable

        if not isinstance(coeff, Variable):
            from fipy.variables.constant import _Constant
            coeff = _Constant(value=coeff)

        if isinstance(coeff, FaceVariable):
            raise TypeError("The coefficient can not be a FaceVariable.")

        _NonDiffusionTerm.__init__(self, coeff=coeff, var=var)
        self.coeffVectors = None
        self._var = None
Example #2
0
    def __init__(self, coeff=1., var=None):
        if self.__class__ is CellTerm:
            raise AbstractBaseClassError

        from fipy.variables.variable import Variable

        if not isinstance(coeff, Variable):
            from fipy.variables.constant import _Constant
            coeff = _Constant(value=coeff)

        if isinstance(coeff, FaceVariable):
             raise TypeError("The coefficient can not be a FaceVariable.")

        _NonDiffusionTerm.__init__(self, coeff=coeff, var=var)
        self.coeffVectors = None
        self._var = None
Example #3
0
    def __init__(self, coeff=1., var=None):
        if self.__class__ is FaceTerm:
            raise NotImplementedError("can't instantiate abstract base class")

        _NonDiffusionTerm.__init__(self, coeff=coeff, var=var)
        self.coeffMatrix = None
Example #4
0
 def __init__(self, coeff=None):
     _NonDiffusionTerm.__init__(self)
     self.geomCoeff = coeff
Example #5
0
    def __init__(self, coeff=1., var=None):
        if self.__class__ is FaceTerm:
            raise NotImplementedError("can't instantiate abstract base class")

        _NonDiffusionTerm.__init__(self, coeff=coeff, var=var)
        self.coeffMatrix = None
 def __init__(self, coeff = None):
     _NonDiffusionTerm.__init__(self)
     self.geomCoeff = coeff