


{"id":338626,"date":"2023-12-14T20:33:25","date_gmt":"2023-12-14T20:33:25","guid":{"rendered":"\/forum\/forums\/topic\/bfe-and-function-editor\/"},"modified":"2023-12-18T11:58:09","modified_gmt":"2023-12-18T11:58:09","slug":"bfe-and-function-editor","status":"closed","type":"topic","link":"https:\/\/innovationspace.ansys.com\/forum\/forums\/topic\/bfe-and-function-editor\/","title":{"rendered":"BFE and Function Editor"},"content":{"rendered":"<div>Hi there,&nbsp;<\/div>\n<div>I&acute;m trying to simulate a deep welding process with a moving heat source in Ansys Workbench. The heat source consits of a conical and a cylindrical part combined, depending on the Y coordinate. So far I&acute;ve come up with two different solutions:&nbsp;<\/div>\n<div>&nbsp;<\/div>\n<div>1) Applying the heat load via BFE, using a APDL Code<\/div>\n<div>&nbsp; &nbsp; Basically a loop over all time steps and all elements, where h is the depth of the keyhole, re the radius of the conical part and ri the radius of the cylindrical part<\/div>\n<div>&nbsp;<\/div>\n<div>*DO,jj,EMIN,EMAX,1&nbsp; &nbsp; ! Selects centroid of every element, Iterates through element numbers<\/div>\n<div>&nbsp; &nbsp; Y=CENTRY(jj)<\/div>\n<div>&nbsp; &nbsp; *IF,Y,LT,h,THEN&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ! Heat source application&nbsp;<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; QF=0<\/div>\n<div>&nbsp; &nbsp; *ELSE<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; X=CENTRX(jj)&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ! Centroid coordinates of jjth-element<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; Z=CENTRZ(jj)<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; CSI=Z+TempCSI&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ! Moving coordinate<\/div>\n<div>&nbsp; &nbsp; *IF,Y,GE,Yi,THEN<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;r1=re-TempR1*(Ye-Y)&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;QF=QF1*exp(((-3)*(X**2+CSI**2)\/r1**2))&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;! Heat source equation conical<\/div>\n<div>&nbsp; &nbsp; *ELSEIF,Y,LT,Yi,THEN<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; QF=QF2*exp(((-3)*(X**2+CSI**2)\/r2**2))&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;! Heat source cylinder<\/div>\n<div>&nbsp; &nbsp; &nbsp;*ELSE<\/div>\n<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; QF=0<\/div>\n<div>&nbsp; &nbsp; &nbsp; *ENDIF<\/div>\n<div>&nbsp; &nbsp; *ENDIF<\/div>\n<div>&nbsp; &nbsp;&nbsp;<\/div>\n<div>BFE,jj,HGEN,,QF&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;! Heat generation for selected element centroids; *ENDDO<\/div>\n<div>2) Applying the heat load via BFE and the MAPDL Function Generator. In this case I used the same function for the heat source as in 1) and the primary Variables X,Y,Z,TIME (sattachement)<\/div>\n<div>&nbsp;<\/div>\n<div>Even though I use the same function, the calculated results vary. What could be the reason fort hat? I understand that with BFE the load is applied at the nodes of an element.&nbsp;<\/div>\n<div>Are the differences due to different calculation points in the table, as the table might be using integration points for calculations instead of nodes? What else could be a reason fort he differences?<\/div>\n<div>If I try the same but with BF, the calculated temperatures via those two ways are basically identical.<\/div>\n<div>&nbsp;<\/div>\n<div>Thanks in advance<\/div>\n","protected":false},"template":"","class_list":["post-338626","topic","type-topic","status-closed","hentry","topic-tag-apdl","topic-tag-help","topic-tag-mapdl","topic-tag-mechanical","topic-tag-moving-heat-source","topic-tag-welding","topic-tag-workbench"],"aioseo_notices":[],"acf":[],"custom_fields":[{"0":{"_bbp_subscription":["13557","88"],"_bbp_author_ip":["23.206.193.41"]," _bbp_last_reply_id":["0"]," _bbp_likes_count":["0"],"_btv_view_count":["1843"],"_bbp_topic_status":["unanswered"],"_edit_lock":["1702900395:219927"],"_bbp_status":["publish"],"_bbp_topic_id":["338626"],"_bbp_forum_id":["27791"],"_bbp_engagement":["88","13557"],"_bbp_voice_count":["2"],"_bbp_reply_count":["1"],"_bbp_last_reply_id":["341241"],"_bbp_last_active_id":["341241"],"_bbp_last_active_time":["2023-12-20 11:07:14"]},"test":"alina-niederbergerst-oth-regensburg-de"}],"_links":{"self":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/topics\/338626","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/topics"}],"about":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/topics\/338626\/revisions"}],"wp:attachment":[{"href":"https:\/\/innovationspace.ansys.com\/forum\/wp-json\/wp\/v2\/media?parent=338626"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}