DEBUG DETAILED_TIMERS
c: COORDINATION GROUPA=1-108 GROUPB=1-108 R_0=1
d: COORDINATION GROUPA=1-108 GROUPB=1-108 SWITCH={CUSTOM FUNC=1/(1+x^6) R_0=1}
PRINT ARG=c,d FILE=colvar FMT=%8.4f STRIDE=1
FLUSH STRIDE=1
s: COMBINE ARG=c,d PERIODIC=NO
RESTRAINT ARG=s KAPPA=0 SLOPE=1 AT=0

dfast: COORDINATION GROUPA=1-108 GROUPB=1-108 SWITCH={CUSTOM FUNC=1/(1+x2^3) R_0=1}
e: COORDINATION GROUPA=1-108 GROUPB=1-108 R_0=1 NN=7 D_0=0.1
f: COORDINATION GROUPA=1-108 GROUPB=1-108 SWITCH={CUSTOM FUNC=1/(1+x^7) R_0=1 D_0=0.1}
g: COORDINATION GROUPA=1-108 GROUPB=1-108 SWITCH={EXP R_0=1}
h: COORDINATION GROUPA=1-108 GROUPB=1-108 SWITCH={CUSTOM FUNC=exp(-x) R_0=1}
PRINT ARG=c,d,dfast,e,f,g,h FILE=check1 FMT=%8.4f
# this would check derivatives:
# DUMPDERIVATIVES ARG=c,d,dfast FILE=der0 FMT=%8.4f
# DUMPDERIVATIVES ARG=e,f FILE=der1 FMT=%8.4f
# DUMPDERIVATIVES ARG=g,h FILE=der2 FMT=%8.4f

# to detect errors we just add and subtract biases
# this should add zero forces
all: COMBINE ARG=c,d,dfast,e,f,g,h COEFFICIENTS=1,-0.5,-0.5,1,-1,1,-1 PERIODIC=NO
RESTRAINT ARG=all KAPPA=0 SLOPE=0.001 AT=0
# SLOPE is very small in order to avoid numerical errors to appear
# it should be sufficient to detect errors
