Skip to content

Commit dfd533a

Browse files
committed
final fix and cleanup
1 parent 078bd4a commit dfd533a

File tree

20 files changed

+12
-57
lines changed

20 files changed

+12
-57
lines changed

Common/include/CConfig.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,6 @@ class CConfig {
355355
su2double BEM_blade_angle; /*!< \brief Propeller blade angle.*/
356356
string BEM_prop_filename; /*!< \brief Propeller filename.*/
357357
unsigned short ActDiskBem_Frequency; /*!< \brief Frequency of updating actuator disk with BEM. */
358-
//bool History_File_Append_Flag; /*!< \brief Flag to append history file.*/
359358
su2double *ActDisk_DeltaPress; /*!< \brief Specified pressure delta for actuator disk. */
360359
su2double *ActDisk_DeltaTemp; /*!< \brief Specified temperature delta for actuator disk. */
361360
su2double *ActDisk_TotalPressRatio; /*!< \brief Specified tot. pres. ratio for actuator disk. */

Common/src/CConfig.cpp

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2433,8 +2433,8 @@ void CConfig::SetConfig_Options() {
24332433
/*!\par CONFIG_CATEGORY: FEA solver \ingroup Config*/
24342434
/*--- Options related to the FEA solver ---*/
24352435

2436-
/*!\brief FEA_FILENAME \n DESCRIPTION: Filename to input for element-based properties \n Default: default_element_properties.dat \ingroup Config */
2437-
addStringOption("FEA_FILENAME", FEA_FileName, string("default_element_properties.dat"));
2436+
/*!\brief FEA_FILENAME \n DESCRIPTION: Filename to input for element-based properties \n Default: default_element_properties \ingroup Config */
2437+
addStringOption("FEA_FILENAME", FEA_FileName, string("default_element_properties"));
24382438
/* DESCRIPTION: Determine if advanced features are used from the element-based FEA analysis (NO, YES = experimental) */
24392439
addBoolOption("FEA_ADVANCED_MODE", FEAAdvancedMode, false);
24402440

@@ -8403,11 +8403,6 @@ string CConfig::GetUnsteady_FileName(string val_filename, int val_iter, const st
84038403
string UnstExt, UnstFilename = std::move(val_filename);
84048404
char buffer[50];
84058405

8406-
/*--- Note that we always call this routine with the extension already attached, so
8407-
we remove it. ---*/
8408-
//unsigned short lastindex = UnstFilename.find_last_of('.');
8409-
//UnstFilename = UnstFilename.substr(0, lastindex);
8410-
84118406
/*--- Check that a positive value iteration is requested (for now). ---*/
84128407

84138408
if (val_iter < 0) {
@@ -8436,11 +8431,6 @@ string CConfig::GetMultizone_FileName(string val_filename, int val_iZone, const
84368431
string multizone_filename = std::move(val_filename);
84378432
char buffer[50];
84388433

8439-
/*--- Note that we always call this routine wit the extension already attached, so
8440-
we remove it. ---*/
8441-
//unsigned short lastindex = multizone_filename.find_last_of('.');
8442-
//multizone_filename = multizone_filename.substr(0, lastindex);
8443-
84448434
if (Multizone_Problem) {
84458435
SPRINTF (buffer, "_%d", SU2_TYPE::Int(val_iZone));
84468436
multizone_filename.append(string(buffer));

Common/src/geometry/meshreader/CSU2ASCIIMeshReaderBase.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,8 @@ bool CSU2ASCIIMeshReaderBase::ReadMetadata(const bool single_pass, CConfig* conf
4444
/*--- Open grid file ---*/
4545
mesh_file.open(meshFilename);
4646
if (mesh_file.fail()) {
47-
cout << "Trying to open mesh filename " << meshFilename << endl;
4847
SU2_MPI::Error(
49-
"Error opening SU2 ASCII grid. \n"
48+
"Error opening SU2 ASCII grid.\n"
5049
"Check that the file exists.",
5150
CURRENT_FUNCTION);
5251
}

SU2_CFD/src/output/CFlowOutput.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2434,14 +2434,6 @@ void CFlowOutput::WriteForcesBreakdown(const CConfig* config, const CSolver* flo
24342434

24352435
auto fileName = config->GetBreakdown_FileName();
24362436

2437-
2438-
//if (unsteady) {
2439-
//const auto lastindex = fileName.find_last_of('.');
2440-
//const auto ext = fileName.substr(lastindex, fileName.size());
2441-
//fileName = fileName.substr(0, lastindex);
2442-
//fileName = config->GetFilename(fileName, ext, curTimeIter);
2443-
//}
2444-
24452437
/*--- Output the mean flow solution using only the master node ---*/
24462438

24472439
cout << "\nWriting the forces breakdown file (" << fileName << ")." << endl;

SU2_CFD/src/output/COutput.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -482,6 +482,7 @@ void COutput::WriteToFile(CConfig *config, CGeometry *geometry, OUTPUT_TYPE form
482482
/*--- Load and sort the output data and connectivity. ---*/
483483

484484
volumeDataSorter->SortConnectivity(config, geometry, true);
485+
485486
LogOutputFiles("SU2 mesh");
486487
fileWriter = new CSU2MeshFileWriter(volumeDataSorter, config->GetiZone(), config->GetnZone());
487488

SU2_CFD/src/output/filewriter/CSU2MeshFileWriter.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,12 @@ void CSU2MeshFileWriter::WriteData(string val_filename) {
3838

3939
ofstream output_file;
4040

41-
42-
cout <<"mesh file writer : file=" << val_filename << endl;
4341
/*--- strip the extension from the original filename and add the .su2 extension ---*/
4442
unsigned short lastindex = val_filename.find_last_of('.');
4543
val_filename = val_filename.substr(0, lastindex);
46-
cout <<"mesh file writer : file=" << val_filename << endl;
4744

4845
/*--- We append the pre-defined suffix (extension) to the filename (prefix) ---*/
4946
val_filename.append(fileExt);
50-
cout <<"mesh file writer : file=" << val_filename << endl;
5147

5248
/*--- Only the FIRST node writes the header (it does not matter if that is the master). ---*/
5349

SU2_CFD/src/solvers/CBaselineSolver.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,17 +91,13 @@ void CBaselineSolver::SetOutputVariables(CGeometry *geometry, CConfig *config) {
9191
} else {
9292
filename = config->GetSolution_FileName();
9393
}
94-
//nijso
95-
cout << "filename = "<<filename << endl;
9694
/*--- Read only the number of variables in the restart file. ---*/
9795

9896
if (config->GetRead_Binary_Restart()) {
9997

10098
/*--- Multizone problems require the number of the zone to be appended. ---*/
10199

102-
103100
filename = config->GetFilename(filename, ".dat", config->GetTimeIter());
104-
cout << "filename = "<<filename << endl;
105101

106102
char fname[100];
107103
strcpy(fname, filename.c_str());

SU2_CFD/src/solvers/CFEASolver.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,6 @@ void CFEASolver::Set_ReferenceGeometry(CGeometry *geometry, CConfig *config) {
487487
/*--- In case there is no file ---*/
488488

489489
if (reference_file.fail()) {
490-
cout << "reference_file" << endl;
491490
SU2_MPI::Error( "There is no FEM reference geometry file!!", CURRENT_FUNCTION);
492491
}
493492

SU2_PY/SU2/io/state.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,6 @@ def find_files(self, config):
259259
files = self.FILES
260260

261261
mesh_name = config.MESH_FILENAME
262-
print("state:: find_files: binary restart = ", config.READ_BINARY_RESTART)
263262
if config.get("READ_BINARY_RESTART", "YES") == "NO":
264263
if not "RESTART_ASCII" in config.get("OUTPUT_FILES", ["RESTART"]):
265264
print(
@@ -270,16 +269,10 @@ def find_files(self, config):
270269
direct_name = config.SOLUTION_FILENAME
271270
adjoint_name = config.SOLUTION_ADJ_FILENAME
272271

273-
print("direct name=", direct_name)
274-
275272
if "RESTART_ASCII" in config.get("OUTPUT_FILES", ["RESTART"]):
276-
# direct_name = direct_name.split(".")[0] + ".csv"
277-
# adjoint_name = adjoint_name.split(".")[0] + ".csv"
278273
direct_name = direct_name + ".csv"
279274
adjoint_name = adjoint_name + ".csv"
280275
else:
281-
# direct_name = direct_name.split(".")[0] + ".dat"
282-
# adjoint_name = adjoint_name.split(".")[0] + ".dat"
283276
direct_name = direct_name + ".dat"
284277
adjoint_name = adjoint_name + ".dat"
285278

SU2_PY/SU2/io/tools.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1178,9 +1178,6 @@ def restart2solution(config, state={}):
11781178
if config.MATH_PROBLEM == "DIRECT":
11791179
restart = config.RESTART_FILENAME
11801180
solution = config.SOLUTION_FILENAME
1181-
# restart = restart.split(".")[0]
1182-
# solution = solution.split(".")[0]
1183-
11841181
pass
11851182

11861183
if "RESTART_ASCII" in config.get("OUTPUT_FILES", ["RESTART_BINARY"]):
@@ -1197,7 +1194,6 @@ def restart2solution(config, state={}):
11971194
restarts = expand_time(restarts, config)
11981195
solutions = expand_time(solutions, config)
11991196

1200-
print("copy restart to solution:", restarts, " ", solutions)
12011197
# move
12021198
for res, sol in zip(restarts, solutions):
12031199
if os.path.exists(res):

0 commit comments

Comments
 (0)