|
[Sponsors] |
April 17, 2009, 05:27 |
problems with particle ostream and ILList
|
#1 |
Senior Member
Stephan Gerber
Join Date: Mar 2009
Location: Germany
Posts: 118
Rep Power: 17 |
Hi all,
i have a strange problem running my own lagrangian solver in parallel. once particles moves from one processor to the other foam complains like this: [0] Expected a ')' or a '}' while reading ILList<LListBase, T>, found on line 0 an error [0] [0] file: IOstream at line 0. [0] [0] From function Istream::readEndList(const char*) [0] in file db/IOstreams/IOstreams/Istream.C at line 159. so it seems that something is wrong with the stream but i have no clue what exactly went wrong and why. Writing data /reading data and restarting runs works fine so i guess i something to do with the routine Foam::Ostream& Foam:perator<<(Ostream& os, const parcel& p). (which is declared friend to the parcel class and still a member of the parcel class (what is strange for me too)) I hope somebody might help me. Any help would be really appreciated. Thanks in advance! Regards Stephan |
|
April 20, 2009, 06:05 |
|
#2 |
Senior Member
Mattijs Janssens
Join Date: Mar 2009
Posts: 1,419
Rep Power: 26 |
Implement binary IO as well. Look at e.g. solidParticle.
|
|
April 22, 2009, 08:56 |
|
#3 |
Senior Member
Stephan Gerber
Join Date: Mar 2009
Location: Germany
Posts: 118
Rep Power: 17 |
Hi Mattijs,
thanks for the hint - i used dieselFoam as the base version but still having the mentioned problems. actually i can write/read/restart in binary formats too and as shown in dieselFoam i implemented binary io too - but still it failes. does anybody has an idea how to efficiently debug this problem. still thanks to mattijs regards stephan |
|
November 5, 2010, 02:08 |
|
#4 |
Member
edison
Join Date: May 2009
Location: Australia
Posts: 35
Rep Power: 17 |
Hi, stephan
I have an exactly the same problem. How did you fix yours? Waiting to be enlightened . Edison |
|
November 7, 2010, 21:23 |
|
#5 |
Member
edison
Join Date: May 2009
Location: Australia
Posts: 35
Rep Power: 17 |
I fixed my bug it turns out that after I introduced new private member to my particle class I forgot to put them also in the Ostream operator<<. I left it here hopefully it will help anyone who has the same problem.
|
|
September 30, 2011, 13:04 |
|
#6 |
New Member
Ryan Danks
Join Date: Jan 2011
Posts: 20
Rep Power: 15 |
Thanks Edison_Ge!
I made the exact same mistake! I would have stuggled all day if I didn't catch your post. |
|
|
|