Federico Alzamora Previtali
Ansys Employee

Are you having problems to get this to compile? Or is the UDF not working?

If the former, are you getting any error/warning messages when you try to compile?

If the second, I would look at the last section of your code, where you return the value of local_h_sfq only in the last else statement