-
How to run functions that are defined in an ACT extension or Mechanical Add-on from a script?
I have an ACT extension installed for Mechanical. I want to run an Mechanical script that will leverage some of the automation that is defined in the ACT extension. How can I do that?
-
Mechanical ACT Custom Load for Macro Encapsulation: define step
I'm creating a custom load object through Mechanical ACT that encapsulates some APDL macro. This writes the APDL code to the ds.dat. How can I define at which step of a multistep analysis this macro gets written?
-
How to export all reaction forces and moments in a file ?
Hi, Here is my problem : I would like to : (i) create in Mechanical all the reaction forces and moments ; (ii) export all these data in a file (.csv for example). For the first point, I have writen a Python script, and I get a folder containing subfoler with reaction forces and moments for my boundary conditions, joints,…
-
Migrating ACT extension: error message with CreateLoadObject()
I'm migrating an ACT extension to a newer version of Ansys and I'm getting an error message that CreateLoadObject() takes 2 arguments and only 1 was given: How do I resolve this?
-
DPF Crashes Workbench with large result files
I've noticed an issue when using DPF with large result files in my ACT scripts (currently using version 2023R2), essentially whenever the result file gets large enough (25+GB) all of my post processing scripts crash workbench a few seconds after starting to run. I reduced the size of mesh and resolved to get a smaller…
-
How to access results of Motion - Function Expression using scripting?
Hi all, is it possible to access results of Function Expression using scripting in Mechanical?
-
Integrate results over a subsection of a surface
I have a surface on which I have calculated a direction heat flux solution. I would like to add a script that then takes a region of interest of that surface and integrates the directional heat flux in that region.
-
How to get the "analysis" from pre solve commands on a general ACT object
Hello! I am currently working on an extension that uses a custom object in the Tree. The object is not a load object, but it does create apdl commands before the solve. For some context the tree looks like this, where I create a custom folder, and then a custom object. The custom Tree object then writes apdl commands using…
-
Check for mesh connectivity between two bodies
How to check whether there is mesh connectivity between two bodies using scripting? for example, manually I can use mesh connection option in Display settings to verify: upon observation, I can confirm whether it has mesh connectivity or not. but, if I have to verify the same using scripting, is there any way?
-
How can I show/hide Mesh on a contour result?
How can I show/hide Mesh on a contour result?
-
Migration from v222 to v232
Hi, ExtAPI.DataModel.InternalObject["ds"].Graphics.ResultPrefs.MinOn = FalseExtAPI.DataModel.InternalObject["ds"].Graphics.ResultPrefs.edgeDisplay = 2 This commande perfectly worked in Ansys 2022 R2 but not anymore in v2023 R2. I get the following error message: 'DispCallable' object has no attribute 'MinOn' Can you give…
-
How can I show / hide Max / Min results on a contour plot?
How can I show / hide Max / Min results on a contour plot?
-
Getting issue while invoke callback in separate thread in ACT
Hello, In ACT for Mechanical Context, I have a callback which is called on the button click implemented in XML: <callbacks><onclick>run</onclick></callbacks> The run() routine is initialized in .py file as run(context) In such a case, the button is being pressed during the runtime of ACT, and UI is suspended. It looks…
-
Parallel Threading vs Serial Threading in Mechanical ACT
Parallel Threading vs Serial Threading in Mechanical ACT
-
Can we get the PID or Process name for an launch: ExtAPI.DataModel.Project.Model.Solve()
I have some basic script to follow the CPU and RAM useage during a solve but it would be more focused if I could get the actual usage for the given analysis. To do that I need to know what PID or Process gets started when a solve is started. Any ideas
-
How to delete load objects in WB LS-DYNA?
How to delete load objects in WB LS-DYNA? I have learned "How to create load objects in WB LS-DYNA" as below link. But I cannot delete it before create new load objects. https://discuss.ansys.com/discussion/comment/1170#Comment_1170 May anyone tell me how, thank you.
-
How to plot stress results on specific coordinates in Mechanical?
Hello, Is it possible to plot the stress values of my model at certain coordinates (theoretical weld transition) in Mechanical? The coordinates result from the joint lines of two plates and a defined evaluation distance to the joint lines. Thus, they usually do not lie exactly on a node, but can also lie in the middle of…
-
Script doesn't work while inside ACT Extension
I'm trying to create a Workbench Mixed Wizard, to analyze a simple cantilever beam. I managed to make the geometry generation script to work for any SpaceClaim instance I open as standalone. Although, when it's part of a step of a Wizard, I get the following error: I feel like I should import the SpaceClaim scripting…
-
Can you provide an example of using the materials module in Mechanical?
Can you provide an example of using the materials module in Mechanical?
-
Select target elements using Point in Polygon Ray Casting Algorithm.
Components 1, 2 and 3 are connected to the base plate as bonded contacts. How can I select the element faces on the base plate which are attached to the component base? Geometry Output
-
Minimall ANSYS installation for building WBEX
Hello, I would like to ask what is the minimal ANSYS installation, which allows me to create wbex file from the scriptable extension. I have discovered that I need to select at least -mechapdl during the installation to get the workbench where I can build the wbex. But this installation has cca 18 GB. Is there any…
-
Referencing scriptable extension using the command
Hi, I would like to reference the script extension using the command. Is it possible to add specific extension directory path? I would like to than load the extension using Extension.LoadExtension…
-
How do I export average values of all results in a folder to a CSV file in Mechanical?
How do I export average values of all results in a folder to a CSV file in Mechanical?
-
how to get elements based on element name IDs using ansys mechanical scripting?
for example, if I want to get all the elements of CONTAC174 of ename, how do I get it?
-
How to use the <filter> XML tag in ACT Extension?
Hi! How can i implement a visibility filter using the <filter> XML tag under the <interface> node of an XML extension file (see image below)? I would like to be able to filter some default Mechanical buttons for a custom ACT solver I'm developing. I managed to find some some 'ButtonVisibility.xml' examples from other Ansys…
-
How can I filter Analysis loads/results for custom ACT Solver in Ansys Mechanical?
Hi! I'm implementing a custom ACT solver for the ACT extension I am developing in Ansys Mechanical during my Ph.D. My custom ACT solver connects to a Static Structural system (just like nCode DesignLife, see image below) and implements a custom analysis routine I developed. Up to now, I managed to implement my custom…
-
How to get the total number of design points in Workbench via script?
Do we have any ACT API to count the total number of design points present in the parameter set?
-
How to get Extension Format