X-Git-Url: https://hackdaworld.org/gitweb/?p=physik%2Fposic.git;a=blobdiff_plain;f=sic.c;h=7ab3dc92d979eadfec8a148d4757fa21fe3a6ab8;hp=45e671fe9439796e9554c542137ffe4f8ce775b4;hb=785f05e0c0ddb57428dc71b0a3f7798673799871;hpb=db67150db2d78312a1a98d45d46bda887c8f668d diff --git a/sic.c b/sic.c index 45e671f..7ab3dc9 100644 --- a/sic.c +++ b/sic.c @@ -12,6 +12,14 @@ #include "posic.h" int main(int argc,char **argv) { + + /* check argv */ + if(argc!=2) { + printf("[sic] error: arg1 (vis/log/save location) "); + printf("must be given!\n"); + return -1; + } + /* main moldyn structure */ t_moldyn md; @@ -24,7 +32,7 @@ int main(int argc,char **argv) { double tau; /* testing location & velocity vector */ - t_3dvec r,v; + //t_3dvec r,v; /* values */ tau=1.0e-15; /* delta t = 1 fs */ @@ -129,8 +137,8 @@ int main(int argc,char **argv) { /* set temperature */ printf("[sic] setting temperature\n"); - set_temperature(&md,273.0+1410.0); - //set_temperature(&md,273.0+450.0); + //set_temperature(&md,273.0+1410.0); + set_temperature(&md,273.0+450.0); //set_temperature(&md,273.0); //set_temperature(&md,1.0); //set_temperature(&md,0.0); @@ -150,11 +158,11 @@ int main(int argc,char **argv) { /* create the simulation schedule */ printf("[sic] adding schedule\n"); - moldyn_add_schedule(&md,100001,1.0); + moldyn_add_schedule(&md,30001,1.0); /* activate logging */ printf("[sic] activate logging\n"); - moldyn_set_log_dir(&md,"saves/si_melting_point"); + moldyn_set_log_dir(&md,argv[1]); moldyn_set_log(&md,LOG_TOTAL_ENERGY,200); moldyn_set_log(&md,VISUAL_STEP,200);