Peka2D_v5
v5.0
|
Functions | |
__global__ void | g_compute_cell_mass (int nTasks, t_arrays *arrays, double *mass) |
This function recounts and stores the total mass of all active cells. More... | |
__global__ void | g_initialize_delta (int nTasks, t_arrays *arrays) |
This function initializes the variation of conserved variables in the arrays structure to 0.0 and the array solidWallByCell to 0. More... | |
__global__ void | g_wall_rotated_calculus (int nTasks, t_arrays *arrays, double *localDt) |
This function initializes the variation of conserved variables in the arrays structure to 0.0 and the array solidWallByCell to 0. More... | |
__global__ void | g_get_dtmin (t_arrays *arrays, double *localDt, int *idmin) |
This function finds the minimum time step out of the vector localDt. If the whole domain is dry, it is set to 1.0 seconds. More... | |
__global__ void | g_update_contributions (int nTasks, t_arrays *arrays) |
This function computes the right-hand side of the equations to update each physical variable. More... | |
__global__ void | g_checkpos_h (int nTasks, t_arrays *arrays, int *check) |
This function checks the positivity of the water depth. If there is a cell where the depth is negative (-tol), it write a notification flag in variable check. More... | |
__global__ void | g_reduce_dt (t_arrays *arrays) |
This function multiplies the time step by a factor of 0.8 if the there is a change to get negative water depths (as checked in function c_checkpos_h). More... | |
__global__ void | g_set_new_dt (t_arrays *arrays) |
This function sets the new time step according to the dumping and final times. If the precomputed time step is too big, it is reduced to match the desired time. More... | |
__global__ void | g_update_cells (int nTasks, t_arrays *arrays) |
This function updates the water depth and water discharges (in wet cells). More... | |
__global__ void | g_check_wetdry (int nTasks, t_arrays *arrays) |
This function checks the presence of wet/dry fronts and writes flags to correct them later. More... | |
__global__ void | g_update_wetdry_cells (int nTasks, t_arrays *arrays) |
This function corrects the wet/dry fronts found in function c_check_wetdry. More... | |
__global__ void | g_compute_mass_error (t_arrays *arrays) |
This function computes the mass error of the current state with respect to the previous one (in %). More... | |
__global__ void | g_reconstruct_active_elements (int nTasks, t_arrays *arrays) |
This function computes the mass error of the current state with respect to the previous one (in %). More... | |
__device__ void | g_add_active_cells (t_arrays *arrays, int id) |
This function adds the newly wetted cells to the active cells set. More... | |
__device__ void | g_add_active_walls (t_arrays *arrays, int id) |
This function adds wall identified by index id to the active walls set. More... | |
__device__ void g_add_active_cells | ( | t_arrays * | arrays, |
int | id | ||
) |
This function adds the newly wetted cells to the active cells set.
arrays | This pointer variable passes the arrays structure. |
id | This integer variable passes the index of the wetted cell. |
__device__ void g_add_active_walls | ( | t_arrays * | arrays, |
int | id | ||
) |
This function adds wall identified by index id to the active walls set.
arrays | This pointer variable passes the arrays structure. |
id | This integer variable passes the index of the wetted cell. |
__global__ void g_check_wetdry | ( | int | nTasks, |
t_arrays * | arrays | ||
) |
This function checks the presence of wet/dry fronts and writes flags to correct them later.
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. |
__global__ void g_checkpos_h | ( | int | nTasks, |
t_arrays * | arrays, | ||
int * | check | ||
) |
This function checks the positivity of the water depth. If there is a cell where the depth is negative (-tol), it write a notification flag in variable check.
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. |
check | This integer acts as a flag to check the positivity of the water depth and is used in calculate.cpp to reduced the time step. |
__global__ void g_compute_cell_mass | ( | int | nTasks, |
t_arrays * | arrays, | ||
double * | mass | ||
) |
This function recounts and stores the total mass of all active cells.
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. |
mass | This pointer variable passes the mass variable to store it. |
__global__ void g_compute_mass_error | ( | t_arrays * | arrays | ) |
This function computes the mass error of the current state with respect to the previous one (in %).
arrays | This pointer variable passes the arrays structure. |
__global__ void g_get_dtmin | ( | t_arrays * | arrays, |
double * | localDt, | ||
int * | idmin | ||
) |
This function finds the minimum time step out of the vector localDt. If the whole domain is dry, it is set to 1.0 seconds.
arrays | This pointer variable passes the arrays structure. arrays->dt is modifed. |
localDt | This pointer variable contains the local time steps. |
idmin | This pointer variable indicates the component of the minimum time step. |
__global__ void g_initialize_delta | ( | int | nTasks, |
t_arrays * | arrays | ||
) |
This function initializes the variation of conserved variables in the arrays structure to 0.0 and the array solidWallByCell to 0.
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. |
__global__ void g_reconstruct_active_elements | ( | int | nTasks, |
t_arrays * | arrays | ||
) |
This function computes the mass error of the current state with respect to the previous one (in %).
arrays | This pointer variable passes the arrays structure. |
__global__ void g_reduce_dt | ( | t_arrays * | arrays | ) |
This function multiplies the time step by a factor of 0.8 if the there is a change to get negative water depths (as checked in function c_checkpos_h).
arrays | This pointer variable passes the arrays structure. |
__global__ void g_set_new_dt | ( | t_arrays * | arrays | ) |
This function sets the new time step according to the dumping and final times. If the precomputed time step is too big, it is reduced to match the desired time.
arrays | This pointer variable passes the arrays structure. |
__global__ void g_update_cells | ( | int | nTasks, |
t_arrays * | arrays | ||
) |
This function updates the water depth and water discharges (in wet cells).
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. |
__global__ void g_update_contributions | ( | int | nTasks, |
t_arrays * | arrays | ||
) |
This function computes the right-hand side of the equations to update each physical variable.
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. arrays->dt is modifed. |
__global__ void g_update_wetdry_cells | ( | int | nTasks, |
t_arrays * | arrays | ||
) |
This function corrects the wet/dry fronts found in function c_check_wetdry.
nTasks | This integer variable passes the number of times the computation needs to be done. |
arrays | This pointer variable passes the arrays structure. |
__global__ void g_wall_rotated_calculus | ( | int | nTasks, |
t_arrays * | arrays, | ||
double * | localDt | ||
) |
This function initializes the variation of conserved variables in the arrays structure to 0.0 and the array solidWallByCell to 0.
nTasks | This integer variable passes the number of times the computation needs to be done. |
localDt | This pointer variable gets the values of the local time steps. |