src/sim/sim_lmp.c
int lmp_execute(sim_lmp_t * obj) {
  
  int ifail = 0;

  int64_t step;
  double dt;

  lammps_command(obj->lmp, obj->run_command);

  step = *((int64_t *) lammps_extract_global(obj->lmp, "ntimestep"));
  dt = *((double *) lammps_extract_global(obj->lmp, "dt"));

  obj->time = dt*step;

  return ifail;
}
/*****************************************************************************
 *
 *  lmp_execute
 *
 *  We have added "ntimestep" to those variables which may be
 *  accessed via lammps_extract_global() in library.cpp to allow
 *  us to compute the current time.
 *
 *  Note that the default situation for LAMMPS is that the time step
 *  is of type "bigint" which is int64_t (LAMMPS_SMALLBIG in lmptype.h).
 *
 *  We use int64_t here as well to compute the time n*dt
 *
 *****************************************************************************/
lmp_execute
We have added "ntimestep" to those variables which may be
accessed via lammps_extract_global() in library.cpp to allow
us to compute the current time.

Note that the default situation for LAMMPS is that the time step
is of type "bigint" which is int64_t (LAMMPS_SMALLBIG in lmptype.h).

We use int64_t here as well to compute the time n*dt
lmp_execute We have added " ntimestep " to those variables which may be accessed via lammps_extract_global () in library . cpp to allow us to compute the current time . Note that the default situation for LAMMPS is that the time step is of type " bigint " which is int64_t ( LAMMPS_SMALLBIG in lmptype . h ) . We use int64_t here as well to compute the time n * dt
int lmp_execute(sim_lmp_t * obj) {
  int ifail = 0;
  int64_t step;
  double dt;
  lammps_command(obj->lmp, obj->run_command);
  step = *((int64_t *) lammps_extract_global(obj->lmp, "ntimestep"));
  dt = *((double *) lammps_extract_global(obj->lmp, "dt"));
  obj->time = dt*step;
  return ifail;
}
int lmp_execute ( sim_lmp_t * obj ) { int ifail = 0 ; int64_t step ; double dt ; lammps_command ( obj -> lmp , obj -> run_command ) ; step = * ( ( int64_t * ) lammps_extract_global ( obj -> lmp , " " ) ) ; dt = * ( ( double * ) lammps_extract_global ( obj -> lmp , " " ) ) ; obj -> time = dt * step ; return ifail ; }
lmp_execute
  We have added "ntimestep" to those variables which may be
  accessed via lammps_extract_global() in library.cpp to allow
  us to compute the current time.
lmp_execute We have added " ntimestep " to those variables which may be accessed via lammps_extract_global () in library . cpp to allow us to compute the current time .