|
[Sponsors] |
Difficulty in loading UDF: udf library not compiled for parallel use |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
September 24, 2020, 17:49 |
Difficulty in loading UDF: udf library not compiled for parallel use
|
#1 |
New Member
Join Date: Oct 2018
Posts: 6
Rep Power: 7 |
Hi all,
I’m having difficulty debug/load the UDF in my work. The problem description is demonstrated as the following: Background: I’m using mixture model to simulate two liquid phases in a tank. The primary phase is water and the second phase is slightly heavier than water. What I want to do is to “count how much of the second phase fluid can accumulate at the bottom of the tank”. So I understand it as it is similar to degassing boundary condition for air, but in my case, for liquid. I assume if the second phase hit the floor below a certain velocity, I “take it out”. Condition: I have windows 10 64bit OS VS2017 installed. ANSYS 2020R2. Problem: As I was trying to build and load the library with a c file saved in the same directory where the case file is saved, I received this error message: Copied D:\Software\ansys\ANSYS 2020R2\UDF practice/D:\Software\ansys\ANSYS 2020R2\UDF practice estudf.c to libudf\src Creating user_nt.udf file for 3ddp_host ... (system "copy "d:\software\ansys\ansys 2020r2\ansys inc\ansys student\v202\fluent"\fluent20.2.0\src\udf\makefile _nt.udf "libudf\win64\3ddp_host\makefile" ") 1 file(s) copied. (chdir "libudf")(chdir "win64\3ddp_host")# Generating ud_io1.h testudf.c # Generating udf_names.c because of makefile testudf.obj udf_names.c # Linking libudf.dll because of user_nt.udf udf_names.obj testudf.obj Microsoft (R) Incremental Linker Version 14.16.27043.0 Copyright (C) Microsoft Corporation. All rights reserved. LINK : fatal error LNK1104: cannot open file 'libudf.dll' Creating user_nt.udf file for 3ddp_node ... (system "copy "d:\software\ansys\ansys 2020r2\ansys inc\ansys student\v202\fluent"\fluent20.2.0\src\udf\makefile _nt.udf "libudf\win64\3ddp_node\makefile" ") 1 file(s) copied. (chdir "libudf")(chdir "win64\3ddp_node")# Generating ud_io1.h testudf.c ..\..\src\testudf.c(13): warning C4003: not enough arguments for function-like macro invocation 'THREAD_SUB_THREAD' ..\..\src\testudf.c(13): error C2059: syntax error: ']' I also received this message if I tried to click load. Question: I noticed that there are bugs. i.e. not enough arguments for function-like macro invocation ‘THREAD_SUB_THREAD’. However, I’m not sure where did I make the mistake. Also in regards of the syntax error: ‘]’, I do not have ‘]’ in that line. Also, can someone help me understand what does it mean in the error message and how to resolve it? What I have tried: 1. Open Fluent from VS Command Prompt 2. Making sure all the files (cas,dat,c) are in the same location 3. Run this in parallel with multiple cores. 4. Making sure that visual C++ is installed. Attached is my udf file. Any help is highly appreciated! |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Error code: 126 when loading parallel UDF | Coop | Fluent UDF and Scheme Programming | 0 | July 13, 2018 08:33 |
UDF compiled and loaded but not available | Easyeight | Fluent UDF and Scheme Programming | 7 | June 28, 2018 11:54 |
Problem loading UDF in Linux environment | hjan23 | FLUENT | 0 | December 15, 2017 04:09 |
Loading library via scheme command | crevoise | Fluent UDF and Scheme Programming | 3 | March 31, 2017 06:50 |
setting up compiled UDF library in windows2000 | sivakumar | FLUENT | 1 | October 19, 2001 03:46 |