|
[Sponsors] |
material name of emissivity for a face thread |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
September 3, 2003, 03:24 |
material name of emissivity for a face thread
|
#1 |
Guest
Posts: n/a
|
Hello everybody and greetings from cold Finland
I would appricate if someone could help me to access either the material name or the emissivity of a wall thread within a UDF. Other solutions to distinguish beteween different wall boundaries are also welcome. thank you in advance Nici |
|
September 3, 2003, 04:45 |
Re: material name of emissivity for a face thread
|
#2 |
Guest
Posts: n/a
|
below find some code I use to distinguish whether a thread is in a list of thread ids. It may not be super efficient but it works OK. Pass in an array of integers which have the ids - same as IDs in the boundary condition panel within the GUI. If the *thread is one of these then it returns the id else it returns NOT_WALL which you can define however.
For FLUENT 6 make sure you #define FLUENT_6 or if you only use 6.x remove the conditional compile from these lines. Hope this is something like what you need. Greg /* --------------------------------------------------------------------------- IS THREAD -------------------------------------------------------------------------- */ int is_thread_cm(Thread *thread, int no_threads, int thread_list[]) { #ifdef FLUENT_6 Domain *domain = Get_Domain(1); #endif int i=0; while ((i<no_threads) && (Lookup_Thread(domain,thread_list[i])!=thread)) i++; if (Lookup_Thread(domain,thread_list[i])==thread) return i; else return NOT_WALL; } |
|
September 3, 2003, 04:46 |
Re: material name of emissivity for a face thread
|
#3 |
Guest
Posts: n/a
|
/* ---------------------------------------------------------------------------
IS THREAD -------------------------------------------------------------------------- */ int is_thread_cm(Thread *thread, int no_threads, int thread_list[]) { #ifdef FLUENT_6 Domain *domain = Get_Domain(1); #endif int i=0; while ((i<no_threads)&&(Lookup_Thread(domain,thread_list[i])!=thread)) i++; if (Lookup_Thread(domain,thread_list[i])==thread) return i; else return NOT_WALL; } |
|
September 3, 2003, 04:47 |
Re: material name of emissivity for a face thread
|
#4 |
Guest
Posts: n/a
|
/* ---------------------------------------------------------------------------
IS THREAD -------------------------------------------------------------------------- */ int is_thread_cm(Thread *thread, int no_threads, int thread_list[]) { #ifdef FLUENT_6 Domain *domain = Get_Domain(1); #endif int i=0; while ((i_<_no_threads)&&(Lookup_Thread(domain,thread_li st[i])!=thread)) i++; if (Lookup_Thread(domain,thread_list[i])==thread) return i; else return NOT_WALL; } |
|
September 3, 2003, 04:48 |
Re: material name of emissivity for a face thread
|
#5 |
Guest
Posts: n/a
|
Sorry had some trouble posting....this last one is the right code except in the while it should be while i lessthan no_threads (in C of course)
|
|
September 3, 2003, 07:02 |
Re: material name of emissivity for a face thread
|
#6 |
Guest
Posts: n/a
|
Hej Greg,
I solved the problem on my own even though it took a while! I found in the src.h macro appropriate for my purpouse if (strcmp( THREAD_MATERIAL(f_t), char_bed) == 0) where char_bed is defined as char *char_bed = "ash" All the other walls are steel so now I can distinguish between the char bed "wall" and steel "wall"! Thank you again for your interest, cheers Nici |
|
September 3, 2003, 13:21 |
how to add the second gradient of UDS
|
#7 |
Guest
Posts: n/a
|
Hi,everybody How to add the second gradient of UDS(user defined scalar) into species equation as source terms. Thanks. I only find the macro in fluent to calculate the first gradient. By the way, is there any way to get the arrangment or distribution of cells in fluent? Thanks.
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Netgen] Import netgen mesh to OpenFOAM | hsieh | OpenFOAM Meshing & Mesh Conversion | 32 | September 13, 2011 06:50 |
Constant velocity of the material | Sas | CFX | 15 | July 13, 2010 09:56 |
[blockMesh] BlockMeshmergePatchPairs | hjasak | OpenFOAM Meshing & Mesh Conversion | 11 | August 15, 2008 08:36 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 12:55 |
[blockMesh] Axisymmetrical mesh | Rasmus Gjesing (Gjesing) | OpenFOAM Meshing & Mesh Conversion | 10 | April 2, 2007 15:00 |