|
[Sponsors] |
How do I know wich species has which integer value? |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
March 7, 2010, 07:17 |
How do I know wich species has which integer value?
|
#1 |
Senior Member
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20 |
For the usage of
Code:
C_YI(cell,thread,i) How can I know this?
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!" |
|
March 7, 2010, 11:34 |
|
#2 |
Senior Member
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20 |
May this be the list from the GUI:
Materials / Mixture / Properties: Mixture Species / Edit / Selected Species ? Is there a way to search for a specific species in this list? Just to make sure I got the right one?
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!" |
|
March 8, 2010, 03:34 |
|
#3 | |
Senior Member
Join Date: Feb 2010
Posts: 164
Rep Power: 17 |
Quote:
#include "udf.h" DEFINE_ON_DEMAND(species_list) { int i = -1; char *spe_name; Domain *d=NULL; Material *mix_mat=NULL; d=Get_Domain(1); mix_mat= mixture_material(d); mixture_species_loop_i(mix_mat,i) { spe_name=MIXTURE_SPECIE_NAME(mix_mat,i); Message0("species index=%d,species name=%s\n",i,spe_name); } } |
||
March 8, 2010, 07:09 |
|
#4 | |
Senior Member
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20 |
Quote:
Thank you!
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!" |
||
March 8, 2010, 09:25 |
how i can open the gambit file in fluent please tell me the saving file name ,
|
#5 |
New Member
sunny rajpal
Join Date: Nov 2009
Posts: 1
Rep Power: 0 |
i have 6.3 fluent edison
|
|
March 8, 2010, 09:30 |
|
#6 |
Senior Member
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20 |
How is this related to the topic?
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!" |
|
October 9, 2010, 17:58 |
|
#7 | |
Member
Roman Gobitz-Pfeifer
Join Date: Dec 2009
Location: Stuttgart
Posts: 83
Rep Power: 17 |
Hi,
I also have to know the numbers for the species, but I don't know how to run this code :-( Can anybody explain how I get this information out of this code? I also tried to copy the code and paste it into the console. I also tried to compile this code, but I don't know how to start it. cheers wikie Quote:
Last edited by Wikie; October 9, 2010 at 18:36. |
||
October 10, 2010, 10:01 |
|
#8 | |
Senior Member
Sebastian Gatzka
Join Date: Mar 2009
Location: Frankfurt, Germany
Posts: 729
Rep Power: 20 |
Quote:
2. Save the code as *.c file. 3. In FLUENT go to menu: Define > User-Defined > Functions > Compiled ... 4. Add the c-File (Source File) 5. Click Load 6. FLUENT menu: Define > User-Defined > Execute on demand 7. Choose the function 8. Output appears. Done!
__________________
Schrödingers wife: "What did you do to the cat? It's half dead!" |
||
October 10, 2010, 10:20 |
|
#9 |
Member
Roman Gobitz-Pfeifer
Join Date: Dec 2009
Location: Stuttgart
Posts: 83
Rep Power: 17 |
Hi Sega,
thanks a lot. I've already done nr. 1-5, but didn't know how to execute this file. Now it's working fine. Thanks wikie |
|
April 15, 2013, 11:50 |
|
#10 | |
Member
Join Date: Jul 2012
Posts: 48
Rep Power: 14 |
Quote:
thanks a lot That was so helpful to me! saved so much of my time! Btw fluent manual (12.0 version) doesn't list anything about this macros right?? Plz correct me if i'm wrong! where u got the info on using these macros???? |
||
April 15, 2013, 11:59 |
|
#11 |
Member
Join Date: Jul 2012
Posts: 48
Rep Power: 14 |
Hey I found another simple way to access the species index using macro - SV_SpeciesIndex("species_name")
species_name should exactly be the name we see in the Models-> Species transport panel! Refer the following code for example : Code:
#include "udf.h" DEFINE_ON_DEMAND(M_species_list) { int i; i = SV_SpeciesIndex("h2o"); Message("species index=%d,species name=h2o\n",i); } |
|
April 17, 2013, 05:40 |
|
#12 | |
Senior Member
Join Date: Feb 2010
Posts: 164
Rep Power: 17 |
Great job!
Quote:
|
||
September 11, 2017, 09:32 |
|
#13 |
New Member
Hirakjyoti Barman
Join Date: Sep 2017
Posts: 7
Rep Power: 9 |
After loading in fluent it is showing
M_species_list: 0 .local.varargs 0 .local.end 0 save .local.int i (r1) 1 push.int 0 3 save 4 push.string [5] Licl 7 call SV_SpeciesIndex (-1) 9 sto.int i (r1) 11 pop.int 12 save 13 push.string [36] species index=%d,species name=Licl 20 ld.int i (r1) 22 call CX_Message (-1) 24 pop.int 25 restore 26 ret.v How can i know wht is the i for licl. plz hlp |
|
May 19, 2020, 14:25 |
|
#14 | |
New Member
Vidushi
Join Date: Sep 2018
Location: Cape Town
Posts: 20
Rep Power: 8 |
Quote:
|
||
May 20, 2020, 01:34 |
|
#15 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
how did you run the code?
__________________
best regards ****************************** press LIKE if this message was helpful |
|
May 20, 2024, 12:13 |
|
#16 | |
New Member
Mohammad
Join Date: May 2024
Posts: 7
Rep Power: 2 |
Quote:
|
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to specify surface flux of a species? | ked | FLUENT | 18 | February 15, 2022 16:03 |
Modelling Biomass Combustion via Species Transport | Racheal | FLUENT | 39 | January 8, 2022 08:42 |
PB: Saving mass fraction of species on two points with an udf | biget.a | FLUENT | 2 | July 23, 2009 04:06 |
Species order fluent | Raddi | FLUENT | 1 | March 13, 2009 01:21 |
mass fraction of species | Ahmed | FLUENT | 0 | April 18, 2007 12:57 |