English Français

Documentation / Developer's manual

Available modules

Calibration,  DataServer,  Launcher,  MetaModelOptim,  Modeler,  Optimizer,  ReLauncher,  Reliability,  ReOptimizer,  Sampler,  Sensitivity,  UncertModeler,  XmlProblem,   Uranie / Optimizer: TMultiGenCode.h Source File
Uranie / Optimizer v4.9.0
/* @license-end */
TMultiGenCode.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
47#ifndef TMULTIGENCODE_H
48#define TMULTIGENCODE_H
49
50// ROOT
51#include "Math/IFunction.h"
52#include "TH1.h"
53#include "TF1.h"
54#include "TFile.h"
55#include "TNtupleD.h"
56#include "TTreeFormula.h"
57#include "TPad.h"
58#include "TRandom3.h"
59#include "TStyle.h"
60#include "TSystem.h"
61
62#include <vector>
63#include <iostream>
64
65// URANIE
66#include "Optimizer.h"
67#include "TCode.h"
68#include "TDataServer.h"
69
70namespace URANIE
71{
72namespace Optimizer
73{
74class TMultiGenCode: public ROOT::Math::IBaseFunctionMultiDim
75{
76
77public:
78 //---------------------------------------------
82
83 TMultiGenCode(URANIE::DataServer::TDataServer *tds,
84 URANIE::Launcher::TCode *code, TString scost);
87
88 //---------------------------------------------
92
93 void init();
95 void clean();
97
98 //---------------------------------------------
102
104 {
105 return new TMultiGenCode(_tds, _code, _sCost);
106 }
107
109 unsigned int NDim() const
110 {
111 return _ninput;
112 }
114
115 //---------------------------------------------
119 void setLog()
120 {
121 _blog = kTRUE;
122 }
123 void unsetLog()
124 {
125 _blog = kFALSE;
126 }
127
129 {
130 _blog = _blog ? kFALSE : kTRUE;
131 }
132 Bool_t getLog()
133 {
134 return _blog;
135 }
136
138 {
139 _bintermedstep = true;
140 }
142
143
144private:
145 //---------------------------------------------
149
150 double DoEval(const double * x) const;
152
153 Bool_t _blog;
155 TString _sinput;
157 double *_xin, *_codevalue;
162 TString _soutput;
163 double * _doutputValue;
164 TString _sCost;
165 Int_t _nCost;
166 URANIE::DataServer::TDataServer *_tds;
167 URANIE::Launcher::TCode *_code;
168 TNtupleD *_informTree;
169 vector<TTreeFormula*> _vinForm;
171
172 ClassDef(URANIE::Optimizer::TMultiGenCode, ID_OPTIMIZER)
173 //Classe de
174
175};
176} // Fin du namespace Optimizer
177} // Fin du namespace URANIE
178
180
181#endif
R__EXTERN URANIE::Optimizer::TMultiGenCode * gTMGC
Definition TMultiGenCode.h:179
NEWMAT::ColumnVector & x
Definition TOptimizerOpt.cxx:70
Definition TMultiGenCode.h:75
void changeLog()
Definition TMultiGenCode.h:128
int _noutput
Definition TMultiGenCode.h:159
unsigned int NDim() const
the NDIM method
Definition TMultiGenCode.h:109
void setLog()
Definition TMultiGenCode.h:119
TMultiGenCode(URANIE::DataServer::TDataServer *tds, URANIE::Launcher::TCode *code, TString scost)
Constructor with a dataserver.
void doNotSaveSteps()
Definition TMultiGenCode.h:137
bool _bintermedstep
Definition TMultiGenCode.h:170
TString _soutput
Name of the output attributes.
Definition TMultiGenCode.h:162
double DoEval(const double *x) const
the DoEval method
int _ninput
Definition TMultiGenCode.h:154
void clean()
The clean method.
TNtupleD * _informTree
Pointeur vers un TCode.
Definition TMultiGenCode.h:168
int * _codeindex
Definition TMultiGenCode.h:158
TString _sCost
The name of the selected cost (the number must be equal to 1)
Definition TMultiGenCode.h:164
URANIE::Launcher::TCode * _code
Pointeur vers un TDS.
Definition TMultiGenCode.h:167
void unsetLog()
Definition TMultiGenCode.h:123
Bool_t getLog()
Definition TMultiGenCode.h:132
TString _sinput
Name of the input attributes.
Definition TMultiGenCode.h:155
Bool_t _blog
Boolean for edit the log.
Definition TMultiGenCode.h:153
URANIE::DataServer::TDataServer * _tds
Definition TMultiGenCode.h:166
double * _dinputValue
Definition TMultiGenCode.h:156
void init()
The init method.
double * _xin
Definition TMultiGenCode.h:157
TMultiGenCode * Clone() const
The clone method.
Definition TMultiGenCode.h:103
vector< TTreeFormula * > _vinForm
Definition TMultiGenCode.h:169
int _noutformula
Definition TMultiGenCode.h:161
int _ninformula
Definition TMultiGenCode.h:160
Int_t _nCost
the current position for the selected cost in the output list of attribute
Definition TMultiGenCode.h:165
double * _codevalue
Definition TMultiGenCode.h:157
double * _doutputValue
The output attribute name.
Definition TMultiGenCode.h:163
Rosenbrock's function (n=2) with first and second order derivatives.
Definition TBestEstimate.h:58