mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Corrected handling of the initial time and header.
This commit is contained in:
@ -211,12 +211,6 @@ Foam::forces::forces
|
|||||||
}
|
}
|
||||||
|
|
||||||
read(dict);
|
read(dict);
|
||||||
|
|
||||||
if (active_)
|
|
||||||
{
|
|
||||||
// Create the forces file if not already created
|
|
||||||
makeFile();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -317,16 +311,18 @@ void Foam::forces::makeFile()
|
|||||||
if (Pstream::master())
|
if (Pstream::master())
|
||||||
{
|
{
|
||||||
fileName forcesDir;
|
fileName forcesDir;
|
||||||
|
word startTimeName =
|
||||||
|
obr_.time().timeName(obr_.time().startTime().value());
|
||||||
|
|
||||||
if (Pstream::parRun())
|
if (Pstream::parRun())
|
||||||
{
|
{
|
||||||
// Put in undecomposed case (Note: gives problems for
|
// Put in undecomposed case (Note: gives problems for
|
||||||
// distributed data running)
|
// distributed data running)
|
||||||
forcesDir =
|
forcesDir = obr_.time().path()/".."/name_/startTimeName;
|
||||||
obr_.time().path()/".."/name_/obr_.time().timeName();
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
forcesDir = obr_.time().path()/name_/obr_.time().timeName();
|
forcesDir = obr_.time().path()/name_/startTimeName;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create directory if does not exist.
|
// Create directory if does not exist.
|
||||||
|
|||||||
Reference in New Issue
Block a user