Skip to contents

Extrapolate water flow calculated on J2000 network on river segments of the Topage network using specific flow hypothesis.

Usage

TnetJ2K_computeQ(path_data, path_export, shapefile)

Arguments

path_data

string Path to the folder containing all files created by TnetJ2K_readfiles()

path_export

string Path where NetCDF file will be exported

shapefile

string Path to the shapefile with all info on segments. All needed columns are in details section.

Value

Downstream flow data on Topage segments as NetCDF file in path_export folder (Qaval.nc).

Details

Before using this function, all Topage segments must have been linked to a J2000 segment. Furthermore, TNETshape_computeCoefQcalc() must be execute before in order to have the rignt ratios in order to dispatch discharge data on Topage network
Water flow on each Topage segment will be calculated using the following formulas:

\(RppAr\_v\) and \(air\_strNFS\) can be calculate with the function TNETshape_computeCoefQcalc()

Calculate Downstream flow (\(Q_{\text{aval}}\))
$$Q_{\text{aval}} = Q_{\text{J2000}} \cdot RppAr\_v$$

where: \(RppAr\_v = \frac{\text{Area drain downstream of Topage segment}}{\text{Area drain downstream of J2000 reference segment}}\)

Columns needed in shapefile

\(gid\_new\)ID of the Topage segment
\(J2000\)ID of the J2000 reference segment
\(RppAr\_v\)The fraction of the area drained downstream of the Topage segment relative to the J2000 reference segment (see details section).

Examples

TnetJ2K_computeQ(path_data = "path/to/data",
              path_export = "path/export/folder",
              shapefile = "path/to/shapefile.shp")
#> ⠙ Computing discharge data (Q): Preparing computations
#> Error: Cannot open "path/to/shapefile.shp"; The file doesn't seem to exist.
#>  Computing discharge data (Q): Preparing computations [8ms]
#> 
              
              
              
############################################################
## Using this function with TNET_initializeSim() function ##
############################################################
infoSimu <- TNET_initializeSim(...)
#> Error: '...' used in an incorrect context

TNET_readJ2K(...) #Read ReachLoop.dat file
#> Error: '...' used in an incorrect context

TnetJ2K_computeQ(path_data = infoSimu$path_Export_tmp, 
              path_export = infoSimu$hydroPath,
              shapefile = infoSimu$TOPAGE_shape)
#> Error: object 'infoSimu' not found