| 查看: 953 | 回复: 0 | ||
[求助]
UDF单机多核并行计算
|
|
UDF如下,不知道应该怎么改 #include "udf.h" #include "sg_pb.h" #include "sg_mphase.h" DEFINE_PB_BREAK_UP_RATE_FREQ(break_up_freq_tav, cell, thread, d_1) { real epsi,f1, f2, rho_d; real C1 = 0.00481, C2 = 0.08, sigma = 0.04; Thread *tm = THREAD_SUPER_THREAD(thread);/*passed thread is phase*/ epsi = C_D(cell, tm); rho_d = C_R(cell, thread); f1 = pow(epsi, 1./3.)/pow(d_1, 2./3.); f2 = -(C2*sigma)/(rho_d*pow(epsi,2./3.)*pow(d_1, 5./3.)); return C1*f1*exp(f2); } DEFINE_PB_BREAK_UP_RATE_PDF(break_up_pdf_par, cell, thread, d_1, thread_2, d_2) { real pdf; real C1 = 180; real f_2, f_3, f_4; f_2 = pow(d_2, 2) / pow(d_1, 3); f_3 = pow(d_2, 6) / pow(d_1, 6); f_4 = pow(1. - (pow(d_2, 3) / pow(d_1, 3)),2); pdf = f_2*f_3*f_4; return C1*pdf; } |
» 猜你喜欢
2027博士申请-临床检验诊断学、病原生物学、微生物方向
已经有5人回复
【长期招聘】复旦大学 AI 制药实验室 博士后招聘
已经有10人回复
各位基础老师们,看完中央《从严治党》的决定后,对学术界更加有信心了吧
已经有4人回复
越来越担心硕士毕业后没有竞争力了
已经有15人回复
申博自荐 2篇一区TOP+1篇EI+2公开发明专利 2027博士申请
已经有3人回复










回复此楼