double cutoff; /* cutoff radius */
double cutoff_square; /* square of the cutoff radius */
+ double nnd; /* nearest neighbour distance (optional) */
- t_linkcell lc; /* linked cell method */
+ t_linkcell lc; /* linked cell list interface */
double t; /* temperature */
int mfd; /* fd for momentum log */
unsigned int vwrite; /* how often to visualize atom information */
char vfb[64]; /* visualization file name base */
- void *visual; /* pointer (hack!) */
+ //void *visual; /* pointer (hack!) */
unsigned int swrite; /* how often to create a save file */
char sfb[64]; /* visualization file name base */
t_random random; /* random interface */
} t_moldyn;
-#define MOLDYN_LVSTAT_TOTAL_E 0x01
-#define MOLDYN_LVSTAT_TOTAL_M 0x02
-#define MOLDYN_LVSTAT_SAVE 0x04
-#define MOLDYN_LVSTAT_VISUAL 0x08
-#define MOLDYN_LVSTAT_INITIALIZED 0x10
-
#define MOLDYN_STAT_PBX 0x08 /* periodic boudaries in x */
#define MOLDYN_STAT_PBY 0x10 /* y */
#define MOLDYN_STAT_PBZ 0x20 /* and z direction */
-#define MOLDYN_1BP 0x00
-#define MOLDYN_2BP 0x01
-#define MOLDYN_3BP 0x02
+#define MOLDYN_1BP 0x00 /* care about single */
+#define MOLDYN_2BP 0x01 /* 2 body */
+#define MOLDYN_3BP 0x02 /* and 3 body particle pots */
+
+#define VSCALE_INIT_EQUI 0x00 /* initial, eq positions */
+#define VSCALE_BERENDSEN 0x01 /* berendsen control */
/*
#define MOLDYN_CUTOFF 1.0e-9
#define MOLDYN_RUNS 1000000
+#define MOLDYN_CRITICAL_EST_TEMP 5.0
+
#define MOLDYN_INTEGRATE_VERLET 0x00
#define MOLDYN_INTEGRATE_DEFAULT MOLDYN_INTEGRATE_VERLET
int set_cutoff(t_moldyn *moldyn,double cutoff);
int set_temperature(t_moldyn *moldyn,double t);
int set_dim(t_moldyn *moldyn,double x,double y,double z,u8 visualize);
+int set_nn_dist(t_moldyn *moldyn,double dist);
int set_pbc(t_moldyn *moldyn,u8 x,u8 y,u8 z);
int set_potential1b(t_moldyn *moldyn,pf_func1b func,void *params);
int set_potential2b(t_moldyn *moldyn,pf_func2b func,void *params);
int create_lattice(t_moldyn *moldyn,u8 type,double lc,int element,double mass,
u8 attr,u8 bnum,int a,int b,int c);
int add_atom(t_moldyn *moldyn,int element,double mass,u8 bnum,u8 attr,
- t_3dvec r,t_3dvec v);
+ t_3dvec *r,t_3dvec *v);
int destroy_atoms(t_moldyn *moldyn);
int thermal_init(t_moldyn *moldyn);
-int scale_velocity(t_moldyn *moldyn);
+int scale_velocity(t_moldyn *moldyn,u8 type);
double get_e_kin(t_moldyn *moldyn);
double get_e_pot(t_moldyn *moldyn);
double get_total_energy(t_moldyn *moldyn);
t_3dvec get_total_p(t_moldyn *moldyn);
-double estimate_time_step(t_moldyn *moldyn,double nn_dist,double t);
+double estimate_time_step(t_moldyn *moldyn,double nn_dist);
int link_cell_init(t_moldyn *moldyn);
int link_cell_update(t_moldyn *moldyn);