]> hackdaworld.org Git - physik/posic.git/commitdiff
little more tersoff ...
authorhackbard <hackbard>
Wed, 16 Aug 2006 15:22:32 +0000 (15:22 +0000)
committerhackbard <hackbard>
Wed, 16 Aug 2006 15:22:32 +0000 (15:22 +0000)
Makefile
moldyn.c

index 7096b48dd563331d868dbaf47ced35742f0eb065..3c8fcd1157eeaf5184c809ac70b4fd906e2c1c95 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
 CC=gcc
-CFLAGS=-Wall -DSIMPLE_TESTING
+CFLAGS=-Wall #-DSIMPLE_TESTING
 LDFLAGS=-lm
 
 OBJS=init/init.o visual/visual.o math/math.o random/random.o list/list.o
index dc2dd8e5a5e89226a9e68bd22ccf22bd2ff25635..1b52a5628b3e3fe4df32ec4a76483795a1491c15 100644 (file)
--- a/moldyn.c
+++ b/moldyn.c
@@ -998,6 +998,14 @@ int tersoff(t_moldyn *moldyn) {
                        v3_sub(&dist_ij,btom,&(atom[i]));
                        d_ij=v3_norm(&dist_ij);
                        if(d_ij<=S) {
+
+                               S=;
+                               R=;
+                               A=;
+                               lambda=;
+                               B=;
+                               mu=;
+
                                if(d_ij<=R) {
                                        f_c=1.0;
                                        df_c=0.0;
@@ -1007,6 +1015,8 @@ int tersoff(t_moldyn *moldyn) {
                                        arg1=PI*(d_ij-R)/s_r;
                                        f_c=0.5+0.5*cos(arg1);
                                        df_c=-0.5*sin(arg1)*(PI/(s_r*d_ij));
+                                       f_r=A*exp(-lambda*d_ij);
+                                       f_a=-B*exp(-mu*d_ij);
                                }
                        }
                        else