2 * tersoff.h - tersoff potential header file
4 * author: Frank Zirkelbach <frank.zirkelbach@physik.uni-augsburg.de>
11 #define TERSOFF_MAXN 16*27
13 /* tersoff exchange type */
14 typedef struct s_tersoff_echange {
20 t_3dvec dist_ik[TERSOFF_MAXN];
21 double d_ik2[TERSOFF_MAXN];
22 double d_ik[TERSOFF_MAXN];
24 double f_c_ik[TERSOFF_MAXN];
25 double df_c_ik[TERSOFF_MAXN];
27 double g[TERSOFF_MAXN];
28 double dg[TERSOFF_MAXN];
29 double cos_theta[TERSOFF_MAXN];
48 /* tersoff mult (2!) potential parameters */
49 typedef struct s_tersoff_mult_params {
50 double S[2]; /* tersoff cutoff radii */
51 double S2[2]; /* tersoff cutoff radii squared */
52 double R[2]; /* tersoff cutoff radii */
53 double Smixed; /* mixed S radius */
54 double S2mixed; /* mixed S radius squared */
55 double Rmixed; /* mixed R radius */
56 double A[2]; /* factor of tersoff attractive part */
57 double B[2]; /* factor of tersoff repulsive part */
58 double Amixed; /* mixed A factor */
59 double Bmixed; /* mixed B factor */
60 double lambda[2]; /* tersoff lambda */
61 double lambda_m; /* mixed lambda */
62 double mu[2]; /* tersoff mu */
63 double mu_m; /* mixed mu */
73 t_tersoff_exchange exchange; /* exchange between 2bp and 3bp calc */
74 } t_tersoff_mult_params;
76 /* function prototypes */
77 int tersoff_mult_complete_params(t_tersoff_mult_params *p);
78 int tersoff_mult_1bp(t_moldyn *moldyn,t_atom *ai);
79 int tersoff_mult_2bp(t_moldyn *moldyn,t_atom *ai,t_atom *aj,u8 bc);
80 int tersoff_mult_3bp_j1(t_moldyn *moldyn,t_atom *ai,t_atom *aj,u8 bc);
81 int tersoff_mult_3bp_k1(t_moldyn *moldyn,
82 t_atom *ai,t_atom *aj,t_atom *ak,u8 bc);
83 int tersoff_mult_3bp_j2(t_moldyn *moldyn,t_atom *ai,t_atom *aj,u8 bc);
84 int tersoff_mult_3bp_k2(t_moldyn *moldyn,
85 t_atom *ai,t_atom *aj,t_atom *ak,u8 bc);