-
-
December 17, 2023 at 9:15 am
Md_Salem
SubscriberHello everyone,
I am working on harmonic analysis in Workbench with coupled field element 226Â
I parametrized the thickness of the coupled field element in the Designmodeler using sympol (theck) this dimension was defined during Extrude process.
IÂ inserted some APDL code inside this Workbench :
Â
ESEL,S,ENAME,,226
NSEL,R,LOC,Z,0.001V=ARG1
D,ALL,VOLT,VI need to use the parameter (theck) in the command (NSEL) instead of (0.001) in order to use it in the optimization process.
Is it possible?
Regards
-
December 19, 2023 at 8:53 am
mjmiddle
Ansys EmployeeYou can link at workbench level. First promote the input argument in the Details of the command snippet.
In the "Parameter Set" in the project schematic, you can set the expression to the name of another parameter. The parameter from DM will have a length dimension. The parameter from the APDL snippet will be dimensionless. You have to make sure the dimensions work out. By setting the expression to P1/1[mm], it divides the mm unit in the P1 dimension by mm in this expression to arrive at an expressionless number:
You will need to be knowledgeable about the dimensions set at project level every time you close and reopen workbench to make sure that the dimesions cancel out. And you also have to be consious of the unit setting in Mechanical, since it will write those dimensions to the APDL solver and the number value of the argument needs to imply the right units for this dimensionless argument.
You will need to right click to refresh the Model cell:
If you run solutions by updating design points, the refresh is automatic.
You can use the argument in your script with this line:
NSEL,R,LOC,Z,ARG1
Using ARG1 in my case, maybe ARG2 in your script. By the way, there is no need to set:
V=ARG1
Just use:
D,ALL,VOLT,ARG1-
December 19, 2023 at 2:05 pm
Md_Salem
SubscriberÂ
Hi mjmiddle,
I appreciated your concern.
Will this script with ARG1 and ARG2, which are dimensionless, work? Also, I do parametrize this problem in order to use it in optimization. I am confused a little bit about which dimensions should be parametrized in the optimization at your script (P1 (ARG1), P2, or both).
Regards
Â
-
-
- The topic ‘How to call parameter in APDL command ?’ is closed to new replies.
- The legend values are not changing.
- LPBF Simulation of dissimilar materials in ANSYS mechanical (Thermal Transient)
- Convergence error in modal analysis
- APDL, memory, solid
- How to model a bimodular material in Mechanical
- Meaning of the error
- Simulate a fan on the end of shaft
- Real Life Example of a non-symmetric eigenvalue problem
- Nonlinear load cases combinations
- How can the results of Pressures and Motions for all elements be obtained?
-
4007
-
1461
-
1287
-
1124
-
1021
© 2025 Copyright ANSYS, Inc. All rights reserved.