43using std::resetiosflags;
45using std::setiosflags;
46using std::setprecision;
50using std::stringstream;
99 OutStream <<
" Main output file (this file) \t: "
127 OutStream <<
" Level of Log detail \t: ";
151 OutStream <<
" Simulation start date/time \t: ";
157 OutStream <<
" Duration of simulation \t: ";
183 OutStream <<
" Random number seeds \t: ";
185 for (
int i = 0; i <
NRNG; i++)
197 OutStream <<
" Elevations for 'slice' raster output files \t: ";
198 for (
int i = 0; i < static_cast<int>(
m_VdSliceElev.size()); i++)
205 OutStream <<
" Output file (this file) \t: "
220 OutStream <<
" Coastline vector smoothing algorithm \t: ";
253 OutStream << resetiosflags(ios::floatfield);
260 OutStream <<
"Raster GIS Input Files" << endl;
272 OutStream << resetiosflags(ios::floatfield);
326 OutStream <<
" Layer " << i << (i == 0 ?
"(Top)" :
"") << (i ==
m_nLayers - 1 ?
"(Bottom)" :
"") << endl;
391 OutStream <<
"Vector GIS Input Files" << endl;
413 OutStream <<
" Sediment input event type \t: ";
444 OutStream <<
" Wave propagation model \t: ";
450 OutStream <<
" Density of sea water \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(0) <<
m_dSeaWaterDensity <<
" kg/m^3" << endl;
451 OutStream <<
" Initial still water level \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(1) <<
m_dOrigSWL <<
" m" << endl;
452 OutStream <<
" Final still water level \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(1) <<
m_dFinalSWL <<
" m" << endl;
465 OutStream <<
"*Depth of closure \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(3) <<
m_dDepthOfClosure <<
" m" << endl;
468 OutStream << resetiosflags(ios::floatfield);
469 OutStream << scientific << setprecision(2);
470 OutStream <<
" Coast platform resistance to erosion \t: " <<
m_dR << endl;
471 OutStream << resetiosflags(ios::floatfield);
474 OutStream <<
" Handling of beach sediment at grid edges \t: ";
482 OutStream <<
" Beach potential erosion/deposition equation \t: ";
488 OutStream <<
" Median particle size of fine sediment \t: " << resetiosflags(ios::floatfield) << fixed <<
m_dD50Fine <<
" mm" << endl;
489 OutStream <<
" Median particle size of sand sediment \t: " << resetiosflags(ios::floatfield) << fixed <<
m_dD50Sand <<
" mm" << endl;
490 OutStream <<
" Median particle size of coarse sediment \t: " << resetiosflags(ios::floatfield) << fixed <<
m_dD50Coarse <<
" mm" << endl;
493 OutStream <<
" Fine-sized sediment relative erodibility \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(1) <<
m_dFineErodibility << endl;
497 OutStream <<
" Transport parameter KLS for CERC equation \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(3) <<
m_dKLS << endl;
499 OutStream <<
" Transport parameter for Kamphuis equation \t: " << resetiosflags(ios::floatfield) << fixed << setprecision(3) <<
m_dKamphuis << endl;
505 OutStream <<
" Sediment input type \t: ";
511 OutStream <<
"line intersection with coast";
516 OutStream << resetiosflags(ios::floatfield);
517 OutStream << scientific << setprecision(2);
519 OutStream << resetiosflags(ios::floatfield);
523 OutStream <<
" Scale parameter A for cliff deposition \t: ";
540 OutStream <<
" Gravitational acceleration \t: " << resetiosflags(ios::floatfield) << fixed <<
m_dG <<
" m^2/s" << endl;
557 OutStream <<
" Profile numbers to be saved \t: ";
561 OutStream <<
" Timesteps when profiles are saved \t: ";
580 OutStream <<
"Sea depth in metres. All erosion and deposition values in millimetres" << endl;
581 OutStream <<
"GISn = GIS files saved as <filename>n." << endl;
596 OutStream << resetiosflags(ios::floatfield);
602 OutStream << resetiosflags(ios::floatfield);
607 OutStream << resetiosflags(ios::floatfield);
671 OutStream << setw(6) << scientific << setprecision(0) << dTmp;
684 OutStream << setw(6) << scientific << setprecision(0) << dTmp;
755 OutStream << scientific << setprecision(0);
967 ofstream LookUpOutStream;
968 LookUpOutStream.open(strLookUpFile.c_str(), ios::out | ios::trunc);
973 LookUpOutStream <<
"DepthOverDB, \tErosionPotential" << endl;
974 double dDepthOverDB = 0.0;
978 LookUpOutStream << dDepthOverDB <<
",\t" << dErosionPotential << endl;
981 LookUpOutStream << endl;
984 LookUpOutStream.close();
991int CSimulation::nSaveProfile(
int const nCoast,
CGeomProfile const* pProfile,
int const nProfSize, vector<double>
const* pdVDistXY, vector<double>
const* pdVZ, vector<double>
const* pdVDepthOverDB, vector<double>
const* pdVErosionPotentialFunc, vector<double>
const* pdVSlope, vector<double>
const* pdVRecessionXY, vector<double>
const* pdVChangeElevZ, vector<CGeom2DIPoint>*
const pPtVGridProfile, vector<double>
const* pdVScapeXY)
const
1002 if (!
bWriteProfileData(nCoast, pProfile, nProfSize, pdVDistXY, pdVZ, pdVDepthOverDB, pdVErosionPotentialFunc, pdVSlope, pdVRecessionXY, pdVChangeElevZ, pPtVGridProfile, pdVScapeXY))
1014bool CSimulation::bWriteProfileData(
int const nCoast,
CGeomProfile const* pProfile,
int const nProfSize, vector<double>
const* pdVDistXY, vector<double>
const* pdVZ, vector<double>
const* pdVDepthOverDB, vector<double>
const* pdVErosionPotentialFunc, vector<double>
const* pdVSlope, vector<double>
const* pdVRecessionXY, vector<double>
const* pdVChangeElevZ, vector<CGeom2DIPoint>*
const pPtVGridProfile, vector<double>
const* pdVScapeXY)
const
1019 stringstream ststrTmp;
1021 strFName.append(
"profile_");
1022 ststrTmp << FillToWidth(
'0', 3) << nProfile;
1023 strFName.append(ststrTmp.str());
1025 strFName.append(
"_timestep_");
1027 ststrTmp.str(
string());
1028 ststrTmp << FillToWidth(
'0', 4) <<
m_ulIter;
1029 strFName.append(ststrTmp.str());
1031 strFName.append(
".csv");
1033 ofstream OutProfStream;
1034 OutProfStream.open(strFName.c_str(), ios::out | ios::trunc);
1038 cerr <<
ERR <<
"cannot open " << strFName <<
" for output" << endl;
1042 OutProfStream <<
"\"Dist\", \"X\", \"Y\", \"Z (before erosion)\", \"Depth/DB\", \"Erosion Potential\", \"Slope\", \"Recession XY\", \"Change Elev Z\", \"Grid X\", \"Grid Y\", \"Weight\", \"For profile " << nProfile <<
" from coastline " << nCoast <<
" at timestep " <<
m_ulIter <<
"\"" << endl;
1043 for (
int i = 0; i < nProfSize; i++)
1048 OutProfStream << pdVDistXY->at(i) <<
",\t" << dX <<
",\t" << dY <<
",\t" << pdVZ->at(i) <<
",\t" << pdVDepthOverDB->at(i) <<
",\t" << pdVErosionPotentialFunc->at(i) <<
",\t" << pdVSlope->at(i) <<
",\t" << pdVRecessionXY->at(i) <<
",\t" << pdVChangeElevZ->at(i) <<
",\t" << pPtVGridProfile->at(i).nGetX() <<
",\t" << pPtVGridProfile->at(i).nGetY() <<
", \t" << pdVScapeXY->at(i) << endl;
1051 OutProfStream.close();
1059int CSimulation::nSaveParProfile(
int const nCoast,
CGeomProfile const* pProfile,
int const nParProfSize,
int const nDirection,
int const nDistFromProfile, vector<double>
const* pdVDistXY, vector<double>
const* pdVZ, vector<double>
const* pdVDepthOverDB, vector<double>
const* pdVErosionPotentialFunc, vector<double>
const* pdVSlope, vector<double>
const* pdVRecessionXY, vector<double>
const* pdVChangeElevZ, vector<CGeom2DIPoint>*
const pPtVGridProfile, vector<double>
const* pdVScapeXY)
const
1069 if (!
bWriteParProfileData(nCoast, nProfile, nParProfSize, nDirection, nDistFromProfile, pdVDistXY, pdVZ, pdVDepthOverDB, pdVErosionPotentialFunc, pdVSlope, pdVRecessionXY, pdVChangeElevZ, pPtVGridProfile, pdVScapeXY))
1081bool CSimulation::bWriteParProfileData(
int const nCoast,
int const nProfile,
int const nProfSize,
int const nDirection,
int const nDistFromProfile, vector<double>
const* pdVDistXY, vector<double>
const* pdVZ, vector<double>
const* pdVDepthOverDB, vector<double>
const* pdVErosionPotentialFunc, vector<double>
const* pdVSlope, vector<double>
const* pdVRecessionXY, vector<double>
const* pdVChangeElevZ, vector<CGeom2DIPoint>*
const pPtVGridProfile, vector<double>
const* pdVScapeXY)
const
1084 stringstream ststrTmp;
1086 strFName.append(
"profile_");
1087 ststrTmp << FillToWidth(
'0', 3) << nProfile;
1088 strFName.append(ststrTmp.str());
1090 strFName.append(
"_parallel_");
1092 ststrTmp.str(
string());
1093 ststrTmp << FillToWidth(
'0', 3) << nDistFromProfile;
1094 strFName.append(ststrTmp.str());
1096 strFName.append((nDirection == 0 ?
"_F" :
"_B"));
1098 strFName.append(
"_timestep_");
1100 ststrTmp.str(
string());
1101 ststrTmp << FillToWidth(
'0', 4) <<
m_ulIter;
1102 strFName.append(ststrTmp.str());
1104 strFName.append(
".csv");
1106 ofstream OutProfStream;
1107 OutProfStream.open(strFName.c_str(), ios::out | ios::trunc);
1111 cerr <<
ERR <<
"cannot open " << strFName <<
" for output" << endl;
1115 OutProfStream <<
"\"Dist\", \"X\", \"Y\", \"Z (before erosion)\", \"Depth/DB\", \"Erosion Potential\", \"Slope\", \"Recession XY\", \"Change Elev Z\", \"Grid X\", \"Grid Y\", \"Weight\", \"For profile " << nProfile <<
" from coastline " << nCoast <<
" at timestep " <<
m_ulIter <<
"\"" << endl;
1116 for (
int i = 0; i < nProfSize; i++)
1121 OutProfStream << pdVDistXY->at(i) <<
",\t" << dX <<
",\t" << dY <<
",\t" << pdVZ->at(i) <<
",\t" << pdVDepthOverDB->at(i) <<
",\t" << pdVErosionPotentialFunc->at(i) <<
",\t" << pdVSlope->at(i) <<
",\t" << pdVRecessionXY->at(i) <<
",\t" << pdVChangeElevZ->at(i) <<
",\t" << pPtVGridProfile->at(i).nGetX() <<
",\t" << pPtVGridProfile->at(i).nGetY() <<
", \t" << pdVScapeXY->at(i) << endl;
1124 OutProfStream.close();
1169 OutStream <<
"TOTAL PLATFORM EROSION" << endl;
1178 OutStream <<
"TOTAL CLIFF COLLAPSE EROSION" << endl;
1185 OutStream <<
"TOTAL DEPOSITION AND SUSPENSION OF CLIFF COLLAPSE TALUS" << endl;
1192 OutStream <<
"TOTAL BEACH EROSION" << endl;
1201 OutStream <<
"TOTAL BEACH DEPOSITION" << endl;
1207 OutStream <<
"TOTAL SEDIMENT INPUT EVENTS" << endl;
1214 OutStream <<
"TOTAL SUSPENDED SEDIMENT" << endl;
1218 OutStream <<
"TOTAL LOST FROM GRID BY BEACH MOVEMENT" << endl;
1226 OutStream <<
"TOTAL LOST FROM GRID BY CLIFF COLLAPSE" << endl;
1231 OutStream <<
"ALL-PROCESS TOTALS (all size classes)" << endl;
1244 if (!
bFPIsEqual(ldSandEroded, (ldSandDeposited + ldSandLost), 1.0L))
1250 OutStream <<
"Coarse sediment deposited = " << ldCoarseDeposited *
m_dCellArea <<
" m^3" << endl;
1252 OutStream <<
"Coarse sediment lost from grid = " << ldCoarseLost *
m_dCellArea <<
" m^3" << endl;
1253 if (!
bFPIsEqual(ldCoarseEroded, (ldCoarseDeposited + ldCoarseLost), 1.0L))
1259 OutStream <<
"Total sediment eroded (all processes) = " << ldActualTotalEroded *
m_dCellArea <<
" m^3" << endl;
1262 OutStream <<
"Total sediment deposited/to suspension (all processes) = " << ldTotalDepositedAndSuspension *
m_dCellArea <<
" m^3" << endl;
1265 OutStream <<
"Total sediment lost from grid (all processes) = " << ldTotalLost *
m_dCellArea <<
" m^3" << endl;
1297 LogStream <<
"END OF RUN TOTALS =================================================================================================================================================" << endl
1300 LogStream <<
"ALL-PROCESS TOTALS (all size classes)" << endl;
1302 LogStream <<
"Sediment eroded (all processes) = " << ldActualTotalEroded *
m_dCellArea <<
" m^3" << endl;
1304 LogStream <<
"Sediment deposited and in suspension (all processes) = " << ldTotalDepositedAndSuspension *
m_dCellArea <<
" m^3" << endl;
1306 LogStream <<
"Sediment lost from grid (all processes) = " << ldTotalLost *
m_dCellArea <<
" m^3" << endl;
1335 <<
"END OF RUN" << endl;
1337 <<
"END OF RUN" << endl;
1351 LogStream << endl <<
m_ulIter <<
": Polygon-to-adjacent polygon shares (non-dimensional), per-polygon seawater volume (m^3), per-polygon D50 values (mm: a blank D50 value means that there is no unconsolidated sediment on that polygon)." << endl;
1353 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------------------------------------" << endl;
1356 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------------------------------------" << endl;
1378 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------------------------------------" << endl << endl;
1387 double dTmpFineTot = 0;
1388 double dTmpSandTot = 0;
1389 double dTmpCoarseTot = 0;
1400 LogStream <<
m_ulIter <<
": Per-polygon pre-existing unconsolidated sediment. Note that this does not include pre-existing unconsolidated sediment outside the polygons.";
1402 LogStream <<
" Also the all-polygon total will be slightly different from the all-polygon total at the end of the last timestep, since the coastline and polygons have been re-drawn.";
1405 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1408 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1424 LogStream <<
strIntRight(pPolygon->
nGetGlobalID(), 11) <<
"|" <<
strIntRight(nCoast, 11) <<
"|" <<
strIntRight(pPolygon->
nGetCoastID(), 11) <<
"|" <<
strDblRight((dThisFine + dThisSand + dThisCoarse) *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dThisFine *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dThisSand *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dThisCoarse *
m_dCellArea, 0, 14) <<
"|" << endl;
1429 dTmpTot += (dThisFine + dThisSand + dThisCoarse) *
m_dCellArea;
1437 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1439 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl << endl;
1449 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1452 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1454 double dTmpFineTot = 0;
1455 double dTmpSandTot = 0;
1456 double dTmpCoarseTot = 0;
1467 LogStream <<
strIntRight(pPolygon->
nGetGlobalID(), 11) <<
"|" <<
strIntRight(nCoast, 11) <<
"|" <<
strIntRight(pPolygon->
nGetCoastID(), 11) <<
"|" <<
strDblRight((dThisFine + dThisSand + dThisCoarse) *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dThisFine *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dThisSand *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dThisCoarse *
m_dCellArea, 0, 14) <<
"|" << endl;
1472 dTmpTot += (dThisFine + dThisSand + dThisCoarse) *
m_dCellArea;
1475 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1477 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl << endl;
1486 double dTmpFineTot = 0;
1487 double dTmpSandTot = 0;
1488 double dTmpCoarseTot = 0;
1490 LogStream << endl <<
m_ulIter <<
": Per-polygon unconsolidated sand/coarse sediment derived from erosion of the consolidated shore platform (all m^3). All fine sediment eroded from the shore platform goes to suspension." << endl;
1492 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1495 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1501 LogStream <<
strIntRight(pPolygon->
nGetGlobalID(), 11) <<
"|" <<
strIntRight(nCoast, 11) <<
"|" <<
strIntRight(pPolygon->
nGetCoastID(), 11) <<
"|" <<
strDblRight((pPolygon->
dGetPlatformErosionUnconsSand() + pPolygon->
dGetPlatformErosionUnconsCoarse()) *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(0, 0, 14) <<
"|" <<
strDblRight(pPolygon->
dGetPlatformErosionUnconsSand() *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(pPolygon->
dGetPlatformErosionUnconsCoarse() *
m_dCellArea, 0, 14) <<
"|" << endl;
1508 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1510 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl << endl;
1518 LogStream <<
m_ulIter <<
": Per-polygon cliff collapse (all m^3). Fine sediment derived from cliff collapse goes to suspension, sand/coarse sediment derived from cliff collapse becomes unconsolidated talus (DDPD = During Dean Profile Deposition)." << endl;
1520 LogStream <<
"-----------|-----------|-----------|--------------------------------------------|-----------------------------|--------------------------------------------|--------------------------------------------|" << endl;
1522 LogStream <<
strCentre(
"Global ID", 11) <<
"|" <<
strCentre(
"", 11) <<
"|" <<
strCentre(
"Coast ID", 11) <<
"|" <<
strCentre(
"Eroded Cliff", 15) <<
strCentre(
"Eroded DDPD", 15) <<
strCentre(
"Deposited", 14) <<
"|" <<
strCentre(
"Eroded", 14) <<
"|" <<
strCentre(
"Suspension", 14) <<
"|" <<
strCentre(
"Eroded Cliff", 15) <<
strCentre(
"Eroded DDPD", 15) <<
strCentre(
"Deposited", 14) <<
"|" <<
strCentre(
"Eroded Cliff", 15) <<
strCentre(
"Eroded DDPD", 15) <<
strCentre(
"Deposited", 14) <<
"|" << endl;
1523 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1525 double dTmpErosionTot = 0;
1526 double dTmpErosionDDPDTot = 0;
1527 double dTmpDepositTot = 0;
1529 double dTmpErosionFineTot = 0;
1530 double dTmpSuspensionFineTot = 0;
1532 double dTmpErosionSandTot = 0;
1533 double dTmpErosionSandDDPDTot = 0;
1534 double dTmpDepositSandTot = 0;
1536 double dTmpErosionCoarseTot = 0;
1537 double dTmpErosionCoarseDDPDTot = 0;
1538 double dTmpDepositCoarseTot = 0;
1572 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1576 <<
strDblRight(dTmpErosionCoarseTot, 0, 14) <<
" " <<
strDblRight(dTmpErosionCoarseDDPDTot, 0, 14) <<
"|" <<
strDblRight(dTmpDepositCoarseTot, 0, 14) <<
"|" << endl;
1577 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl << endl;
1585 LogStream <<
m_ulIter <<
": Per-polygon totals of stored unconsolidated beach sediment prior to polygon-to-polygon movement (all m^3). Note that this does not include unconsolidated sediment stored outside the polygons." << endl;
1587 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1590 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1593 double dTmpFineTot = 0;
1594 double dTmpSandTot = 0;
1595 double dTmpCoarseTot = 0;
1605 LogStream <<
strIntRight(pPolygon->
nGetGlobalID(), 11) <<
"|" <<
strIntRight(nCoast, 11) <<
"|" <<
strIntRight(pPolygon->
nGetCoastID(), 11) <<
"|" <<
strDblRight((dFine + dSand + dCoarse) *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dFine *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dSand *
m_dCellArea, 0, 14) <<
"|" <<
strDblRight(dCoarse *
m_dCellArea, 0, 14) <<
"|" << endl;
1607 dTmpTot += (dFine + dSand + dCoarse) *
m_dCellArea;
1613 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl;
1615 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|" << endl << endl;
1623 LogStream <<
m_ulIter <<
": Per-polygon potential (i.e. not considering sediment availability) erosion of all size classes of unconsolidated beach sediment (-ve, all m^3), calculated with the ";
1630 LogStream <<
"-----------|-----------|-----------|--------------|" << endl;
1633 LogStream <<
"-----------|-----------|-----------|--------------|" << endl;
1644 LogStream <<
"-----------|-----------|-----------|--------------|" << endl;
1646 LogStream <<
"-----------|-----------|-----------|--------------|" << endl << endl;
1690 LogStream <<
"-----------|-----------|-----------|--------------|--------------|" << endl;
1694 LogStream <<
"-----------|-----------|-----------|--------------|--------------|" << endl;
1696 for (
int n = 0; n < static_cast<int>(pnVVPolyAndAdjacent.size()); n++)
1700 for (
int m = 0; m < static_cast<int>(pnVVPolyAndAdjacent[n].size()); m++)
1717 if (pnVVPolyAndAdjacent[n][m] ==
true)
1725 int nAdjDownCoast = pnVVPolyAndAdjacent[n][m];
1736 LogStream <<
"-----------|-----------|-----------|--------------|--------------|" << endl << endl;
1745 LogStream <<
m_ulIter <<
": Sorted sequence of polygon processing (" <<
INT_NODATA <<
" = leaves grid), and any X -> Y -> X circularities" << endl;
1747 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|" << endl;
1751 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|" << endl;
1753 for (
int nPoly = 0; nPoly < static_cast<int>(pnVVPolyAndAdjacent.size()); nPoly++)
1762 for (
int m = 2; m < static_cast<int>(pnVVPolyAndAdjacent[nPoly].size()); m++)
1766 if (pnVVPolyAndAdjacent[nPoly][m] ==
true)
1775 int nAdjPolyDownCoastSeq = pnVVPolyAndAdjacent[nPoly][m];
1782 strTmp += to_string(nAdjacentPolyID);
1784 if (m < (
static_cast<int>(pnVVPolyAndAdjacent[nPoly].size()) - 1))
1792 if (! VCirc.empty())
1795 for (
unsigned int i = 0; i < VCirc.size(); i++)
1797 strTmp += to_string(VCirc[i]);
1799 if (i < (VCirc.size()-1))
1805 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|" << endl << endl;
1814 LogStream <<
m_ulIter <<
": per-polygon erosion and deposition of unconsolidated beach sediment, all m^3. Fine sediment is moved to suspension, not deposited (DDPD = During Dean Profile Deposition)." << endl;
1816 LogStream <<
"-----------|-----------|-----------|--------------------------------------------|-----------------------------|--------------------------------------------|--------------------------------------------|" << endl;
1818 LogStream <<
strCentre(
"Global ID", 11) <<
"|" <<
strCentre(
"", 11) <<
"|" <<
strCentre(
"Coast ID", 11) <<
"|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1819 LogStream <<
strCentre(
"", 11) <<
"|" <<
strCentre(
"", 11) <<
"|" <<
strCentre(
"", 11) <<
"|" <<
strCentre(
"Erosion", 14) <<
" " <<
strCentre(
"Erosion DPDD", 14) <<
"|" <<
strCentre(
"Dep + Susp", 14) <<
"|" <<
strCentre(
"Erosion", 14) <<
"|" <<
strCentre(
"Suspension", 14) <<
"|" <<
strCentre(
"Erosion", 14) <<
" " <<
strCentre(
"Erosion DPDD", 14) <<
"|" <<
strCentre(
"Deposition", 14) <<
"|" <<
strCentre(
"Erosion", 14) <<
" " <<
strCentre(
"Erosion DPDD", 14) <<
"|" <<
strCentre(
"Deposition", 14) <<
"|" << endl;
1820 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1822 double dTmpTotAllErosion = 0;
1823 double dTmpTotAllErosionDDPD = 0;
1824 double dTmpTotAllDeposition = 0;
1826 double dTmpFineErosion = 0;
1829 double dTmpSandErosion = 0;
1830 double dTmpSandErosionDDPD = 0;
1831 double dTmpSandDeposition = 0;
1833 double dTmpCoarseErosion = 0;
1834 double dTmpCoarseErosionDDPD = 0;
1835 double dTmpCoarseDeposition = 0;
1839 int nPoly = pnVVPolyAndAdjacent[n][1];
1855 dTmpTotAllErosion += (dAllErosionNotDDPD *
m_dCellArea);
1862 dTmpSandErosion += (dSandErosionNotDDPD *
m_dCellArea);
1866 dTmpCoarseErosion += (dCoarseErosionNotDDPD *
m_dCellArea);
1871 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1872 LogStream <<
"Lost from grid |" <<
strLeft(
"", 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strDblRight((
m_dThisIterLeftGridUnconsSand +
m_dThisIterLeftGridUnconsCoarse) *
m_dCellArea, 0, 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strDblRight(
m_dThisIterLeftGridUnconsSand *
m_dCellArea, 0, 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strLeft(
"", 14) <<
"|" <<
strDblRight(
m_dThisIterLeftGridUnconsCoarse *
m_dCellArea, 0, 14) <<
"|" << endl;
1878 bool bShowZeroFine =
false;
1879 bool bShowZeroSand =
false;
1880 bool bShowZeroCoarse =
false;
1883 bShowZeroFine =
true;
1886 bShowZeroSand =
true;
1889 bShowZeroCoarse =
true;
1891 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1896 <<
strDblRight(-dTmpFineErosion, 0, 14, bShowZeroFine) <<
"|" <<
strDblRight(dTmpFineErosion, 0, 14, bShowZeroFine) <<
"|"
1898 <<
strDblRight(-dTmpSandErosion, 0, 14, bShowZeroSand) <<
"|" <<
strDblRight(dTmpSandErosionDDPD, 0, 14, bShowZeroSand) <<
"|" <<
strDblRight(dTmpSandDeposition, 0, 14, bShowZeroSand) <<
"|"
1900 <<
strDblRight(-dTmpCoarseErosion, 0, 14, bShowZeroCoarse) <<
"|" <<
strDblRight(dTmpCoarseErosionDDPD, 0, 14, bShowZeroCoarse) <<
"|" <<
strDblRight(dTmpCoarseDeposition, 0, 14, bShowZeroCoarse) <<
"|" << endl;
1901 LogStream <<
"-----------|-----------|-----------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|--------------|" << endl;
1913 int nSuspFineCellsAllCells = 0;
1914 int nUnconsFineCellsAllCells = 0;
1915 int nUnconsSandCellsAllCells = 0;
1916 int nUnconsCoarseCellsAllCells = 0;
1920 int nSuspFineCellsInPolygons = 0;
1921 int nUnconsFineCellsInPolygons = 0;
1922 int nUnconsSandCellsInPolygons = 0;
1923 int nUnconsCoarseCellsInPolygons = 0;
1926 double dEndIterSuspFineAllCells = 0;
1927 double dEndIterUnconsFineAllCells = 0;
1928 double dEndIterUnconsSandAllCells = 0;
1929 double dEndIterUnconsCoarseAllCells = 0;
1930 double dEndIterConsFineAllCells = 0;
1931 double dEndIterConsSandAllCells = 0;
1932 double dEndIterConsCoarseAllCells = 0;
1935 double dEndIterSuspFineInPolygons = 0;
1936 double dEndIterUnconsFineInPolygons = 0;
1937 double dEndIterUnconsSandInPolygons = 0;
1938 double dEndIterUnconsCoarseInPolygons = 0;
1939 double dEndIterConsFineInPolygons = 0;
1940 double dEndIterConsSandInPolygons = 0;
1941 double dEndIterConsCoarseInPolygons = 0;
1948 dEndIterConsFineAllCells +=
m_pRasterGrid->m_Cell[nX][nY].dGetTotConsFineThickConsiderNotch();
1949 dEndIterConsSandAllCells +=
m_pRasterGrid->m_Cell[nX][nY].dGetTotConsSandThickConsiderNotch();
1950 dEndIterConsCoarseAllCells +=
m_pRasterGrid->m_Cell[nX][nY].dGetTotConsCoarseThickConsiderNotch();
1952 double dSuspFine =
m_pRasterGrid->m_Cell[nX][nY].dGetSuspendedSediment();
1955 dEndIterSuspFineAllCells += dSuspFine;
1956 nSuspFineCellsAllCells++;
1959 double dUnconsFine =
m_pRasterGrid->m_Cell[nX][nY].dGetTotUnconsFine();
1960 if (dUnconsFine > 0)
1962 dEndIterUnconsFineAllCells += dUnconsFine;
1963 nUnconsFineCellsAllCells++;
1966 double dUnconsSand =
m_pRasterGrid->m_Cell[nX][nY].dGetTotUnconsSand();
1967 if (dUnconsSand > 0)
1969 dEndIterUnconsSandAllCells += dUnconsSand;
1970 nUnconsSandCellsAllCells++;
1973 double dUnconsCoarse =
m_pRasterGrid->m_Cell[nX][nY].dGetTotUnconsCoarse();
1974 if (dUnconsCoarse > 0)
1976 dEndIterUnconsCoarseAllCells += dUnconsCoarse;
1977 nUnconsCoarseCellsAllCells++;
1984 dEndIterConsFineInPolygons +=
m_pRasterGrid->m_Cell[nX][nY].dGetTotConsFineThickConsiderNotch();
1985 dEndIterConsSandInPolygons +=
m_pRasterGrid->m_Cell[nX][nY].dGetTotConsSandThickConsiderNotch();
1986 dEndIterConsCoarseInPolygons +=
m_pRasterGrid->m_Cell[nX][nY].dGetTotConsCoarseThickConsiderNotch();
1988 dSuspFine =
m_pRasterGrid->m_Cell[nX][nY].dGetSuspendedSediment();
1991 dEndIterSuspFineInPolygons += dSuspFine;
1992 nSuspFineCellsInPolygons++;
1995 dUnconsFine =
m_pRasterGrid->m_Cell[nX][nY].dGetTotUnconsFine();
1996 if (dUnconsFine > 0)
1998 dEndIterUnconsFineInPolygons += dUnconsFine;
1999 nUnconsFineCellsInPolygons++;
2002 dUnconsSand =
m_pRasterGrid->m_Cell[nX][nY].dGetTotUnconsSand();
2003 if (dUnconsSand > 0)
2005 dEndIterUnconsSandInPolygons += dUnconsSand;
2006 nUnconsSandCellsInPolygons++;
2009 dUnconsCoarse =
m_pRasterGrid->m_Cell[nX][nY].dGetTotUnconsCoarse();
2010 if (dUnconsCoarse > 0)
2012 dEndIterUnconsCoarseInPolygons += dUnconsCoarse;
2013 nUnconsCoarseCellsInPolygons++;
2019 double dFineTmp = 0;
2020 double dSandTmp = 0;
2021 double dCoarseTmp = 0;
2023 LogStream << endl <<
m_ulIter <<
": Consolidated sediment budget, all m^3. This includes sediment within and outside the polygons." << endl;
2026 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2028 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2050 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2061 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
2077 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2079 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2100 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2102 double dFineError = (dEndIterConsFineAllCells *
m_dCellArea) - dFineTmp;
2103 double dSandError = (dEndIterConsSandAllCells *
m_dCellArea) - dSandTmp;
2104 double dCoarseError = (dEndIterConsCoarseAllCells *
m_dCellArea) - dCoarseTmp;
2107 bool bError =
false;
2108 string strFineErrMsg =
"";
2109 string strSandErrMsg =
"";
2110 string strCoarseErrMsg =
"";
2111 string strAllErrMsg =
"";
2134 LogStream <<
strLeft(
"Consolidated sediment mass balance check (+ve means end total > start total)", 101) <<
"|" <<
strLeft(
"", 8) <<
"|" <<
strLeft(
"", 44) <<
"|" << endl;
2138 LogStream <<
strLeft(strAllErrMsg, 101) <<
"|" <<
strLeft(
"ALL", 8) <<
"|" <<
strDblRight(dFineError + dSandError + dCoarseError, 3, 30,
false) <<
strRightPerCent(dFineError + dSandError + dCoarseError, dEndIterConsFineAllCells + dEndIterConsSandAllCells + dEndIterConsCoarseAllCells, 14, 2) <<
"|" << endl;
2139 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
2150 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2152 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2180 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2191 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
2202 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
2213 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
2223 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
2244 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2246 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2274 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << string(14,
'-') <<
"|" << endl;
2276 dFineError = ((dEndIterSuspFineAllCells + dEndIterUnconsFineAllCells) *
m_dCellArea) - dFineTmp,
2277 dSandError = (dEndIterUnconsSandAllCells *
m_dCellArea) - dSandTmp,
2278 dCoarseError = (dEndIterUnconsCoarseAllCells *
m_dCellArea) - dCoarseTmp;
2284 strCoarseErrMsg =
"";
2308 LogStream <<
strLeft(
"Unconsolidated sediment mass balance check (+ve means iteration-end total > iteration-start total)", 101) <<
"|" <<
strLeft(
"", 8) <<
"|" <<
strLeft(
"", 44) <<
"|" << endl;
2312 LogStream <<
strLeft(strAllErrMsg, 101) <<
"|" <<
strLeft(
"ALL", 8) <<
"|" <<
strDblRight(dFineError + dSandError + dCoarseError, 0, 30,
false) <<
strRightPerCent(dFineError + dSandError + dCoarseError, dEndIterSuspFineAllCells + dEndIterUnconsFineAllCells + dEndIterUnconsSandAllCells + dEndIterUnconsCoarseAllCells, 14, 2) <<
"|" << endl;
2313 LogStream << string(101,
'-') <<
"|" << string(8,
'-') <<
"|" << string(44,
'-') <<
"|" << endl;
Geometry class used for coast polygon objects.
double dGetCliffCollapseErosionCoarse(void) const
Get the this-iteration total of unconsolidated coarse sediment from cliff collapse on this polygon,...
double dGetSedimentInputUnconsSand(void) const
Get the value of sand sediment on the polygon derived from sediment input events(s)
double dGetPotentialErosion(void) const
Returns this timestep's total change in depth of unconsolidated sediment (all size classes) due to be...
double dGetCliffCollapseUnconsSandDeposition(void) const
Get the this-iteration total of unconsolidated sand sediment deposited from cliff collapse on this po...
double dGetCliffCollapseToSuspensionFine(void) const
Get the this-iteration total of unconsolidated fine sediment from cliff collapse which goes to suspen...
double dGetPreExistingUnconsSand(void) const
Get the value of pre-existing unconsolidated sand sediment stored on this polygon.
double dGetPreExistingConsSand(void) const
Get the value of pre-existing consolidated sand sediment stored on this polygon.
double dGetUpCoastAdjacentPolygonBoundaryShare(int const) const
Gets the boundary shares for all up-coast adjacent polygons.
int nGetUpCoastAdjacentPolygon(int const) const
Gets a single up-coast adjacent polygon.
double dGetCliffCollapseErosionFine(void) const
Get the this-iteration total of unconsolidated fine sediment eroded from cliff collapse on this polyg...
double dGetPlatformErosionUnconsCoarse(void) const
Get the this-iteration total of unconsolidated coarse sediment derived from shore platform erosion on...
double dGetCliffCollapseCoarseErodedDeanProfile(void) const
Get the this-iteration total of unconsolidated coarse sediment eroded during deposition of cliff coll...
double dGetSedimentInputUnconsFine(void) const
Get the value of fine sediment on the polygon derived from sediment input events(s)
int nGetNumUpCoastAdjacentPolygons(void) const
Gets all up-coast adjacent polygons.
double dGetPreExistingConsFine(void) const
Get the value of pre-existing consolidated fine sediment stored on this polygon.
int nGetGlobalID(void) const
Get the global ID.
double dGetCliffCollapseUnconsCoarseDeposition(void) const
Get the this-iteration total of unconsolidated coarse sediment deposited from cliff collapse on this ...
double dGetSeawaterVolume(void) const
Get the volume of seawater in the coast polygon.
double dGetDownCoastAdjacentPolygonBoundaryShare(int const) const
Gets the boundary shares for all down-coast adjacent polygons.
double dGetPreExistingUnconsFine(void) const
Get the value of pre-existing unconsolidated fine sediment stored on this polygon.
int nGetDownCoastAdjacentPolygon(int const) const
Gets a single down-coast adjacent polygon.
int nGetNumDownCoastAdjacentPolygons(void) const
Gets all down-coast adjacent polygons.
double dGetCliffCollapseErosionSand(void) const
Get the this-iteration total of unconsolidated sand sediment from cliff collapse on this polygon,...
double dGetAvgUnconsD50(void) const
Get the average d50 for unconsolidated sediment on this polygon.
double dGetPlatformErosionUnconsSand(void) const
Get the this-iteration total of unconsolidated sand sediment derived from shore platform erosion on t...
double dGetPreExistingUnconsCoarse(void) const
Get the value of pre-existing unconsolidated coarse sediment stored on this polygon.
double dGetCliffCollapseSandErodedDeanProfile(void) const
Get the this-iteration total of unconsolidated sand sediment eroded during deposition of cliff collap...
double dGetPreExistingConsCoarse(void) const
Get the value of pre-existing consolidated coarse sediment stored on this polygon.
double dGetSedimentInputUnconsCoarse(void) const
Get the value of coarse sediment on the polygon derived from sediment input events(s)
bool bDownCoastThisIter(void) const
Is sediment movement on this polygon downcoast this iteration?
int nGetCoastID(void) const
Get the coast ID, this is the same as the down-coast sequence.
vector< int > VnGetCircularities(void) const
Get all circularities for this polygon.
Geometry class used to represent coast profile objects.
int nGetCoastID(void) const
Returns the profile's coast ID.
double m_dThisIterPotentialBeachErosion
Total potential beach erosion (all size classes of unconsolidated sediment) for this iteration (depth...
double m_dCliffDepositionPlanviewWidth
Planview width of cliff collapse talus (m)
int m_nLogFileDetail
The level of detail in the log file output. Can be LOG_FILE_LOW_DETAIL, LOG_FILE_MIDDLE_DETAIL,...
void WritePolygonSedimentInputEventTable(int const)
Writes to the log file a table showing per-polygon sediment input event totals.
string m_strGDALISSDriverCode
GDAL code for the initial suspended sediment raster file.
vector< string > m_VstrInitialSandConsSedimentFile
The name of the initial sand-sized consolidated sediment GIS file.
double m_dAllCellsDeepWaterWaveHeight
Deep water wave height (m) for all sea cells.
int m_nGISMaxSaveDigits
The maximum number of digits in GIS filenames. These can be sequential, or the iteration number.
string m_strGDALISSProjection
GDAL projection string for the initial suspended sediment raster file.
string m_strInitialSuspSedimentFile
Name of initial suspended sediment file.
string m_strSedimentInputEventFile
The name of the sediment input events time series file.
double m_dNotchDepthAtCollapse
Notch overhang (i.e. length of horizontal incision) to initiate collapse (m)
bool m_bFloodSWLSetupSurgeLine
Are we saving the flood still water level setup surge line? TODO 007.
time_t m_tSysEndTime
System finish-simulation time.
string m_strCMEIni
Folder for the CME .ini file.
double m_dTotalCoarseUnconsInPolygons
Total coarse unconsolidated sediment in all polygons, before polygon-to-polygon movement (only cells ...
bool m_bSedimentInputAtPoint
Do we have sediment inputat a point?
double m_dMinSWL
Minimum still water level.
double m_dG
Gravitational acceleration (m**2/sec)
vector< string > m_VstrInitialCoarseUnconsSedimentFile
The name of the initial coarse-sized unconsolidated sediment GIS file.
double m_dThisIterSWL
The still water level for this timestep (this includes tidal changes and any long-term SWL change)
string m_strGDALICDataType
GDAL data type of the initial intervention class raster file.
int m_nBeachErosionDepositionEquation
Which beach erosion-deposition equation is used. Possible values are UNCONS_SEDIMENT_EQUATION_CERC an...
ofstream CliffCollapseNetChangeTSStream
Cliff collapse net change (erosion - deposition) time series file output stream.
bool m_bBeachDepositionTSSave
Save the beach (unconsolidated sediment) deposition time series file?
bool bWritePerTimestepResults(void)
Write the results for this timestep to the .out file.
CGeomRasterGrid * m_pRasterGrid
Pointer to the raster grid object.
vector< string > m_VstrGDALICCDataType
GDAL data type for the initial consolidated coarse sediment GIS data.
int m_nXGridSize
The size of the grid in the x direction.
string strListRasterFiles(void) const
Return a space-separated string containing the names of the raster GIS output files.
double m_dWaveDataWrapHours
Number of hours after which deep water wave data wraps.
string strListVectorFiles(void) const
Return a space-separated string containing the names of the vector GIS output files.
vector< string > m_VstrGDALICFDataType
GDAL data type for the initial consolidated fine sediment GIS data.
double m_dMaxUserInputWavePeriod
Used to constrain depth of closure.
bool m_bFloodSetupSurgeRunupTSSave
Save the flood setup surge runup time series file? TODO 007 Does this work correctly?
int nWriteEndRunDetails(void)
Writes end-of-run information to Out, Log and time-series files.
vector< string > m_VstrGDALICCDriverCode
GDAL driver code for the initial consolidated coarse sediment GIS data.
double m_dThisIterBeachErosionCoarse
Total actual beach erosion (coarse unconsolidated sediment) for this iteration (depth in m)
double m_dStartIterUnconsCoarseAllCells
Depth (m) of coarse unconsolidated sediment at the start of the simulation, all cells (both inside an...
vector< CRWCoast > m_VCoast
The coastline objects.
double m_dCoastNormalLength
Length of the cost-normal profiles, in m.
void WritePolygonCliffCollapseErosion(int const)
Writes to the log file a table showing per-polygon per-polygon cliff collapse.
static string pstrChangeToForwardSlash(string const *)
Swaps all backslashes in the input string to forward slashes, leaving the original unchanged.
vector< string > m_VstrGDALIUFDataType
GDAL data type for the initial unconsolidated fine sediment GIS data.
bool m_bSaveGISThisIter
Save GIS files this iteration?
long double m_ldGTotCliffCollapseCoarseErodedDuringDeposition
All-simulation total of coarse sediment eroded during talus deposition following cliff collapse (m)
double m_dUnconsCoarseNotDepositedLastIter
Depth of unconsolidated coarse sediment that could not be deposited during the last iteration,...
string m_strOGRSedInputDataType
GDAL data type for the sediment input event locations vector file.
bool bSaveAllVectorGISFiles(void)
The bSaveAllvectorGISFiles member function saves the vector GIS files TODO 081 Choose more files to o...
bool m_bSingleDeepWaterWaveValues
Do we have just a point source for (i.e. only a single measurement of) deep water wave values.
string m_strRunName
The name of this simulation.
static string strGetComputerName(void)
Returns a string, hopefully giving the name of the computer on which the simulation is running.
static string strDispSimTime(double const)
strDispSimTime returns a string formatted as year Julian_day hour, given a parameter in hours
double m_dSouthEastXExtCRS
The south-east x coordinate, in the external coordinate reference system (CRS)
long double m_ldGTotActualCoarseBeachErosion
All-simulation total of coarse sediment eroded during beach (unconsolidated sediment) movement (m)
void WriteLookUpData(void) const
Output the erosion potential look-up values, for checking purposes.
double m_dThisIterCliffCollapseFineErodedDuringDeposition
Total fine sediment eroded during Dean profile deposition of talus following cliff collapse (depth in...
void WritePolygonSedimentBeforeMovement(int const)
Writes to the log file a table showing per-polygon totals of stored unconsolidated beach sediment pri...
double m_dThisIterDiffWaveSetupSurgeWaterLevel
TODO 007 Info needed.
double m_dThisIterActualPlatformErosionCoarseCons
Total actual platform erosion (coarse consolidated sediment) for this iteration (depth in m)
int m_nYGridSize
The size of the grid in the y direction.
vector< double > m_VdErosionPotential
For erosion potential lookup.
vector< string > m_VstrGDALIUFProjection
GDAL projection for the initial unconsolidated fine sediment GIS data.
bool m_bStillWaterLevelTSSave
Save the still water level time series file?
long double m_ldGTotCliffTalusFineToSuspension
All-simulation total of fine sediment moved to suspension, due to cliff collapse (m)
int nSaveParProfile(int const, CGeomProfile const *, int const, int const, int const, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< CGeom2DIPoint > *const, vector< double > const *) const
Save a coastline-normal parallel profile.
string m_strSedimentInputEventShapefile
The name of the sediment input events shape file.
double m_dCoarseErodibility
The relative erodibility (0- 1) of coarse unconsolidated beach sediment.
double m_dCliffTalusMinDepositionLength
Planview length of cliff deposition talus (m)
void WritePolygonSortedSequence(int const, vector< vector< int > > &)
Writes to the log file a table showing the sorted sequence of polygon processing, and any circulariti...
string m_strVectorGISOutFormat
Base name for CME vector GIS output files.
vector< string > m_VstrGDALICFDriverCode
GDAL driver code for the initial consolidated fine sediment GIS data.
vector< string > m_VstrInitialFineConsSedimentFile
The name of the initial fine-sized consolidated sediment GIS file.
int m_nUnconsSedimentHandlingAtGridEdges
How sediment which moves off an edge of the grid is handled. Possible values are GRID_EDGE_CLOSED,...
double m_dSandErodibility
The relative erodibility (0- 1) of sand unconsolidated beach sediment.
int m_nSimStartHour
Start time of the simulation (hours)
string m_strGDALLDriverCode
GDAL code for the for the initial landform class raster file.
bool m_bSuspSedTSSave
Save the suspended sediment time series file?
string m_strDeepWaterWaveStationsShapefile
The name of the deep water wave stations shape file.
vector< double > m_VdDepthOverDB
For erosion potential lookup.
bool m_bCliffCollapseNetTSSave
Save the cliff collapse net change time series file?
double m_dStartIterSuspFineInPolygons
Depth (m) of fine suspended sediment at the start of the simulation (only cells in polygons)
unsigned long m_ulThisIterNumCoastCells
The number of grid cells which are marked as coast, for this iteration.
vector< string > m_VstrGDALICSDriverCode
GDAL driver code for the initial consolidated sand sediment GIS data.
unsigned long m_ulNumCells
The number of cells in the grid.
double m_dTotPotentialPlatformErosionBetweenProfiles
Total potential platform erosion between profiles.
double m_dWaveDepthRatioForWaveCalcs
Start depth for wave calculations.
bool m_bFloodLocation
Are we saving the flood location? TODO 007.
string m_strGDALISSDataType
GDAL data type for the initial suspended sediment raster file.
void WriteStartRunDetails(void)
Writes beginning-of-run information to Out and Log files.
double m_dThisIterCliffCollapseErosionCoarseUncons
This-iteration total of coarse unconsolidated sediment produced by cliff collapse (m^3)
vector< string > m_VstrGDALIUCProjection
GDAL projection for the initial unconsolidated coarse sediment GIS data.
ofstream CliffCollapseDepositionTSStream
Cliff collapse deposition time series file output stream.
string m_strGDALLDataType
GDAL data type for the initial landform class raster file.
long double m_ldGTotCoarseBeachDeposition
All-simulation total of coarse sediment deposited during beach (unconsolidated sediment) movement (m)
double m_dDepositionCoarseDiff
Error term: if we are unable to deposit enough unconslidated coarse on polygon(s),...
double m_dBeachSedimentPorosity
The porosity of unconsolidated beach sediment (0 - 1)
int m_nSimStartSec
Start time of the simulation (seconds)
int m_nSimStartDay
Start date of the simulation (day)
unsigned long m_ulThisIterNumActualPlatformErosionCells
The number of grid cells on which actual platform erosion occurs, for this iteration.
bool m_bActualPlatformErosionTSSave
Save the actual (supply-limited) shore platform erosion time series file?
string m_strOGRFloodGeometry
GDAL geometry for the flood input locations point or vector file.
long double m_ldGTotPotentialSedLostBeachErosion
All-simulation total of potential sediment lost via beach (unconsolidated) sediment movement (m),...
double m_dThisIterCliffCollapseErosionFineUncons
This-iteration total of fine unconsolidated sediment produced by cliff collapse (m^3)
bool m_bDoShorePlatformErosion
Simulate shore platform erosion?
bool m_bSliceSave
Save slices?
void WritePolygonShorePlatformErosion(int const)
Writes to the log file a table showing per-polygon unconsolidated sand/coarse sediment derived from e...
string m_strOGRDWWVDriverCode
GDAL code for the deep water wave stations vector file.
double m_dNorthWestYExtCRS
The north-west y coordinate, in the external coordinate reference system (CRS)
vector< string > m_VstrGDALICSDriverDesc
GDAL driver description for the initial consolidated sand sediment GIS data.
bool m_bSaveRegular
Save GIS files at regular intervals?
int m_nLayers
The number of sediment layers.
double m_dStartIterConsCoarseAllCells
Depth (m) of coarse consolidated sediment at the start of the simulation, all cells (both inside and ...
double m_dStartIterConsSandAllCells
Depth (m) of sand consolidated sediment at the start of the simulation, all cells (both inside and ou...
bool m_bSedimentInputAlongLine
Do we have sediment input along a line?
bool m_bSedimentInput
Do we have sediment input events?
unsigned long m_ulThisIterNumBeachDepositionCells
The number of grid cells on which beach (unconsolidated sediment) deposition occurs,...
double m_dDepositionSandDiff
Error term: if we are unable to deposit enough unconslidated sand on polygon(s), this is held over to...
string m_strGDALBasementDEMDriverCode
GDAL code for the basement DEM raster file type.
vector< string > m_VstrGDALIUFDriverCode
GDAL driver code for the initial unconsolidated fine sediment GIS data.
int nSaveProfile(int const, CGeomProfile const *, int const, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< CGeom2DIPoint > *const, vector< double > const *) const
Save a coastline-normal profile.
double m_dThisiterUnconsCoarseInput
Depth (m) of coarse unconsolidated sediment added, at this iteration.
int m_nUSave
If user-defined GIS save intervals, the number of these.
double m_dThisIterPotentialPlatformErosion
Total potential platform erosion (all size classes of consolidated sediment) for this iteration (dept...
bool bWriteTSFiles(void)
Write the results for this timestep to the time series CSV files.
double m_dDeanProfileStartAboveSWL
Berm height i.e. height above SWL of start of depositional Dean profile.
int m_nSavGolCoastPoly
The order of the coastline profile smoothing polynomial if Savitsky-Golay smoothing is used (usually ...
void WritePolygonPotentialErosion(int const)
Writes to the log file a table showing per-polygon potential erosion of all size classes of unconsoli...
ofstream BeachDepositionTSStream
Beach sediment deposition time series file output stream.
double m_dNotchBaseBelowSWL
Notch base below SWL (m)
string m_strInitialBasementDEMFile
Name of initial basement DEM file.
long double m_ldGTotCliffCollapseFine
All-simulation total of fine sediment from cliff collapse (m)
void WritePolygonActualMovement(int const, vector< vector< int > > const &)
Writes to the log file a table showing per-polygon actual movement of unconsolidated beach sediment.
bool m_bWorldFile
Write a GIS World file?
long double m_ldGTotCliffTalusCoarseDeposition
All-simulation total of coarse sediment deposited as talus following cliff collapse (m)
string m_strLogFile
Name of output log file.
double m_dDepthOverDBMax
Maximum value of deoth over DB, is used in erosion potential look-up function.
long double m_ldGTotCliffCollapseCoarse
All-simulation total of coarse sediment from cliff collapse (m)
double m_dFineErodibility
The relative erodibility (0- 1) of fine unconsolidated beach sediment.
double m_dThisiterUnconsFineInput
Depth (m) of fine unconsolidated sediment added, at this iteration.
time_t m_tSysStartTime
System start-simulation time.
double m_dSeaWaterDensity
Density of sea water in kg/m**3.
long double m_ldGTotSuspendedSediment
All-simulation total of suspended sediment (m)
double m_dR
Coast platform resistance to erosion R, see Walkden & Hall, 2011.
string m_strGDALLProjection
GDAL projection string for the initial landform class raster file.
ofstream StillWaterLevelTSStream
SWL time series file output stream.
vector< string > m_VstrInitialSandUnconsSedimentFile
The name of the initial sand-sized unconsolidated sediment GIS file.
double m_dThisIterActualPlatformErosionSandCons
Total actual platform erosion (sand consolidated sediment) for this iteration (depth in m)
bool m_bOmitSearchWestEdge
Omit the west edge of the grid from coast-end searches?
string m_strGDALIHProjection
GDAL projection string for the initial intervention height raster file.
string m_strGDALICDriverDesc
GDAL description of the initial intervention class raster file.
bool m_bSedimentInputAtCoast
Do we have sediment input at the coast?
double m_dCliffErosionResistance
Resistance of cliff to notch erosion.
vector< string > m_VstrGDALIUSProjection
GDAL projection for the initial unconsolidated sand sediment GIS data.
double m_dThisIterBeachDepositionCoarse
Total beach deposition (coarse unconsolidated sediment) for this iteration (depth in m)
double dGridCentroidYToExtCRSY(int const) const
Given the integer Y-axis ordinate of a cell in the raster grid CRS, returns the external CRS Y-axis o...
double m_dD50Sand
The D50 for sand sediment.
long double m_ldGTotCliffTalusSandDeposition
All-simulation total of sand sediment deposited as talus following cliff collapse (m)
vector< int > m_VnProfileToSave
The numbers of the profiles which are to be saved.
double m_dKLS
Transport parameter KLS in the CERC equation.
ofstream BeachSedimentNetChangeTSStream
Beach sediment net change (erosion - deposition) time series file output stream.
string m_strOGRDWWVDriverDesc
int m_nWavePropagationModel
The wave propagation model used. Possible values are WAVE_MODEL_CSHORE and WAVE_MODEL_COVE.
long double m_ldGTotCliffCollapseSandErodedDuringDeposition
All-simulation total of sand sediment eroded during talus deposition following cliff collapse (m)
double m_dAllCellsDeepWaterWaveAngle
Deep water wave angle for all sea cells.
vector< string > m_VstrGDALICFProjection
GDAL projection for the initial consolidated fine sediment GIS data.
string m_strOGRFloodDriverCode
GDAL code for the flood input locations point or vector file.
double m_dSimElapsed
Time simulated so far, in hours.
vector< string > m_VstrGDALICCProjection
GDAL projection for the initial consolidated coarse sediment GIS data.
bool bWriteProfileData(int const, CGeomProfile const *, int const, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< CGeom2DIPoint > *const, vector< double > const *) const
Writes values for a single profile, for checking purposes.
long double m_ldGTotCoarseSedimentInput
All-simulation total of coarse sediment input (m)
bool bWriteParProfileData(int const, int const, int const, int const, int const, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< double > const *, vector< CGeom2DIPoint > *const, vector< double > const *) const
Writes values for a single parallel profile, for checking purposes.
double m_dThisIterUnconsCoarseCliffDeposition
This-iteration total of coarse unconsolidated sediment deposited due to cliff collapse (m^3)
double m_dThisIterTotSeaDepth
Total sea depth (m) for this iteration.
double m_dTotPotentialPlatformErosionOnProfiles
Total potential platform erosion on profiles.
bool m_bOmitSearchNorthEdge
Omit the north edge of the grid from coast-end searches?
long double m_ldGTotCoarseActualPlatformErosion
All-simulation total of coarse sediment actual platform erosion (m)
long double m_ldGTotFineActualPlatformErosion
All-simulation total of fine sediment actual platform erosion (m)
double m_dThisIterUnconsSandCliffDeposition
This-iteration total of sand unconsolidated sediment deposited due to cliff collapse (m^3)
long double m_ldGTotSandSedimentInput
All-simulation total of sand sediment input (m)
string strListTSFiles(void) const
Return a space-separated string containing the names of the time series output files.
bool m_bFloodSetupSurgeTSSave
Save the flood setup surge time series file? TODO 007 Does this work correctly?
string m_strGDALLDriverDesc
GDAL description of the initial landform class raster file.
double m_dNorthWestXExtCRS
The north-west x coordinate, in the external coordinate reference system (CRS)
double m_dD50Coarse
The D50 for coarse sediment.
vector< unsigned long > m_VulProfileTimestep
Timesteps at which to save profiles.
ofstream CliffCollapseErosionTSStream
Cliff collapse erosion time series file output stream.
double m_dThisIterPotentialSedLostBeachErosion
Total unconsolidated sediment from beach erosion (all size classes) lost from the grid this iteration...
double m_dSouthEastYExtCRS
The south-east y coordinate, in the external coordinate reference system (CRS)
string m_strFloodLocationShapefile
The name of the flood loction events shape file.
long double m_ldGTotCliffCollapseFineErodedDuringDeposition
All-simulation total of fine sediment eroded during talus deposition following cliff collapse (m)
long double m_ldGTotCoarseDepositionDiff
All-simulation total of shortfall in unconsolidated coarse sediment deposition (m,...
double m_dCoastNormalAvgSpacing
Average spacing of the cost-normal profiles, in m.
double m_dStartIterConsFineAllCells
Depth (m) of fine consolidated sediment at the start of the simulation, all cells (both inside and ou...
long double m_ldGTotActualCoarseLostBeachErosion
All-simulation total of coarse sediment lost via beach (unconsolidated) sediment movement (m)
bool m_bGISSaveDigitsSequential
Are the GIS save digits (which are part of each GIS file name) sequential, or are they the iteration ...
int m_nSimStartMonth
Start date of the simulation (month)
double m_dMinCliffTalusHeightFrac
Minimum height of the landward end of cliff collapse talus, as a fraction of cliff elevation.
double m_dThisIterBeachErosionSand
Total actual beach erosion (sand unconsolidated sediment) for this iteration (depth in m)
vector< string > m_VstrGDALIUSDriverDesc
GDAL driver description for the initial unconsolidated sand sediment GIS data.
void WritePolygonPreExistingSedimentTable(int const)
Writes to the log file a table showing per-polygon pre-existing unconsolidated sediment.
vector< string > m_VstrInitialFineUnconsSedimentFile
The name of the initial fine-sized unconsolidated sediment GIS file.
double m_dThisIterFineSedimentToSuspension
Total fine unconsolidated sediment in suspension for this iteration (depth in m)
double m_dThisIterBeachErosionFine
Total actual beach erosion (fine unconsolidated sediment) for this iteration (depth in m)
double m_dThisIterCliffCollapseSandErodedDuringDeposition
Total sand sediment eroded during Dean profile deposition of talus following cliff collapse (depth in...
int m_nSimStartMin
Start time of the simulation (minutes)
bool bSaveAllRasterGISFiles(void)
The bSaveAllRasterGISFiles member function saves the raster GIS files using values from the RasterGri...
string m_strOGRDWWVGeometry
GDAL geometry for the deep water wave stations vector file.
unsigned long m_ulThisIterNumActualBeachErosionCells
The number of grid cells on which actual beach (unconsolidated sediment) erosion occurs,...
double m_dCliffDepositionA
Scale parameter A for cliff deposition (m^(1/3)), may be zero for auto-calculation.
string m_strDataPathName
Folder in which the CME data file is found.
string m_strOutPath
Path for all output files.
bool m_bBeachErosionTSSave
Save the beach (unconsolidated sediment) erosion time series file?
vector< string > m_VstrGDALICFDriverDesc
GDAL driver description for the initial consolidated fine sediment GIS data.
static string strGetBuild(void)
Returns the date and time on which the program was compiled.
string m_strTideDataFile
Name of tide data file.
vector< string > m_VstrGDALIUFDriverDesc
GDAL driver description for the initial unconsolidated fine sediment GIS data.
unsigned long m_ulThisIterNumPotentialPlatformErosionCells
The number of grid cells on which potential platform erosion occurs, for this iteration.
vector< string > m_VstrGDALIUSDataType
GDAL data type for the initial unconsolidated sand sediment GIS data.
double m_dStartIterUnconsSandAllCells
Depth (m) of sand unconsolidated sediment at the start of the simulation, all cells (both inside and ...
double m_dMaxSWL
Maximum still water level.
long double m_ldGTotActualSandLostBeachErosion
All-simulation total of sand sediment lost via beach (unconsolidated) sediment movement (m)
int m_nGISSave
The save number for GIS files (can be sequential, or the iteration number)
string m_strInterventionClassFile
Name of intervention class file.
long double m_ldGTotActualFineLostBeachErosion
All-simulation total of fine sediment lost via beach (unconsolidated) sediment movement (m)
string m_strGDALBasementDEMDataType
GDAL data type for the basement DEM raster file.
bool m_bFloodSWLSetupLine
Are we saving the flood still water level setup line? TODO 007.
double m_dThisIterCliffCollapseErosionFineCons
This-iteration total of fine consolidated sediment produced by cliff collapse (m^3)
long double m_ldGTotCoarseSedLostCliffCollapse
All-simulation total of coarse sediment lost via cliff collapse (m)
long double m_ldGTotSandActualPlatformErosion
All-simulation total of sand sediment actual platform erosion (m)
int m_nSimStartYear
Start date of the simulation (year)
void WritePolygonShareTable(int const)
Writes to the log file a table showing polygon to polygon shares of unconsolidated sediment transport...
string m_strDeepWaterWavesInputFile
The name of the deep water wave stations time series file.
long double m_ldGTotSandSedLostCliffCollapse
All-simulation total of sand sediment lost via cliff collapse (m)
double m_dUnconsSandNotDepositedLastIter
Depth of unconsolidated sand sediment that could not be deposited during the last iteration,...
string m_strGDALICProjection
GDAL projection string for the initial intervention class raster file.
double m_dTotalCoarseConsInPolygons
Total coarse consolidated sediment in all polygons, before polygon-to-polygon movement (only cells in...
int m_nCoastCurvatureMovingWindowSize
ofstream SeaAreaTSStream
Sea area time series file output stream.
unsigned long m_ulThisIterNumSeaCells
The number of grid cells which are marked as sea, for this iteration.
double m_dTotalSandUnconsInPolygons
Total sand unconsolidated sediment in all polygons, before polygon-to-polygon movement (only cells in...
bool m_bRiverineFlooding
Are we doing flooding? TODO 007.
double m_dStartIterUnconsFineAllCells
Depth (m) of fine unconsolidated sediment at the start of the simulation, all cells (both inside and ...
CGeomCoastPolygon * pGetPolygon(int const) const
Returns a pointer to a coast polygon, in down-coast sequence.
double m_dRegularSaveInterval
The interval between regular saves, in hours.
long double m_ldGTotActualFineBeachErosion
All-simulation total of fine sediment eroded during beach (unconsolidated sediment) movement (m)
string m_strGDALISSDriverDesc
GDAL description for the initial suspended sediment raster file.
unsigned long m_ulTotPotentialPlatformErosionOnProfiles
The number of cells on which on-profile average potential shore platform erosion occurs.
bool m_bCliffCollapseDepositionTSSave
Save the cliff collapse deposition time series file?
string m_strGDALRasterOutputDriverLongname
GDAL raster output driver long name.
vector< string > m_VstrGDALIUCDriverCode
GDAL driver code for the initial unconsolidated coarse sediment GIS data.
ofstream PlatformErosionTSStream
Shore platform erosion time series file output stream.
void DoEndOfTimestepTotals(void)
Update and print totals at the end of each timestep.
double m_dCellArea
Area of a cell (in external CRS units)
unsigned long m_ulTotPotentialPlatformErosionBetweenProfiles
The number of cells on which between-profile average potential shore platform erosion occurs.
double m_dCoastNormalRandSpacingFactor
Random factor for spacing of along-coast normals.
double m_dMaxUserInputWaveHeight
Maximum deep water wave height.
vector< double > m_VdSliceElev
Elevations for raster slice output.
string m_strOGRSedInputGeometry
GDAL geometry for the sediment input event locations vector file.
string m_strOGRSedInputDriverCode
GDAL code for the sediment input event locations vector file.
double m_dFinalSWL
The end-of-simulation still water (m), is same as m_dOrigSWL unless SWL changes.
bool m_bDoBeachSedimentTransport
Simulate unconsolidated sediment (beach) transport?
unsigned long m_ulThisIterNumPotentialBeachErosionCells
The number of grid cells on which potential beach (unconsolidated sediment) erosion occurs,...
int m_nCoastSmooth
Which method to use for coast smoothing.
string m_strGDALBasementDEMDriverDesc
GDAL description of the basement DEM raster file type.
string m_strInitialLandformFile
Name of initial landform file.
string m_strInterventionHeightFile
Name of intervention height file.
double m_dThisIterCliffCollapseErosionSandCons
This-iteration total of sand consolidated sediment produced by cliff collapse (m^3)
bool m_bBeachSedimentChangeNetTSSave
Save the beach (unconsolidated sediment) net change time series file?
vector< string > m_VstrGDALICSDataType
GDAL data type for the initial consolidated sand sediment GIS data.
double m_dThisIterBeachDepositionSand
Total beach deposition (sand unconsolidated sediment) for this iteration (depth in m)
string m_strOGRFloodDriverDesc
bool m_bSeaAreaTSSave
Save the sea area time series file?
bool m_bScaleRasterOutput
Scale raster output?
vector< string > m_VstrGDALICSProjection
GDAL dprojection for the initial consolidated sand sediment GIS data.
void CalcProcessStats(void)
This calculates and displays process statistics.
int nGetCoastPolygonSize(void) const
Returns the size of the coast polygon vector.
double m_dThisIterLeftGridUnconsCoarse
Total coarse unconsolidated sediment lost from the grid this iteration (depth in m)
double m_dThisIterCliffCollapseErosionSandUncons
This-iteration total of sand unconsolidated sediment produced by cliff collapse (m^3)
string m_strOGRFloodDataType
GDAL data type for the flood input locations point or vector file.
double m_dD50Fine
The D50 for fine sediment.
bool m_bOmitSearchSouthEdge
Omit the south edge of the grid from coast-end searches?
string m_strGDALBasementDEMProjection
GDAL projection string for the basement DEM raster file.
double m_dTotalSandConsInPolygons
Total sand consolidated sediment in all polygons, before polygon-to-polygon movement (only cells in p...
unsigned long m_ulIter
The number of the current iteration (time step)
void WritePolygonUnsortedSequence(int const, vector< vector< int > > &)
Writes to the log file a table showing the unsorted sequence of polygon processing.
double m_dBeachSedimentDensity
The density of unconsolidated beach sediment (kg/m**3)
double dGridCentroidXToExtCRSX(int const) const
Given the integer X-axis ordinate of a cell in the raster grid CRS, returns the external CRS X-axis o...
vector< string > m_VstrInitialCoarseConsSedimentFile
The name of the initial coarse-sized consolidated sediment GIS file.
string m_strOGRDWWVDataType
GDAL data type for the deep water wave stations vector file.
double m_dSimDuration
Duration of simulation, in hours.
double m_dTotalFineUnconsInPolygons
Total fine unconsolidated sediment in all polygons, before polygon-to-polygon movement (only cells in...
string m_strGDALIHDriverCode
GDAL code for the initial intervention height raster file.
long double m_ldGTotSandDepositionDiff
All-simulation total of shortfall in unconsolidated sand sediment deposition (m, not currently used)
string m_strGDALICDriverCode
GDAL code for the initial intervention class raster file.
ofstream FloodSetupSurgeTSStream
Flood setup surge time series file output stream.
double m_dTotalFineConsInPolygons
Total fine consolidated sediment in all polygons, before polygon-to-polygon movement (only cells in p...
double m_dThisiterUnconsSandInput
Depth (m) of sand unconsolidated sediment added, at this iteration.
double m_dExtCRSGridArea
The area of the grid (in external CRS units)
bool m_bOutputProfileData
Output profile data?
double m_dThisIterDiffWaveSetupSurgeRunupWaterLevel
TODO 007 Info needed.
double m_dCellSide
Length of a cell side (in external CRS units)
vector< string > m_VstrGDALIUCDriverDesc
GDAL driver description for the initial unconsolidated coarse sediment GIS data.
double m_dMaxBeachElevAboveSWL
Maximum elevation of beach above SWL (m)
long double m_ldGTotActualSandBeachErosion
All-simulation total of sand sediment eroded during beach (unconsolidated sediment) movement (m)
double m_dAllCellsDeepWaterWavePeriod
Deep water wave period for all sea cells.
double m_dThisIterCliffCollapseCoarseErodedDuringDeposition
Total coarse sediment eroded during Dean profile deposition of talus following cliff collapse (depth ...
long double m_ldGTotSandBeachDeposition
All-simulation total of sand sediment deposited during beach (unconsolidated sediment) movement (m)
double m_dUSaveTime[SAVEMAX]
Save time, in hours from the start of the simukation, if we are not saving regularly.
double m_dThisIterActualPlatformErosionFineCons
Total actual platform erosion (fine consolidated sediment) for this iteration (depth in m)
long double m_ldGTotPotentialBeachErosion
All-simulation total of potential beach erosion (m), all size classes.
double m_dProfileMaxSlope
Maximum slope on costline-normal profiles.
int m_nProfileSmoothWindow
The size of the window used for running-mean coast-normal profile smoothing (must be odd)
string m_strGDALIHDriverDesc
GDAL description for the initial intervention height raster file.
bool m_bDoCliffCollapse
Simulate cliff collapse?
double m_dThisIterCliffCollapseErosionCoarseCons
This-iteration total of coarse consolidated sediment produced by cliff collapse (m^3)
double m_dThisIterLeftGridUnconsSand
Total sand unconsolidated sediment lost from the grid this iteration (depth in m)
unsigned long m_ulRandSeed[NRNG]
A seed for each of the NRNG random number generators.
double m_dDepthOfClosure
Depth of closure (in m) TODO 007 can be calculated using Hallermeier, R.J. (1978) or Birkemeier (1985...
vector< string > m_VstrGDALICCDriverDesc
GDAL driver decription for the initial consolidated coarse sediment GIS data.
double m_dOrigSWL
The start-of-simulation still water level (m)
double m_dStartIterSuspFineAllCells
Depth (m) of fine suspended sediment at the start of the simulation, all cells (both inside and outsi...
string m_strOutFile
Name of main output file.
string m_strGDALIHDataType
GDAL data type for the initial intervention height raster file.
ofstream FineSedSuspensionTSStream
Fine sediment in suspension time series file output stream.
ofstream FloodSetupSurgeRunupTSStream
Flood setup surge runup time series file output stream.
long double m_ldGTotFineSedimentInput
All-simulation total of fine sediment input (m)
double m_dThisIterMeanSWL
The mean still water level for this timestep (does not include tidal changes, but includes any long-t...
vector< string > m_VstrGDALIUCDataType
GDAL data type for the initial unconsolidated coarse sediment GIS data.
bool m_bCliffCollapseErosionTSSave
Save the cliff collapse erosion time series file?
long double m_ldGTotPotentialPlatformErosion
All-simulation total of potential platform erosion (m), all size classes.
ofstream BeachErosionTSStream
Beach sediment erosion time series file output stream.
long double m_ldGTotCliffCollapseSand
All-simulation total of sand sediment from cliff collapse (m)
ofstream OutStream
The main output file stream.
bool m_bFloodSWLSetupSurgeRunupLine
Are we saving the flood still water level setup surge runup line? TODO 007.
bool m_bOutputParallelProfileData
Output parallel profile data?
double m_dKamphuis
Transport parameter for the Kamphuis equation.
bool m_bOutputErosionPotentialData
Output erosion potential data?
bool m_bVectorWaveFloodLineSave
Are we saving the vector wave flood line? TODO 007.
vector< string > m_VstrGDALIUSDriverCode
GDAL driver code for the initial unconsolidated sand sediment GIS data.
bool m_bOmitSearchEastEdge
Omit the east edge of the grid from coast-end searches?
vector< CGeomCoastPolygon * > m_pVCoastPolygon
Pointers to coast polygon objects, in down-coast sequence TODO 044 Will need to use global polygon ID...
int m_nCoastSmoothWindow
The size of the window used for coast smoothing. Must be an odd number.
double m_dThisIterLeftGridUnconsFine
Total fine unconsolidated sediment lost from the grid this iteration (depth in m)
This file contains global definitions for CoastalME.
int const WAVE_MODEL_COVE
string const PER_ITER_HEAD
int const UNCONS_SEDIMENT_EQUATION_KAMPHUIS
int const LOG_FILE_LOW_DETAIL
int const RTN_ERR_RASTER_FILE_WRITE
string const PER_ITER_HEAD4
double const DEPTH_OVER_DB_INCREMENT
int const WAVE_MODEL_CSHORE
int const RTN_ERR_PROFILEWRITE
string const PER_ITER_HEAD2
int const LOG_FILE_MIDDLE_DETAIL
bool bFPIsEqual(const T d1, const T d2, const T dEpsilon)
string const ENDHYDROLOGYHEAD
int const GRID_EDGE_CLOSED
int const GRID_EDGE_RECIRCULATE
double const MASS_BALANCE_TOLERANCE
string const ENDSEDIMENTHEAD
int const LOG_FILE_HIGH_DETAIL
string const PROGRAM_NAME
int const SMOOTH_SAVITZKY_GOLAY
string const PER_ITER_HEAD3
int const SMOOTH_RUNNING_MEAN
int const RTN_ERR_VECTOR_FILE_WRITE
string const PER_ITER_HEAD5
int const CSHOREARRAYOUTSIZE
The size of the arrays output by CShore. If you change this, then you must also set the same value on...
string const EROSION_POTENTIAL_LOOKUP_FILE
int const UNCONS_SEDIMENT_EQUATION_CERC
string const PER_ITER_HEAD1
string const MASS_BALANCE_ERROR
int const RTN_ERR_TIMESERIES_FILE_WRITE
Contains CRWCoast definitions.
double dGetInterpolatedValue(vector< double > const *pVdXdata, vector< double > const *pVdYdata, double dX, bool bExtrapolate)
Definitions of routines which return interpolated value at x from parallel arrays.
Contains CSimulation definitions.
string strLeft(const string &strIn, int const nWidth)
Left-aligns string within a field of given width, pads with blank spaces to enforce alignment....
string strDblRight(double const dX, int const nDigits, int const nWidth, bool const bShowDash)
Converts double to string with specified number of decimal places, within a field of given width,...
string strRightPerCent(double const d1, double const d2, int const nWidth, int const nDigits, bool const bShowDash)
Calculates a percentage from two numbers then, if the result is non-zero, right-aligns the result as ...
string strCentre(const char *pchIn, int const nWidth)
Centre-aligns char array within a field of given width, pads with blank spaces to enforce alignment....
string strRight(const string &strIn, int const nWidth)
Right-aligns string within a field of given width, pads with blank spaces to enforce alignment....
string strIntRight(int const nX, int const nWidth)
Converts int to string within a field of given width, pads with blank spaces to enforce alignment....