Changeset 7097
- Timestamp:
- May 27, 2009, 12:57:54 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/anuga/shallow_water/shallow_water_ext.c
r7034 r7097 27 27 28 28 // Computational function for rotation 29 // FIXME: Perhaps inline this and profile 29 // Tried to inline, but no speedup was achieved 27th May 2009 (Ole) 30 // static inline int _rotate(double *q, double n1, double n2) { 30 31 int _rotate(double *q, double n1, double n2) { 31 32 /*Rotate the momentum component q (q[1], q[2]) … … 168 169 // This is used by flux functions 169 170 // Input parameters uh and h may be modified by this function. 170 171 // FIXME: Perhaps inline this and profile171 // Tried to inline, but no speedup was achieved 27th May 2009 (Ole) 172 //static inline double _compute_speed(double *uh, 172 173 double _compute_speed(double *uh, 173 174 175 174 double *h, 175 double epsilon, 176 double h0) { 176 177 177 178 double u; … … 280 281 double h0 = H0*H0; // This ensures a good balance when h approaches H0. 281 282 // But evidence suggests that h0 can be as little as 282 // epsilon!283 // epsilon! 283 284 284 285 // Copy conserved quantities to protect from modification … … 295 296 296 297 z = 0.5*(z_left + z_right); // Average elevation values. 297 // Even though this will nominally allow for discontinuities 298 // in the elevation data, there is currently no numerical 299 // support for this so results may be strange near jumps in the bed. 298 // Even though this will nominally allow 299 // for discontinuities in the elevation data, 300 // there is currently no numerical support for 301 // this so results may be strange near 302 // jumps in the bed. 300 303 301 304 // Compute speeds in x-direction
Note: See TracChangeset
for help on using the changeset viewer.