Changeset 7939


Ignore:
Timestamp:
Aug 13, 2010, 3:35:39 PM (9 years ago)
Author:
steve
Message:

Adding in culvert routines into structures directory

Location:
trunk/anuga_core/source/anuga
Files:
12 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/anuga_core/source/anuga/abstract_2d_finite_volumes/generic_domain.py

    r7938 r7939  
    14801480                self.evolve_one_rk3_step(yieldstep, finaltime)
    14811481
    1482 
    14831482            #==========================================
    14841483            # Apply other fractional steps
    14851484            #==========================================
    1486             #self.apply_fractional_steps()
     1485            self.apply_fractional_steps()
    14871486
    14881487            #==========================================
     
    18401839        msg = 'Method compute_fluxes must be overridden by Domain subclass'
    18411840        raise Exception, msg
     1841
     1842
     1843    ##
     1844    # @brief apply_fractional_step.
     1845    # Method should be overwritten in subclass, here it does nothing
     1846    def apply_fractional_steps(self):
     1847        pass
    18421848
    18431849    ##
  • trunk/anuga_core/source/anuga/shallow_water/shallow_water_domain.py

    r7938 r7939  
    166166        self.forcing_terms.append(gravity)
    167167
     168
     169        self.fractional_step_operators = []
     170
    168171        # Stored output
    169172        self.store = True
    170173        self.set_store_vertices_uniquely(False)
    171 
    172174        self.quantities_to_be_stored = {'elevation': 1,
    173175                                        'stage': 2,
     
    529531            (either from this module or C-extension)"""
    530532        compute_fluxes(self)
     533
     534
     535    def apply_fractional_steps(self):
     536        """Loop throughand apply all extra fractional steps"""
     537        for operator in self.fractional_step_operators:
     538            operator.apply()
    531539
    532540    def distribute_to_vertices_and_edges(self):
     
    11321140    elevation = domain.quantities['elevation']
    11331141
     1142    #FIXME SR Should avoid allocating memory!
    11341143    height = stage.centroid_values - elevation.centroid_values
    11351144    elevation = elevation.vertex_values
Note: See TracChangeset for help on using the changeset viewer.