Changeset 1158 for trunk


Ignore:
Timestamp:
May 10, 2015 10:01:05 AM (5 years ago)
Author:
pbelotti
Message:

do not use exprClone in readnl to split function (e.g. tan(f(x)) into sin(f(x))/cos(f(x))

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Couenne/src/readnl/nl2e.cpp

    r864 r1158  
    7474                    new exprExp (new exprOpp (nl2e (e->L.e, asl)))));
    7575
    76   case OP_tan: {
    77     expression *arg;
    78     arg = nl2e (e -> L.e, asl);
    79     return new exprDiv (new exprSin (arg), new exprCos (new exprClone (arg)));
    80   }
     76  case OP_tan:
     77    return new exprDiv (new exprSin (nl2e (e -> L.e, asl)), new exprCos (new exprClone (nl2e (e -> L.e, asl))));
    8178  case OP_sqrt:    return new exprPow (nl2e (e -> L.e, asl), new exprConst (0.5));
    8279  case OP_sinh:    return new exprMul (new exprConst (0.5),
Note: See TracChangeset for help on using the changeset viewer.