Changeset 5283


Ignore:
Timestamp:
May 6, 2008, 4:33:10 PM (16 years ago)
Author:
herve
Message:

changes made according to Ole's suggestion reducing considerably computation time.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/source/anuga/shallow_water/test_tsunami_okada.py

    r5281 r5283  
    127127        # get vertical displacement at each point of the domain respecting
    128128        # original script's order
     129        interpolation_points=[]
    129130        k=0.0
    130131        for i in range(0,6):
     
    133134                Yt=p
    134135                Xt=k
    135                 Z=tsunami.get_values(interpolation_points=[[Xt,Yt]]
    136                                      ,location='edges')
    137                 stage.append(-Z[0])
     136                interpolation_points.append([Xt, Yt])
     137
    138138            k=k+4000
     139        Z=tsunami.get_values(interpolation_points=interpolation_points,
     140                             location='edges')
    139141       
    140142        assert allclose(stage,tmp,atol=1.e-8)
     
    249251        tsunami = Quantity(domain)
    250252        tsunami.set_values(Ts)
    251 <<<<<<< .mine
    252253        interpolation_points=[]
    253 =======
    254254
    255255        #k=0.0
     
    268268        # Here's a faster way - try that in the first test
    269269        interpolation_points=[]
    270 >>>>>>> .r5278
    271270        k=0.0
    272271        for i in range(0,6):
     
    278277
    279278            k=k+4000
    280 
    281 <<<<<<< .mine
    282279        Z=tsunami.get_values(interpolation_points=interpolation_points,
    283280                             location='edges')
     
    289286        #print 'hello',stage   
    290287        assert allclose(stage,tmp,atol=1.e-3)
    291 =======
    292         Z=tsunami.get_values(interpolation_points=interpolation_points,
    293                              location='edges')
    294 >>>>>>> .r5278
    295 
    296         stage = -Z # FIXME(Ole): Why the sign flip?
    297        
    298         assert allclose(stage, tmp, atol=1.e-3)
    299288
    300289#-------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.