0027232: Configuration - fix mblen missing building issue on Android
[occt.git] / src / HLRBRep / HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter.hxx
CommitLineData
42cf5bc1 1// Created on: 1992-10-14
2// Created by: Christophe MARION
3// Copyright (c) 1992-1999 Matra Datavision
4// Copyright (c) 1999-2014 OPEN CASCADE SAS
5//
6// This file is part of Open CASCADE Technology software library.
7//
8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
13//
14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
16
17#ifndef _HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter_HeaderFile
18#define _HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_DefineAlloc.hxx>
22#include <Standard_Handle.hxx>
23
24#include <gp_Pnt2d.hxx>
25#include <Standard_Address.hxx>
26#include <Standard_Real.hxx>
27#include <TColStd_SequenceOfReal.hxx>
28#include <TColStd_SequenceOfInteger.hxx>
5d88fd54 29#include <Extrema_SequenceOfPOnCurv2d.hxx>
42cf5bc1 30#include <Standard_Boolean.hxx>
31#include <Standard_Integer.hxx>
32#include <math_FunctionWithDerivative.hxx>
33class Standard_OutOfRange;
34class Standard_TypeMismatch;
35class HLRBRep_CurveTool;
36class Extrema_POnCurv2d;
37class gp_Pnt2d;
38class gp_Vec2d;
42cf5bc1 39
40class HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter : public math_FunctionWithDerivative
41{
42public:
43
44 DEFINE_STANDARD_ALLOC
45
46
47 Standard_EXPORT HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter();
48
49 Standard_EXPORT HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter(const gp_Pnt2d& P, const Standard_Address& C);
50
36b9ff75 51 //! sets the field mycurve of the function.
42cf5bc1 52 Standard_EXPORT void Initialize (const Standard_Address& C);
53
36b9ff75 54 //! sets the field P of the function.
42cf5bc1 55 Standard_EXPORT void SetPoint (const gp_Pnt2d& P);
56
36b9ff75 57 //! Calculation of F(U).
79104795 58 Standard_EXPORT Standard_Boolean Value (const Standard_Real U, Standard_Real& F) Standard_OVERRIDE;
42cf5bc1 59
36b9ff75 60 //! Calculation of F'(U).
79104795 61 Standard_EXPORT Standard_Boolean Derivative (const Standard_Real U, Standard_Real& DF) Standard_OVERRIDE;
42cf5bc1 62
36b9ff75 63 //! Calculation of F(U) and F'(U).
79104795 64 Standard_EXPORT Standard_Boolean Values (const Standard_Real U, Standard_Real& F, Standard_Real& DF) Standard_OVERRIDE;
42cf5bc1 65
36b9ff75 66 //! Save the found extremum.
42cf5bc1 67 Standard_EXPORT virtual Standard_Integer GetStateNumber() Standard_OVERRIDE;
68
36b9ff75 69 //! Return the nunber of found extrema.
42cf5bc1 70 Standard_EXPORT Standard_Integer NbExt() const;
71
36b9ff75 72 //! Returns the Nth distance.
42cf5bc1 73 Standard_EXPORT Standard_Real SquareDistance (const Standard_Integer N) const;
74
36b9ff75 75 //! Shows if the Nth distance is a minimum.
42cf5bc1 76 Standard_EXPORT Standard_Boolean IsMin (const Standard_Integer N) const;
77
36b9ff75 78 //! Returns the Nth extremum.
42cf5bc1 79 Standard_EXPORT const Extrema_POnCurv2d& Point (const Standard_Integer N) const;
80
36b9ff75 81 //! Determines boundaries of subinterval for find of root.
42cf5bc1 82 Standard_EXPORT void SubIntervalInitialize (const Standard_Real theUfirst, const Standard_Real theUlast);
83
36b9ff75 84 //! Computes a Tol value. If 1st derivative of curve
85 //! |D1|<Tol, it is considered D1=0.
42cf5bc1 86 Standard_EXPORT Standard_Real SearchOfTolerance();
87
88
89
90
91protected:
92
93
94
95
96
97private:
98
99
100
101 gp_Pnt2d myP;
102 Standard_Address myC;
103 Standard_Real myU;
104 gp_Pnt2d myPc;
105 Standard_Real myD1f;
106 TColStd_SequenceOfReal mySqDist;
107 TColStd_SequenceOfInteger myIsMin;
5d88fd54 108 Extrema_SequenceOfPOnCurv2d myPoint;
42cf5bc1 109 Standard_Boolean myPinit;
110 Standard_Boolean myCinit;
111 Standard_Boolean myD1Init;
112 Standard_Real myTol;
113 Standard_Integer myMaxDerivOrder;
114 Standard_Real myUinfium;
115 Standard_Real myUsupremum;
116
117
118};
119
120
121
122
123
124
125
126#endif // _HLRBRep_PCLocFOfTheLocateExtPCOfTheProjPCurOfCInter_HeaderFile