File Updateforcing.h
FileList > src > Updateforcing.h
Go to the source code of this file
#include "General.h"
#include "Param.h"
#include "Arrays.h"
#include "Forcing.h"
#include "InitialConditions.h"
#include "MemManagement.h"
#include "ReadForcing.h"
#include "GridManip.h"
#include "Util_CPU.h"
Public Functions
Type | Name |
---|---|
__global__ void | AddDeformGPU (Param XParam, BlockP< T > XBlock, deformmap< float > defmap, EvolvingP< T > XEv, T scale, T * zb) Perform a deformation step on the model on the GPU. Applies deformation maps to the model based on the current simulation time and deformation parameters. |
__host__ void | AddPatmforcingCPU (Param XParam, BlockP< T > XBlock, DynForcingP< float > PAtm, Model< T > XModel) Add atmospheric pressure forcing to the model on the CPU. Adds atmospheric pressure forcing to the model based on pressure data and current simulation time. |
__global__ void | AddPatmforcingGPU (Param XParam, BlockP< T > XBlock, DynForcingP< float > PAtm, Model< T > XModel) Add atmospheric pressure forcing to the model on the GPU. Adds atmospheric pressure forcing to the model based on pressure data and current simulation time. |
__host__ void | AddRiverForcing (Param XParam, Loop< T > XLoop, std::vector< River > XRivers, Model< T > XModel) Add river forcing to the model. Adds river discharge forcing to the model based on river data and current simulation time. |
__host__ void | AddinfiltrationImplicitCPU (Param XParam, Loop< T > XLoop, BlockP< T > XBlock, T * il, T * cl, EvolvingP< T > XEv, T * hgw) Add infiltration forcing to the model implicitly on the CPU. Adds infiltration forcing to the model based on infiltration data and current water depth, updating water depth and surface elevation. |
__global__ void | AddinfiltrationImplicitGPU (Param XParam, Loop< T > XLoop, BlockP< T > XBlock, T * il, T * cl, EvolvingP< T > XEv, T * hgw) Add infiltration forcing to the model implicitly on the GPU. Adds infiltration forcing to the model based on infiltration data and current water depth, updating water depth and surface elevation. |
__host__ void | AddrainforcingCPU (Param XParam, BlockP< T > XBlock, DynForcingP< float > Rain, AdvanceP< T > XAdv) Add rainfall forcing to the model on the CPU. Adds rainfall forcing to the model based on rainfall data and current simulation time. |
__global__ void | AddrainforcingGPU (Param XParam, BlockP< T > XBlock, DynForcingP< float > Rain, AdvanceP< T > XAdv) Add rainfall forcing to the model on the GPU. Adds rainfall forcing to the model based on rainfall data and current simulation time. |
__host__ void | AddrainforcingImplicitCPU (Param XParam, Loop< T > XLoop, BlockP< T > XBlock, DynForcingP< float > Rain, EvolvingP< T > XEv) Add rainfall forcing to the model implicitly on the CPU. Adds rainfall forcing to the model based on rainfall data and current simulation time, updating water depth and surface elevation. |
__global__ void | AddrainforcingImplicitGPU (Param XParam, Loop< T > XLoop, BlockP< T > XBlock, DynForcingP< float > Rain, EvolvingP< T > XEv) Add rainfall forcing to the model implicitly on the GPU. Adds rainfall forcing to the model based on rainfall data and current simulation time, updating water depth and surface elevation. |
__host__ void | AddwindforcingCPU (Param XParam, BlockP< T > XBlock, DynForcingP< float > Uwind, DynForcingP< float > Vwind, AdvanceP< T > XAdv) Add wind forcing to the model on the CPU. Adds wind forcing to the model based on wind data and current simulation time. |
__global__ void | AddwindforcingGPU (Param XParam, BlockP< T > XBlock, DynForcingP< float > Uwind, DynForcingP< float > Vwind, AdvanceP< T > XAdv) Add wind forcing to the model on the GPU. Adds wind forcing to the model based on wind data and current simulation time. |
void | Forcingthisstep (Param XParam, double totaltime, DynForcingP< float > & XDynForcing) Update dynamic forcing for the current simulation step. |
__global__ void | InjectRiverGPU (Param XParam, River XRiver, T qnow, int * Riverblks, BlockP< T > XBlock, AdvanceP< T > XAdv) Inject river discharge into the model grid on the GPU. Injects river discharge into the model grid based on river geometry and discharge rate. |
void | deformstep (Param XParam, Loop< T > XLoop, std::vector< deformmap< float > > deform, Model< T > XModel, Model< T > XModel_g) Perform a deformation step on the model. Applies deformation maps to the model based on the current simulation time and deformation parameters. Overloaded function to handle both CPU and GPU models. |
__device__ T | interpDyn2BUQ (T x, T y, TexSetP Forcing) Interpolate dynamic forcing data at given coordinates on the GPU. Interpolates dynamic forcing data at specified coordinates using bilinear interpolation. |
void | updateforcing (Param XParam, Loop< T > XLoop, Forcing< float > & XForcing) Update dynamic forcings for the current simulation step. Updates the dynamic forcing data for the current simulation time step. |
Public Functions Documentation
function AddDeformGPU
Perform a deformation step on the model on the GPU. Applies deformation maps to the model based on the current simulation time and deformation parameters.
template<class T>
__global__ void AddDeformGPU (
Param XParam,
BlockP < T > XBlock,
deformmap < float > defmap,
EvolvingP < T > XEv,
T scale,
T * zb
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationdeform
Vector of deformation mapsXModel
Model data structure for GPU
function AddPatmforcingCPU
Add atmospheric pressure forcing to the model on the CPU. Adds atmospheric pressure forcing to the model based on pressure data and current simulation time.
template<class T>
__host__ void AddPatmforcingCPU (
Param XParam,
BlockP < T > XBlock,
DynForcingP < float > PAtm,
Model < T > XModel
)
Parameters:
XParam
Model parametersXBlock
Block data structurePAtm
Atmospheric pressure dynamic forcing structureXModel
Model data structure
function AddPatmforcingGPU
Add atmospheric pressure forcing to the model on the GPU. Adds atmospheric pressure forcing to the model based on pressure data and current simulation time.
template<class T>
__global__ void AddPatmforcingGPU (
Param XParam,
BlockP < T > XBlock,
DynForcingP < float > PAtm,
Model < T > XModel
)
Parameters:
XParam
Model parametersXBlock
Block data structurePAtm
Atmospheric pressure dynamic forcing structureXModel
Model data structure
function AddRiverForcing
Add river forcing to the model. Adds river discharge forcing to the model based on river data and current simulation time.
template<class T>
__host__ void AddRiverForcing (
Param XParam,
Loop < T > XLoop,
std::vector< River > XRivers,
Model < T > XModel
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationXRivers
Vector of river data structuresXModel
Model data structure
function AddinfiltrationImplicitCPU
Add infiltration forcing to the model implicitly on the CPU. Adds infiltration forcing to the model based on infiltration data and current water depth, updating water depth and surface elevation.
template<class T>
__host__ void AddinfiltrationImplicitCPU (
Param XParam,
Loop < T > XLoop,
BlockP < T > XBlock,
T * il,
T * cl,
EvolvingP < T > XEv,
T * hgw
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationXBlock
Block data structureil
Initial infiltration rates arraycl
Continuous infiltration rates arrayXEv
Evolving data structurehgw
Groundwater height array
function AddinfiltrationImplicitGPU
Add infiltration forcing to the model implicitly on the GPU. Adds infiltration forcing to the model based on infiltration data and current water depth, updating water depth and surface elevation.
template<class T>
__global__ void AddinfiltrationImplicitGPU (
Param XParam,
Loop < T > XLoop,
BlockP < T > XBlock,
T * il,
T * cl,
EvolvingP < T > XEv,
T * hgw
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationXBlock
Block data structureil
Initial infiltration rates arraycl
Continuous infiltration rates arrayXEv
Evolving data structurehgw
Groundwater height array
function AddrainforcingCPU
Add rainfall forcing to the model on the CPU. Adds rainfall forcing to the model based on rainfall data and current simulation time.
template<class T>
__host__ void AddrainforcingCPU (
Param XParam,
BlockP < T > XBlock,
DynForcingP < float > Rain,
AdvanceP < T > XAdv
)
Parameters:
XParam
Model parametersXBlock
Block data structureRain
Rainfall dynamic forcing structureXAdv
Advance data structure
function AddrainforcingGPU
Add rainfall forcing to the model on the GPU. Adds rainfall forcing to the model based on rainfall data and current simulation time.
template<class T>
__global__ void AddrainforcingGPU (
Param XParam,
BlockP < T > XBlock,
DynForcingP < float > Rain,
AdvanceP < T > XAdv
)
Parameters:
XParam
Model parametersXBlock
Block data structureRain
Rainfall dynamic forcing structureXAdv
Advance data structure
function AddrainforcingImplicitCPU
Add rainfall forcing to the model implicitly on the CPU. Adds rainfall forcing to the model based on rainfall data and current simulation time, updating water depth and surface elevation.
template<class T>
__host__ void AddrainforcingImplicitCPU (
Param XParam,
Loop < T > XLoop,
BlockP < T > XBlock,
DynForcingP < float > Rain,
EvolvingP < T > XEv
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationXBlock
Block data structureRain
Rainfall dynamic forcing structureXEv
Evolving data structure
function AddrainforcingImplicitGPU
Add rainfall forcing to the model implicitly on the GPU. Adds rainfall forcing to the model based on rainfall data and current simulation time, updating water depth and surface elevation.
template<class T>
__global__ void AddrainforcingImplicitGPU (
Param XParam,
Loop < T > XLoop,
BlockP < T > XBlock,
DynForcingP < float > Rain,
EvolvingP < T > XEv
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationXBlock
Block data structureRain
Rainfall dynamic forcing structureXEv
Evolving data structure
function AddwindforcingCPU
Add wind forcing to the model on the CPU. Adds wind forcing to the model based on wind data and current simulation time.
template<class T>
__host__ void AddwindforcingCPU (
Param XParam,
BlockP < T > XBlock,
DynForcingP < float > Uwind,
DynForcingP < float > Vwind,
AdvanceP < T > XAdv
)
Parameters:
XParam
Model parametersXBlock
Block data structureUwind
U-component of wind dynamic forcing structureVwind
V-component of wind dynamic forcing structureXAdv
Advance data structure
function AddwindforcingGPU
Add wind forcing to the model on the GPU. Adds wind forcing to the model based on wind data and current simulation time.
template<class T>
__global__ void AddwindforcingGPU (
Param XParam,
BlockP < T > XBlock,
DynForcingP < float > Uwind,
DynForcingP < float > Vwind,
AdvanceP < T > XAdv
)
Parameters:
XParam
Model parametersXBlock
Block data structureUwind
U-component of wind dynamic forcing structureVwind
V-component of wind dynamic forcing structureXAdv
Advance data structure
function Forcingthisstep
Update dynamic forcing for the current simulation step.
Updates the dynamic forcing data for the current simulation time step, handling uniform and non-uniform cases.
Parameters:
XParam
Model parameterstotaltime
Current simulation timeXDynForcing
Dynamic forcing structure to update
function InjectRiverGPU
Inject river discharge into the model grid on the GPU. Injects river discharge into the model grid based on river geometry and discharge rate.
template<class T>
__global__ void InjectRiverGPU (
Param XParam,
River XRiver,
T qnow,
int * Riverblks,
BlockP < T > XBlock,
AdvanceP < T > XAdv
)
Parameters:
XParam
Model parametersXRiver
River data structureqnow
Current river discharge rateRiverblks
Array of blocks affected by the riverXBlock
Block data structureXAdv
Advance data structure
function deformstep
Perform a deformation step on the model. Applies deformation maps to the model based on the current simulation time and deformation parameters. Overloaded function to handle both CPU and GPU models.
template<class T>
void deformstep (
Param XParam,
Loop < T > XLoop,
std::vector< deformmap < float > > deform,
Model < T > XModel,
Model < T > XModel_g
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationdeform
Vector of deformation mapsXModel
Model data structureXModel_g
Model data structure for GPU
function interpDyn2BUQ
Interpolate dynamic forcing data at given coordinates on the GPU. Interpolates dynamic forcing data at specified coordinates using bilinear interpolation.
Parameters:
x
X-coordinatey
Y-coordinate- Forcing Dynamic forcing data structure
function updateforcing
Update dynamic forcings for the current simulation step. Updates the dynamic forcing data for the current simulation time step.
template<class T>
void updateforcing (
Param XParam,
Loop < T > XLoop,
Forcing < float > & XForcing
)
Parameters:
XParam
Model parametersXLoop
Loop structure containing time informationXForcing
Forcing data structure to update
The documentation for this class was generated from the following file src/Updateforcing.h