|
[Sponsors] |
June 2, 2014, 06:31 |
execute on demand --> (segmentation fault)
|
#1 |
New Member
Join Date: Jun 2014
Posts: 1
Rep Power: 0 |
Hi,
for my Master-Thesis I have to couple Maxwell with Fluent. Therefore I got a UDF from an earlier work. My Problem is when I interprete the UDF and click then execute on demand comes: recieved a fatal signal (Segmentation fault) the file is koordinaten.c: #include "udf.h" /************************************************** ****************************/ FILE *logfile; DEFINE_INIT(my_init_function,domain) { cell_t c; Thread *t; real x[ND_ND]; real i = 0; real j = 0; FILE *ff; ff=fopen("Koordinaten.log","at"); fprintf(ff,"\nDEFINE_INIT\n"); printf("\nDEFINE_INIT\n"); printf("Wert von Zelle: %d\n", c); printf("Wert von thread: %d\n", t); printf("Wert von ND_ND: %d\n", ND_ND); /* loop over all cell threads in the domain */ thread_loop_c (t,domain) { /* loop over all cells */ begin_c_loop_all (c,t) { C_CENTROID(x,c,t); fprintf(ff,"Zelle-%d-Koordinaten x %le y %le z %le\n", c,x[0],x[1],x[2]); } end_c_loop_all (c,t) } fclose(ff); } DEFINE_ADJUST(djust,domain) { FILE *ff; ff=fopen("libudf.log","at"); fprintf(ff,"\nDEFINE_ADJUST\n"); fclose(ff); printf("\nDEFINE_ADJUST\n"); } DEFINE_ON_DEMAND(demand) { FILE *ff; ff=fopen("libudf.log","at"); fprintf(ff,"\nDEFINE_ON_DEMAND\n"); fclose(ff); printf("\nDEFINE_ON_DEMAND\n"); } Has anybody an idea? |
|
June 6, 2014, 03:27 |
|
#2 |
Senior Member
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27 |
Could it be that the file libudf.log is already opened in a different program?
|
|
Tags |
fluent - udf, maxwell, udf |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Segmentation fault when running dieselFoam or dieselEngineFoam in parallel | francesco | OpenFOAM Bugs | 4 | May 2, 2017 22:59 |
Segmentation Fault w/ compiled OF 2.2.0 - motorBike example | sudo | OpenFOAM Running, Solving & CFD | 3 | April 2, 2013 18:27 |
segmentation fault when installing OF-2.1.1 on a cluster | Rebecca513 | OpenFOAM Installation | 9 | July 31, 2012 16:06 |
Segmentation Fault | Shawn_A | OpenFOAM Running, Solving & CFD | 6 | October 31, 2011 15:38 |
ParaView segmentation fault only for multiphase | gwierink | OpenFOAM | 9 | March 25, 2010 08:23 |