summaryrefslogtreecommitdiff
path: root/inc/math_NewtonMinimum.lxx
blob: 877c3758bffcc388ac0c900028c70080e07cec95 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
// File:	math_NewtonMinimum.lxx
// Created:	Fri May  3 09:38:48 1996
// Author:	Philippe MANGIN
//		<pmn@sgi38>

#include <StdFail_NotDone.hxx>

inline Standard_Boolean math_NewtonMinimum::IsDone() const 
{
  return Done;
}

inline const math_Vector& math_NewtonMinimum::Location() const 
{
   StdFail_NotDone_Raise_if(!Done, "NewtonMinimum");
   return TheLocation;
}

inline void math_NewtonMinimum::Location(math_Vector& Loc) const 
{
   StdFail_NotDone_Raise_if(!Done, "NewtonMinimum");
   Loc = TheLocation;
}

inline Standard_Real math_NewtonMinimum::Minimum() const 
{
   StdFail_NotDone_Raise_if(!Done, "NewtonMinimum");
   return TheMinimum;
}

inline const math_Vector& math_NewtonMinimum::Gradient() const 
{
   StdFail_NotDone_Raise_if(!Done, "NewtonMinimum");
   return TheGradient;
}

inline void math_NewtonMinimum::Gradient(math_Vector& Grad) const 
{
   StdFail_NotDone_Raise_if(!Done, "NewtonMinimum");
   Grad = TheGradient;
}

inline Standard_Integer math_NewtonMinimum::NbIterations() const 
{
   StdFail_NotDone_Raise_if(!Done, "NewtonMinimum");
   return nbiter;
}