amr-wind/utilities/diagnostics.cpp
//
// Print maximum values (useful for tracking evolution)
//
Print maximum values (useful for tracking evolution)
Print maximum values ( useful for tracking evolution )
void incflo::PrintMaxValues(const std::string& header)
{
    BL_PROFILE("amr-wind::incflo::PrintMaxValues");
    amrex::Print() << "\nL-inf norm summary: " << header << std::endl
                   << "........................................................"
                      "......................";
    for (int lev = 0; lev <= finest_level; lev++) {
        amrex::Print() << "\nLevel " << lev << std::endl;
        auto& vel = icns().fields().field;
        amrex::Print() << "  " << std::setw(16) << std::left << vel.name();
        for (int i = 0; i < vel.num_comp(); ++i)
            amrex::Print() << std::setw(20) << std::right << vel(lev).norm0(i);
        amrex::Print() << std::endl;
        auto& gradp = grad_p();
        amrex::Print() << "  " << std::setw(16) << std::left << gradp.name();
        for (int i = 0; i < gradp.num_comp(); ++i)
            amrex::Print() << std::setw(20) << std::right
                           << gradp(lev).norm0(i);
        amrex::Print() << std::endl;
        for (auto& eqn : scalar_eqns()) {
            auto& field = eqn->fields().field;
            amrex::Print() << "  " << std::setw(16) << std::left
                           << field.name();
            for (int i = 0; i < field.num_comp(); ++i)
                amrex::Print()
                    << std::setw(20) << std::right << field(lev).norm0(i);
            amrex::Print() << std::endl;
        }
    }
    amrex::Print() << "........................................................"
                      "......................"
                   << std::endl
                   << std::endl;
}
void incflo :: PrintMaxValues ( const std :: string & header ) { BL_PROFILE ( " " ) ; amrex :: Print ( ) << " \n " << header << std :: endl << " " " " ; for ( int lev = 0 ; lev <= finest_level ; lev ++ ) { amrex :: Print ( ) << " \n " << lev << std :: endl ; auto & vel = icns ( ) . fields ( ) . field ; amrex :: Print ( ) << " " << std :: setw ( 16 ) << std :: left << vel . name ( ) ; for ( int i = 0 ; i < vel . num_comp ( ) ; ++ i ) amrex :: Print ( ) << std :: setw ( 20 ) << std :: right << vel ( lev ) . norm0 ( i ) ; amrex :: Print ( ) << std :: endl ; auto & gradp = grad_p ( ) ; amrex :: Print ( ) << " " << std :: setw ( 16 ) << std :: left << gradp . name ( ) ; for ( int i = 0 ; i < gradp . num_comp ( ) ; ++ i ) amrex :: Print ( ) << std :: setw ( 20 ) << std :: right << gradp ( lev ) . norm0 ( i ) ; amrex :: Print ( ) << std :: endl ; for ( auto & eqn : scalar_eqns ( ) ) { auto & field = eqn -> fields ( ) . field ; amrex :: Print ( ) << " " << std :: setw ( 16 ) << std :: left << field . name ( ) ; for ( int i = 0 ; i < field . num_comp ( ) ; ++ i ) amrex :: Print ( ) << std :: setw ( 20 ) << std :: right << field ( lev ) . norm0 ( i ) ; amrex :: Print ( ) << std :: endl ; } } amrex :: Print ( ) << " " " " << std :: endl << std :: endl ; }
Print maximum values (useful for tracking evolution)
Print maximum values ( useful for tracking evolution )