SQUASH: various style changes

This commit is contained in:
Kutalmis Bercin 2025-03-13 11:48:22 +00:00 committed by Kutalmış Berçin
parent 060f37e912
commit a879f47980

View File

@ -243,6 +243,8 @@ bool Foam::functionObjects::fieldStatistics::execute()
bool Foam::functionObjects::fieldStatistics::write()
{
Log << type() << " " << name() << " write:" << endl;
// Create an output file per field
if (writeToFile() && !writtenHeader_)
{
@ -298,6 +300,8 @@ bool Foam::functionObjects::fieldStatistics::write()
{
const auto& results = results_(fieldName);
Info<< tab << "Field" << tab << fieldName << nl;
for (const auto& iter : results.csorted())
{
const word& name = iter.key();
@ -309,18 +313,19 @@ bool Foam::functionObjects::fieldStatistics::write()
{
if constexpr (std::is_same_v<std::decay_t<decltype(v)>, scalar>)
{
Info<< name << " " << v;
Info<< tab << name << tab << v << nl;
}
else
{
Info<< name << " ";
for (const auto& val : v) Info<< val << " ";
Info<< tab << name << tab;
for (const auto& val : v) Info<< val << tab;
Info<< nl;
}
Info<< nl;
},
value
);
}
Info<< endl;
}
}