/[escript]/trunk/escript/py_src/flows.py
ViewVC logotype

Diff of /trunk/escript/py_src/flows.py

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

revision 3440 by gross, Fri Jan 14 00:04:53 2011 UTC revision 3452 by caltinay, Tue Jan 25 01:53:57 2011 UTC
# Line 159  class DarcyFlow(object): Line 159  class DarcyFlow(object):
159        :type permeability: scalar or tensor values on the domain (e.g. `escript.Data`)        :type permeability: scalar or tensor values on the domain (e.g. `escript.Data`)
160    
161        :note: the values of parameters which are not set by calling ``setValue`` are not altered.        :note: the values of parameters which are not set by calling ``setValue`` are not altered.
162        :note: at any point on the boundary of the domain the pressure (``location_of_fixed_pressure`` >0)        :note: at any point on the boundary of the domain the pressure
163        or the normal component of the flux (``location_of_fixed_flux[i]>0``) if direction of the normal is along the *x_i* axis.               (``location_of_fixed_pressure`` >0) or the normal component of the
164                 flux (``location_of_fixed_flux[i]>0``) if direction of the normal
165                 is along the *x_i* axis.
166    
167        """        """
168        if self.useVPIteration:        if self.useVPIteration:
# Line 251  class DarcyFlow(object): Line 253  class DarcyFlow(object):
253        :rtype: ``tuple`` of `escript.Data`.        :rtype: ``tuple`` of `escript.Data`.
254    
255        :note: The problem is solved as a least squares form        :note: The problem is solved as a least squares form
256        *(K^[-1]+D^* l2 D)u+G p=D^* l2 * f + K^[-1]g*               *(K^[-1]+D^* l2 D)u+G p=D^* l2 * f + K^[-1]g*
257        *G^*u+*G^* K Gp=G^*g*               *G^*u+*G^* K Gp=G^*g*
258        where *D* is the *div* operator and *(Gp)_i=p_{,i}* for the permeability *K=k_{ij}*.               where *D* is the *div* operator and *(Gp)_i=p_{,i}* for the permeability *K=k_{ij}*.
259        """        """
260        self.verbose=verbose        self.verbose=verbose
261        if self.useVPIteration:        if self.useVPIteration:
# Line 288  class DarcyFlow(object): Line 290  class DarcyFlow(object):
290        """        """
291        solves the problem.        solves the problem.
292                
293        The iteration is terminated if the residual norm is less then self.getTolerance().        The iteration is terminated if the residual norm is less than self.getTolerance().
294    
295        :param u0: initial guess for the flux. At locations in the domain marked by ``location_of_fixed_flux`` the value of ``u0`` is kept unchanged.        :param u0: initial guess for the flux. At locations in the domain marked by ``location_of_fixed_flux`` the value of ``u0`` is kept unchanged.
296        :type u0: vector value on the domain (e.g. `escript.Data`).        :type u0: vector value on the domain (e.g. `escript.Data`).
297        :param p0: initial guess for the pressure. At locations in the domain marked by ``location_of_fixed_pressure`` the value of ``p0`` is kept unchanged.        :param p0: initial guess for the pressure. At locations in the domain marked by ``location_of_fixed_pressure`` the value of ``p0`` is kept unchanged.
298        :type p0: scalar value on the domain (e.g. `escript.Data`).        :type p0: scalar value on the domain (e.g. `escript.Data`).
       :param verbose: if set some information on iteration progress are printed  
       :type verbose: ``bool``  
299        :return: flux and pressure        :return: flux and pressure
300        :rtype: ``tuple`` of `escript.Data`.        :rtype: ``tuple`` of `escript.Data`.
301    
302        :note: The problem is solved as a least squares form        :note: The problem is solved as a least squares form
303        *(K^[-1]+D^* (DKD^*)^[-1] D)u+G p=D^* (DKD^*)^[-1] f + K^[-1]g*               *(K^[-1]+D^* (DKD^*)^[-1] D)u+G p=D^* (DKD^*)^[-1] f + K^[-1]g*
304        *G^*u+*G^* K Gp=G^*g*               *G^*u+*G^* K Gp=G^*g*
305        where *D* is the *div* operator and *(Gp)_i=p_{,i}* for the permeability *K=k_{ij}*.               where *D* is the *div* operator and *(Gp)_i=p_{,i}* for the permeability *K=k_{ij}*.
306        """        """
307        rtol=self.getTolerance()        rtol=self.getTolerance()
308        atol=self.getAbsoluteTolerance()        atol=self.getAbsoluteTolerance()

Legend:
Removed from v.3440  
changed lines
  Added in v.3452

  ViewVC Help
Powered by ViewVC 1.1.26