mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: CSV data entry - corrected writing - mantis #971
This commit is contained in:
@ -50,10 +50,7 @@ Foam::Ostream& Foam::operator<<
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Check state of Ostream
|
// Check state of Ostream
|
||||||
os.check
|
os.check("Ostream& operator<<(Ostream&, const CSV<Type>&)");
|
||||||
(
|
|
||||||
"Ostream& operator<<(Ostream&, const CSV<Type>&)"
|
|
||||||
);
|
|
||||||
|
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
@ -83,11 +80,15 @@ void Foam::CSV<Type>::writeData(Ostream& os) const
|
|||||||
os << componentColumns_;
|
os << componentColumns_;
|
||||||
os.format(IOstream::BINARY);
|
os.format(IOstream::BINARY);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
os << componentColumns_;
|
||||||
|
}
|
||||||
os << token::END_STATEMENT << nl;
|
os << token::END_STATEMENT << nl;
|
||||||
|
|
||||||
os.writeKeyword("separator") << string(separator_)
|
os.writeKeyword("separator") << string(separator_)
|
||||||
<< token::END_STATEMENT << nl;
|
<< token::END_STATEMENT << nl;
|
||||||
os.writeKeyword("mergeSeparators") << string(mergeSeparators_)
|
os.writeKeyword("mergeSeparators") << mergeSeparators_
|
||||||
<< token::END_STATEMENT << nl;
|
<< token::END_STATEMENT << nl;
|
||||||
os.writeKeyword("fileName") << fName_ << token::END_STATEMENT << nl;
|
os.writeKeyword("fileName") << fName_ << token::END_STATEMENT << nl;
|
||||||
os << decrIndent << indent << token::END_BLOCK << endl;
|
os << decrIndent << indent << token::END_BLOCK << endl;
|
||||||
|
|||||||
@ -22,8 +22,17 @@ boundaryField
|
|||||||
{
|
{
|
||||||
movingWall
|
movingWall
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type uniformFixedValue;
|
||||||
value uniform (1 0 0);
|
uniformValue csvFile;
|
||||||
|
csvFileCoeffs
|
||||||
|
{
|
||||||
|
nHeaderLine 1;
|
||||||
|
refColumn 0;
|
||||||
|
componentColumns (1 2 3);
|
||||||
|
mergeSeparators no;
|
||||||
|
fileName "$FOAM_CASE/csvData";
|
||||||
|
separator " ";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fixedWalls
|
fixedWalls
|
||||||
|
|||||||
Reference in New Issue
Block a user