Changeset 3642
- Timestamp:
- Sep 21, 2006, 11:30:59 AM (18 years ago)
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/documentation/user_manual/anuga_user_manual.tex
r3541 r3642 1400 1400 \end{methoddesc} 1401 1401 1402 \begin{methoddesc} {set\_minimum_s ww_depth}{time=0.0}1402 \begin{methoddesc} {set\_minimum_storable_height}{time=0.0} 1403 1403 Module: \module{pyvolution.domain} 1404 1404 1405 1405 Sets the minimum depth that will be recognised when writing 1406 1407 1406 to an sww file. This is useful for removing thin water layers 1407 that seems to be caused by friction creep. 1408 1408 \end{methoddesc} 1409 1409 … … 1648 1648 1649 1649 \begin{classdesc}{Reflective\_boundary}{Boundary} 1650 Module: \module{ pyvolution.shallow\_water}1650 Module: \module{shallow\_water} 1651 1651 1652 1652 Reflective boundary returns same conserved quantities as those present in -
anuga_core/source/anuga/config.py
r3632 r3642 106 106 107 107 #Specific to shallow water W.E. 108 minimum_allowed_height = 1.0e-3 #Water depth below which it is considered to be 0 108 minimum_allowed_height = 1.0e-3 #Water depth below which it is considered to be 0 in the model 109 109 maximum_allowed_speed = 100.0 #Maximal particle speed of water 110 110 111 minimum_s ww_depth = 0.0111 minimum_storable_height = 0.001 #Water depth below which it is *stored* as 0 -
anuga_core/source/anuga/shallow_water/data_manager.py
r3563 r3642 67 67 from anuga.coordinate_transforms.geo_reference import Geo_reference 68 68 from anuga.geospatial_data.geospatial_data import Geospatial_data 69 from anuga.config import minimum_s ww_depth69 from anuga.config import minimum_storable_height as default_minimum_storable_height 70 70 71 71 def make_filename(s): … … 252 252 Data_format.__init__(self, domain, 'sww', mode) 253 253 254 if hasattr(domain, 'minimum_s ww_depth'):255 self.minimum_s ww_depth = domain.minimum_sww_depth254 if hasattr(domain, 'minimum_storable_height'): 255 self.minimum_storable_height = domain.minimum_storable_height 256 256 else: 257 self.minimum_s ww_depth = minimum_sww_depth257 self.minimum_storable_height = default_minimum_storable_height 258 258 259 259 # NetCDF file definition … … 380 380 from os import stat 381 381 382 minimum_sww_depth = 0.001383 #minimum_sww_depth = 0.0 #FIXME pass in or read from domain384 382 from Numeric import choose 385 383 … … 482 480 #print z[:] 483 481 #print A-z[:] 484 A = choose( A-z[:] >= self.minimum_sww_depth,485 482 A = choose(A-z[:] >= self.minimum_storable_height, 483 (z[:], A)) 486 484 stage[i,:] = A.astype(self.precision) 487 485 elif name == 'xmomentum': -
anuga_core/source/anuga/shallow_water/shallow_water_domain.py
r3583 r3642 85 85 86 86 from anuga.utilities.numerical_tools import gradient, mean 87 from anuga.config import minimum_s ww_depth87 from anuga.config import minimum_storable_height 88 88 89 89 … … 148 148 self.format = 'sww' 149 149 self.set_store_vertices_uniquely(False) 150 self.minimum_s ww_depth = minimum_sww_depth150 self.minimum_storable_height = minimum_storable_height 151 151 self.quantities_to_be_stored = ['stage','xmomentum','ymomentum'] 152 152 … … 165 165 166 166 167 def set_minimum_s ww_depth(self, minimum_sww_depth):167 def set_minimum_storable_height(self, minimum_storable_height): 168 168 """ 169 169 Set the minimum depth that will be recognised when writing … … 173 173 The minimum allowed sww depth is in meters. 174 174 """ 175 self.minimum_s ww_depth = minimum_sww_depth175 self.minimum_storable_height = minimum_storable_height 176 176 177 177 -
anuga_core/source/anuga/shallow_water/test_data_manager.py
r3563 r3642 459 459 460 460 461 def test_sww_minimum_s ww_depth(self):461 def test_sww_minimum_storable_height(self): 462 462 """Test that sww information can be written correctly 463 463 multiple timesteps using a different reduction operator (min) … … 472 472 self.domain.smooth = True 473 473 self.domain.reduction = min 474 self.domain.minimum_s ww_depth= 100474 self.domain.minimum_storable_height = 100 475 475 476 476 sww = get_dataobject(self.domain) … … 4986 4986 #------------------------------------------------------------- 4987 4987 if __name__ == "__main__": 4988 #suite = unittest.makeSuite(Test_Data_Manager,'test_sww_minimum_s ww_depth')4988 #suite = unittest.makeSuite(Test_Data_Manager,'test_sww_minimum_storable_height') 4989 4989 suite = unittest.makeSuite(Test_Data_Manager,'test') 4990 4990 runner = unittest.TextTestRunner() -
anuga_work/development/dam_2006/run_dam.py
r3610 r3642 71 71 domain.set_datadir(project.outputtimedir) 72 72 domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum']) 73 domain.set_minimum_s ww_depth(0.01)73 domain.set_minimum_storable_height(0.01) 74 74 domain.set_store_vertices_uniquely(True) # for writting to sww 75 75 -
anuga_work/production/hobart_2006/run_hobart.py
r3638 r3642 146 146 domain.set_datadir(project.outputtimedir) 147 147 domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum']) 148 domain.set_minimum_s ww_depth(0.01)148 domain.set_minimum_storable_height(0.01) 149 149 domain.set_store_vertices_uniquely(True) # for writting to sww 150 150
Note: See TracChangeset
for help on using the changeset viewer.