#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include "global.h"
Go to the source code of this file.
◆ BrownianStep()
Definition at line 26 of file BrownianStep.c.
26 {
28 double A, S1, S2, T;
29 int n;
30 S1 = 0.; S2 = 0;
31 double halfdt = 0.5*
deltaT;
32 for (n = 1; n <=
nAtom; n++){
33 T =
vx[n] + halfdt *
ax[n];
36
37 T =
vy[n] + halfdt *
ay[n];
40 }
41 A = -S1 / S2;
44 for (n = 1; n <=
nAtom; n++){
45 vx[n] = C *
vx[n] + D *
ax[n];
47 vy[n] = C *
vy[n] + D *
ay[n];
49 }
50 }else{
51 int n;
52
54 for(n = 1 ; n <=
nAtom ; n ++){
57 }}
58 double zeta = 1.0;
59 double dx, dy;
60 for(n = 1 ; n <=
nAtom ; n ++){
69 }
70 }
71}
References ax, ay, deltaT, nAtom, rx, ry, Sqr, stepCount, stepEquil, vx, and vy.