タグ: structures
-
-
June 23, 2025 at 8:11 am
25rmm26
Subscriber- I have an APDL script that was consistently failing during the geometry creation phase (
/PREP7
). - After extensive debugging with an AI coding partner, we identified and corrected all errors, creating a final, clean script saved as "
run_this.txt
". - I start a clean Ansys session, ensuring the working directory is empty, and then execute the script using the
File > Read Input from...
menu, selecting the correct "run_this.txt
" file. - The output log confirms that "
run_this.txt
" is being read. However, immediately following the/INPUT
log entry, the log shows that old commands (e.g.,ROTATE LINES
), which do not exist in my new script, are being executed. This results in old errors (e.g.,Keypoint 60 not defined
) that should have been fixed. - This behavior persists even when the script begins with
/CLEAR,NOSTART
to bypass any potential interference from astart.ans
file. - What could cause such a discrepancy between the file content specified in the
/INPUT
command and the commands that are actually executed? Are there any other configuration files, environment variables, or session settings besidesstart.ans
that could override or interfere with the input file stream in this manner?
Thank you for your time and assistance. I look forward to your guidance on this matter.
- I have an APDL script that was consistently failing during the geometry creation phase (
-
June 24, 2025 at 6:24 pm
mrife
Ansys Employee"After extensive debugging with an AI coding partner...." I would not expect any AI/LLM to give 100% correct APDL code at this point (aside from one command answers). Can you show us the beginning of the corrected APDL script.
-
June 25, 2025 at 12:25 am
25rmm26
SubscriberAnsysサポートチーム様
早急なご返信ありがとうございます。
/PREP7
ご要望に応じて、 AI コーディング パートナーと徹底的にデバッグした後に開発された、修正された APDL スクリプト (ブロック) の冒頭を以下に示します。! --- 修正されたスクリプトの始まり (/PREP7 ブロック) ---仕上げる/クリア、ノースタート/準備7! --- パラメータ ---DDD=4e-3NNN=44THK=.08e-3THI=60GL=.001GW=.0002PPP=(2*1.4*((1.04**2)-1))/(1.4+1)MMM=1.04CCC=340DTT=(DDD/(MMM*CCC))/NNN! --- 要素と材質 ---ET,1,シェル181R,1,THKMP、EX、1,200e9MP,PRXY,1,0.3MP、DENS、1、7.8e3! --- ジオメトリ作成 ---エリアック,0,0,DDD/2CSYS,0長方形、-.5*GL、-.5*GW、GL、GWASEL,S,エリア,,最後AROTAT、ALL、、、、、、THIアセル、オール長方形、-.5*GL、-.5*GW、GL、GWASEL,S,エリア,,最後AROTAT、ALL、、、、、、、-THIアセル、オール*DO,I,1,NNN-1x_pos = -DDD/2 + (DDD/NNN)*Iy_hgt = sqrt((DDD/2)**2 - x_pos**2)kp1 = 1000 + (I*2 - 1)kp2 = 1000 + (I*2)K, kp1, x_pos, -y_hgtK、kp2、x_pos、y_hgtL、kp1、kp2*エンドド! --- 結合とクリーンアップ ---AOVLAP、すべて番号、すべて! --- メッシュ ---サイズ、DDD/NNN*1.1アメシュ、オール番号、ノード仕上げる -
June 25, 2025 at 12:35 am
25rmm26
SubscriberOur investigation concluded that even when we specify this correct script file with the
/INPUT
command, the output log shows that old commands, which do not exist in this file, are being executed. For example, our script usesAROTAT
, but the log showsROTATE LINES
being executed, which then causes an error. This appears to be an environment-dependent issue.If you have any insight into this behavior, we would greatly appreciate your guidance.
Thank you for your time and assistance.
Best regards,
-
June 25, 2025 at 1:03 pm
mrife
Ansys EmployeeCan you post an english only version of the input file? Google translate is either not doing a good job on some of the words, or the input file has unknown commands...or maybe uses APDL macros you created. For example エリアック gets translated as 'eliac'....no idea what eliac is.
-
June 25, 2025 at 3:56 pm
25rmm26
Subscriber! --- Beginning of the corrected script (/PREP7 block) ---
FINISH
/CLEAR,NOSTART/PREP7
! --- Parameters ---
DDD=4e-3
NNN=44
THK=.08e-3
THI=60
GL=.001
GW=.0002
PPP=(2*1.4*((1.04**2)-1))/(1.4+1)
MMM=1.04
CCC=340
DTT=(DDD/(MMM*CCC))/NNN! --- Element and Material ---
ET,1,SHELL181
R,1,THK
MP,EX,1,200e9
MP,PRXY,1,0.3
MP,DENS,1,7.8e3! --- Geometry Creation ---
AREAC,0,0,DDD/2
CSYS,0
RECTNG,-.5*GL,-.5*GW,GL,GW
ASEL,S,AREA,,LAST
AROTAT,ALL,,,,,,THI
ASEL,ALLRECTNG,-.5*GL,-.5*GW,GL,GW
ASEL,S,AREA,,LAST
AROTAT,ALL,,,,,,,-THI
ASEL,ALL*DO,I,1,NNN-1
x_pos = -DDD/2 + (DDD/NNN)*I
y_hgt = sqrt((DDD/2)**2 - x_pos**2)
kp1 = 1000 + (I*2 - 1)
kp2 = 1000 + (I*2)
K, kp1, x_pos, -y_hgt
K, kp2, x_pos, y_hgt
L, kp1, kp2
*ENDDO! --- Combine and Cleanup ---
AOVLAP,ALL
NUMMRG,ALL! --- Mesh ---
ESIZE,DDD/NNN*1.1
AMESH,ALL
NUMMRG,NODEFINISH
-
June 26, 2025 at 4:40 am
mjmiddle
Ansys EmployeeI tested by making an area in APDL. I entered the command AROTAT,ALL,,,,,,60
I looked in the APDL shell, and it printed these lines for creating area and rotating:
CREATE A RECTANGULAR AREA WITH
X-DISTANCES FROM -0.4000000000 TO -0.5000000000E-01
Y-DISTANCES FROM -0.1000000000 TO 0.2500000000
OUTPUT AREA = 1PLOT AREAS FROM 1 TO 1 BY 1
ROTATE LINES 1, 2, 3, 4,
ABOUT THE AXIS DEFINED BY COORDS
0.78886E-30 0.78886E-30 0.78886E-30, 0.78886E-30 0.78886E-30 0.78886E-30,
DEGREE OF ARC= 360.00 NUMBER OF SEGMENTS= 4*** ERROR *** CP = 1.188 TIME= 00:24:10
Keypoint 60 not defined.So both the "ROTATE LINES" message and the error "Keypoint 60 not defined" are not coming from running any other file. The ROTATE LINES is typical for this command, and the keypoint 60 error is from the wrong format of the AROTAT command. Please refer to the help page on this command:
https://ansyshelp.ansys.com/account/secured?returnurl=/Views/Secured/corp/v251/en/ans_cmd/Hlp_C_AROTAT.html
The command says it "Generates cylindrical areas by rotating a line pattern about an axis" so the ROTATE LINES message seems justified. And your 60 value is in the place of the PAX1 argument, which is expected to be a keypoint. I think you meant tp specify 60 degrees for the ARC argument. But even if you do this, you will still get an error because the axis points are not defined. Therefore PAX1, PAX2 are required arguments.
-
- このトピックに返信するには、ログインする必要があります。
-
3347
-
1042
-
1028
-
870
-
826
© 2025 Copyright ANSYS, Inc. All rights reserved.