don't use floating point numbers as booleans
This commit is contained in:
@ -250,7 +250,7 @@ void PairOxdnaCoaxstk::compute(int eflag, int vflag)
|
||||
b_cxst1[atype][btype], dtheta_cxst1_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t1) {
|
||||
if (f4t1 != 0.0) {
|
||||
|
||||
az[0] = nz_xtrct[a][0];
|
||||
az[1] = nz_xtrct[a][1];
|
||||
@ -268,7 +268,7 @@ void PairOxdnaCoaxstk::compute(int eflag, int vflag)
|
||||
b_cxst4[atype][btype], dtheta_cxst4_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t4) {
|
||||
if (f4t4 != 0.0) {
|
||||
|
||||
cost5 = MathExtra::dot3(delr_st_norm,az);
|
||||
if (cost5 > 1.0) cost5 = 1.0;
|
||||
@ -282,7 +282,7 @@ void PairOxdnaCoaxstk::compute(int eflag, int vflag)
|
||||
b_cxst5[atype][btype], dtheta_cxst5_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t5) {
|
||||
if (f4t5 != 0.0) {
|
||||
|
||||
cost6 = MathExtra::dot3(delr_st_norm,bz);
|
||||
if (cost6 > 1.0) cost6 = 1.0;
|
||||
@ -311,7 +311,7 @@ void PairOxdnaCoaxstk::compute(int eflag, int vflag)
|
||||
evdwl = f2 * f4t1 * f4t4 * f4t5 * f4t6 * f5c3 * f5c3 * factor_lj;
|
||||
|
||||
// early rejection criterium
|
||||
if (evdwl) {
|
||||
if (evdwl != 0.0) {
|
||||
|
||||
df2 = DF2(r_st, k_cxst[atype][btype], cut_cxst_0[atype][btype],
|
||||
cut_cxst_lc[atype][btype], cut_cxst_hc[atype][btype], cut_cxst_lo[atype][btype], cut_cxst_hi[atype][btype],
|
||||
|
||||
@ -235,7 +235,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
b_hb_lo[atype][btype], b_hb_hi[atype][btype], shift_hb[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f1) {
|
||||
if (f1 != 0.0) {
|
||||
|
||||
cost1 = -1.0*MathExtra::dot3(ax,bx);
|
||||
if (cost1 > 1.0) cost1 = 1.0;
|
||||
@ -246,7 +246,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
b_hb1[atype][btype], dtheta_hb1_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t1) {
|
||||
if (f4t1 != 0.0) {
|
||||
|
||||
cost2 = -1.0*MathExtra::dot3(ax,delr_hb_norm);
|
||||
if (cost2 > 1.0) cost2 = 1.0;
|
||||
@ -257,7 +257,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
b_hb2[atype][btype], dtheta_hb2_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t2) {
|
||||
if (f4t2 != 0.0) {
|
||||
|
||||
cost3 = MathExtra::dot3(bx,delr_hb_norm);
|
||||
if (cost3 > 1.0) cost3 = 1.0;
|
||||
@ -268,7 +268,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
b_hb3[atype][btype], dtheta_hb3_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t3) {
|
||||
if (f4t3 != 0.0) {
|
||||
|
||||
az[0] = nz_xtrct[a][0];
|
||||
az[1] = nz_xtrct[a][1];
|
||||
@ -286,7 +286,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
b_hb4[atype][btype], dtheta_hb4_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t4) {
|
||||
if (f4t4 != 0.0) {
|
||||
|
||||
cost7 = -1.0*MathExtra::dot3(az,delr_hb_norm);
|
||||
if (cost7 > 1.0) cost7 = 1.0;
|
||||
@ -297,7 +297,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
b_hb7[atype][btype], dtheta_hb7_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t7) {
|
||||
if (f4t7 != 0.0) {
|
||||
|
||||
cost8 = MathExtra::dot3(bz,delr_hb_norm);
|
||||
if (cost8 > 1.0) cost8 = 1.0;
|
||||
@ -310,7 +310,7 @@ void PairOxdnaHbond::compute(int eflag, int vflag)
|
||||
evdwl = f1 * f4t1 * f4t2 * f4t3 * f4t4 * f4t7 * f4t8 * factor_lj;
|
||||
|
||||
// early rejection criterium
|
||||
if (evdwl) {
|
||||
if (evdwl != 0.0) {
|
||||
|
||||
df1 = DF1(r_hb, epsilon_hb[atype][btype], a_hb[atype][btype], cut_hb_0[atype][btype],
|
||||
cut_hb_lc[atype][btype], cut_hb_hc[atype][btype], cut_hb_lo[atype][btype], cut_hb_hi[atype][btype],
|
||||
|
||||
@ -341,7 +341,7 @@ void PairOxdnaStk::compute(int eflag, int vflag)
|
||||
b_st_lo[atype][btype], b_st_hi[atype][btype], shift_st[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f1) {
|
||||
if (f1 != 0.0) {
|
||||
|
||||
az[0] = nz_xtrct[a][0];
|
||||
az[1] = nz_xtrct[a][1];
|
||||
@ -360,7 +360,7 @@ void PairOxdnaStk::compute(int eflag, int vflag)
|
||||
b_st4[atype][btype], dtheta_st4_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t4) {
|
||||
if (f4t4 != 0.0) {
|
||||
|
||||
// theta5 angle and correction
|
||||
cost5p = MathExtra::dot3(delr_st_norm,bz);
|
||||
@ -372,7 +372,7 @@ void PairOxdnaStk::compute(int eflag, int vflag)
|
||||
b_st5[atype][btype], dtheta_st5_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t5) {
|
||||
if (f4t5 != 0.0) {
|
||||
|
||||
ay[0] = ny_xtrct[a][0];
|
||||
ay[1] = ny_xtrct[a][1];
|
||||
@ -406,7 +406,7 @@ void PairOxdnaStk::compute(int eflag, int vflag)
|
||||
evdwl = f1 * f4t4 * f4t5 * f4t6 * f5c1 * f5c2;
|
||||
|
||||
// early rejection criterium
|
||||
if (evdwl) {
|
||||
if (evdwl != 0.0) {
|
||||
|
||||
df1 = DF1(r_st, epsilon_st[atype][btype], a_st[atype][btype], cut_st_0[atype][btype],
|
||||
cut_st_lc[atype][btype], cut_st_hc[atype][btype], cut_st_lo[atype][btype], cut_st_hi[atype][btype],
|
||||
|
||||
@ -214,7 +214,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
b_xst_lo[atype][btype], b_xst_hi[atype][btype], cut_xst_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f2) {
|
||||
if (f2 != 0.0) {
|
||||
|
||||
cost1 = -1.0*MathExtra::dot3(ax,bx);
|
||||
if (cost1 > 1.0) cost1 = 1.0;
|
||||
@ -225,7 +225,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
b_xst1[atype][btype], dtheta_xst1_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t1) {
|
||||
if (f4t1 != 0.0) {
|
||||
|
||||
cost2 = -1.0*MathExtra::dot3(ax,delr_hb_norm);
|
||||
if (cost2 > 1.0) cost2 = 1.0;
|
||||
@ -236,7 +236,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
b_xst2[atype][btype], dtheta_xst2_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t2) {
|
||||
if (f4t2 != 0.0) {
|
||||
|
||||
cost3 = MathExtra::dot3(bx,delr_hb_norm);
|
||||
if (cost3 > 1.0) cost3 = 1.0;
|
||||
@ -247,7 +247,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
b_xst3[atype][btype], dtheta_xst3_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t3) {
|
||||
if (f4t3 != 0.0) {
|
||||
|
||||
az[0] = nz_xtrct[a][0];
|
||||
az[1] = nz_xtrct[a][1];
|
||||
@ -268,7 +268,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
b_xst4[atype][btype], dtheta_xst4_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t4) {
|
||||
if (f4t4 != 0.0) {
|
||||
|
||||
cost7 = -1.0*MathExtra::dot3(az,delr_hb_norm);
|
||||
if (cost7 > 1.0) cost7 = 1.0;
|
||||
@ -282,7 +282,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
b_xst7[atype][btype], dtheta_xst7_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t7) {
|
||||
if (f4t7 != 0.0) {
|
||||
|
||||
cost8 = MathExtra::dot3(bz,delr_hb_norm);
|
||||
if (cost8 > 1.0) cost8 = 1.0;
|
||||
@ -300,7 +300,7 @@ void PairOxdnaXstk::compute(int eflag, int vflag)
|
||||
|
||||
|
||||
// early rejection criterium
|
||||
if (evdwl) {
|
||||
if (evdwl != 0.0) {
|
||||
|
||||
df2 = DF2(r_hb, k_xst[atype][btype], cut_xst_0[atype][btype],
|
||||
cut_xst_lc[atype][btype], cut_xst_hc[atype][btype], cut_xst_lo[atype][btype], cut_xst_hi[atype][btype],
|
||||
|
||||
@ -373,7 +373,7 @@ void PairOxrna2Stk::compute(int eflag, int vflag)
|
||||
b_st_lo[atype][btype], b_st_hi[atype][btype], shift_st[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f1) {
|
||||
if (f1 != 0.0) {
|
||||
|
||||
// theta5 angle and correction
|
||||
cost5p = MathExtra::dot3(delr_st_norm,bz);
|
||||
@ -385,7 +385,7 @@ void PairOxrna2Stk::compute(int eflag, int vflag)
|
||||
b_st5[atype][btype], dtheta_st5_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t5) {
|
||||
if (f4t5 != 0.0) {
|
||||
|
||||
cost6p = MathExtra::dot3(delr_st_norm,az);
|
||||
if (cost6p > 1.0) cost6p = 1.0;
|
||||
@ -437,7 +437,7 @@ void PairOxrna2Stk::compute(int eflag, int vflag)
|
||||
evdwl = f1 * f4t5 * f4t6 * f4t9 * f4t10 * f5c1 * f5c2;
|
||||
|
||||
// early rejection criterium
|
||||
if (evdwl) {
|
||||
if (evdwl != 0.0) {
|
||||
|
||||
df1 = DF1(r_st, epsilon_st[atype][btype], a_st[atype][btype], cut_st_0[atype][btype],
|
||||
cut_st_lc[atype][btype], cut_st_hc[atype][btype], cut_st_lo[atype][btype], cut_st_hi[atype][btype],
|
||||
|
||||
@ -206,7 +206,7 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
||||
b_xst_lo[atype][btype], b_xst_hi[atype][btype], cut_xst_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f2) {
|
||||
if (f2 != 0.0) {
|
||||
|
||||
cost1 = -1.0*MathExtra::dot3(ax,bx);
|
||||
if (cost1 > 1.0) cost1 = 1.0;
|
||||
@ -217,7 +217,7 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
||||
b_xst1[atype][btype], dtheta_xst1_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t1) {
|
||||
if (f4t1 != 0.0) {
|
||||
|
||||
cost2 = -1.0*MathExtra::dot3(ax,delr_hb_norm);
|
||||
if (cost2 > 1.0) cost2 = 1.0;
|
||||
@ -228,7 +228,7 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
||||
b_xst2[atype][btype], dtheta_xst2_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t2) {
|
||||
if (f4t2 != 0.0) {
|
||||
|
||||
cost3 = MathExtra::dot3(bx,delr_hb_norm);
|
||||
if (cost3 > 1.0) cost3 = 1.0;
|
||||
@ -239,7 +239,7 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
||||
b_xst3[atype][btype], dtheta_xst3_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t3) {
|
||||
if (f4t3 != 0.0) {
|
||||
|
||||
az[0] = nz_xtrct[a][0];
|
||||
az[1] = nz_xtrct[a][1];
|
||||
@ -257,7 +257,7 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
||||
b_xst7[atype][btype], dtheta_xst7_c[atype][btype]);
|
||||
|
||||
// early rejection criterium
|
||||
if (f4t7) {
|
||||
if (f4t7 != 0.0) {
|
||||
|
||||
bz[0] = nz_xtrct[b][0];
|
||||
bz[1] = nz_xtrct[b][1];
|
||||
@ -279,7 +279,7 @@ void PairOxrna2Xstk::compute(int eflag, int vflag)
|
||||
|
||||
|
||||
// early rejection criterium
|
||||
if (evdwl) {
|
||||
if (evdwl != 0.0) {
|
||||
|
||||
df2 = DF2(r_hb, k_xst[atype][btype], cut_xst_0[atype][btype],
|
||||
cut_xst_lc[atype][btype], cut_xst_hc[atype][btype], cut_xst_lo[atype][btype], cut_xst_hi[atype][btype],
|
||||
|
||||
Reference in New Issue
Block a user