X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=libctsupport%2Fmathfuncs.cpp;h=c9b18ac3da75ca61cf6c10e82bfe5689a4bca0a7;hp=3604b2f5074ca360f5737882403038223a085c98;hb=9b2bb510160bdb56f04847f5b55ab61dd8a47976;hpb=9f7d379c2b03f3c09907cfd885072433e0428042 diff --git a/libctsupport/mathfuncs.cpp b/libctsupport/mathfuncs.cpp index 3604b2f..c9b18ac 100644 --- a/libctsupport/mathfuncs.cpp +++ b/libctsupport/mathfuncs.cpp @@ -2,7 +2,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: mathfuncs.cpp,v 1.5 2001/01/01 10:14:34 kevin Exp $ +** $Id: mathfuncs.cpp,v 1.6 2001/01/02 05:34:57 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -93,15 +93,12 @@ vectorNumericStatistics (std::vector vec, const int nPoints, double& min min = vec[0]; max = vec[0]; int i; - int iMinPos = 0; for (i = 0; i < nPoints; i++) { double v = vec[i]; if (v > max) max = v; - if (v < min) { + if (v < min) min = v; - iMinPos = i; - } mean += v; } mean /= nPoints;