MCPcopy Create free account
hub / github.com/avaneev/biteopt / applyRound

Function applyRound

constr3.cpp:15–20  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13const int N = 10;
14
15inline double applyRound( double v )
16{
17 v *= 100000000.0;
18 v = ( v < 0.0 ? -floor( 0.5 - v ) : floor( v + 0.5 ));
19 return( v / 100000000.0 );
20}
21
22class CTestOpt : public CBiteOptDeep
23{

Callers 2

optcostMethod · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected