2 * sic.c - investigation of the sic precipitation process of silicon carbide
4 * author: Frank Zirkelbach <frank.zirkelbach@physik.uni-augsburg.de>
11 #include "math/math.h"
12 #include "init/init.h"
13 #include "visual/visual.h"
20 int main(int argc,char **argv) {
22 /* main moldyn structure */
25 /* potential parameters */
28 t_tersoff_mult_params tp;
30 /* misc variables, mainly to initialize stuff */
33 /* initialize moldyn */
34 moldyn_init(&md,argc,argv);
36 /* choose integration algorithm */
37 set_int_alg(&md,MOLDYN_INTEGRATE_VERLET);
39 /* choose potential */
40 //set_potential(&md,MOLDYN_1BP,tersoff_mult_1bp,&tp);
41 //set_potential(&md,MOLDYN_2BP,tersoff_mult_2bp,&tp);
42 //set_potential(&md,MOLDYN_3BP,tersoff_mult_3bp,&tp);
43 set_potential(&md,MOLDYN_2BP,lennard_jones,&lj);
46 * potential parameters
50 lj.sigma6=LJ_SIGMA_SI*LJ_SIGMA_SI*LJ_SIGMA;
52 lj.sigma12=lj.sigma6*lj.sigma6;
53 lj.epsilon4=4.0*LJ_EPSILON_SI;
55 /* harmonic oscillator */
56 ho.equilibrium_distance=0.25*sqrt(3.0)*LC_SI;
60 set_cutoff(&md,LC_SI);
62 /* set (initial) dimensions of simulation volume */
63 set_dim(&md,10*LC_SI,10*LC_SI,10*LC_SI,TRUE);
65 /* set periodic boundary conditions in all directions */
66 set_pbc(&md,TRUE,TRUE,TRUE);
68 /* create the lattice / place atoms */
69 memset(&v,0,sizeof(t_3dvec));
72 r.x=0.23*sqrt(3.0)*LC_SI/2.0;
73 add_atom(&md,SI,M_SI,0,ATOM_ATTR_2BP,&r,&v);
75 add_atom(&md,SI,M_SI,0,ATOM_ATTR_2BP,&r,&v);
78 set_temperature(&md,0.0);
80 /* initial thermal fluctuations of particles */
83 /* create the simulation schedule */
84 moldyn_add_schedule(&md,10000,1.0e-15);
87 * let's do the actual md algorithm now
89 * integration of newtons equations
92 moldyn_integrate(&md);
96 link_cell_shutdown(&md);