Commit a8058f59 authored by RemiM's avatar RemiM Committed by Ronan Trepos
Browse files

Suppress useless covariables and add comments

parent 7d250993
......@@ -32,7 +32,7 @@ public :
Var FTHN;
// Remis Add
Var CT_RUE; // curve_thermal_rue
Var CT_RUE; // curve_thermal_rue (cf rsunflo::curve_thermal_rue(type = "high"))
bool first_compute;
ContrainteTemperature(const vle::devs::DynamicsInit& model,
......
......@@ -78,16 +78,6 @@ public :
// Sum of radiations during flowering
Var SGR_FM;
// Covariables to compute HI
// Jours de stress végétatifs (E1 - F1) (covariables statistiques)
Var NET_EF;
// Jours de stress végétatifs (F1 - M0) (covariables statistiques)
Var NET_FM;
// Jours de stress végétatifs (M0 - M3) (covariables statistiques)
Var NET_MH;
// Somme temps thermique après floraison (M0 - M3) (covariables statistiques)
Var TT_MH;
// Covariables to compute GY
......@@ -147,11 +137,6 @@ public :
FHTR.init(this, "FHTR", events);
CT_RUE.init(this, "CT_RUE", events);
////// Covariables HI
NET_EF.init(this, "NET_EF" , events);
NET_FM.init(this, "NET_FM" , events);
NET_MH.init(this, "NET_MH" , events);
TT_MH.init(this, "TT_MH" , events);
////// Covariables GY
SRR_EF.init(this, "SRR_EF", events);
......@@ -280,75 +265,7 @@ public :
}
{
if ( ETRETM() > pr.SeuilETRETM ){
NET_EF = NET_EF(-1);
} else if ( ( PhasePhenoPlante() >= PHASEPHENOPLANTE_FLORAISON)
&& ( PhasePhenoPlante() < PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 > date_TT_F1
NET_EF = NET_EF(-1);
} else if ( ( PhasePhenoPlante() < PHASEPHENOPLANTE_CROISSANCEACTIVE)
|| ( PhasePhenoPlante() >= PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 < date_TT_E1
NET_EF = NET_EF(-1);
} else {
NET_EF = NET_EF(-1) + 1;
}
}
{
if ( ETRETM() > pr.SeuilETRETM ){
NET_FM = NET_FM(-1);
} else if ( ( PhasePhenoPlante() >= PHASEPHENOPLANTE_MATURATION)
&& ( PhasePhenoPlante() < PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 > date_TT_M0
NET_FM = NET_FM(-1);
} else if ( ( PhasePhenoPlante() < PHASEPHENOPLANTE_FLORAISON)
|| ( PhasePhenoPlante() >= PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 < date_TT_F1
NET_FM = NET_FM(-1);
} else {
NET_FM = NET_FM(-1) + 1;
}
}
{
if ( ETRETM() > pr.SeuilETRETM ){
NET_MH = NET_MH(-1);
} else if ( ( PhasePhenoPlante() >= PHASEPHENOPLANTE_DESSICATION)
&& ( PhasePhenoPlante() < PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 > date_TT_M3
NET_MH = NET_MH(-1);
} else if ( ( PhasePhenoPlante() < PHASEPHENOPLANTE_MATURATION)
|| ( PhasePhenoPlante() >= PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 < date_TT_M0
NET_MH = NET_MH(-1);
} else {
NET_MH = NET_MH(-1) + 1;
}
}
{
if ( Tmoy() <= pp.Tbase ){
TT_MH = TT_MH(-1);
} else if ( ( PhasePhenoPlante() >= PHASEPHENOPLANTE_DESSICATION)
&& ( PhasePhenoPlante() < PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 > date_TT_M3
TT_MH = TT_MH(-1);
} else if ( ( PhasePhenoPlante() < PHASEPHENOPLANTE_MATURATION)
|| ( PhasePhenoPlante() >= PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 < date_TT_M0
TT_MH = TT_MH(-1);
} else {
TT_MH = TT_MH(-1) + (Tmoy() - pp.Tbase);
}
}
{
if ( (PhasePhenoPlante() < PHASEPHENOPLANTE_JUVENILE)
......
......@@ -46,15 +46,6 @@ public :
Var photo_RDT_aFinMATURATION;
// Jours de stress végétatifs (E1 - F1) (covariables statistiques)
Var NET_EF;
// Jours de stress végétatifs (F1 - M0) (covariables statistiques)
Var NET_FM;
// Jours de stress végétatifs (M0 - M3) (covariables statistiques)
Var NET_MH;
// Somme temps thermique après floraison (M0 - M3) (covariables statistiques)
Var TT_MH;
// Covariables to compute GY
// Somme précipitations durant la phase végétative (covariables statistiques)
......@@ -95,12 +86,6 @@ public :
photo_RDT_aFinMATURATION.init(this, "photo_RDT_aFinMATURATION" , events);
first_compute = true;
// Jours de stress végétatifs (E1 - F1) (covariables statistiques)
NET_EF.init(this, "NET_EF", events);
NET_FM.init(this, "NET_FM", events);
NET_MH.init(this, "NET_MH", events);
TT_MH.init(this, "TT_MH", events);
////// Covariables GY
SRR_EF.init(this, "SRR_EF", events);
SRR_FM.init(this, "SRR_FM", events);
......@@ -153,7 +138,7 @@ public :
}
{
/* {
double IRs_tmp = 0.0;
if ( ( PhasePhenoPlante() < PHASEPHENOPLANTE_FLORAISON)
......@@ -182,31 +167,18 @@ public :
photo_IRs_aFinMATURATION = photo_IRs_aFinMATURATION(-1);
} else {
photo_IRs_aFinMATURATION = photo_IRs_aFinMATURATION(-1);
}
} */
{
double RDT_tmp = 0.0;
if ( ( PhasePhenoPlante() >= PHASEPHENOPLANTE_DESSICATION )
&& ( PhasePhenoPlante() < PHASEPHENOPLANTE_RECOLTEE) ){
// traduit condition TT_A2 >= date_TT_M3
// RDT_tmp = TDM() * photo_IRs_aFinMATURATION() / 10.0;
// RDT_tmp = 0.1*(-15.81 + 0.025*photo_TDM_CROISSANCEACTIVE_A_FLORAISON() +
// 0.39147*NET_EF() - 0.45*NET_FM() - 0.058*NET_MH() + 0.016*TT_MH() + 62.19 * pv.IRg) ;
// RDT_tmp = 0.1*(-15.81 + 0.025*photo_TDM_CROISSANCEACTIVE_A_FLORAISON() +
// 0.39147*NET_EF() - 0.45*NET_FM() - 0.058*NET_MH() + 0.016*TT_MH() + 62.19 * pv.IRg) ;
RDT_tmp =0.1*(-16.12 + 58.35*pv.IRg + (-0.036)*SRR_EF() +
(-0.062)*SRR_FM() + 0.020*SIR_EF() + 0.075*SIR_FM() +
0.37*SFHTR_EF() + (-0.77)*SFHTR_FM() + (-69.84)*SHT_FM() + (-0.84)*SFNRUE_MH() + 0.011*pv.date_TT_M3);
} else {
//double dI = IRs() - IRs(-1);
//double dT = TDM() - TDM(-1);
//RDT_tmp = TDM() * IRs() / 10.0;
//RDT_tmp = RDT(-1) + (TDM(-1)*dI + IRs(-1)*dT +dI*dT)/ 10.0;
// RDT_tmp = 0.1*(-15.81 + 0.025*photo_TDM_CROISSANCEACTIVE_A_FLORAISON() +
// 0.39147*NET_EF() - 0.45*NET_FM() - 0.058*NET_MH() + 0.016*TT_MH() + 62.19 * pv.IRg) ;
// RDT_tmp = 0.1*(-15.81 + 0.025*photo_TDM_CROISSANCEACTIVE_A_FLORAISON() +
// 0.39147*NET_EF() - 0.45*NET_FM() - 0.058*NET_MH() + 0.016*TT_MH() + 62.19 * pv.IRg) ;
RDT_tmp =0.1*(-16.12 + 58.35*pv.IRg + (-0.036)*SRR_EF() +
(-0.062)*SRR_FM() + 0.020*SIR_EF() + 0.075*SIR_FM() +
0.37*SFHTR_EF() + (-0.77)*SFHTR_FM() + (-69.84)*SHT_FM() + (-0.84)*SFNRUE_MH() + 0.011*pv.date_TT_M3);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment