File indexing completed on 2026-09-27 09:16:46
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017 #ifndef _AppDef_LinearCriteria_HeaderFile
0018 #define _AppDef_LinearCriteria_HeaderFile
0019
0020 #include <Standard.hxx>
0021
0022 #include <AppDef_MultiLine.hxx>
0023 #include <Standard_Real.hxx>
0024 #include <Standard_Integer.hxx>
0025 #include <AppDef_SmoothCriterion.hxx>
0026 #include <NCollection_Array1.hxx>
0027 #include <NCollection_HArray1.hxx>
0028 #include <NCollection_Array2.hxx>
0029 #include <NCollection_HArray2.hxx>
0030 #include <math_Vector.hxx>
0031 class FEmTool_ElementaryCriterion;
0032 class FEmTool_Curve;
0033 class math_Matrix;
0034
0035
0036
0037 class AppDef_LinearCriteria : public AppDef_SmoothCriterion
0038 {
0039
0040 public:
0041 Standard_EXPORT AppDef_LinearCriteria(const AppDef_MultiLine& SSP,
0042 const int FirstPoint,
0043 const int LastPoint);
0044
0045 Standard_EXPORT void SetParameters(
0046 const occ::handle<NCollection_HArray1<double>>& Parameters) override;
0047
0048 Standard_EXPORT void SetCurve(const occ::handle<FEmTool_Curve>& C) override;
0049
0050 Standard_EXPORT void GetCurve(occ::handle<FEmTool_Curve>& C) const override;
0051
0052 Standard_EXPORT void SetEstimation(const double E1, const double E2, const double E3) override;
0053
0054 Standard_EXPORT double& EstLength() override;
0055
0056 Standard_EXPORT void GetEstimation(double& E1, double& E2, double& E3) const override;
0057
0058 Standard_EXPORT occ::handle<NCollection_HArray2<occ::handle<NCollection_HArray1<int>>>>
0059 AssemblyTable() const override;
0060
0061 Standard_EXPORT occ::handle<NCollection_HArray2<int>> DependenceTable() const override;
0062
0063 Standard_EXPORT int QualityValues(const double J1min,
0064 const double J2min,
0065 const double J3min,
0066 double& J1,
0067 double& J2,
0068 double& J3) override;
0069
0070 Standard_EXPORT void ErrorValues(double& MaxError,
0071 double& QuadraticError,
0072 double& AverageError) override;
0073
0074 Standard_EXPORT void Hessian(const int Element,
0075 const int Dimension1,
0076 const int Dimension2,
0077 math_Matrix& H) override;
0078
0079 Standard_EXPORT void Gradient(const int Element, const int Dimension, math_Vector& G) override;
0080
0081
0082 Standard_EXPORT void InputVector(
0083 const math_Vector& X,
0084 const occ::handle<NCollection_HArray2<occ::handle<NCollection_HArray1<int>>>>& AssTable)
0085 override;
0086
0087 Standard_EXPORT void SetWeight(const double QuadraticWeight,
0088 const double QualityWeight,
0089 const double percentJ1,
0090 const double percentJ2,
0091 const double percentJ3) override;
0092
0093 Standard_EXPORT void GetWeight(double& QuadraticWeight, double& QualityWeight) const override;
0094
0095 Standard_EXPORT void SetWeight(const NCollection_Array1<double>& Weight) override;
0096
0097 DEFINE_STANDARD_RTTIEXT(AppDef_LinearCriteria, AppDef_SmoothCriterion)
0098
0099 private:
0100 Standard_EXPORT void BuildCache(const int E);
0101
0102 AppDef_MultiLine mySSP;
0103 occ::handle<NCollection_HArray1<double>> myParameters;
0104 occ::handle<NCollection_HArray1<double>> myCache;
0105 occ::handle<FEmTool_ElementaryCriterion> myCriteria[3];
0106 double myEstimation[3];
0107 double myQuadraticWeight;
0108 double myQualityWeight;
0109 double myPercent[3];
0110 NCollection_Array1<double> myPntWeight;
0111 occ::handle<FEmTool_Curve> myCurve;
0112 double myLength;
0113 int myE;
0114 int IF;
0115 int IL;
0116 };
0117
0118 #endif