English Français

Documentation / Manuel développeur

Modules disponibles

Calibration,  DataServer,  Launcher,  MetaModelOptim,  Modeler,  Optimizer,  ReLauncher,  Reliability,  ReOptimizer,  Sampler,  Sensitivity,  UncertModeler,  XmlProblem,   Uranie / Sampler: TSamplingMixture.h Source File
Uranie / Sampler v4.9.0
/* @license-end */
TSamplingMixture.h
Go to the documentation of this file.
1
2// Copyright (C) 2013-2024 CEA/DES
3//
4// This program is free software: you can redistribute it and/or modify
5// it under the terms of the GNU Lesser General Public License as published
6// by the Free Software Foundation, either version 3 of the License, or any
7// later version.
8//
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU Lesser General Public License for more details.
13//
14// You should have received a copy of the GNU Lesser General Public License
15// along with this program. If not, see <http://www.gnu.org/licenses/>.
18// $Id$
19// $Author$
20// $Date$
21// $Revision$
22// $State$
24
31#ifndef TSAMPLINGMIXTURE_H
32#define TSAMPLINGMIXTURE_H
62#include <iostream>
63using std::cout;
64using std::endl;
65
67#include "TVectorD.h"
68
70#include "simplex.h"
71
72#include "TSamplerDeterminist.h"
73
74namespace URANIE
75{
76namespace Sampler
77{
79{
80
81 // Attributes
82public:
92private:
97
98 Double_t _dThreshold;
99 vector<vector<double> > _planes;
100 Simplex *_simplex;
101
102 Bool_t _bSummits;
106 Bool_t _bCentroide;
108
110
113
115 Bool_t _bTrace;
116 TString _sTraceFile;
117
118 // Operations
120 void fillListOfCandidatesPoints(list<vector<double> > lst, EType typePoint);
123public:
124 //---------------------------------------------
128
136 TSamplingMixture(URANIE::DataServer::TDataServer *tds, Int_t ns,
137 Double_t dThreshold = 1.0, Option_t *option = "");
138
142
151 void init();
153
154 //---------------------------------------------
158
172 {
173 return _sAttNameCandidate.Data();
174 }
175
177
181 {
182 return _sAttNameTypeOfPoints.Data();
183 }
184
186
190 {
191 return _nGenerateSample;
192 }
194
199 void setTrace(TString straceFile = "");
202 {
203 _bTrace = kFALSE;
204 }
206 Bool_t getTrace()
207 {
208 return _bTrace;
209 }
211 TString getTraceFile();
212
215 {
216 _bSummits = kTRUE;
217 }
220 {
221 _bSummits = kFALSE;
222 }
225 {
226 _bCenterEdges = kTRUE;
227 }
230 {
231 _bCenterEdges = kFALSE;
232 }
233
236 {
237 _bThirdEdges = kTRUE;
238 }
241 {
242 _bThirdEdges = kFALSE;
243 }
244
247 {
248 _bCenterFaces = kTRUE;
249 }
252 {
253 _bCenterFaces = kFALSE;
254 }
255
258 {
259 _bCentroide = kTRUE;
260 }
263 {
264 _bCentroide = kFALSE;
265 }
266
269 {
270 _bCenterSegments = kTRUE;
271 }
274 {
275 _bCenterSegments = kFALSE;
276 }
277
280 {
281 _bSaveCandidates = kTRUE;
282 }
285 {
286 _bSaveCandidates = kFALSE;
287 }
290 {
291 return _bSaveCandidates;
292 }
294
295 //---------------------------------------------
299
307 void addConstraint(TVectorD vecConstraint);
309
310 //---------------------------------------------
314
321 virtual void generateSample(Option_t *option = "MD");
323
326 void generateCandidates(Option_t *option);
328
329 //---------------------------------------------
333
334 virtual void printLog(Option_t *option = "");
336
337 ClassDef(URANIE::Sampler::TSamplingMixture, ID_SAMPLER)
338 // Classe to generate mixture sampling
339};
340} // Fin du namespace Sampler
341} // Fin du namespace URANIE
342
343#endif
344// fin du fichier $RCSfile$.
Creation of the abstract class TSamplerDeterminist.
Definition TSamplerDeterminist.h:44
Interface with the simplex class developped by B. Secher (LGLS).
Definition TSamplingMixture.h:79
TString _sTraceFile
The name of the trace file.
Definition TSamplingMixture.h:116
Int_t getNGeneratedSample()
Return the number of call of the generateSample method.
Definition TSamplingMixture.h:189
void unsetCenterEdges()
Unset the Flag of CenterEdges.
Definition TSamplingMixture.h:229
const char * getNameInternalAttributeCandidatesPoints()
Return the name of the internal attribute to known if point is a candidates point ( equal to 0) or no...
Definition TSamplingMixture.h:171
TSamplingMixture(URANIE::DataServer::TDataServer *tds, Int_t ns, Double_t dThreshold=1.0, Option_t *option="")
Constructor from a TDataServer, the name of the method and the size of the sample.
void unsetSummits()
Unset the Flag of summits.
Definition TSamplingMixture.h:219
void unsetTrace()
Unset trace.
Definition TSamplingMixture.h:201
void setCenterFaces()
Set the Flag of CenterFaces.
Definition TSamplingMixture.h:246
void setThirdEdges()
Set the Flag of ThirdEdges.
Definition TSamplingMixture.h:235
void setSummits()
Set the Flag of summits.
Definition TSamplingMixture.h:214
Bool_t _bSaveCandidates
Flag for saving candidates points.
Definition TSamplingMixture.h:109
virtual ~TSamplingMixture()
Default destructor.
virtual void generateSample(Option_t *option="MD")
Generates the sample.
Set The List of Candidates Points void setListOfCandidatesPoints()
const char * getNameInternalAttributeTypePoints()
Return the name of the internal attribute to known the type of points.
Definition TSamplingMixture.h:180
Double_t _dThreshold
constraint: \sum{x_{i} = dThreshold
Definition TSamplingMixture.h:98
void unsetThirdEdges()
Unset the Flag of ThirdEdges.
Definition TSamplingMixture.h:240
Simplex * _simplex
Simplex Classe from B. Secher.
Definition TSamplingMixture.h:100
Bool_t getTrace()
Return the trace flag.
Definition TSamplingMixture.h:206
Bool_t _bCenterSegments
Flag for the CenterSegments.
Definition TSamplingMixture.h:107
vector< vector< double > > _planes
The matrix of contraintes.
Definition TSamplingMixture.h:99
Int_t _nGenerateSample
The index of times that the generateSample method is call.
Definition TSamplingMixture.h:114
ERelation
Definition TSamplingMixture.h:94
@ kLower
Definition TSamplingMixture.h:95
@ kUpper
Definition TSamplingMixture.h:95
Bool_t _bCenterFaces
Flag for the CenterFaces.
Definition TSamplingMixture.h:105
void setSaveCandidates()
Set the Flag of save candidates.
Definition TSamplingMixture.h:279
void unsetCenterFaces()
Unset the Flag of CenterFaces.
Definition TSamplingMixture.h:251
void unsetCenterSegments()
Unset the Flag of CenterSegments.
Definition TSamplingMixture.h:273
Fill the list of points in the TDS with a type void fillListOfCandidatesPoints(list< vector< double > > lst, EType typePoint)
void unsetSaveCandidates()
Unset the Flag of CenterSegments.
Definition TSamplingMixture.h:284
EType
Definition TSamplingMixture.h:84
@ kCenterEdge
Definition TSamplingMixture.h:86
@ kCenterSegment
Definition TSamplingMixture.h:89
@ kCenterFace
Definition TSamplingMixture.h:88
@ kSummit
Definition TSamplingMixture.h:85
@ kThirdEdge
Definition TSamplingMixture.h:87
@ kCentroide
Definition TSamplingMixture.h:90
TString _sAttNameTypeOfPoints
Name of the internal attribute for the type of points Etype (kSummit, kCenterEdge,...
Definition TSamplingMixture.h:111
Bool_t _bTrace
The flag to known is trace is needed.
Definition TSamplingMixture.h:115
void setCentroide()
Set the Flag of Centroide.
Definition TSamplingMixture.h:257
Bool_t isSaveCandidates()
Return isSaveCandidates.
Definition TSamplingMixture.h:289
Bool_t _bCenterEdges
Flag for the CenterEdges.
Definition TSamplingMixture.h:103
void unsetCentroide()
Unset the Flag of Centroide.
Definition TSamplingMixture.h:262
virtual void printLog(Option_t *option="")
Prints the log.
void setCenterSegments()
Set the Flag of CenterSegments.
Definition TSamplingMixture.h:268
void addConstraint(TVectorD vecConstraint)
Add the constraint defined in a vector.
TString _sAttNameCandidate
Name of the internal attribute for candidates points(1) else 0.
Definition TSamplingMixture.h:112
Bool_t _bThirdEdges
Flag for the ThirdEdges.
Definition TSamplingMixture.h:104
void generateCandidates(Option_t *option)
Generates the list of candidates.
void init()
The init method.
void setCenterEdges()
Set the Flag of CenterEdges.
Definition TSamplingMixture.h:224
Bool_t _bSummits
Flag for the summits.
Definition TSamplingMixture.h:102
void setTrace(TString straceFile="")
Activate the trace of the process.
TString getTraceFile()
Return the name of the trace file.
Bool_t _bCentroide
Flag for the Centroide.
Definition TSamplingMixture.h:106
Definition TAMHCopula.h:60