DecomposePar 的问题
-
同样的case,serial就可以跑,但是decomposePar以后就会提示读取文件错误,请问有没有类似经验的。。
该文件内容如下~[1] --> FOAM FATAL ERROR: [1] cannot find file "/home/maosui/OpenFOAM/xxxx/processor1/constant/zPDF_Distribution_Ring1" [1] [1] From function virtual Foam::autoPtr<Foam::ISstream> Foam::fileOperations::uncollatedFileOperation::readStream(Foam::regIOobject&, const Foam::fileName&, const Foam::word&, bool) const [1] in file global/fileOperations/uncollatedFileOperation/uncollatedFileOperation.C at line 538. [1] FOAM parallel run exiting [1]
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 8.0 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; location "constant"; object scalarListList; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // ( 0.00000220 0.00000100 0.03776709 11.90000000 0 0.65000000 0 0.00000439 0.00000055 0.19366611 11.90000000 0 0.60200000 0 0.00000659 0.00000055 0.40863111 11.90000000 0 0.56800000 0 0.00000878 0.00000055 0.59395333 12.00000000 0 0.59600000 0 0.00001100 0.00000055 0.71230484 12.10000000 0 0.54400000 0
-
@星星星星晴 在 DecomposePar 的问题 中说:
uncollated
既然你提到了 uncollated,那么猜测你的算例应该是用了 collated 模式,但是有些文件却使用的 uncollated 的方式读取。
如果是这个问题,解决办法可以参考:
https://github.com/ZhangYanTJU/boundaryConditions/blob/master/LEMOSinflowGeneratorMod/decayingTurbulenceFvPatchVectorField.C#L140 -
@浪迹天大 谢谢,我研究一下,这个file 我就是读了一下文件名字,然后放到IOobject里,原来在of4就完全没问题
positionsFile_(this->coeffDict().lookup("positionsFile")), positions_ ( IOobject ( positionsFile_, owner.db().time().constant(), owner.mesh(), IOobject::MUST_READ, IOobject::NO_WRITE ) ), PDFFileName_(this->coeffDict().lookup("PDFFile")), PDFsamples_ ( IOobject ( PDFFileName_, owner.db().time().constant(), owner.db(), IOobject::MUST_READ, IOobject::NO_WRITE ) ),