-
-
February 7, 2025 at 5:12 pm
salazj27
SubscriberI am attempting to mimmic the environment experienced by a cube satellite in orbit that is prescribed some roll rate about its z-axis. I want to estimate the thermal load it will be subjected to during this CW roll manuever, to do this I have begun by writing a APDL command script, however, I am new to this and Ansys in general so I am dealing within some difficulties. Here is my code before I begin explaining what is going wrong:
! Setting up the time step for the solver
*SET,time_step,20
*AFUN,DEG
*DO,i,0,9,1
*SET,time,(i)*time_step ! Time Step
TIME,time
*SET,angle,1*time ! Rotation at this time (degrees)
*SET,angle,MOD(angle,360)
*SET,flux_1,1361*cos(angle)
*SET,flux_2,1361*cos(90-angle)
*SET,flux_3,1361*cos(180-angle)
*SET,flux_4,1361*cos(270-angle)! Debugging angles and heat fluxes
*VWRITE, angle, time, flux_1, flux_2, flux_3, flux_4
(F10.4, 5F10.4)! Apply the flux to the selected surface(s)
*IF, angle, GE, 0, AND, angle, LT, 90, THEN
*VWRITE, 'Face1', angle
(A20, F10.4)
cmsel,s,Face1
sf,all,hflux,flux_1
ALLSEL
cmsel,s,Face2
sf,all,hflux,flux_2
ALLSEL
*ELSEIF, angle, GE, 90, AND, angle, LT, 180, THEN
*VWRITE, 'Face2', angle
(A20, F10.4)
cmsel,s,Face2
sf,all,hflux,flux_2
ALLSEL
cmsel,s,Face3
sf,all,hflux,flux_3
ALLSEL*ELSEIF, angle, GE, 180, AND, angle, LT, 270, THEN
*VWRITE, 'Face3', angle
(A20, F10.4)
cmsel,s,Face3
sf,all,hflux,flux_3
ALLSEL
cmsel,s,Face4
sf,all,hflux,flux_4
ALLSEL*ELSEIF, angle, GE, 270, THEN
*VWRITE, 'Face4', angle
(A20, F10.4)
cmsel,s,Face4
sf,all,hflux,flux_4
ALLSEL
cmsel,s,Face1
sf,all,hflux,flux_1
ALLSEL
*ENDIF
*ENDDO
ALLSEL
SAVEI am dealing with applying the heat fluxes to the major faces of a 3U cube satellite. Outside of the script I have defined the four faces as named selections, Face1-Face4, so that the heat flux would traverse around the cube satellite in a ccw manner as the 'angle' value satisfies the If/Elseif conditions. However, the flux seems to only be applied to the last condition that is satisfied. For instance, the image below is the result of this code where you can see that the flux was only applied to the face at 180 degrees (the final condition satisfied).
The initial face (@ angle =0) was the X-out face. When running the animation, the initial face does not appear to be heated up at all. Does anyone have any input? Is there a way I can edit the code I have already, or is there an entirely seperate function within this program that allows me to model this case.
An extra note is that Ansys Mechanical is all I have access to right now. Thank you in advance for any efforts!
-
February 8, 2025 at 6:29 pm
salazj27
Subscriber-
-
February 9, 2025 at 2:42 am
salazj27
Subscriber-
-
February 10, 2025 at 10:36 am
Ashish Khemka
Forum ModeratorThanks a lot for the update! I will mark the post answered.
Regards,
Ashish Khemka
-
- You must be logged in to reply to this topic.
-
6465
-
1906
-
1458
-
1308
-
1022
© 2026 Copyright ANSYS, Inc. All rights reserved.
