#include "Collect_potential.h"

#include "Model.h"
#include "Model_kit.h"
#include "Path.h"

namespace MM
{

Collect_potential::
Collect_potential (Atom_group & atom_group, Text in)
:
    Collect_scalar (atom_group, in)
{
//    new_graph_presentation ("Potential");
    new_file_presentation (Path::report() +"dyn_Potential.xls");
}

Monitor * Collect_potential::
clone (Atom_group & atom_group, Text const & /*args*/, Text in) const
{
    return new Collect_potential (atom_group, in);
}

double Collect_potential::
extract_current_value ()
{
    return dynamic_cast <Model &> (atom_group()).kit().
        interaction ().potential ();
}

}//MM

