Changeset 2345 for trunk/src/STMath.cpp


Ignore:
Timestamp:
11/08/11 19:03:54 (13 years ago)
Author:
WataruKawasaki
Message:

New Development: No

JIRA Issue: No

Ready for Test: Yes

Interface Changes: No

What Interface Changed:

Test Programs:

Put in Release Notes: No

Module(s): SD

Description: bugfix.


File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/STMath.cpp

    r2317 r2345  
    224224        Vector<Double> x0 = (subt.col("DIRECTION").getArrayDouble(TableExprId(irow))) ;
    225225        Vector<Double> x1 = rec.asArrayDouble("DIRECTION") ;
    226         double dx = x0[0] - x1[0] ;
    227         double dy = x0[0] - x1[0] ;
     226        double dx = x0[0] - x1[0];
     227        double dy = x0[1] - x1[1];
    228228        Double dd = sqrt( dx * dx + dy * dy ) ;
    229229        //if ( !allNearAbs((subt.col("DIRECTION").getArrayDouble(TableExprId(irow))), rec.asArrayDouble("DIRECTION"), tol ) ) {
     
    444444          dircol(jrow).getAngle(Unit(String("rad"))).getValue() ;
    445445        //if ( t[0] != direction[0] || t[1] != direction[1] ) {
    446         Double dx = t[0] - direction[0] ;
    447         Double dy = t[1] - direction[1] ;
    448         Double dd = sqrt( dx * dx + dy * dy ) ;
     446        Double dx = t[0] - direction[0];
     447        Double dy = t[1] - direction[1];
     448        Double dd = sqrt(dx*dx + dy*dy);
    449449        //if ( !allNearAbs( t, direction, tol ) ) {
    450450        if ( dd > tol &&  in->nbeam() < 2 ) {
     
    37113711  }
    37123712 
    3713   return out ;
     3713  return out;
    37143714}
    37153715
Note: See TracChangeset for help on using the changeset viewer.