/[escript]/trunk/downunder/py_src/regularizations.py
ViewVC logotype

Diff of /trunk/downunder/py_src/regularizations.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4154 by jfenwick, Tue Jan 22 09:30:23 2013 UTC revision 4211 by caltinay, Mon Feb 18 23:54:46 2013 UTC
# Line 25  __all__ = ['Regularization'] Line 25  __all__ = ['Regularization']
25  from costfunctions import CostFunction  from costfunctions import CostFunction
26    
27  import numpy as np  import numpy as np
28  from esys.escript import ReducedFunction, outer, Data, Scalar, grad, inner, integrate, interpolate, kronecker, boundingBoxEdgeLengths, vol, sqrt, length  from esys.escript import Function, outer, Data, Scalar, grad, inner, integrate, interpolate, kronecker, boundingBoxEdgeLengths, vol, sqrt, length
29  from esys.escript.linearPDEs import LinearPDE, IllegalCoefficientValue  from esys.escript.linearPDEs import LinearPDE, IllegalCoefficientValue
30  from esys.escript.pdetools import ArithmeticTuple  from esys.escript.pdetools import ArithmeticTuple
31    
# Line 412  class Regularization(CostFunction): Line 412  class Regularization(CostFunction):
412          DIM=self.getDomain().getDim()          DIM=self.getDomain().getDim()
413          numLS=self.getNumLevelSets()          numLS=self.getNumLevelSets()
414    
415          print "WARNING: WRONG FUNCTION SPACE"          grad_m=grad(m, Function(m.getDomain()))
           
         grad_m=grad(m, ReducedFunction(m.getDomain()))  
416          if self.__w0 is not None:          if self.__w0 is not None:
417              Y = m * self.__w0 * mu              Y = m * self.__w0 * mu
418          else:          else:

Legend:
Removed from v.4154  
changed lines
  Added in v.4211

  ViewVC Help
Powered by ViewVC 1.1.26