X-Git-Url: https://hackdaworld.org/gitweb/?a=blobdiff_plain;f=sic.c;h=3c815bac57a9ce9d0325bb4e43523177e25ad79e;hb=acdd9a6aa72f3692ccd03cc0df20e3d60555f555;hp=22210255abab5145bee92bd98e44f1280506aa1d;hpb=57847266c05bc38218bf162efdb08e8dd40894d7;p=physik%2Fposic.git diff --git a/sic.c b/sic.c index 2221025..3c815ba 100644 --- a/sic.c +++ b/sic.c @@ -13,8 +13,12 @@ /* potential */ #include "potentials/harmonic_oscillator.h" #include "potentials/lennard_jones.h" + +#ifdef TERSOFF_ORIG +#include "potentials/tersoff_orig.h" +#else #include "potentials/tersoff.h" -//#include "potentials/tersoff_orig.h" +#endif #define INJECT 1 #define NR_ATOMS 4 @@ -97,14 +101,16 @@ int main(int argc,char **argv) { /* choose potential */ set_potential1b(&md,tersoff_mult_1bp); - //set_potential2b(&md,tersoff_mult_2bp); - //set_potential3b_j1(&md,tersoff_mult_2bp); - //set_potential3b_k1(&md,tersoff_mult_3bp); - //set_potential3b_j3(&md,tersoff_mult_post_2bp); +#ifdef TERSOFF_ORIG + set_potential3b_j1(&md,tersoff_mult_2bp); + set_potential3b_k1(&md,tersoff_mult_3bp); + set_potential3b_j2(&md,tersoff_mult_post_2bp); +#else set_potential3b_j1(&md,tersoff_mult_3bp_j1); set_potential3b_k1(&md,tersoff_mult_3bp_k1); set_potential3b_j2(&md,tersoff_mult_3bp_j2); set_potential3b_k2(&md,tersoff_mult_3bp_k2); +#endif //set_potential2b(&md,lennard_jones); //set_potential2b(&md,harmonic_oscillator); set_potential_params(&md,&tp); @@ -164,7 +170,8 @@ int main(int argc,char **argv) { tersoff_mult_complete_params(&tp); /* set (initial) dimensions of simulation volume */ - set_dim(&md,6*LC_SI,6*LC_SI,6*LC_SI,TRUE); + //set_dim(&md,6*LC_SI,6*LC_SI,6*LC_SI,TRUE); + set_dim(&md,6*TM_LC_3C_SIC,6*TM_LC_3C_SIC,6*TM_LC_3C_SIC,TRUE); /* set periodic boundary conditions in all directions */ set_pbc(&md,TRUE,TRUE,TRUE); @@ -172,10 +179,21 @@ int main(int argc,char **argv) { /* create the lattice / place atoms */ //create_lattice(&md,CUBIC,LC_SI,SI,M_SI, //create_lattice(&md,FCC,LC_SI,SI,M_SI, - create_lattice(&md,DIAMOND,LC_SI,SI,M_SI, - ATOM_ATTR_1BP|ATOM_ATTR_2BP|ATOM_ATTR_3BP|ATOM_ATTR_HB, + //create_lattice(&md,DIAMOND,LC_SI,SI,M_SI, + //create_lattice(&md,DIAMOND,LC_C,C,M_C, + // ATOM_ATTR_1BP|ATOM_ATTR_2BP|ATOM_ATTR_3BP|ATOM_ATTR_HB, // ATOM_ATTR_2BP|ATOM_ATTR_HB, - 0,6,6,6); + // 1,6,6,6,NULL); + + /* create centered zinc blende lattice */ + r.x=0.5*0.25*TM_LC_3C_SIC; r.y=r.x; r.z=r.x; + create_lattice(&md,FCC,TM_LC_3C_SIC,SI,M_SI, + ATOM_ATTR_1BP|ATOM_ATTR_2BP|ATOM_ATTR_3BP|ATOM_ATTR_HB, + 0,6,6,6,&r); + r.x+=0.25*TM_LC_3C_SIC; r.y=r.x; r.z=r.x; + create_lattice(&md,FCC,TM_LC_3C_SIC,C,M_C, + ATOM_ATTR_1BP|ATOM_ATTR_2BP|ATOM_ATTR_3BP|ATOM_ATTR_HB, + 1,6,6,6,&r); moldyn_bc_check(&md); /* testing configuration */ @@ -225,7 +243,7 @@ int main(int argc,char **argv) { /* create the simulation schedule */ /* initial configuration */ - moldyn_add_schedule(&md,10000,1.0); + moldyn_add_schedule(&md,1000,1.0); /* adding atoms */ //for(inject=0;inject