public Float computeInitialConditions ( String key , Map < String , String > fullCurrentSoil , Map < String , String > previousSoil ) { Float newValue = ( parseFloat ( fullCurrentSoil . get ( key ) ) * parseFloat ( fullCurrentSoil . get ( SLLB ) ) + parseFloat ( previousSoil . get ( key ) ) * parseFloat ( previousSoil . get ( SLLB ) ) ) ; newValue = newValue / ( parseFloat ( fullCurrentSoil . get ( SLLB ) ) + parseFloat ( previousSoil . get ( SLLB ) ) ) ; return newValue ; }
Perform initial condition convertion for icnh4 and icno3 it s important to take into account the deep of the layer for computing the aggregated value .