CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

UDF for PMV and PPD

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 2 Post By lcbarreto

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 18, 2017, 17:16
Post UDF for PMV and PPD
  #1
Member
 
Lucas Barreto
Join Date: Sep 2017
Location: São Paulo, Brazil
Posts: 35
Rep Power: 9
lcbarreto is on a distinguished road
Hi guys,

I am simulating the flow inside of an aircraft cabin and and I need to evaluate the passenger's thermal comfort and in order to do that I need to calculate the Fanger's parameters: PMV (Predicted Mean Vote) and the PPD (Predicted Percentage Dissatisfied). The theory behind the calculation is pretty straight forward, however I am out of practice with my C programming, so I am having difficulties creating my UDF file, Does anyone here have this routine and would be willing to share it? I have looked on other threads and haven't found it.

Thanks in advance
lcbarreto is offline   Reply With Quote

Old   September 19, 2017, 11:54
Default
  #2
Member
 
Lucas Barreto
Join Date: Sep 2017
Location: São Paulo, Brazil
Posts: 35
Rep Power: 9
lcbarreto is on a distinguished road
Hello again guys,

I am developing a C code for the PMV and PPD calculation, can anyone take a look at it and see if there is anything wrong with it? I haven't had the opportunity to test it yet, I am still stuck on a previous part of the simulation.

Thanks in advance.
Attached Files
File Type: c Thermal_comfort.c (2.6 KB, 200 views)
swtbkim and 1ndrapermana like this.
lcbarreto is offline   Reply With Quote

Old   September 27, 2017, 07:10
Default
  #3
Senior Member
 
Join Date: Sep 2017
Posts: 246
Rep Power: 12
obscureed is on a distinguished road
This file needs a lot of tidying before it will compile:
-- Statements need to end with semicolon.
-- The braces {...} need to match up. Indentation is decorative only. (You currently seem to think that braces are needed outside an if...else... structure, and that is wrong. You want "if(condition) {statement; statement;} else {statement; statement;}")
-- x**4 is not C; you probably want POW(x,4).

Please do not expect us to fix this kind of thing for you.
obscureed is offline   Reply With Quote

Old   September 27, 2017, 08:19
Default
  #4
Member
 
Lucas Barreto
Join Date: Sep 2017
Location: São Paulo, Brazil
Posts: 35
Rep Power: 9
lcbarreto is on a distinguished road
Quote:
Originally Posted by obscureed View Post
This file needs a lot of tidying before it will compile:
-- Statements need to end with semicolon.
-- The braces {...} need to match up. Indentation is decorative only. (You currently seem to think that braces are needed outside an if...else... structure, and that is wrong. You want "if(condition) {statement; statement;} else {statement; statement;}")
-- x**4 is not C; you probably want POW(x,4).

Please do not expect us to fix this kind of thing for you.
Thank you for the insight, I have already fixed the code with the tips that you gave. I am still revising the C programming structure, I am having a hard time understanding the loops especifically used on this library (udf.h) But I am working on it.

Thank you again.
lcbarreto is offline   Reply With Quote

Old   February 7, 2019, 07:44
Default
  #5
New Member
 
hasna
Join Date: Feb 2019
Posts: 6
Rep Power: 7
hasnaabid is on a distinguished road
Currently, I am experiencing the same problem I would be grateful if someone can help me to overcome this problem.
hasnaabid is offline   Reply With Quote

Reply

Tags
fluent - udf, pmv, post processing, ppd, thermal comfort


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
trying to calculate PMV, PPD and PD in fluent using UDF chunying Fluent UDF and Scheme Programming 7 May 20, 2019 09:07
PPD & PMV value Tanty Ali CFX 6 April 3, 2018 06:40
(PPD) Percentage of People Dissatisfied John CFX 1 May 8, 2008 09:46


All times are GMT -4. The time now is 15:00.