|
[Sponsors] |
January 11, 2018, 04:10 |
Error: The fl process could not be started
|
#1 |
New Member
mohsen
Join Date: Jan 2018
Posts: 6
Rep Power: 8 |
Hi ٍeveryone,
i'm going to simulate grains of solid rocket engine with udf. i use DEFINE_PROFILE and DEFINE_CG MOTION macros to link moving boundary to pressure.... my udf's code As follows: #include "udf.h" #include "sg.h" DEFINE_PROFILE(mflux,t,i) { int m = 0; face_t f; double a,nn,y1,y2; double PRESSURE,PRESSURE2,press,rdot; double x[ND_ND]; a=0.001499; nn=0.4255; PRESSURE=0; begin_f_loop(f,t) { PRESSURE += F_P(f,t); m = m + 1; } end_f_loop(f,t) printf("sum P on boundary: %d = %f pas\n", PRESSURE); PRESSURE2 = PRESSURE/m; printf("average P on boundary: %d = %f pas\n", PRESSURE2); press = (PRESSURE2)*1e-6; rdot = (a * pow(press,nn)); begin_f_loop(f,t) { F_CENTROID(x,f,t); y2=x[1]; if (y2<=0.05) F_PROFILE(f,t,i) = 1605.*rdot + 1e-6; /* 1605=density*/ else F_PROFILE(f,t,i) = 1e-6; } end_f_loop(f,t) printf("burning rate: %f\n", rdot); } DEFINE_GRID_MOTION(moving_inlet,d,dt,time,dtime) { Thread *tf = DT_THREAD(dt); face_t f; Node *v; real NV_VEC(disp); real y,x,dis,dis_y,dis_x; double PRESSURE,PRESSURE2,press,rdot; int n,ig; int m = 0; real a=0.001499; real nn=0.4255; real k[ND_ND]; PRESSURE=0; begin_f_loop(f,tf) { PRESSURE += F_P(f,tf); m = m + 1; } end_f_loop(f,tf) PRESSURE2 = PRESSURE/m; press = (PRESSURE2)*1e-6; rdot = (a * pow(press,nn)); SET_DEFORMING_THREAD_FLAG(THREAD_T0(tf)); dis_x = 0.0; dis_y = 0.0; begin_f_loop(f,tf) { f_node_loop(f,tf,n) { v = F_NODE(f,tf,n); if(NODE_POS_NEED_UPDATE(v)) { NODE_POS_UPDATED(v); x = NODE_X(v); y = NODE_Y(v); if(y>=0.05) { dis_x = 0.; dis_y = 0.; } else { dis_x = 0.; dis_y = rdot*dtime; } NV_D(disp, = ,dis_x,dis_y,0); NV_V(NODE_COORD(v), +=, disp); } } } end_f_loop(f,tf) printf("dis y: %f\n", dis_y); } After I do the basic settings; while i choose "reference value"and compute "mass flow inlet" The following error is seen in fluent console: Node 0: Process 34456: Received signal SIGSEGV. ================================================== ============================ ================================================== ============================ Node 1: Process 29852: Received signal SIGSEGV. ================================================== ============================ MPI Application rank 0 exited before MPI_Finalize() with status 2 The fl process could not be started. what is the problem? So could anyone can help to solve this? Thank you. |
|
January 11, 2018, 09:07 |
|
#2 |
Senior Member
Join Date: Sep 2017
Posts: 246
Rep Power: 12 |
OK, my first piece of advice is to simplify things a lot, to build up the complexity in stages. So, for example, I would recommend starting with a constant (non-pressure-dependent) rate first. I would probably recommend a non-UDF inlet condition at first -- and constant velocity-inlet is more stable than mass-flow-inlet. The mesh motion will be the hardest thing to get working (apart from convergence), so start on as simple a case as you can.
It has been a while since I used mesh motion, but I do remember that Fluent was extremely fussy (or basically bug-ridden) about the set-up, and often generated errors like the one you have mentioned. So, whenever there is even a small risk that Fluent could have stupidly forgotten about the DEFINE_GRID_MOTION UDF, go back and reapply it. This definitely includes when you recompile the UDF, and when you reopen a .cas file -- possibly also when you save as .cas file. Absolute paranoia is unfortunately helpful here. I think this was such an annoying situation that I reported it as a bug -- so be sure to use the latest version of Fluent if you can. ANSYS support will not help you much if you are using an old version, especially (and justifiably) if they know that bugs have been fixed. |
|
January 11, 2018, 12:33 |
|
#3 |
New Member
mohsen
Join Date: Jan 2018
Posts: 6
Rep Power: 8 |
Thank you for your reply
i think this code have a basically problem....because i tested this code with ansys 16.2, 17.2 and 18.2 i think problem is here(at DEFINE_PROFILE): begin_f_loop(f,t) { PRESSURE += F_P(f,t); m = m + 1; } end_f_loop(f,t) PRESSURE2 = PRESSURE/m; press = (PRESSURE2)*1e-6; rdot = (a*pow(press,nn)); while i remove that few lines, code runs correctly. |
|
January 11, 2018, 14:35 |
|
#4 |
Senior Member
Join Date: Sep 2017
Posts: 246
Rep Power: 12 |
OK, that's interesting.
The only problem I can see in those lines would be if press2 (the average pressure in MPa) was negative -- in which case pow(press2,0.4255) would generate an error. (This would not be the fault of C -- it means your formula makes no sense.) You should test for this. You can also debug by temporarily adding lots of lines saying things like: Message("have calculated press = %16.8g\n",press); /* DEBUG */ I stick with the advice of running a simulation with a fixed burn rate. Good luck! |
|
January 12, 2018, 00:42 |
|
#5 |
Senior Member
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34 |
Debug your code on single core first (not parallel)
than move to parallel version. best regards |
|
January 12, 2018, 03:37 |
|
#6 |
New Member
mohsen
Join Date: Jan 2018
Posts: 6
Rep Power: 8 |
i run my code on serial (not parallel)....
problem not here... |
|
January 13, 2018, 09:09 |
|
#7 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
I think that the problem is that you are calculating GRID_MOTION for all threads, not only for the boundary thread.
|
|
January 15, 2018, 13:22 |
The problem is solved
|
#8 |
New Member
mohsen
Join Date: Jan 2018
Posts: 6
Rep Power: 8 |
i add DEFINE_ADJUST to my code an the problem is solved..
thanks all.... |
|
October 17, 2020, 05:24 |
|
#9 |
Member
Ali Suleiman
Join Date: Nov 2019
Posts: 43
Rep Power: 7 |
Hi mohsensalehi1993
where you added DEFINE_ADJUST |
|
Tags |
define_profile, dynamic mesh, solid rocket engine |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
How to setup a simple OpenFOAM cluster? | TommiPLaiho | OpenFOAM Installation | 3 | October 27, 2013 16:15 |
Coupling of drying process and flow simulation | franzdrs | Main CFD Forum | 0 | April 29, 2013 15:11 |
Fluent coupled with external process | Nitesh Goyal | FLUENT | 0 | July 10, 2007 10:35 |
HELP-error: the fluent process cannot be started | James Willie | FLUENT | 0 | January 24, 2006 12:17 |
study of a melting process | bryan | FLUENT | 0 | November 24, 2004 00:59 |