Skip to content

Commit 5b7c300

Browse files
authored
Merge pull request #122 from wenqing/clang-format
Clang format for some files and a new tag of 5.8
2 parents 400ebfc + 6d9d86f commit 5b7c300

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+926
-774
lines changed

Base/FileFinder.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ class FileFinder
4949
<< "Error: FileFinder::getPath() -- directory list is empty."
5050
<< "\n";
5151
for (std::list<std::string>::iterator it = _directories.begin();
52-
it != _directories.end(); ++it)
52+
it != _directories.end();
53+
++it)
5354
{
5455
std::string testDir(*it);
5556
std::ifstream is(testDir.append(filename).c_str());

Base/printList.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ void printList(std::list<size_t> const& mylist, std::string const& title)
2424
{
2525
std::cout << title << "\n";
2626
for (std::list<size_t>::const_iterator my_it(mylist.begin());
27-
my_it != mylist.end(); my_it++)
27+
my_it != mylist.end();
28+
my_it++)
2829
std::cout << *my_it << " ";
2930
std::cout << "\n";
3031
}

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,8 +163,8 @@ mark_as_advanced(FORCE OGS_PYTHON OGS_CMAKE_DEBUG OGS_ONE_BIG_GTEST OGS_BUILD_IN
163163
###########################################################################
164164
### OGS version information is now obtained from Git tags. Adjust authors & date.
165165
###########################################################################
166-
set (OGS_RELEASE_PERSONS "LB/NW/TN/WW")
167-
set (OGS_DATE "09.08.2016")
166+
set (OGS_RELEASE_PERSONS "")
167+
set (OGS_DATE "21.12.2018")
168168

169169
###################
170170
### Fem configs ###

FEM/DUMUX.cpp

Lines changed: 48 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -484,9 +484,9 @@ int CDUMUXData::WriteInputForDuMux(CRFProcess* m_pcs,
484484
// TF commented out since we want to use the improved PointDuMux
485485
// class
486486
// value =
487-
//pcs_vector[this->ProcessIndex_CO2inLiquid]->GetNodeValue(i,
488-
//indexConcentration_DIC) * (this->Molweight_CO2 / 1000) /
489-
//this->NodeData[i]->phase_density[0];
487+
// pcs_vector[this->ProcessIndex_CO2inLiquid]->GetNodeValue(i,
488+
// indexConcentration_DIC) * (this->Molweight_CO2 / 1000) /
489+
// this->NodeData[i]->phase_density[0];
490490
value = pcs_vector[this->ProcessIndex_CO2inLiquid]->GetNodeValue(
491491
i, indexConcentration_DIC) *
492492
(this->Molweight_CO2 / 1000) /
@@ -583,10 +583,11 @@ int CDUMUXData::WriteInputForDuMux(CRFProcess* m_pcs,
583583
tempstring = temp.str();
584584
// TF commented out since we want to use the improved PointDuMux class
585585
// temp.str(""); temp.clear(); temp << this->NodeData[i]->x;
586-
//tempstring += "; " + temp.str(); temp.str(""); temp.clear(); temp <<
587-
//this->NodeData[i]->y; tempstring += "; " + temp.str(); temp.str("");
588-
//temp.clear(); temp << this->NodeData[i]->z; tempstring += "; " +
589-
//temp.str();
586+
// tempstring += "; " + temp.str(); temp.str(""); temp.clear();
587+
// temp
588+
// << this->NodeData[i]->y; tempstring += "; " + temp.str();
589+
// temp.str(""); temp.clear(); temp << this->NodeData[i]->z; tempstring
590+
// += "; " + temp.str();
590591
for (size_t k(0); k < 3; k++)
591592
{
592593
temp.str("");
@@ -597,29 +598,29 @@ int CDUMUXData::WriteInputForDuMux(CRFProcess* m_pcs,
597598

598599
// TF commented out since we want to use the improved PointDuMux class
599600
// temp.str(""); temp.clear(); temp.precision(12); temp <<
600-
//this->NodeData[i]->phase_pressure[0]; tempstring
601+
// this->NodeData[i]->phase_pressure[0]; tempstring
601602
//+= "; " + temp.str();
602603
// temp.str(""); temp.clear(); temp.precision(12); temp <<
603-
//this->NodeData[i]->phase_pressure[1]; tempstring
604+
// this->NodeData[i]->phase_pressure[1]; tempstring
604605
//+= "; " + temp.str();
605606
// temp.str(""); temp.clear(); temp.precision(12); temp <<
606-
//this->NodeData[i]->phase_saturation[0];
607+
// this->NodeData[i]->phase_saturation[0];
607608
// tempstring
608609
//+= "; " + temp.str();
609610
// temp.str(""); temp.clear(); temp.precision(12); temp <<
610-
//this->NodeData[i]->phase_saturation[1];
611+
// this->NodeData[i]->phase_saturation[1];
611612
// tempstring
612613
//+= "; " + temp.str();
613614
// temp.str(""); temp.clear(); temp.precision(12); temp <<
614-
//this->NodeData[i]->phase_density[0]; tempstring
615+
// this->NodeData[i]->phase_density[0]; tempstring
615616
//+=
616617
//"; " + temp.str();
617618
// temp.str(""); temp.clear(); temp.precision(12); temp <<
618-
//this->NodeData[i]->phase_density[1]; tempstring
619+
// this->NodeData[i]->phase_density[1]; tempstring
619620
//+=
620621
//"; " + temp.str();
621622
// temp.str(""); temp.clear(); temp.precision(12); temp <<
622-
//this->NodeData[i]->CO2inLiquid; tempstring += ";
623+
// this->NodeData[i]->CO2inLiquid; tempstring += ";
623624
//"
624625
//+ temp.str();
625626
temp.str("");
@@ -663,10 +664,10 @@ int CDUMUXData::WriteInputForDuMux(CRFProcess* m_pcs,
663664
i, indexConcentration_DIC);
664665
// TF commented out since we want to use the improved PointDuMux class
665666
// mass_CO2_gas = node_volume *
666-
//this->NodeData[i]->phase_saturation[1] *
667+
// this->NodeData[i]->phase_saturation[1] *
667668
// this->NodeData[i]->phase_density[1];
668669
// mass_CO2_water = node_volume *
669-
//this->NodeData[i]->phase_saturation[0] * concentration_CO2_water *
670+
// this->NodeData[i]->phase_saturation[0] * concentration_CO2_water *
670671
// this->Molweight_CO2 * 0.001;
671672
mass_CO2_gas = node_volume *
672673
this->NodeData[i]->getPhaseSaturation()[1] *
@@ -834,11 +835,11 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
834835
// TF commented out since we want to use the improved PointDuMux
835836
// class
836837
// if ((atof(TextFile->Data_separated[i][1].data()) !=
837-
//this->NodeData[i]->x) ||
838+
// this->NodeData[i]->x) ||
838839
//(atof(TextFile->Data_separated[i][2].data()) !=
839-
//this->NodeData[i]->y) ||
840+
// this->NodeData[i]->y) ||
840841
//(atof(TextFile->Data_separated[i][3].data()) !=
841-
//this->NodeData[i]->z)) {
842+
// this->NodeData[i]->z)) {
842843
if ((atof(TextFile->Data_separated[i][1].data()) !=
843844
(*(this->NodeData[i]))[0]) ||
844845
(atof(TextFile->Data_separated[i][2].data()) !=
@@ -865,7 +866,7 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
865866
// TF commented out since we want to use the improved PointDuMux
866867
// class
867868
// this->NodeData[i]->phase_pressure[j] =
868-
//atof(TextFile->Data_separated[i][column].data()) *
869+
// atof(TextFile->Data_separated[i][column].data()) *
869870
// Multiplier;
870871
this->NodeData[i]->getPhasePressure()[j] =
871872
atof(TextFile->Data_separated[i][column].data()) * Multiplier;
@@ -891,7 +892,7 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
891892
// TF commented out since we want to use the improved PointDuMux
892893
// class
893894
// this->NodeData[i]->q[j][k] =
894-
//atof(TextFile->Data_separated[i][column].data()) *
895+
// atof(TextFile->Data_separated[i][column].data()) *
895896
// Multiplier;
896897
this->NodeData[i]->getQ()[j][k] =
897898
atof(TextFile->Data_separated[i][column].data()) *
@@ -900,32 +901,32 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
900901
column += 1;
901902
// TF commented out since we want to use the improved PointDuMux class
902903
// this->NodeData[i]->CO2inLiquid =
903-
//atof(TextFile->Data_separated[i][column].data()) * Multiplier;
904+
// atof(TextFile->Data_separated[i][column].data()) * Multiplier;
904905
this->NodeData[i]->setCO2InLiquid(
905906
atof(TextFile->Data_separated[i][column].data()) * Multiplier);
906907
// cout << i << " " << this->NodeData[i]->CO2inLiquid << "\n";
907908
column += 1;
908909
// TF commented out since we want to use the improved PointDuMux class
909910
// this->NodeData[i]->NaClinLiquid =
910-
//atof(TextFile->Data_separated[i][column].data()) * Multiplier;
911+
// atof(TextFile->Data_separated[i][column].data()) * Multiplier;
911912
this->NodeData[i]->setNaClInLiquid(
912913
atof(TextFile->Data_separated[i][column].data()) * Multiplier);
913914
column += 1;
914915
// TF commented out since we want to use the improved PointDuMux class
915916
// this->NodeData[i]->temperature =
916-
//atof(TextFile->Data_separated[i][column].data()) * Multiplier;
917+
// atof(TextFile->Data_separated[i][column].data()) * Multiplier;
917918
this->NodeData[i]->setTemperature(
918919
atof(TextFile->Data_separated[i][column].data()) * Multiplier);
919920
column += 1;
920921
// TF commented out since we want to use the improved PointDuMux class
921922
// this->NodeData[i]->phase_density[0] =
922-
//atof(TextFile->Data_separated[i][column].data()) * Multiplier;
923+
// atof(TextFile->Data_separated[i][column].data()) * Multiplier;
923924
this->NodeData[i]->getPhaseDensity()[0] =
924925
atof(TextFile->Data_separated[i][column].data()) * Multiplier;
925926
column += 1;
926927
// TF commented out since we want to use the improved PointDuMux class
927928
// this->NodeData[i]->phase_density[1] =
928-
//atof(TextFile->Data_separated[i][column].data()) * Multiplier;
929+
// atof(TextFile->Data_separated[i][column].data()) * Multiplier;
929930
this->NodeData[i]->getPhaseDensity()[1] =
930931
atof(TextFile->Data_separated[i][column].data()) * Multiplier;
931932
}
@@ -980,10 +981,11 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
980981
tempstring = temp.str();
981982
// TF commented out since we want to use the improved PointDuMux class
982983
// temp.str(""); temp.clear(); temp << this->NodeData[i]->x;
983-
//tempstring += "; " + temp.str(); temp.str(""); temp.clear(); temp <<
984-
//this->NodeData[i]->y; tempstring += "; " + temp.str(); temp.str("");
985-
//temp.clear(); temp << this->NodeData[i]->z; tempstring += "; " +
986-
//temp.str();
984+
// tempstring += "; " + temp.str(); temp.str(""); temp.clear();
985+
// temp
986+
// << this->NodeData[i]->y; tempstring += "; " + temp.str();
987+
// temp.str(""); temp.clear(); temp << this->NodeData[i]->z; tempstring
988+
// += "; " + temp.str();
987989
for (size_t k(0); k < 3; k++)
988990
{
989991
temp.str("");
@@ -994,29 +996,29 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
994996

995997
// TF commented out since we want to use the improved PointDuMux class
996998
// temp.str(""); temp.clear(); temp.precision(12); temp <<
997-
//this->NodeData[i]->phase_pressure[0]; tempstring
999+
// this->NodeData[i]->phase_pressure[0]; tempstring
9981000
//+= "; " + temp.str();
9991001
// temp.str(""); temp.clear(); temp.precision(12); temp <<
1000-
//this->NodeData[i]->phase_pressure[1]; tempstring
1002+
// this->NodeData[i]->phase_pressure[1]; tempstring
10011003
//+= "; " + temp.str();
10021004
// temp.str(""); temp.clear(); temp.precision(12); temp <<
1003-
//this->NodeData[i]->phase_saturation[0];
1005+
// this->NodeData[i]->phase_saturation[0];
10041006
// tempstring
10051007
//+= "; " + temp.str();
10061008
// temp.str(""); temp.clear(); temp.precision(12); temp <<
1007-
//this->NodeData[i]->phase_saturation[1];
1009+
// this->NodeData[i]->phase_saturation[1];
10081010
// tempstring
10091011
//+= "; " + temp.str();
10101012
// temp.str(""); temp.clear(); temp.precision(12); temp <<
1011-
//this->NodeData[i]->phase_density[0]; tempstring
1013+
// this->NodeData[i]->phase_density[0]; tempstring
10121014
//+=
10131015
//"; " + temp.str();
10141016
// temp.str(""); temp.clear(); temp.precision(12); temp <<
1015-
//this->NodeData[i]->phase_density[1]; tempstring
1017+
// this->NodeData[i]->phase_density[1]; tempstring
10161018
//+=
10171019
//"; " + temp.str();
10181020
// temp.str(""); temp.clear(); temp.precision(12); temp <<
1019-
//this->NodeData[i]->CO2inLiquid; tempstring += ";
1021+
// this->NodeData[i]->CO2inLiquid; tempstring += ";
10201022
//"
10211023
//+ temp.str();
10221024
temp.str("");
@@ -1057,12 +1059,12 @@ void CDUMUXData::ReadDuMuxData(CRFProcess* m_pcs,
10571059

10581060
// TF commented out since we want to use the improved PointDuMux class
10591061
// concentration_CO2_water = this->NodeData[i]->CO2inLiquid *
1060-
//this->NodeData[i]->phase_density[0] / (this->Molweight_CO2 * 1e-3);
1062+
// this->NodeData[i]->phase_density[0] / (this->Molweight_CO2 * 1e-3);
10611063
// mass_CO2_gas = node_volume *
1062-
//this->NodeData[i]->phase_saturation[1] *
1064+
// this->NodeData[i]->phase_saturation[1] *
10631065
// this->NodeData[i]->phase_density[1];
10641066
// mass_CO2_water = node_volume *
1065-
//this->NodeData[i]->phase_saturation[0] * concentration_CO2_water *
1067+
// this->NodeData[i]->phase_saturation[0] * concentration_CO2_water *
10661068
// this->Molweight_CO2 * 0.001;
10671069
concentration_CO2_water = this->NodeData[i]->getCO2InLiquid() *
10681070
this->NodeData[i]->getPhaseDensity()[0] /
@@ -1164,7 +1166,7 @@ void CDUMUXData::WriteDataToGeoSys(CRFProcess* m_pcs)
11641166
m_pcs->GetNodeValueIndex("PRESSURE1") + 1; //+1... new time level
11651167
// TF commented out since we want to use the improved PointDuMux class
11661168
// value = this->NodeData[i]->getPhasePressure()[1] -
1167-
//this->NodeData[i]->getPhasePressure()[0];
1169+
// this->NodeData[i]->getPhasePressure()[0];
11681170
value =
11691171
pnt_dumux->getPhasePressure()[1] - pnt_dumux->getPhasePressure()[0];
11701172
m_pcs->SetNodeValue(i, index, value);
@@ -1291,7 +1293,7 @@ void CDUMUXData::WriteDataToGeoSys(CRFProcess* m_pcs)
12911293
// * density_liq[kg/m�] / (Molweight_CO2 [g/mol] * 1e-3 [kg/g]) TF
12921294
// commented out since we want to use the improved PointDuMux class
12931295
// value = this->NodeData[i]->CO2inLiquid *
1294-
//this->NodeData[i]->phase_density[0] / (this->Molweight_CO2 *
1296+
// this->NodeData[i]->phase_density[0] / (this->Molweight_CO2 *
12951297
// 1e-3);
12961298
value = pnt_dumux->getCO2InLiquid() * pnt_dumux->getPhaseDensity()[0] /
12971299
(this->Molweight_CO2 * 1e-3);
@@ -1307,7 +1309,7 @@ void CDUMUXData::WriteDataToGeoSys(CRFProcess* m_pcs)
13071309
// TF commented out since we want to use the improved PointDuMux
13081310
// class
13091311
// cout << "Node: " << i << " Druck: " <<
1310-
//this->NodeData[i]->phase_pressure[1] << " X_CO2: " <<
1312+
// this->NodeData[i]->phase_pressure[1] << " X_CO2: " <<
13111313
// this->NodeData[i]->CO2inLiquid << " Dichte: " <<
13121314
// this->NodeData[i]->phase_density[0] << " C(4): " << value
13131315
//<< "\n";
@@ -1420,7 +1422,8 @@ void CDUMUXData::WriteDataToGeoSys(CRFProcess* m_pcs)
14201422
// position = path.find_last_of("\\");
14211423
// path = path.substr(0,position);
14221424
// temp.str(""); temp.clear(); temp << timestep; tempstring =
1423-
//temp.str(); string aus_file = path + "\\CheckVelocity_" + Phases[k] +
1425+
// temp.str(); string aus_file = path + "\\CheckVelocity_" + Phases[k]
1426+
// +
14241427
//"_" + tempstring + ".csv"; ofstream aus;
14251428
// aus.open(aus_file.data(),ios::out);
14261429
// for (int i = 0; i < vec_string.size(); i++) {
@@ -1655,4 +1658,4 @@ int CDUMUXData::RunDuMux(long Timestep, CRFProcess* m_pcs)
16551658
// ToDO:
16561659
// - Konstruktor nur einmal aufrufen
16571660
// - in st-file: Masse einlesen und mit aktueller Dichte in Volumenstrom
1658-
//umrechnen
1661+
// umrechnen

0 commit comments

Comments
 (0)