first attempt to port fix halt to minimizations
This commit is contained in:
@ -135,8 +135,7 @@ files"_restart.html. None of the "fix_modify"_fix_modify.html options
|
|||||||
are relevant to this fix. No global or per-atom quantities are stored
|
are relevant to this fix. No global or per-atom quantities are stored
|
||||||
by this fix for access by various "output commands"_Howto_output.html.
|
by this fix for access by various "output commands"_Howto_output.html.
|
||||||
No parameter of this fix can be used with the {start/stop} keywords of
|
No parameter of this fix can be used with the {start/stop} keywords of
|
||||||
the "run"_run.html command. This fix is not invoked during "energy
|
the "run"_run.html command.
|
||||||
minimization"_minimize.html.
|
|
||||||
|
|
||||||
[Restrictions:] none
|
[Restrictions:] none
|
||||||
|
|
||||||
|
|||||||
@ -143,6 +143,13 @@ void FixHalt::init()
|
|||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
void FixHalt::min_step(double, double *)
|
||||||
|
{
|
||||||
|
if ((update->ntimestep % nevery) == 0) end_of_step();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
void FixHalt::end_of_step()
|
void FixHalt::end_of_step()
|
||||||
{
|
{
|
||||||
// variable evaluation may invoke computes so wrap with clear/add
|
// variable evaluation may invoke computes so wrap with clear/add
|
||||||
|
|||||||
@ -32,6 +32,7 @@ class FixHalt : public Fix {
|
|||||||
int setmask();
|
int setmask();
|
||||||
void init();
|
void init();
|
||||||
void end_of_step();
|
void end_of_step();
|
||||||
|
void min_step(double, double *);
|
||||||
void post_run();
|
void post_run();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|||||||
Reference in New Issue
Block a user