Subversion Repositories public iLand

Rev

Rev 262 | Rev 277 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 262 Rev 265
Line 136... Line 136...
136
    double interception_fraction = 1. - exp(-k * LAI);
136
    double interception_fraction = 1. - exp(-k * LAI);
137
    mEffectiveArea = mStockedArea * interception_fraction; // m2
137
    mEffectiveArea = mStockedArea * interception_fraction; // m2
138
138
139
    // calculate the total weighted leaf area on this RU:
139
    // calculate the total weighted leaf area on this RU:
140
    mLRI_modification = interception_fraction *  mStockedArea / mAggregatedWLA;
140
    mLRI_modification = interception_fraction *  mStockedArea / mAggregatedWLA;
-
 
141
    if (mLRI_modification == 0.)
-
 
142
        qDebug() << "lri modifaction==0!";
141
143
142
144
143
    DBGMODE(qDebug() << QString("production: LAI: %1 (intercepted fraction: %2, stocked area: %4). LRI-Multiplier: %3")
145
    DBGMODE(qDebug() << QString("production: LAI: %1 (intercepted fraction: %2, stocked area: %4). LRI-Multiplier: %3")
144
            .arg(LAI)
146
            .arg(LAI)
145
            .arg(interception_fraction)
147
            .arg(interception_fraction)
Line 165... Line 167...
165
    }
167
    }
166
}
168
}
167
169
168
void ResourceUnit::calculateInterceptedArea()
170
void ResourceUnit::calculateInterceptedArea()
169
{
171
{
-
 
172
    if (mAggregatedLR==0) {
-
 
173
        mEffectiveArea_perWLA = 0.;
-
 
174
        return;
-
 
175
    }
170
    Q_ASSERT(mAggregatedLR>0.);
176
    Q_ASSERT(mAggregatedLR>0.);
171
    mEffectiveArea_perWLA = mEffectiveArea / mAggregatedLR;
177
    mEffectiveArea_perWLA = mEffectiveArea / mAggregatedLR;
172
    qDebug() << "RU: aggregated lightresponse:" << mAggregatedLR  << "eff.area./wla:" << mEffectiveArea_perWLA;
178
    qDebug() << "RU: aggregated lightresponse:" << mAggregatedLR  << "eff.area./wla:" << mEffectiveArea_perWLA;
173
}
179
}
174
180