CFD Online Discussion Forums

CFD Online Discussion Forums (
-   Siemens (
-   -   Cell numbering convention (

Hassaneen August 6, 2000 05:47

Cell numbering convention
Does any one know how to let STAR-CD number cells in X-direction instead of Y-direction (1,2,3, X-D) Thanks

Tara August 6, 2000 15:47

Re: Cell numbering convention
Hi Hassaneen,

You can you the CDIR command to change the numbering scheme in terms of a local mesh direction. (page 3-18 of the User Guide). Once this is defined, you can use the RESTRUCTURE command to reorder the vertices of a given cell set.

Hassaneen August 7, 2000 04:23

Re: Cell numbering convention
Please be more clear because that manual is not. How could I excute that command CDIR. Thanks =Ahmed=

Stephan Meyer August 7, 2000 07:49

Re: Cell numbering convention
Hello, Ahmed,

try HELP CDIR in the prostar command prompt.


Hassaneen August 7, 2000 11:50

Re: Cell numbering convention
Stephan, this code will drive me crazy. I couldn't do it even with HELP CDIR. Do you have any suggestion. Thanks =Ahmed=

Hassaneen August 7, 2000 12:36

Re: Cell numbering convention
Stephan, just now I changed the numbering of the Vertices but the Cells don't change accordingly.??

Stephan Meyer August 9, 2000 02:45

Re: Cell numbering convention
Hello, Ahmed,

You're right. I didn't manage to change the cell numbering, too. This is what I tried:











This actually renumbers the cells, but not exactly like I wanted to. It looks a bit like rubik's cube. The first ten cells are in the lowest (seen in y-direction) row, but not numbered in x-direction. The commands



only renumber the vertices.

What You can do is write the cells and vertices to ascii-files and sort them with another program (e.g. write one Yourself in fortran or any other programming language). You need to do the following steps for this:

1.) write the vertices to a file:


see HELP VWRITE for the format of the file

2.) write the cells to a file:


again see HELP CWRITE for the format of the file

3.) get the centroid coordinates of each cell from the two files You have written out

4.) sort them

5.) change the cell number in the cell file (e.g. in star.cel)

6.) read the cells back into prostar:


since You haven't changed the vertices, it's not necessary to do anything with them.

I hope this helps. Maybe anyone else on this forum has a better idea???


Hassaneen August 9, 2000 04:13

Re: Cell numbering convention
Stephan, my friend: Some how I have got the cells numbered in the way I want. That was achieved by using the tut.cel and tut.vrt from their tutorial (tut13.1). They are using the same tech. you are explaining. Have you got any experience with moving grids in Piston engine simulation Stephan?? if yes, I have a question for you. Thanks =Ahmed=

Stephan Meyer August 10, 2000 12:26

Re: Cell numbering convention
Hi, Ahmed

I've done some simulations with moving grids, but not especially for pistons engines. Anyway, just ask Your question, I'll try to help, if I can.


Hassaneen August 11, 2000 02:40

Re: Cell numbering convention
Dear Stephan, Thanks a lot for your help in changing the numbering order for the vertices. For the moving grid, I got my problem working now after a huge effort. Thank you again, I appreciate. Regards =Ahmed=

Hassaneen August 14, 2000 03:36

Re: Cell numbering convention
Dear Stephan, By chance I've got the cells numbered the way we need it. That happen when I was trying to create a 2-D shell and then create a 3-D mesh from it. The code already numbered the cells in the X-direction. =Ahmed=

All times are GMT -4. The time now is 03:34.