|
[Sponsors] |
how to define udf file for for source term, scattering, absorption coefficient. |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 15, 2023, 05:47 |
how to define udf file for for source term, scattering, absorption coefficient.
|
#1 |
New Member
uwumukunzi fidele
Join Date: Feb 2023
Posts: 1
Rep Power: 0 |
hello,
i am working on solar collector modeling, but I have failed to write udf file for user defined function for momentum source term, scattering, absorption coefficient. this is the error i am getting for cords of momentum source term (structure reference not implemented) cords: #include "udf.h" #include "math.h" #define H 2 #define To 300 #define kio 0.06 #define pi 3.14 DEFINE_SOURCE(ymom_source,cell,thread,ds,eqn) { real x[1]; double Fk; double beta=0.000222297; real T=C_T(cell,thread); double kim; kim=kio/(1+beta*(T-To)); Fk=(2*kim*pow(H,2)*(-kio*beta)/(1+beta*pow(T-To,2))*x[1].ds[T]*x[1]; return Fk; } |
|
Tags |
fluent, fluent - udf, fluent - udf - parallel |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Custom Thermophysical Properties | wsmith02 | OpenFOAM | 4 | June 1, 2023 15:30 |
[swak4Foam] Installation Problem with OF 6 version | Aurel | OpenFOAM Community Contributions | 14 | November 18, 2020 17:18 |
[OpenFOAM.org] Error creating ParaView-4.1.0 OpenFOAM 2.3.0 | tlcoons | OpenFOAM Installation | 13 | April 20, 2016 18:34 |
[foam-extend.org] problem when installing foam-extend-1.6 | Thomas pan | OpenFOAM Installation | 7 | September 9, 2015 22:53 |
SparceImage v1.7.x Issue on MAC OS X | rcarmi | OpenFOAM Installation | 4 | August 14, 2014 07:42 |