Header file for Colored LU-SGS method. More...

Go to the source code of this file.
Functions | |
| void | parallel_pre_lusgs (int neles, int nface, double factor, double *fnorm_vol, double *dt, double *diag, double *fspr) |
| Computes Diagonal matrix for Colored LU-SGS method. More... | |
| void | ns_parallel_lower_sweep (int n0, int ne, int neles, int nfvars, int nface, int ndims, int *nei_ele, int *icolor, int *lcolor, double *fnorm_vol, double *vec_fnorm, double *uptsb, double *rhsb, double *dub, double *diag, double *fspr) |
| Lower sweep of Colored LU-SGS method for Navier-Stokes equations. More... | |
| void | rans_parallel_lower_sweep (int n0, int ne, int neles, int nvars, int nfvars, int nface, int ndims, int *nei_ele, int *icolor, int *lcolor, double *fnorm_vol, double *vec_fnorm, double *uptsb, double *rhsb, double *dub, double *diag, double *fspr, double *dsrc) |
| Lower sweep of Colored LU-SGS method for RANS equations. More... | |
| void | ns_parallel_upper_sweep (int n0, int ne, int neles, int nfvars, int nface, int ndims, int *nei_ele, int *icolor, int *lcolor, double *fnorm_vol, double *vec_fnorm, double *uptsb, double *rhsb, double *dub, double *diag, double *fspr) |
| Upper sweep of Colored LU-SGS method for Navier-Stokes equations. More... | |
| void | rans_parallel_upper_sweep (int n0, int ne, int neles, int nvars, int nfvars, int nface, int ndims, int *nei_ele, int *icolor, int *lcolor, double *fnorm_vol, double *vec_fnorm, double *uptsb, double *rhsb, double *dub, double *diag, double *fspr, double *dsrc) |
| Upper sweep of Colored LU-SGS method for RANS equations. More... | |
| void | parallel_update (int neles, int nvars, double *uptsb, double *rhsb) |
| Updates solution array. More... | |
Header file for Colored LU-SGS method.
Declaration of each function used in Colored LU-SGS method. Parameters are explained here.
Definition in file coloredlusgs.h.
| void ns_parallel_lower_sweep | ( | int | n0, |
| int | ne, | ||
| int | neles, | ||
| int | nfvars, | ||
| int | nface, | ||
| int | ndims, | ||
| int * | nei_ele, | ||
| int * | icolor, | ||
| int * | lcolor, | ||
| double * | fnorm_vol, | ||
| double * | vec_fnorm, | ||
| double * | uptsb, | ||
| double * | rhsb, | ||
| double * | dub, | ||
| double * | diag, | ||
| double * | fspr | ||
| ) |
Lower sweep of Colored LU-SGS method for Navier-Stokes equations.
| n0 | First index for coloring set |
| ne | Last index for coloring set |
| neles | Number of element cells |
| nfvars | Number of flux variables |
| nface | Number of faces depends on element type |
| ndims | Dimensions |
| nei_ele | Indices for neighbor cells |
| icolor | Color Index of each cell |
| lcolor | Color level of each cell |
| fnorm_vol | Surface magnitude/cell volume |
| vec_fnorm | Surface vector |
| uptsb | Solution array |
| rhsb | Residual (RHS) array |
| dub | Difference array for update (output) |
| diag | Diagonal matrix array |
| fspr | Wave speed for each cell face |
This function computes diagonal matrix of the implicit operator. In LU-SGS method, implicit operator is replaced with spectral radius, so that all element except diagonal is zero. Therefore, diag array can be allocated as one-dimensional, which has less memory requirement.
Diffusive margin of wave speed is applied.
Definition at line 82 of file coloredlusgs.c.


| void ns_parallel_upper_sweep | ( | int | n0, |
| int | ne, | ||
| int | neles, | ||
| int | nfvars, | ||
| int | nface, | ||
| int | ndims, | ||
| int * | nei_ele, | ||
| int * | icolor, | ||
| int * | lcolor, | ||
| double * | fnorm_vol, | ||
| double * | vec_fnorm, | ||
| double * | uptsb, | ||
| double * | rhsb, | ||
| double * | dub, | ||
| double * | diag, | ||
| double * | fspr | ||
| ) |
Upper sweep of Colored LU-SGS method for Navier-Stokes equations.
| n0 | First index for coloring set |
| ne | Last index for coloring set |
| neles | Number of element cells |
| nfvars | Number of flux variables |
| nface | Number of faces depends on element type |
| ndims | Dimensions |
| nei_ele | Indices for neighbor cells |
| icolor | Color Index of each cell |
| lcolor | Color level of each cell |
| fnorm_vol | Surface magnitude/cell volume |
| vec_fnorm | Surface vector |
| uptsb | Solution array |
| rhsb | Residual (RHS) array |
| dub | Difference array for update (output) |
| diag | Diagonal matrix array |
| fspr | Wave speed for each cell face |
By processing upper sweep, next time step solution \(\Delta Q\) is computed. This function is used for Euler or Navier-Stokes equations, which has the same flux shape.
Solution array is stored in rhsb array, since right-hand-side array is no longer needed.
Definition at line 220 of file coloredlusgs.c.


| void parallel_pre_lusgs | ( | int | neles, |
| int | nface, | ||
| double | factor, | ||
| double * | fnorm_vol, | ||
| double * | dt, | ||
| double * | diag, | ||
| double * | fspr | ||
| ) |
Computes Diagonal matrix for Colored LU-SGS method.
| neles | Number of element cells |
| nface | Number of faces depends on element type |
| factor | Multiplication factor for diffusive margin |
| fnorm_vol | Surface magnitude/cell volume |
| dt | Time step |
| diag | Diagonal matrix for LU-SGS method |
| fspr | Wave speed for each cell face |
This function computes diagonal matrix of the implicit operator. In LU-SGS method, implicit operator is replaced with spectral radius, so that all element except diagonal is zero. Therefore, diag array can be allocated as one-dimensional, which has less memory requirement.
Diffusive margin of wave speed is applied.
Definition at line 47 of file coloredlusgs.c.

| void parallel_update | ( | int | neles, |
| int | nvars, | ||
| double * | uptsb, | ||
| double * | rhsb | ||
| ) |
Updates solution array.
| neles | Number of element cells |
| nvars | Number of conservative variables |
| uptsb | Solution array |
| rhsb | Result of LU-SGS sweeps |
solution array is updated by adding \(\Delta Q\). Be aware that rhsb array in function parameter is the difference array after upper sweep, not the right-hand-side array.
index variables are defined to make private
Definition at line 360 of file coloredlusgs.c.
| void rans_parallel_lower_sweep | ( | int | n0, |
| int | ne, | ||
| int | neles, | ||
| int | nvars, | ||
| int | nfvars, | ||
| int | nface, | ||
| int | ndims, | ||
| int * | nei_ele, | ||
| int * | icolor, | ||
| int * | lcolor, | ||
| double * | fnorm_vol, | ||
| double * | vec_fnorm, | ||
| double * | uptsb, | ||
| double * | rhsb, | ||
| double * | dub, | ||
| double * | diag, | ||
| double * | fspr, | ||
| double * | dsrc | ||
| ) |
Lower sweep of Colored LU-SGS method for RANS equations.
| n0 | First index for coloring set |
| ne | Last index for coloring set |
| neles | Number of element cells |
| nvars | Number of conservative variables |
| nfvars | Number of flux variables |
| nface | Number of faces depends on element type |
| ndims | Dimensions |
| nei_ele | Indices for neighbor cells |
| icolor | Color Index of each cell |
| lcolor | Color level of each cell |
| fnorm_vol | Surface magnitude/cell volume |
| vec_fnorm | Surface vector |
| uptsb | Solution array |
| rhsb | Residual (RHS) array |
| dub | Difference array for update (output) |
| diag | Diagonal matrix array |
| fspr | Wave speed for each cell face |
By processing lower sweep, intermediate solution \(\Delta Q^*\) is computed. This function is used for RANS equations.
solution array is stored in dub array.
Definition at line 146 of file coloredlusgs.c.

| void rans_parallel_upper_sweep | ( | int | n0, |
| int | ne, | ||
| int | neles, | ||
| int | nvars, | ||
| int | nfvars, | ||
| int | nface, | ||
| int | ndims, | ||
| int * | nei_ele, | ||
| int * | icolor, | ||
| int * | lcolor, | ||
| double * | fnorm_vol, | ||
| double * | vec_fnorm, | ||
| double * | uptsb, | ||
| double * | rhsb, | ||
| double * | dub, | ||
| double * | diag, | ||
| double * | fspr, | ||
| double * | dsrc | ||
| ) |
Upper sweep of Colored LU-SGS method for RANS equations.
| n0 | First index for coloring set |
| ne | Last index for coloring set |
| neles | Number of element cells |
| nvars | Number of conservative variables |
| nfvars | Number of flux variables |
| nface | Number of faces depends on element type |
| ndims | Dimensions |
| nei_ele | Indices for neighbor cells |
| icolor | Color Index of each cell |
| lcolor | Color level of each cell |
| fnorm_vol | Surface magnitude/cell volume |
| vec_fnorm | Surface vector |
| uptsb | Solution array |
| rhsb | Residual (RHS) array |
| dub | Difference array for update (output) |
| diag | Diagonal matrix array |
| fspr | Wave speed for each cell face |
By processing upper sweep, next time step solution \(\Delta Q\) is computed. This function is used for RANS equations.
Solution array is stored in rhsb array, since right-hand-side array is no longer needed.
Definition at line 287 of file coloredlusgs.c.
