Changeset 5740
- Timestamp:
- Sep 5, 2008, 5:11:58 PM (17 years ago)
- Location:
- anuga_work/development/anuga_1d
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_work/development/anuga_1d/config.py
r5587 r5740 78 78 beta_w = 1.5 79 79 beta_h = 0.2 80 timestepping_method = 'euler' 81 80 82 CFL = 1.0 #FIXME (ole): Is this in use yet?? 81 83 #(Steve) yes, change domain.CFL to -
anuga_work/development/anuga_1d/domain.py
r5738 r5740 20 20 21 21 from Numeric import array, zeros, Float, Int 22 23 from config import timestepping_method 24 from config import CFL 25 26 22 27 23 28 #Store Points … … 34 39 self.beta = 1.0 35 40 self.limiter = "minmod_kurganov" 41 self.CFL = CFL 42 self.set_timestepping_method(timestepping_method) 43 36 44 self.wet_nodes = zeros((N,2), Int) # should this be here 37 45 … … 538 546 return self.centroids 539 547 548 549 def get_timestepping_method(self): 550 return self.timestepping_method 551 552 def set_timestepping_method(self,timestepping_method): 553 554 if timestepping_method in ['euler', 'rk2', 'rk3']: 555 self.timestepping_method = timestepping_method 556 return 557 558 msg = '%s is an incorrect timestepping type'% timestepping_method 559 raise Exception, msg 560 561 540 562 def set_quantity(self, name, *args, **kwargs): 541 563 """Set values for named quantity … … 702 724 #-------------------------- 703 725 704 def evolve(self, 705 yieldstep = None, 706 finaltime = None, 707 duration = None, 726 def evolve(self, yieldstep = None, finaltime = None, duration = None, 708 727 skip_initial_step = False): 709 728 """Evolve model through time starting from self.starttime. … … 740 759 741 760 from config import min_timestep, max_timestep, epsilon 761 762 print 'yieldstep', yieldstep 763 print 'duration', duration 742 764 743 765 # FIXME: Maybe lump into a larger check prior to evolving -
anuga_work/development/anuga_1d/shallow_water_domain.py
r5731 r5740 168 168 distribute_to_vertices_and_edges(self) 169 169 170 def evolve(self, yieldstep = None, finaltime = None, 170 def evolve(self, yieldstep = None, finaltime = None, duration = None, 171 171 skip_initial_step = False): 172 172 """Specialisation of basic evolve method from parent class … … 207 207 208 208 #Call basic machinery from parent class 209 for t in Generic_Domain.evolve(self, yieldstep, finaltime, 209 for t in Generic_Domain.evolve(self, yieldstep, finaltime,duration, 210 210 skip_initial_step): 211 211 #Real time viz
Note: See TracChangeset
for help on using the changeset viewer.