Changeset 5442


Ignore:
Timestamp:
Jun 26, 2008, 1:21:05 PM (14 years ago)
Author:
ole
Message:

Retired h-limiter and beta_h as per ticket:194.
All unit tests and validation tests pass.

Files:
74 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/source/anuga/abstract_2d_finite_volumes/domain.py

    r5421 r5442  
    180180
    181181        # Defaults
    182         from anuga.config import max_smallsteps, beta_w, beta_h, epsilon
     182        from anuga.config import max_smallsteps, beta_w, epsilon
    183183        from anuga.config import CFL
    184184        from anuga.config import timestepping_method
    185185        from anuga.config import protect_against_isolated_degenerate_timesteps
    186186        self.beta_w = beta_w
    187         self.beta_h = beta_h
    188187        self.epsilon = epsilon
    189188        self.protect_against_isolated_degenerate_timesteps = protect_against_isolated_degenerate_timesteps
    190189       
    191190       
    192 
    193         # FIXME: Maybe have separate orders for h-limiter and w-limiter?
    194         # Or maybe get rid of order altogether and use beta_w and beta_h
     191        # Maybe get rid of order altogether and use beta_w
    195192        # FIXME (Ole): In any case, this should appear in the config file - not here
    196193        self.set_default_order(1)
  • anuga_core/source/anuga/abstract_2d_finite_volumes/test_util.py

    r5221 r5442  
    14311431       
    14321432        domain.default_order=2
    1433         domain.beta_h = 0
    14341433       
    14351434        # This test was made before tight_slope_limiters were introduced
     
    15581557       
    15591558        domain.default_order=2
    1560         domain.beta_h = 0
    15611559
    15621560        # Set some field values
     
    16711669       
    16721670        domain.default_order=2
    1673         domain.beta_h = 0
    16741671
    16751672        # This test was made before tight_slope_limiters were introduced
  • anuga_core/source/anuga/config.py

    r5441 r5442  
    5252# 1'st order extrapolations.
    5353#
    54 # Large values of beta_h may cause simulations to require more timesteps
    55 # as surface will 'hug' closer to the bed.
    56 # Small values of beta_h will make code faster, but one may experience
    57 # artificial momenta caused by discontinuities in water depths in
    58 # the presence of steep slopes. One example of this would be
    59 # stationary water 'lapping' upwards to a higher point on the coast.
    60 #
    61 # NOTE (Ole): I believe this was addressed with the introduction of
    62 # tight_slope_limiters. I wish to retire the beta_? parameters.
    63 # Can you please let me know if you disagree?
    6454
    65 # There are separate betas for the w, uh, vh and h limiters
     55# There are separate betas for the w, uh, and vh limiters
    6656# I think these are better SR but they conflict with the unit tests!
    6757beta_w      = 1.0
     
    7161beta_vh     = 1.0
    7262beta_vh_dry = 0.2
    73 
    74 # beta_h can be safely put to zero esp if we are using
    75 # tight_slope_limiters = 1. This will
    76 # also speed things up in general
    77 beta_h = 0.0
    7863
    7964
  • anuga_core/source/anuga/damage_modelling/test_inundation_damage.py

    r4742 r5442  
    7070       
    7171        domain.default_order=2
    72         domain.beta_h = 0
    7372        #Set some field values
    7473        #domain.set_quantity('stage', 1.0)
     
    141140       
    142141        domain.default_order=2
    143         domain.beta_h = 0
    144142        #Set some field values
    145143        #domain.set_quantity('stage', 1.0)
     
    262260       
    263261        domain.default_order=2
    264         domain.beta_h = 0
    265262
    266263        #Set some field values
     
    335332       
    336333        domain.default_order=2
    337         domain.beta_h = 0
    338334
    339335        #Set some field values
  • anuga_core/source/anuga/fit_interpolate/test_interpolate.py

    r5181 r5442  
    4949        domain = Domain(points, vertices, boundary)
    5050        domain.default_order=2
    51         domain.beta_h = 0
    5251
    5352
     
    15961595       
    15971596        domain.default_order = 2
    1598         domain.beta_h = 0
    15991597
    16001598        # This test was made before tight_slope_limiters were introduced
  • anuga_core/source/anuga/shallow_water/shallow_water_domain.py

    r5436 r5442  
    9999from anuga.config import minimum_storable_height
    100100from anuga.config import minimum_allowed_height, maximum_allowed_speed
    101 from anuga.config import g, epsilon, beta_h, beta_w, beta_w_dry,\
     101from anuga.config import g, epsilon, beta_w, beta_w_dry,\
    102102     beta_uh, beta_uh_dry, beta_vh, beta_vh_dry, tight_slope_limiters
    103103from anuga.config import alpha_balance
     
    169169        self.beta_vh     = beta_vh
    170170        self.beta_vh_dry = beta_vh_dry
    171         self.beta_h      = beta_h
    172171        self.alpha_balance = alpha_balance
    173172
     
    209208        self.quantities['ymomentum'].beta = beta
    210209       
    211         self.beta_h      = beta
    212210       
    213211
     
    420418        # self.check_integrity()
    421419
    422         msg = 'Parameter beta_h must be in the interval [0, 2['
    423         assert 0 <= self.beta_h <= 2.0, msg
    424420        msg = 'Parameter beta_w must be in the interval [0, 2['
    425421        assert 0 <= self.beta_w <= 2.0, msg
     
    859855
    860856
    861 def h_limiter(domain):
    862     """Limit slopes for each volume to eliminate artificial variance
    863     introduced by e.g. second order extrapolator
    864 
    865     limit on h = w-z
    866 
    867     This limiter depends on two quantities (w,z) so it resides within
    868     this module rather than within quantity.py
    869 
    870     Wrapper for c-extension
    871     """
    872 
    873     N = len(domain) # number_of_triangles
    874     beta_h = domain.beta_h
    875 
    876     # Shortcuts
    877     wc = domain.quantities['stage'].centroid_values
    878     zc = domain.quantities['elevation'].centroid_values
    879     hc = wc - zc
    880 
    881     wv = domain.quantities['stage'].vertex_values
    882     zv = domain.quantities['elevation'].vertex_values
    883     hv = wv - zv
    884 
    885     #Call C-extension
    886     from shallow_water_ext import h_limiter_sw
    887     hvbar = h_limiter_sw(domain, hc, hv)
    888 
    889     return hvbar
    890 
    891857
    892858def balance_deep_and_shallow(domain):
     
    904870    """
    905871
    906     # FIXME (Ole): I reckon this can be simplified significantly:
    907     #
    908     # Always use beta_h == 0, and phase it out.
    909     # Compute hc and hv in the c-code
    910     # Omit updating xmomv
    911     #
    912872    from shallow_water_ext import balance_deep_and_shallow as balance_deep_and_shallow_c
    913873
    914874
    915     #print 'calling balance depth and shallow'
    916875    # Shortcuts
    917876    wc = domain.quantities['stage'].centroid_values
     
    929888    ymomv = domain.quantities['ymomentum'].vertex_values
    930889
    931     # Limit h
    932     if domain.beta_h > 0:
    933         hvbar = h_limiter(domain)
    934        
    935         balance_deep_and_shallow_c(domain, domain.beta_h,
    936                                    wc, zc, wv, zv, hvbar,
    937                                    xmomc, ymomc, xmomv, ymomv)       
    938     else:
    939         # print 'Using first order h-limiter'
    940         # FIXME: Pass wc in for now - it will be ignored.
    941        
    942         # This is how one would make a first order h_limited value
    943         # as in the old balancer (pre 17 Feb 2005):
    944         #  If we wish to hard wire this, one should modify the C-code
    945         # from Numeric import zeros, Float
    946         # hvbar = zeros( (len(wc), 3), Float)
    947         # for i in range(3):
    948         #     hvbar[:,i] = wc[:] - zc[:]
    949 
    950         balance_deep_and_shallow_c(domain, domain.beta_h,
    951                                    wc, zc, wv, zv, wc,
    952                                    xmomc, ymomc, xmomv, ymomv)
     890    balance_deep_and_shallow_c(domain,
     891                               wc, zc, wv, zv, wc,
     892                               xmomc, ymomc, xmomv, ymomv)
    953893
    954894
  • anuga_core/source/anuga/shallow_water/shallow_water_ext.c

    r5315 r5442  
    538538
    539539int _balance_deep_and_shallow(int N,
    540                               double beta_h,
    541540                              double* wc,
    542541                              double* zc,
     
    623622        alpha = 1.0;
    624623        for (i=0; i<3; i++) {
    625        
    626           // FIXME (Ole): Simplify (remove) when (if) hvbar gets retired
    627           if (beta_h > epsilon) {
    628             hc_k = hvbar[k3+i]; // Depth to be used at vertices
    629           }
    630624         
    631625          h_diff = hc_k - hv[i];         
     
    674668      for (i=0; i<3; i++) {
    675669     
    676         // FIXME (Ole): Simplify when (if) hvbar gets retired       
    677         if (beta_h > epsilon) {   
    678           wv[k3+i] = zv[k3+i] + (1-alpha)*hvbar[k3+i] + alpha*hv[i];
    679         } else {
    680           wv[k3+i] = zv[k3+i] + (1-alpha)*hc_k + alpha*hv[i];   
    681         }
     670        wv[k3+i] = zv[k3+i] + (1-alpha)*hc_k + alpha*hv[i];     
    682671
    683672        // Update momentum at vertices
     
    23322321  // modes.
    23332322  //
    2334   //    balance_deep_and_shallow(beta_h, wc, zc, wv, zv,
     2323  //    balance_deep_and_shallow(wc, zc, wv, zv,
    23352324  //                             xmomc, ymomc, xmomv, ymomv)
    23362325
     
    23502339   
    23512340  double alpha_balance = 2.0;
    2352   double H0, beta_h;
     2341  double H0;
    23532342
    23542343  int N, tight_slope_limiters, use_centroid_velocities; //, err;
    23552344
    23562345  // Convert Python arguments to C
    2357   if (!PyArg_ParseTuple(args, "OdOOOOOOOOO",
     2346  if (!PyArg_ParseTuple(args, "OOOOOOOOOO",
    23582347                        &domain,
    2359                         &beta_h,
    23602348                        &wc, &zc,
    23612349                        &wv, &zv, &hvbar,
     
    24112399  N = wc -> dimensions[0];
    24122400  _balance_deep_and_shallow(N,
    2413                             beta_h,
    24142401                            (double*) wc -> data,
    24152402                            (double*) zc -> data,
     
    24322419
    24332420
    2434 PyObject *h_limiter(PyObject *self, PyObject *args) {
    2435 
    2436   PyObject *domain, *Tmp;
    2437   PyArrayObject
    2438     *hv, *hc, //Depth at vertices and centroids
    2439     *hvbar,   //Limited depth at vertices (return values)
    2440     *neighbours;
    2441 
    2442   int k, i, n, N, k3;
    2443   int dimensions[2];
    2444   double beta_h; // Safety factor (see config.py)
    2445   double *hmin, *hmax, hn;
    2446 
    2447   // Convert Python arguments to C
    2448   if (!PyArg_ParseTuple(args, "OOO", &domain, &hc, &hv)) {
    2449     PyErr_SetString(PyExc_RuntimeError, "shallow_water_ext.c: h_limiter could not parse input arguments");
    2450     return NULL;
    2451   } 
    2452  
    2453   neighbours = get_consecutive_array(domain, "neighbours");
    2454 
    2455   //Get safety factor beta_h
    2456   Tmp = PyObject_GetAttrString(domain, "beta_h");
    2457   if (!Tmp) {
    2458     PyErr_SetString(PyExc_RuntimeError, "shallow_water_ext.c: h_limiter could not obtain object beta_h from domain");
    2459     return NULL;
    2460   } 
    2461   beta_h = PyFloat_AsDouble(Tmp);
    2462 
    2463   Py_DECREF(Tmp);
    2464 
    2465   N = hc -> dimensions[0];
    2466 
    2467   //Create hvbar
    2468   dimensions[0] = N;
    2469   dimensions[1] = 3;
    2470   hvbar = (PyArrayObject *) PyArray_FromDims(2, dimensions, PyArray_DOUBLE);
    2471 
    2472 
    2473   //Find min and max of this and neighbour's centroid values
    2474   hmin = malloc(N * sizeof(double));
    2475   hmax = malloc(N * sizeof(double));
    2476   for (k=0; k<N; k++) {
    2477     k3=k*3;
    2478 
    2479     hmin[k] = ((double*) hc -> data)[k];
    2480     hmax[k] = hmin[k];
    2481 
    2482     for (i=0; i<3; i++) {
    2483       n = ((long*) neighbours -> data)[k3+i];
    2484 
    2485       // Initialise hvbar with values from hv
    2486       ((double*) hvbar -> data)[k3+i] = ((double*) hv -> data)[k3+i];
    2487 
    2488       if (n >= 0) {
    2489         hn = ((double*) hc -> data)[n]; // Neighbour's centroid value
    2490 
    2491         hmin[k] = min(hmin[k], hn);
    2492         hmax[k] = max(hmax[k], hn);
    2493       }
    2494     }
    2495   }
    2496 
    2497   // Call underlying standard routine
    2498   _limit_old(N, beta_h, (double*) hc -> data, (double*) hvbar -> data, hmin, hmax);
    2499 
    2500   // // //Py_DECREF(domain); //FIXME: Necessary?
    2501   free(hmin);
    2502   free(hmax);
    2503 
    2504   // Return result using PyArray to avoid memory leak
    2505   return PyArray_Return(hvbar);
    2506 }
    2507 
    2508 PyObject *h_limiter_sw(PyObject *self, PyObject *args) {
    2509   //a faster version of h_limiter above
    2510   PyObject *domain, *Tmp;
    2511   PyArrayObject
    2512     *hv, *hc, //Depth at vertices and centroids
    2513     *hvbar,   //Limited depth at vertices (return values)
    2514     *neighbours;
    2515 
    2516   int k, i, N, k3,k0,k1,k2;
    2517   int dimensions[2];
    2518   double beta_h; //Safety factor (see config.py)
    2519   double hmin, hmax, dh[3];
    2520 // Convert Python arguments to C
    2521   if (!PyArg_ParseTuple(args, "OOO", &domain, &hc, &hv)) {
    2522     PyErr_SetString(PyExc_RuntimeError, "shallow_water_ext.c: h_limiter_sw could not parse input arguments");
    2523     return NULL;
    2524   } 
    2525   neighbours = get_consecutive_array(domain, "neighbours");
    2526 
    2527   //Get safety factor beta_h
    2528   Tmp = PyObject_GetAttrString(domain, "beta_h");
    2529   if (!Tmp) {
    2530     PyErr_SetString(PyExc_RuntimeError, "shallow_water_ext.c: h_limiter_sw could not obtain object beta_h from domain");
    2531     return NULL;
    2532   } 
    2533   beta_h = PyFloat_AsDouble(Tmp);
    2534 
    2535   Py_DECREF(Tmp);
    2536 
    2537   N = hc -> dimensions[0];
    2538 
    2539   //Create hvbar
    2540   dimensions[0] = N;
    2541   dimensions[1] = 3;
    2542   hvbar = (PyArrayObject *) PyArray_FromDims(2, dimensions, PyArray_DOUBLE);
    2543   for (k=0;k<N;k++){
    2544     k3=k*3;
    2545     //get the ids of the neighbours
    2546     k0 = ((long*) neighbours -> data)[k3];
    2547     k1 = ((long*) neighbours -> data)[k3+1];
    2548     k2 = ((long*) neighbours -> data)[k3+2];
    2549     //set hvbar provisionally
    2550     for (i=0;i<3;i++){
    2551       ((double*) hvbar -> data)[k3+i] = ((double*) hv -> data)[k3+i];
    2552       dh[i]=((double*) hvbar -> data)[k3+i]-((double*) hc -> data)[k];
    2553     }
    2554     hmin=((double*) hc -> data)[k];
    2555     hmax=hmin;
    2556     if (k0>=0){
    2557       hmin=min(hmin,((double*) hc -> data)[k0]);
    2558       hmax=max(hmax,((double*) hc -> data)[k0]);
    2559     }
    2560     if (k1>=0){
    2561       hmin=min(hmin,((double*) hc -> data)[k1]);
    2562       hmax=max(hmax,((double*) hc -> data)[k1]);
    2563     }
    2564     if (k2>=0){
    2565       hmin=min(hmin,((double*) hc -> data)[k2]);
    2566       hmax=max(hmax,((double*) hc -> data)[k2]);
    2567     }
    2568     hmin-=((double*) hc -> data)[k];
    2569     hmax-=((double*) hc -> data)[k];
    2570     limit_gradient(dh,hmin,hmax,beta_h);
    2571     for (i=0;i<3;i++)
    2572       ((double*) hvbar -> data)[k3+i] = ((double*) hc -> data)[k]+dh[i];
    2573   }
    2574   return PyArray_Return(hvbar);
    2575 }
    25762421
    25772422PyObject *assign_windfield_values(PyObject *self, PyObject *args) {
     
    26372482  {"balance_deep_and_shallow", balance_deep_and_shallow,
    26382483   METH_VARARGS, "Print out"},
    2639   {"h_limiter", h_limiter,
    2640    METH_VARARGS, "Print out"},
    2641   {"h_limiter_sw", h_limiter_sw,
    2642    METH_VARARGS, "Print out"},
    26432484  {"protect", protect, METH_VARARGS | METH_KEYWORDS, "Print out"},
    26442485  {"assign_windfield_values", assign_windfield_values,
  • anuga_core/source/anuga/shallow_water/test_data_manager.py

    r5420 r5442  
    562562        self.domain.smooth = False
    563563        self.domain.store = True
    564         self.domain.beta_h = 0
    565564
    566565        self.domain.tight_slope_limiters = True
  • anuga_core/source/anuga/shallow_water/test_shallow_water_domain.py

    r5441 r5442  
    14361436        domain.tight_slope_limiters = 0 # Backwards compatibility (14/4/7)                 
    14371437        domain.H0 = 0 # Backwards compatibility (6/2/7)
    1438         domain.beta_h = 0.0 # Backwards compatibility (14/2/7)
    14391438        domain.use_centroid_velocities = 0 # Backwards compatibility (7/5/8)
    14401439       
     
    14891488        #    print
    14901489
    1491         #Reference (nautilus 26/6/2008) (beta_h == 0)
     1490        #Reference (nautilus 26/6/2008)
    14921491       
    14931492        G0 = [-0.20000000000000001, -0.20000000000000001, -0.19920600846161715, -0.19153647344085376, -0.19127622768281194, -0.1770671909675095, -0.16739412133181927, -0.16196038919122191, -0.15621633053131384, -0.15130021599977705, -0.13930978857215484, -0.19349274358263582, -0.19975307598803765, -0.19999897143103357, -0.1999999995532111, -0.19999999999949952, -0.19999999999949952, -0.19999999999949952, -0.19997270012494556, -0.19925805948554556, -0.19934513778450533, -0.19966484196394893, -0.1997352860102084, -0.19968260481750394, -0.19980280797303882, -0.19998804881822749, -0.19999999778075916, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167, -0.19999999999966167]
     
    27342733        domain.beta_vh     = 0.9
    27352734        domain.beta_vh_dry = 0.9
    2736         domain.beta_h = 0.0 #Use first order in h-limiter
    27372735       
    27382736        # FIXME (Ole): Need tests where this is commented out
     
    32183216        domain.smooth = False
    32193217        domain.default_order = 2
    3220         domain.beta_h = 0.0
    32213218        domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    32223219
     
    32913288        domain.smooth = False
    32923289        domain.default_order=2
    3293         domain.beta_h = 0.0
    32943290
    32953291        #IC
     
    39553951        domain.smooth = False
    39563952        domain.default_order = 1
    3957         domain.beta_h = 0.0 # Use first order in h-limiter
    39583953       
    39593954        # FIXME (Ole): Need tests where these two are commented out
     
    41264121        domain.beta_vh     = 0.9
    41274122        domain.beta_vh_dry = 0.9
    4128         domain.beta_h = 0.0 #Use first order in h-limiter
    41294123       
    41304124        # FIXME (Ole): Need tests where this is commented out
     
    42304224        domain.beta_vh     = 0.9
    42314225        domain.beta_vh_dry = 0.9
    4232         domain.beta_h = 0.0 #Use first order in h-limiter
    42334226       
    42344227        # FIXME (Ole): Need tests where this is commented out
     
    43304323        domain.beta_vh     = 0.9
    43314324        domain.beta_vh_dry = 0.9
    4332         domain.beta_h = 0.0 #Use first order in h-limiter
    43334325       
    43344326       
     
    44704462        domain.beta_vh     = 0.9
    44714463        domain.beta_vh_dry = 0.9
    4472         domain.beta_h = 0.0 #Use first order in h-limiter
    44734464        domain.H0 = 0.001
    44744465        domain.tight_slope_limiters = 1
     
    45974588        domain.beta_vh     = 0.9
    45984589        domain.beta_vh_dry = 0.9
    4599         domain.beta_h = 0.0 #Use first order in h-limiter
    46004590       
    46014591        # FIXME (Ole): Need tests where these two are commented out
     
    55025492        domain.smooth = False
    55035493        domain.store = True
    5504         domain.beta_h = 0
    55055494       
    55065495
  • anuga_validation/automated_validation_tests/okushiri_tank_validation/run_okushiri.py

    r5303 r5442  
    6161    domain.set_quantities_to_be_monitored('stage')
    6262
    63     # New slope limiter and first order h-limiter
    64     # (this in planned to be the default!)
    65     domain.beta_h = 0.0
    66     domain.tight_slope_limiters = True # Run time invariant in this case
    6763    domain.use_centroid_velocities = True
    6864
  • anuga_validation/circular_island/run_circular.py

    r5147 r5442  
    213213#domain.set_maximum_allowed_speed(0.1)     # Allow a little runoff (0.1 is OK)
    214214domain.tight_slope_limiters = 1
    215 domain.beta_h = 0.0
    216215
    217216sww_file=output_dir+sep+model_name+'.sww'
  • anuga_validation/circular_island/sqrt_table_run_circular.py

    r5131 r5442  
    225225domain.set_maximum_allowed_speed(0.1)     # Allow a little runoff (0.1 is OK)
    226226domain.tight_slope_limiters = 1
    227 domain.beta_h = 0.0
    228227sww_file=output_dir+sep+model_name+'.sww'
    229228
  • anuga_validation/convergence_study/dam_break.py

    r5300 r5442  
    7171domain.beta_uh     = 0.6
    7272domain.beta_vh     = 0.6
    73 domain.beta_h    = 0.0
    7473
    7574
  • anuga_validation/convergence_study/tilted.py

    r5180 r5442  
    7474domain.beta_vh     = 0.6
    7575domain.beta_vh_dry = 0.0
    76 domain.beta_h    = 0.0
     76
    7777
    7878interactive_visualisation = True
  • anuga_validation/convergence_study/wave.py

    r5306 r5442  
    7777domain.beta_vh     = 1.0
    7878domain.beta_vh_dry = 0.0
    79 domain.beta_h    = 0.0
    80 
    8179
    8280
  • anuga_validation/okushiri_2005/run_okushiri.py

    r5424 r5442  
    5757domain.set_minimum_storable_height(0.001) # Don't store h < 0.001m
    5858domain.tight_slope_limiters = True
    59 domain.beta_h = 0.0
    6059
    6160#Timings on AMD64-242 (beta_h=0)
  • anuga_validation/performance_tests/okushiri/run_okushiri_profile.py

    r4768 r5442  
    6060#domain.set_quantities_to_be_stored(None)
    6161
    62 # New slope limiter and first order h-limiter
    63 # (this in planned to be the default!)
    64 domain.beta_h = 0.0
    65 domain.tight_slope_limiters = 1 # Run time invariant in this case
    6662
    6763#-------------------------
  • anuga_work/development/MISG_2008/sensitivity_study.py

    r5245 r5442  
    4949domain.set_name('sensitivity')              # Output to file runup.sww
    5050domain.set_datadir('.')                     # Use current directory for output
    51 domain.tight_slope_limiters = 1
    52 domain.beta_h = 0
    5351domain.set_minimum_storable_height(0.01)
    5452
  • anuga_work/development/Rudy_vandrie_2007/run_example.py

    r4631 r5442  
    5656domain.set_all_limiters(0.9)              # Max second order scheme (old lim)
    5757domain.set_minimum_storable_height(0.001) # Don't store w < 0.001m
    58 domain.set_maximum_allowed_speed(0.1)     # Allow a little runoff (0.1 is OK)
    5958
    60 # New slope limiter and first order h-limiter
    61 # (this in planned to be the default!)
    62 domain.beta_h = 0.0
    63 domain.tight_slope_limiters = 0
    6459
    6560#-------------------------
  • anuga_work/development/Rudy_vandrie_2007/run_hydro_example.py

    r4631 r5442  
    3030domain.set_name('hydro_example')                  # Output name
    3131domain.set_minimum_storable_height(0.0001)
    32 domain.beta_h = 0.0
    33 domain.tight_slope_limiters = 1
     32
    3433
    3534
  • anuga_work/development/attenuation_near_shore/run_beach.py

    r5155 r5442  
    143143    # comment out aserts in shallow_water/shallow_water_domain.py", line 402
    144144    # if you want to use these values
    145     #domain.beta_h      = 1.5
    146145    #domain.beta_w      = 1.5
    147146    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
  • anuga_work/development/attenuation_near_shore/run_beach_structured.py

    r5176 r5442  
    149149    domain.beta_uh     = 0.6
    150150    domain.beta_vh     = 0.6
    151     domain.beta_h      = 0.0
    152 
    153151
    154152    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
  • anuga_work/development/boxingday08/run_boxingday.py

    r5247 r5442  
    146146domain.set_minimum_storable_height(0.01)
    147147
    148 domain.beta_h = 0
    149148domain.tight_slope_limiters = 1
    150149domain.set_default_order(2)
  • anuga_work/development/boxingday08/run_boxingday_most.py

    r5404 r5442  
    133133domain.set_minimum_storable_height(0.01)
    134134
    135 domain.beta_h = 0
    136135domain.tight_slope_limiters = 1
    137136domain.set_default_order(2)
  • anuga_work/development/boxingday08/run_boxingday_polyline.py

    r5401 r5442  
    135135domain.set_minimum_storable_height(0.01)
    136136
    137 domain.beta_h = 0
    138137domain.tight_slope_limiters = 1
    139138domain.set_default_order(2)
  • anuga_work/development/boxingday08/run_boxingday_urs.py

    r5401 r5442  
    135135domain.set_minimum_storable_height(0.01)
    136136
    137 domain.beta_h = 0
    138137domain.tight_slope_limiters = 1
    139138domain.set_default_order(2)
  • anuga_work/development/cocos/grid_data.py

    r4993 r5442  
    142142domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    143143#    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    144 domain.beta_h = 0
    145144Br = Reflective_boundary(domain)
    146145
  • anuga_work/development/continental_margin_0708/con_900.py

    r5066 r5442  
    103103            domain.set_quantity('friction', 0)         # Constant friction   
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105             domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
     105            domain.tight_slope_limiters = True
     106
    107107
    108108            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/curved_down_slope.py

    r5066 r5442  
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105105            domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
    107106
    108107
  • anuga_work/development/continental_margin_0708/curved_down_slope_large.py

    r5066 r5442  
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105105            domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
    107106
    108107
  • anuga_work/development/continental_margin_0708/curved_linear.py

    r5066 r5442  
    101101            domain.set_quantity('stage', 0)            # Constant negative initial stage
    102102            domain.tight_slope_limiters = 1
    103             domain.beta_h = 0
    104103
    105104
  • anuga_work/development/continental_margin_0708/curved_up_slope.py

    r5066 r5442  
    102102            domain.set_quantity('stage', 0)            # Constant negative initial stage
    103103            domain.tight_slope_limiters = 1
    104             domain.beta_h = 0
    105104
    106105            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/curved_up_slope_large.py

    r5066 r5442  
    7474            domain.set_datadir(output_dir) 
    7575            domain.tight_slope_limiters = 1
    76             domain.beta_h = 0
    7776
    7877
  • anuga_work/development/continental_margin_0708/friction_0.02.py

    r5066 r5442  
    103103            domain.set_quantity('friction', 0.02)         # Constant friction   
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105             domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
     105            domain.tight_slope_limiters = True
    107106
    108107            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/gettimeseriesfrict.py

    r5066 r5442  
    103103            domain.set_quantity('stage', 0)            # Constant negative initial stage
    104104            domain.tight_slope_limiters = 1
    105             domain.beta_h = 0
     105
    106106            #------------------------------------------------------------------------------
    107107            # Setup boundary conditions
  • anuga_work/development/continental_margin_0708/linear.py

    r5066 r5442  
    9999            domain.set_quantity('stage', 0)            # Constant negative initial stage
    100100            domain.tight_slope_limiters = 1
    101             domain.beta_h = 0
    102101
    103102
  • anuga_work/development/continental_margin_0708/linear_curved.py

    r5066 r5442  
    102102            domain.set_quantity('stage', 0)            # Constant negative initial stage
    103103            domain.tight_slope_limiters = 1
    104             domain.beta_h = 0
    105104
    106105
  • anuga_work/development/continental_margin_0708/linear_slope.py

    r5066 r5442  
    103103            domain.set_quantity('stage', 0)            # Constant negative initial stage
    104104            domain.tight_slope_limiters = 1
    105             domain.beta_h = 0
    106105
    107106            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/linear_slope_large.py

    r5066 r5442  
    103103            domain.set_quantity('stage', 0)            # Constant negative initial stage
    104104            domain.tight_slope_limiters = 1
    105             domain.beta_h = 0
    106105
    107106
  • anuga_work/development/continental_margin_0708/mesh_80000_curved_down_slope.py

    r5066 r5442  
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105105            domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
    107106
    108107
  • anuga_work/development/continental_margin_0708/neg_con_900.py

    r5066 r5442  
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105105            domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
    107106
    108107            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/sin_wave_900.py

    r5066 r5442  
    104104            domain.set_quantity('stage', 0)            # Constant negative initial stage
    105105            domain.tight_slope_limiters = 1
    106             domain.beta_h = 0
    107106
    108107            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/sol_900.py

    r5066 r5442  
    103103            domain.set_quantity('stage', 0)            # Constant negative initial stage
    104104            domain.tight_slope_limiters = 1
    105             domain.beta_h = 0
     105
    106106
    107107            #------------------------------------------------------------------------------
  • anuga_work/development/continental_margin_0708/timeseriessol.py

    r5066 r5442  
    102102            domain.set_quantity('friction', 0)         # Constant friction   
    103103            domain.set_quantity('stage', 0)            # Constant negative initial stage
    104             domain.tight_slope_limiters = 1
    105             domain.beta_h = 0
     104            domain.tight_slope_limiters = True
     105
    106106            #------------------------------------------------------------------------------
    107107            # Setup boundary conditions
  • anuga_work/development/continental_margin_0708/wave_value_tester_900.py

    r5066 r5442  
    103103            domain.set_quantity('stage', 0)            # Constant negative initial stage
    104104            domain.tight_slope_limiters = 1
    105             domain.beta_h = 0
    106105
    107106            #------------------------------------------------------------------------------
  • anuga_work/development/convergence_okushiri_2008/run_okushiri_truescale.py

    r5411 r5442  
    103103domain.set_all_limiters(0.9)              # Max second order scheme (old lim)
    104104domain.set_minimum_storable_height(0.1)   # Don't store h < 0.1m
    105 domain.tight_slope_limiters = 1
    106 domain.beta_h = 0.0
    107105
    108106
  • anuga_work/development/dam_test_from_brad_2007/dam_sample.py

    r4631 r5442  
    2929domain.set_name('dam_sample')                 # Output name
    3030#domain.set_store_vertices_uniquely(True)      # Look at the 'real' triangles
    31 domain.beta_h = 0.0
    32 domain.tight_slope_limiters = 1
    3331domain.set_minimum_allowed_height(0.01)
    3432
  • anuga_work/development/demos/island.py

    r5440 r5442  
    6161print domain.statistics()
    6262
    63 #I tried to introduce this parameter top control the h-limiter,
    64 #but it doesn't remove the 'lapping water'
    65 #NEW (ON): I think it has been fixed (or at least reduced significantly) now
    66 #
    67 # beta_h == 1.0 means that the largest gradients (on h) are allowed
    68 # beta_h == 0.0 means that constant (1st order) gradients are introduced
    69 # on h. This is equivalent to the constant depth used previously.
    70 #domain.beta_h     = 0.5
    71 #domain.beta_w_dry = 0.0
    72 #domain.alpha_balance = 10.0
    73 #domain.minimum_allowed_height = 1.0e-4
    74 #domain.maximum_allowed_speed = 0
    75 #domain.minimum_storable_height = 1.0e-4
    76 
    77 #------------------------
    78 # Combinations with creep
    79 #------------------------
    80 
    81 #domain.maximum_allowed_speed = 0
    82 #domain.beta_h = 0.0
    83 #domain.tight_slope_limiters = 0
    84 
    85 #domain.maximum_allowed_speed = 0
    86 #domain.beta_h = 0.0
    87 #domain.H0 = 0.01
    88 #domain.tight_slope_limiters = 1
    8963
    9064#---------------------------
     
    9266#---------------------------
    9367
    94 #domain.maximum_allowed_speed = 1
    95 #domain.beta_h = 0.0
    96 #domain.tight_slope_limiters = 0
    97 
    9868domain.maximum_allowed_speed = 0
    99 domain.beta_h = 0.0
    10069domain.tight_slope_limiters = True
    10170
  • anuga_work/development/near_shore_PMD/run_beach.py

    r5236 r5442  
    171171    domain.beta_uh     = 0.6
    172172    domain.beta_vh     = 0.6
    173     domain.beta_h      = 0.0
    174173
    175174    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
  • anuga_work/development/reef_0708/Flatgap_10000.py

    r5066 r5442  
    137137            domain.set_quantity('stage', 0.)            # Constant negative initial stage
    138138            domain.tight_slope_limiters = 1
    139             domain.beta_h = 0
    140139
    141140
  • anuga_work/development/reef_0708/gradual_lgflat.py

    r5066 r5442  
    118118            domain.set_quantity('stage', 0.)            # Constant negative initial stage
    119119            domain.tight_slope_limiters = 1
    120             domain.beta_h = 0
    121120
    122121            #------------------------------------------------------------------------------
  • anuga_work/development/reef_0708/transect_gap_1000.py

    r5066 r5442  
    137137            domain.set_quantity('stage', 0.)            # Constant negative initial stage
    138138            domain.tight_slope_limiters = 1
    139             domain.beta_h = 0
    140139
    141140
  • anuga_work/development/solitary_waves/solitary_wave_runup.py

    r4678 r5442  
    8686#domain.set_minimum_storable_height(0.01)
    8787#domain.set_minimum_allowed_height(0.01)
    88 domain.beta_h = 0.0
    89 domain.tight_slope_limiters = 1
    9088domain.set_name(simulation_name)
    9189
  • anuga_work/production/FSM/run_kolonia.py

    r5205 r5442  
    159159    #domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    160160    print 'domain id', id(domain)
    161     domain.beta_h = 0
    162161
    163162    #------------------------------------------------------------------------------
  • anuga_work/production/broome/run_broome_urs.py

    r5001 r5442  
    173173    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    174174    print 'domain id', id(domain)
    175     domain.beta_h = 0
    176     #domain.tight_slope_limiters = 1
    177175
    178176    #-------------------------------------------------------------------------
  • anuga_work/production/busselton/run_busselton.py

    r5415 r5442  
    160160    #domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    161161    print 'domain id', id(domain)
    162     domain.beta_h = 0
    163162
    164163    #-------------------------------------------------------------------------
  • anuga_work/production/carnarvon/run_carnarvon.py

    r5005 r5442  
    159159    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    160160    print 'domain id', id(domain)
    161     domain.beta_h = 0
    162     #domain.tight_slope_limiters = 1
     161
    163162
    164163    #-------------------------------------------------------------------------
  • anuga_work/production/dampier_2006/run_dampier.py

    r4631 r5442  
    159159domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    160160print 'domain id', id(domain)
    161 domain.beta_h = 0
    162 #domain.tight_slope_limiters = 1
    163161
    164162#-------------------------------------------------------------------------
  • anuga_work/production/dampier_2006/run_dampier_simple.py

    r4631 r5442  
    232232domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    233233print 'domain id', id(domain)
    234 domain.beta_h = 0
    235 domain.tight_slope_limiters = 1
    236234'''
    237235#-------------------------------------------------------------------------
  • anuga_work/production/dampier_2006/run_dampier_urs.py

    r4631 r5442  
    168168    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    169169    print 'domain id', id(domain)
    170     domain.beta_h = 0
    171     #domain.tight_slope_limiters = 1
     170
    172171
    173172    #-------------------------------------------------------------------------
  • anuga_work/production/exmouth_2006/run_exmouth.py

    r5408 r5442  
    167167    #domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    168168    #print 'domain id', id(domain)
    169     domain.beta_h = 0 #sets the surface of the triangle to follow the bathy
     169
    170170    #domain.H0=0.01 #controls the flux limiter (limiter2007)
    171171    domain.tight_slope_limiters = 0 #minimises creep
  • anuga_work/production/galle_2007/run_gal5.py

    r4547 r5442  
    7878domain.set_store_vertices_uniquely(False)
    7979domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    80 domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    81 domain.beta_h = 0 # Use first order near bathymetry (faster)
     80
    8281
    8382#------------------------------------------------------------------------------
  • anuga_work/production/geraldton/run_geraldton.py

    r5150 r5442  
    157157    domain.set_store_vertices_uniquely(False)
    158158    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    159     domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    160159    print 'domain id', id(domain)
    161     domain.beta_h = 0
    162     #domain.tight_slope_limiters = 1
     160
    163161
    164162    #-------------------------------------------------------------------------
  • anuga_work/production/onslow_2006/run_onslow_grad.py

    r5381 r5442  
    172172    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    173173    print 'domain id', id(domain)
    174     domain.beta_h = 0
     174
    175175    domain.tight_slope_limiters = 0
    176176   
  • anuga_work/production/onslow_2006/run_onslow_urs.py

    r5151 r5442  
    167167    domain.set_store_vertices_uniquely(False)
    168168    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    169 #    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    170     domain.beta_h = 0 #sets the surface of the triangle to follow the bathy
    171     #domain.H0=0.01 #controls the flux limiter (limiter2007)
    172     #domain.tight_slope_limiters = 1 #minimises creep
     169
    173170
    174171    #-------------------------------------------------------------------------
  • anuga_work/production/onslow_2006/ticket160_run.py

    r4631 r5442  
    181181    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    182182    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    183     domain.beta_h = 0
    184     domain.tight_slope_limiters = 1
    185183    domain.H0=0.01
    186184
  • anuga_work/production/perth/run_perth.py

    r5415 r5442  
    158158    #domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    159159    print 'domain id', id(domain)
    160     domain.beta_h = 0
     160
    161161
    162162    #-------------------------------------------------------------------------
  • anuga_work/production/pt_hedland_2006/run_pt_hedland_urs.py

    r4943 r5442  
    159159    domain.set_store_vertices_uniquely(False)
    160160    domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    161     domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    162     domain.beta_h = 0 #sets the surface of the triangle to follow the bathy
    163     #domain.H0=0.01 #controls the flux limiter (limiter2007)
    164     domain.tight_slope_limiters = 1 #minimises creep
     161
    165162
    166163    #-------------------------------------------------------------------------
  • anuga_work/production/shark_bay_2007/run_shark_bay.py

    r4689 r5442  
    169169    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    170170    print 'domain id', id(domain)
    171     domain.beta_h = 0
    172     #domain.tight_slope_limiters = 1
    173171   
    174172
  • anuga_work/production/shark_bay_2007/run_shark_bay_embayment_study.py

    r4885 r5442  
    118118domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    119119
    120 domain.beta_h = 0
    121 domain.tight_slope_limiters = 1
     120domain.tight_slope_limiters = True
    122121   
    123122
  • anuga_work/production/shark_bay_2007/run_shark_bay_frequency_sweep.py

    r4884 r5442  
    162162    domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    163163    print 'domain id', id(domain)
    164     domain.beta_h = 0
    165     domain.tight_slope_limiters = 1
     164    domain.tight_slope_limiters = True
    166165   
    167166
  • anuga_work/production/tonga/run_fangauta.py

    r5212 r5442  
    160160    #domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    161161    print 'domain id', id(domain)
    162     domain.beta_h = 0
    163162
    164163     
  • anuga_work/production/tonga/tongatapu.py

    r5194 r5442  
    159159    #domain.set_maximum_allowed_speed(0.1) # Allow a little runoff (0.1 is OK)
    160160    print 'domain id', id(domain)
    161     domain.beta_h = 0
     161
    162162
    163163    #------------------------------------------------------------------------------
  • anuga_work/production/west_tas_2008/run_west_tas_smf.py

    r5245 r5442  
    118118domain.set_quantities_to_be_stored(['stage', 'xmomentum', 'ymomentum'])
    119119domain.set_minimum_storable_height(0.01)
    120 domain.beta_h = 0
    121 domain.tight_slope_limiters = 1
    122120domain.set_store_vertices_uniquely(False)
    123 domain.set_maximum_allowed_speed(0.1)
     121
    124122
    125123#-------------------------------------------------------------------------------                                 
Note: See TracChangeset for help on using the changeset viewer.