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

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

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

revision 4628 by sshaw, Mon Jan 20 03:42:55 2014 UTC revision 4629 by sshaw, Fri Jan 24 03:29:25 2014 UTC
# Line 430  class VTIWave(WaveBase): Line 430  class VTIWave(WaveBase):
430    
431          self.__wavelet=wavelet          self.__wavelet=wavelet
432    
433          self.fastAssembler = hasattr(domain, "setAssembler")          self.fastAssembler = False #hasattr(domain, "setAssembler")
434            self.c33=v_p**2 * rho
435            self.c44=v_s**2 * rho
436            self.c11=(1+2*eps) * self.c33
437            self.c66=(1+2*gamma) * self.c44
438            self.c13=sqrt(2*self.c33*(self.c33-self.c44) * delta + (self.c33-self.c44)**2)-self.c44
439            self.c12=self.c11-2*self.c66
440    
441          if self.fastAssembler:          if self.fastAssembler:
442              c33=v_p**2 * rho              self.__mypde=VTIWavePDE(domain, [("c11", self.c11),
443              c44=v_s**2 * rho                      ("c12", self.c12), ("c13", self.c13), ("c33", self.c33),
444              c11=(1+2*eps) * c33                      ("c44", self.c44), ("c66", self.c66)])
             c66=(1+2*gamma) * c44  
             c13=sqrt(2*c33*(c33-c44) * delta + (c33-c44)**2)-c44  
             c12=c11-2*c66  
             self.__mypde=VTIWavePDE(domain, [("c11", c11), ("c12", c12),  
                         ("c13", c13), ("c33", c33), ("c44", c44), ("c66", c66)])  
445          else:          else:
446              self.__mypde=LinearPDESystem(domain)              self.__mypde=LinearPDESystem(domain)
447              self.__mypde.setValue(X=self.__mypde.createCoefficient('X'))              self.__mypde.setValue(X=self.__mypde.createCoefficient('X'))
# Line 458  class VTIWave(WaveBase): Line 459  class VTIWave(WaveBase):
459          self.__r=Vector(0, DiracDeltaFunctions(self.__mypde.getDomain()))          self.__r=Vector(0, DiracDeltaFunctions(self.__mypde.getDomain()))
460          self.__r.setTaggedValue(self.__source_tag, source_vector)          self.__r.setTaggedValue(self.__source_tag, source_vector)
461    
         if not self.fastAssembler:  
             self.c33=v_p**2 * rho  
             self.c44=v_s**2 * rho  
             self.c11=(1+2*eps) * self.c33  
             self.c66=(1+2*gamma) * self.c44  
             self.c13=sqrt(2*self.c33*(self.c33-self.c44) * delta + (self.c33-self.c44)**2)-self.c44  
             self.c12=self.c11-2*self.c66  
   
462      def _getAcceleration(self, t, u):      def _getAcceleration(self, t, u):
463          """          """
464          returns the acceleraton for time t and solution u at time t          returns the acceleraton for time t and solution u at time t

Legend:
Removed from v.4628  
changed lines
  Added in v.4629

  ViewVC Help
Powered by ViewVC 1.1.26