git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@9227 f3b2605a-c512-4ea7-a41b-209d697bcdaa

This commit is contained in:
sjplimp
2013-01-04 17:58:46 +00:00
parent fe5de26b23
commit 9b87f88124
8 changed files with 12 additions and 12 deletions

View File

@ -11,7 +11,7 @@ CCFLAGS = -g -O -DMPICH_IGNORE_CXX_SEEK -I../library
DEPFLAGS = -M
LINK = g++
LINKFLAGS = -g -O -L../library -L${LAMMPS}/src
USRLIB = -lcouple -llmp_g++
USRLIB = -lcouple -llammps_g++
SYSLIB = -lfftw -lmpich -lpthread
ARCHIVE = ar
ARFLAGS = -rc

View File

@ -14,7 +14,7 @@ qstexe.h contains full pathname to Quest executable
After editing the Makefile, lmppath.h, and qstexe.h to make them
suitable for your box, type:
g++ -f Makefile.g++
make -f Makefile.g++
and you should get the lmpqst executable.

View File

@ -14,7 +14,7 @@ mass 1 28.08
velocity all create 300.0 87293 loop geom
fix 1 all nve
fix 2 all external
fix 2 all external pf/callback 1 1
dump 1 all custom 1 dump.md id type x y z fx fy fz
thermo 1

View File

@ -10,6 +10,7 @@
#include "stdio.h"
#include "stdlib.h"
#include "string.h"
#include "stdint.h"
#include "many2one.h"
#include "one2many.h"
@ -35,7 +36,7 @@ using namespace LAMMPS_NS;
#define ANGSTROM_per_BOHR 0.529
#define EV_per_RYDBERG 13.6056923
void quest_callback(void *, int, int, int *, double **, double **);
void quest_callback(void *, bigint, int, int *, double **, double **);
struct Info {
int me;
@ -92,6 +93,7 @@ int main(int narg, char **arg)
info.quest_input = quest_input;
// set callback to Quest inside fix external
// this could also be done thru Python, using a ctypes callback
int ifix = lmp->modify->find_fix("2");
FixExternal *fix = (FixExternal *) lmp->modify->fix[ifix];
@ -122,8 +124,8 @@ int main(int narg, char **arg)
f can be NULL if proc owns no atoms
------------------------------------------------------------------------- */
void quest_callback(void *ptr, int ntimestep, int nlocal,
int *id, double **x, double **f)
void quest_callback(void *ptr, bigint ntimestep,
int nlocal, int *id, double **x, double **f)
{
int i,j;
char str[128];

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -200,4 +200,3 @@ void FixExternal::set_callback(FnPtr caller_callback, void *caller_ptr)
callback = caller_callback;
ptr_caller = caller_ptr;
}

View File

@ -48,7 +48,6 @@ class FixExternal : public Fix {
int mode,ncall,napply;
FnPtr callback;
void *ptr_caller;
int nmax;
double **fexternal;
};