Changeset 3266
- Timestamp:
- 10/15/2009 10:17:06 AM (4 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
trunk/fipy/terms/term.py
r3043 r3266 81 81 def _calcResidual(self, var, matrix, RHSvector): 82 82 83 L2norm = numerix. sqrt(numerix.sum(self._calcResidualVector(var, matrix, RHSvector)**2))84 RHSL2norm = numerix. sqrt(numerix.sum(RHSvector**2))83 L2norm = numerix.L2norm(self._calcResidualVector(var, matrix, RHSvector)) 84 RHSL2norm = numerix.L2norm(RHSvector) 85 85 86 86 if RHSL2norm == 0: … … 193 193 def justResidualVector(self, var, solver=None, boundaryConditions=(), dt=1., underRelaxation=None, residualFn=None): 194 194 r""" 195 Builds andthe `Term`'s linear system once. This method195 Builds the `Term`'s linear system once. This method 196 196 also recalculates and returns the residual as well as applying 197 197 under-relaxation.