示例#1
0
 void DataStorage::storeFunction(
     const fsi::vector & f,
     int substep
     )
 {
     assert( f.rows() == F.cols() );
     assert( substep <= F.rows() );
     assert( not std::isnan( f.norm() ) );
     F.row( substep ) = f;
 }
示例#2
0
 void DataStorage::storeSolution(
     const fsi::vector & sol,
     int substep
     )
 {
     assert( sol.rows() == solStages.cols() );
     assert( substep <= solStages.rows() );
     assert( not std::isnan( sol.norm() ) );
     solStages.row( substep ) = sol;
 }
示例#3
0
    virtual bool isConvergence(
        const fsi::vector & x,
        const fsi::vector & xprev
        )
    {
        iter++;

        allConverged_ = false;

        if ( (x - xprev).norm() < tol * x.norm() )
            allConverged_ = true;

        return allConverged_;
    }