CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   handling polyMesh/cells file (http://www.cfd-online.com/Forums/openfoam/93307-handling-polymesh-cells-file.html)

alessandro.zomparelli October 11, 2011 11:07

handling polyMesh/cells file
 
Hi to all!
I'm trying to export a geometry from "processing" to "OpenFOAM". I wrote the following files based on my cell-mesh configuration: "points", "boundary", "faces", "owner" and "neighbour". The resulting mesh gives error in some cases or return to me a tangled mesh in paraFoam with only tri and quad faces.
Thinking that the problem was due to the fact that my cells are polyhedral I decided to try with a "cells" file instead of "owner" and "neighbour". (Is it right?)
My problem is now: how to write a "cells" file?
I tried something like this:

Quote:

FoamFile
{
version 2.0;
format ascii;
class cellList;
location "constant/polyMesh";
object cells;
}

437
(
7(0 1 2 3 4 5 6) //0
9(7 8 9 10 11 12 13 14 15) //1
9(16 17 18 19 20 21 22 23 24) //2
11(25 26 27 28 29 30 31 32 33 34 35) //3
9(36 37 38 39 40 41 42 43 44) //4

...

8(715 716 717 718 719 720 721 722) //65
6(723 724 725 726 727 728) //66
11(729 730 731 732 733 734 735 736 737 738 739) //67
9(740 741 742 743 744 745 746 747 748) //68
7(749 750 751 752 753 754 755) //69
)
and after calling paraFoam it returns to me the error:

Quote:

--> FOAM FATAL IO ERROR:
incorrect first token, expected '(', found on line 82 the punctuation token ')'

file: /home/alessandro/.processing/sketchbook/ProcessingToOpenFOAM_01/OpenFoam/constant/polyMesh/cells at line 82.

From function operator>>(Istream&, List<T>&)
in file lnInclude/ListIO.C at line 132.

FOAM exiting
someone can help me?
thanks :)
Alessandro

alessandro.zomparelli October 11, 2011 11:29

ops, I found the error, the number of cells was wrong at the beginning of list :p

but now it gives to me a different error. After launching paraFoam, when i click on the eye-icon of my mesh the program crash. This is the output from terminal:

Quote:

*** glibc detected *** /opt/paraviewopenfoam3101/lib/paraview-3.10/paraview: malloc(): memory corruption: 0x0000000001f5a920 ***
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x79d7a)[0x7f5340061d7a]
/lib/x86_64-linux-gnu/libc.so.6(__libc_malloc+0x6e)[0x7f534006431e]
/usr/lib/x86_64-linux-gnu/libstdc++.so.6(_Znwm+0x1d)[0x7f534064be0d]
/usr/lib/x86_64-linux-gnu/libstdc++.so.6(_Znam+0x9)[0x7f534064bf29]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/libOpenFOAM.so(_ZN4Foam4ListIiE7setSizeEi+0x35)[0x7f532e23b925]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/libOpenFOAM.so(_ZN4Foam8polyMesh8initMeshERNS_4Lis tINS_4cellEEE+0x1cc)[0x7f532e400a6c]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/libOpenFOAM.so(_ZN4Foam8polyMeshC2ERKNS_8IOobjectE +0x105e)[0x7f532e3ee0de]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/libfiniteVolume.so(_ZN4Foam6fvMeshC1ERKNS_8IOobjec tE+0x19)[0x7f532b61e5f9]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/libvtkPV3Foam.so(_ZN4Foam10vtkPV3Foam14updateFoamM eshEv+0xdd)[0x7f532ab89ecd]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/libvtkPV3Foam.so(_ZN4Foam10vtkPV3Foam6UpdateEP20vt kMultiBlockDataSetS2_+0x73)[0x7f532ab8a1d3]
/opt/openfoam201/platforms/linux64GccDPOpt/lib/paraview-3.10/libPV3FoamReader_SM.so(_ZN16vtkPV3FoamReader11Requ estDataEP14vtkInformationPP20vtkInformationVectorS 3_+0x6b1)[0x7f532ae57e51]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN12vtkExecutive13CallA lgorithmEP14vtkInformationiPP20vtkInformationVecto rS3_+0x54)[0x7f5341b65424]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN23vtkDemandDrivenPipe line11ExecuteDataEP14vtkInformationPP20vtkInformat ionVectorS3_+0x4c)[0x7f5341b580fc]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN24vtkCompositeDataPip eline11ExecuteDataEP14vtkInformationPP20vtkInforma tionVectorS3_+0xd1)[0x7f5341b35951]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN23vtkDemandDrivenPipe line14ProcessRequestEP14vtkInformationPP20vtkInfor mationVectorS3_+0x21b)[0x7f5341b5b20b]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN32vtkStreamingDemandD rivenPipeline14ProcessRequestEP14vtkInformationPP2 0vtkInformationVectorS3_+0xb1)[0x7f5341ce2321]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN24vtkCompositeDataPip eline14ProcessRequestEP14vtkInformationPP20vtkInfo rmationVectorS3_+0x1f1)[0x7f5341b32781]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN24vtkCompositeDataPip eline15ForwardUpstreamEP14vtkInformation+0x266)[0x7f5341b33a76]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN23vtkDemandDrivenPipe line14ProcessRequestEP14vtkInformationPP20vtkInfor mationVectorS3_+0x1c5)[0x7f5341b5b1b5]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN32vtkStreamingDemandD rivenPipeline14ProcessRequestEP14vtkInformationPP2 0vtkInformationVectorS3_+0xb1)[0x7f5341ce2321]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN24vtkCompositeDataPip eline14ProcessRequestEP14vtkInformationPP20vtkInfo rmationVectorS3_+0x1f1)[0x7f5341b32781]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN23vtkDemandDrivenPipe line10UpdateDataEi+0x1df)[0x7f5341b5af4f]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFiltering.so.pv3.10(_ZN32vtkStreamingDemandD rivenPipeline6UpdateEi+0x8b)[0x7f5341ce150b]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFilteringCS.so(_Z19vtkAlgorithmCommandP26vtk ClientServerInterpreterP13vtkObjectBasePKcRK21vtkC lientServerStreamRS5_+0x1766)[0x7f534468d8e6]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkFilteringCS.so(_Z29vtkDataObjectAlgorithmCom mandP26vtkClientServerInterpreterP13vtkObjectBaseP KcRK21vtkClientServerStreamRS5_+0x226)[0x7f53446a5e36]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVFiltersCS.so(_Z22vtkPVPostFilterCommandP26 vtkClientServerInterpreterP13vtkObjectBasePKcRK21v tkClientServerStreamRS5_+0x1ae)[0x7f534daa477e]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkClientServer.so(_ZN26vtkClientServerInterpre ter20ProcessCommandInvokeERK21vtkClientServerStrea mi+0x16f)[0x7f534417706f]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkClientServer.so(_ZN26vtkClientServerInterpre ter17ProcessOneMessageERK21vtkClientServerStreami+ 0x30e)[0x7f53441783ee]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkClientServer.so(_ZN26vtkClientServerInterpre ter13ProcessStreamERK21vtkClientServerStream+0x1d)[0x7f534417850d]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerCommon.so(_ZN17vtkSelfConnection20Pr ocessStreamLocallyER21vtkClientServerStream+0x20)[0x7f5349af3ad0]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerCommon.so(_ZN26vtkProcessModuleConne ction10SendStreamEjR21vtkClientServerStream+0x61)[0x7f5349a8c2e1]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerCommon.so(_ZN33vtkProcessModuleConne ctionManager10SendStreamExjR21vtkClientServerStrea mi+0x36)[0x7f5349a8f0f6]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerCommon.so(_ZN16vtkProcessModule10Sen dStreamExjR21vtkClientServerStreami+0x6b)[0x7f5349a9756b]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerManager.so(_ZN15vtkSMOutputPort22Upd atePipelineInternalEdb+0x29a)[0x7f534de2dbba]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerManager.so(_ZN16vtkSMSourceProxy14Up datePipelineEd+0x4b)[0x7f534de9832b]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libvtkPVServerManager.so(_ZN20vtkSMRenderViewProxy 27CreateDefaultRepresentationEP10vtkSMProxyi+0x94)[0x7f534de854a4]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqCore.so(_ZN15pqObjectBuilder24createDataRepre sentationEP12pqOutputPortP6pqViewRK7QString+0x5c4)[0x7f534ed61d04]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqCore.so(_ZNK15pqDisplayPolicy17newRepresentat ionEP12pqOutputPortP6pqView+0x61)[0x7f534ed29df1]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqCore.so(_ZNK15pqDisplayPolicy27setRepresentat ionVisibilityEP12pqOutputPortP6pqViewb+0xc1)[0x7f534ed29f11]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqComponents.so(_ZN23pqPipelineBrowserWidget13s etVisibilityEbRK5QListI11QModelIndexE+0x2b6)[0x7f534f2c4f56]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqComponents.so(_ZN23pqPipelineBrowserWidget18h andleIndexClickedERK11QModelIndex+0x1c7)[0x7f534f2c55f7]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqComponents.so(_ZN23pqPipelineBrowserWidget11q t_metacallEN11QMetaObject4CallEiPPv+0x79)[0x7f534f3893f9]
/usr/lib/libQtCore.so.4(_ZN11QMetaObject8activateEP7QObject PKS_iPPv+0x278)[0x7f534a0e85f8]
/opt/paraviewopenfoam3101/lib/paraview-3.10/libpqWidgets.so(_ZN14pqFlatTreeView7clickedERK11QM odelIndex/usr/lib/libQtCore.so.4(_ZN16QCoreApplication4execEv+0xab)[0x7f534a0d6ecb]
======= Memory map: ========
00400000-0096b000 r-xp 00000000 08:08 1991073 /opt/paraviewopenfoam3101/lib/paraview-3.10/paraview
00b6a000-00b6b000 r--p 0056a000 08:08 1991073 /opt/paraviewopenfoam3101/lib/paraview-3.10/paraview
00b6b000-00b6c000 rw-p 0056b000 08:08 1991073 /opt/paraviewopenfoam3101/lib/paraview-3.10/paraview
00e06000-01f88000 rw-p 00000000 00:00 0 [heap]
405bd000-40642000 rw-p 00000000 00:05 6079 /dev/zero
41430000-41432000 rwxp 00000000 00:05 6079 /dev/zero
7f532a183000-7f532a18c000 r-xp 00000000 08:08 546402 /usr/lib/qt4/plugins/iconengines/libqsvgicon.so
7f532a18c000-7f532a38b000 ---p 00009000 08:08 546402 /usr/lib/qt4/plugins/iconengines/libqsvgicon.so
7f532a38b000-7f532a38c000 r--p 00008000 08:08 546402 /usr/lib/qt4/plugins/iconengines/libqsvgicon.so
7f532a38c000-7f532a38d000 rw-p 00009000 08:08 546402 /usr/lib/qt4/plugins/iconengines/libqsvgicon.so
7f532a38d000-7f532a58d000 rw-s 6a6dc000 00:05 8510 /dev/nvidia0
7f532a58d000-7f532a68d000 rw-s 214bf000 00:05 8510 /dev/nvidia0
7f532a68d000-7f532a6a8000 r-xp 00000000 08:08 1984692 /opt/openfoam201/platforms/linux64GccDPOpt/lib/liblagrangian.so
7f532a6a8000-7f532a8a8000 ---p 0001b000 08:08 1984692 /opt/openfoam201/platforms/linux64GccDPOpt/lib/liblagrangian.so
7f532a8a8000-7f532a8a9000 r--p 0001b000 08:08 1984692 /opt/openfoam201/platforms/linux64GccDPOpt/lib/liblagrangian.so
7f532a8a9000-7f532a8aa000 rw-p 0001c000 08:08 1984692 /opt/openfoam201/platforms/linux64GccDPOpt/lib/liblagrangian.so
7f532a8aa000-7f532a94a000 r-xp 00000000 08:08 1984672 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libgenericPatchFields.so
7f532a94a000-7f532ab49000 ---p 000a0000 08:08 1984672 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libgenericPatchFields.so
7f532ab49000-7f532ab4d000 r--p 0009f000 08:08 1984672 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libgenericPatchFields.so
7f532ab4d000-7f532ab4e000 rw-p 000a3000 08:08 1984672 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libgenericPatchFields.so
7f532ab4e000-7f532ac3d000 r-xp 00000000 08:08 1984662 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libvtkPV3Foam.so
7f532ac3d000-7f532ae3c000 ---p 000ef000 08:08 1984662 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libvtkPV3Foam.so
7f532ae3c000-7f532ae40000 r--p 000ee000 08:08 1984662 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libvtkPV3Foam.so
7f532ae40000-7f532ae42000 rw-p 000f2000 08:08 1984662 /opt/openfoam201/platforms/linux64GccDPOpt/lib/libvtkPV3Foam.so
7f532ae42000-7f532ae43000 rw-p 00000000 00:00 0
7f532ae43000-7f532ae6a000 r-xp 00000000 08:08 1984661 /opt/openfoam201/platforms/linux64GccDPOpt/lib/paraview-3.10/libPV3FoamReader_SM.so
7f532ae6a000-7f532b069000 ---p 00027000 08:08 1984661 /opt/openfoam201/platforms/linux64GccDPOpt/lib/paraview-3.10/libPV3FoamReader_SM.so
7f532b069000-7f532b06b000 r--p 00026000 08:08 1984661 /opt/openfoam201/platforms/linux64GccDPOpt/lib/paraview-3.10/libPV3FoamReader_SM.soAborted

there is something wrong in my process? I'm new of paraFoam, isn't it sufficient to write files of the "constant/polyMesh" folder? I also copied from a tutorial case "0", "constant" and "system" folder changing (when necessary) names of boundaries in some files.


All times are GMT -4. The time now is 06:47.