tsphere now only reports to stdout at a certain time step intervals - sphere - GPU-based 3D discrete element method algorithm with optional fluid coupling
 (HTM) git clone git://src.adamsgaard.dk/sphere
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) LICENSE
       ---
 (DIR) commit 7e87969a61a5a8ce5f636d5d777a33e6cefed427
 (DIR) parent 95180945f0ef9f2bf1ad44f25f43ef7fec95c52d
 (HTM) Author: Anders Damsgaard <anders.damsgaard@geo.au.dk>
       Date:   Wed, 21 Aug 2013 15:37:02 +0200
       
       sphere now only reports to stdout at a certain time step intervals
       
       Diffstat:
         M src/device.cu                       |      10 ++++++++--
       
       1 file changed, 8 insertions(+), 2 deletions(-)
       ---
 (DIR) diff --git a/src/device.cu b/src/device.cu
       t@@ -620,6 +620,8 @@ __host__ void DEM::startTime()
            // Initialize counter variable values
            filetimeclock = 0.0;
            long iter = 0;
       +    int stdout_report = 100; // the no of time steps between reporting to stdout
       +    int stdout_report_counter = stdout_report;
        
            // Create first status.dat
            //sprintf(file,"output/%s.status.dat", sid);
       t@@ -951,8 +953,12 @@ __host__ void DEM::startTime()
        
                // Report time to console
                if (verbose == 1) {
       -            cout << "\r  Current simulation time: " 
       -                << time.current << " s.        ";// << std::flush;
       +            stdout_report_counter--;
       +            if (stdout_report < 0) {
       +                cout << "\r  Current simulation time: " 
       +                    << time.current << " s.        ";// << std::flush;
       +                stdout_report_counter = stdout_report;
       +            }
                }