//! Assignment operator: ensure that list is not deleted twice
void operator = (const Cell& theOther)
{
- Standard_Integer myDim = Standard_Integer(theOther.index.Size());
- for(Standard_Integer anIdx = 0; anIdx < myDim; anIdx++)
+ Standard_Integer aDim = Standard_Integer(theOther.index.Size());
+ for(Standard_Integer anIdx = 0; anIdx < aDim; anIdx++)
index[anIdx] = theOther.index[anIdx];
Objects = theOther.Objects;
//! Compare cell with other one
Standard_Boolean IsEqual (const Cell& theOther) const
{
- Standard_Integer myDim = Standard_Integer(theOther.index.Size());
- for (int i=0; i < myDim; i++)
+ Standard_Integer aDim = Standard_Integer(theOther.index.Size());
+ for (int i=0; i < aDim; i++)
if ( index[i] != theOther.index[i] ) return Standard_False;
return Standard_True;
}
Standard_Integer HashCode (const Standard_Integer theUpper) const
{
// number of bits per each dimension in the hash code
- Standard_Integer myDim = Standard_Integer(index.Size());
- const Standard_Size aShiftBits = (BITS(long)-1) / myDim;
+ Standard_Integer aDim = Standard_Integer(index.Size());
+ const Standard_Size aShiftBits = (BITS(long)-1) / aDim;
long aCode=0;
- for (int i=0; i < myDim; i++)
+ for (int i=0; i < aDim; i++)
aCode = ( aCode << aShiftBits ) ^ index[i];
return (unsigned)aCode % theUpper;
}
//Newton method
if (dynamic_cast<math_MultipleVarFunctionWithHessian*>(myFunc))
{
- math_MultipleVarFunctionWithHessian* myTmp =
+ math_MultipleVarFunctionWithHessian* aTmp =
dynamic_cast<math_MultipleVarFunctionWithHessian*> (myFunc);
- math_NewtonMinimum newtonMinimum(*myTmp);
+ math_NewtonMinimum newtonMinimum(*aTmp);
newtonMinimum.SetBoundary(myGlobA, myGlobB);
- newtonMinimum.Perform(*myTmp, thePnt);
+ newtonMinimum.Perform(*aTmp, thePnt);
if (newtonMinimum.IsDone())
{
// BFGS method used.
if (dynamic_cast<math_MultipleVarFunctionWithGradient*>(myFunc))
{
- math_MultipleVarFunctionWithGradient* myTmp =
+ math_MultipleVarFunctionWithGradient* aTmp =
dynamic_cast<math_MultipleVarFunctionWithGradient*> (myFunc);
- math_BFGS bfgs(myTmp->NbVariables());
- bfgs.Perform(*myTmp, thePnt);
+ math_BFGS bfgs(aTmp->NbVariables());
+ bfgs.Perform(*aTmp, thePnt);
if (bfgs.IsDone())
{
bfgs.Location(theOutPnt);