Problem with bin_particles_in_cells command
Hi,
I see that the command "bin_particles_in_cells(domain)" is giving me error in Fluent 12 version, saying "Too few arguments". Looks like it needs one more argument, and of int type. The command used to work fine in Fluent 6 with just the 'domain' argument. If anyone has any idea of the updated usage, I would be grateful. Thanks Mayank |
experiencing the same problem
I have been using User Defined Function: bin_particles_in_cells(d).
This function worked with Fluent 6.3.26 but it does not work anymore with ANSYS FLUENT. Does anyone know how to go around this problem? Thanks, DR |
Hi,
did anybody solve this problem?? I also want to use the command "bin_particles_in_cells(domain)". I'm using version 12.1. The error message is "Too few arguments". Can anybody help me please I stuck here!! Thanks, Wikie |
Hi,
I found the function bin_particles_in_cells in the cl_dpm.h file. "FLUENT_EXPORT void bin_particles_in_cells(Domain *domain, cxboolean init_cells);" So this function needs another argument init_cells of cxboolean type. Right now I dont't know how to handle this. Does anybody else what is meant by init_cells?? Cheers, Wikie |
Hi every body,
I am using a UDF containing bin_particles_in_cell and I need to know that what this macro does. I will be grateful if someone can answer it. Cheers |
Hi Wikie,
Do you have any idea about the argument "cxboolean init_cells"? I've tried some value(0,1,FALSE,TRUE) for the argument. There is no error and the case can run. BUT the results are obviously wrong. There is NO particle is tracked in the domain. Thanks a lot. |
hi
does anybody here solved the problem about : cxboolean init_cells? :confused::confused::confused: i am using Fluent v 15.0 |
Hello guys,
I have just solved this issue. Cxboolean type is just T/F data type and init_cells is something I suppose we have to do like, initialize particles in cells. So try your cases with: So you can just try Bin_particles_in_cells(domain, TRUE) Thanks and good luck. Regards: MAC |
Simple UDF for looping on all particles in each cell.
Since Fluent 12, the implementation of bin_particles_in_cells(domain, count) has changed and you need additional macro (unthread_particles_to_all_inj(domain, check)). Please be aware that this additional macro had only one argument at least until Fluent version 14. Since Fluent 17 it needs 2 arguments (domain and check (which is a boolean variable)).
Here is a simple UDF for looping on all particles in each cell. DEFINE_ADJUST(Looping, domain) { cxboolean count; cxboolean check; Thread *t; cell_t c; Particle *p; Alloc_Storage_Vars(domain, SV_DPM_PARTICLE_BIN, SV_NULL); bin_particles_in_cells(domain, count); thread_loop_c (t,domain) { begin_c_loop(c, t) { begin_particle_cell_loop(p,c,t) { /* you can do your calculation on particles in one cell here*/ } end_particle_cell_loop(p, c, t) } end_c_loop(c, t) unthread_particles_to_all_inj(domain, check); Free_Storage_Vars(domain, SV_DPM_PARTICLE_BIN, SV_NULL); /* release allocated memory*/ } } |
Quote:
|
Quote:
|
All times are GMT -4. The time now is 00:02. |