How to define nodes for a certain cell ?

 Register Blogs Members List Search Today's Posts Mark Forums Read

 October 25, 2000, 11:00 How to define nodes for a certain cell ? #1 mikhail Guest   Posts: n/a Hi ! While looping over cells in a thread I need to define coordinates of all cell nodes to provide the next calculations.All I want to do might be done by using functions NODE_X(node), NODE_Y(node), NODE_Z(node),NODE_GX(node),NODE_GY(node),NODE_GZ(n ode), but how can I get this "node" parameter for a certain cell ? Your reply would be very convenient... Best wishes. Mikhail

 October 29, 2000, 22:52 Re: How to define nodes for a certain cell ? #2 minun Guest   Posts: n/a do you want a kind of following ones? DEFINE_ADJUST(test_coord,domain) { cell_t c; Thread *t; Node *v; int n; real xn,yn; thread_loop_c(t, domain){ begin_c_loop(c, t){ Message("cell %d (%d) : ",c,C_NNODES(c,t)); c_node_loop(c, t, n){ v = C_NODE(c, t, n); xn = NODE_X(v); yn = NODE_Y(v); Message(" %d(%g,%g)",n,xn,yn); } Message("\n"); } end_c_loop(c,t) } }

 November 8, 2000, 21:59 Re: How to define nodes for a certain cell ? #3 Harry Guest   Posts: n/a Hi Minun, I've try to run your program, but it doesn't work. The error seem when reach the "Message("cell %d (%d) : ",c,C_NNODES(c,t));" line with the error message (unsigned char error). Is it true??, and how to fix it?

 November 12, 2000, 21:51 Re: How to define nodes for a certain cell ? #4 minun Guest   Posts: n/a If you compile the source with 'compiled udf', it should work well. I guess you compiled it with 'interpreted udf'. Change that line to 'printf("cell %d (%d) : ",c,cell_type_nnodes[(int)C_TYPE(c,t)]); You can find following message posted by Chris in this forum. ================================================== =============== That is a bug. It should work OK as is for compiled UDFs. To make it work in the interpreted UDFs, change the line: num = C_NNODES(c,thread); to read: num = cell_type_nnodes[(int)C_TYPE(c,thread)]; Chris

 November 17, 2000, 02:42 Re: How to define nodes for a certain cell ? #5 Harry Guest   Posts: n/a Thank you very much, and i'll try it

 Thread Tools Display Modes Linear Mode

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post bigbang OpenFOAM Meshing & Mesh Conversion 6 March 18, 2016 18:42 Taylorreihe OpenFOAM Post-Processing 4 February 19, 2016 13:46 Travis FLUENT 4 January 15, 2009 12:48 Fan Main CFD Forum 10 September 9, 2006 12:24 Greg Perkins FLUENT 0 October 11, 2000 03:43

All times are GMT -4. The time now is 09:10.