diff options
author | IOhannes m zmölnig <zmoelnig@users.sourceforge.net> | 2011-08-12 10:03:07 +0000 |
---|---|---|
committer | IOhannes m zmölnig <zmoelnig@users.sourceforge.net> | 2011-08-12 10:03:07 +0000 |
commit | d803e6e7c40b12a0d9b26c17b7d43a3b3c3aad91 (patch) | |
tree | 9c26bea195ddc70b9047a2197244f416af51559a | |
parent | 3773bd350ff451b1626216bef01239f2a0ab1339 (diff) |
use logical AND rather than bitwise AND with boolean values
svn path=/trunk/externals/pmpd/; revision=15209
-rw-r--r-- | pmpd~.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -163,7 +163,7 @@ t_int *pmpd_tilde_perform(t_int *w) // compute forces generated by NLlinks (spring / dashpot)
{
L=x->NLlink[i].mass1->posX - x->NLlink[i].mass2->posX - x->NLlink[i].L0;
- if (L<x->NLlink[i].Lmax & L>x->NLlink[i].Lmin)
+ if ((L < x->NLlink[i].Lmax) && (L > x->NLlink[i].Lmin))
{
F = x->NLlink[i].K1 * pow(fabs(L) ,x->NLlink[i].Pow) ;
if (L < 0) F *= -1;
|