Skip to main content

CMS circa Ansys 2019 R3

CMS circa 2019R3

Roughly a year ago, I wrote about how you could reuse CMS elements using APDL snippets within Ansys Mechanical. The new feature of Condensed Geometry in recent releases unfortunately does not completely solve the problem; but does get you half way there.

To recap, the goal here is to have a part (A) that is complicated/huge but now condensed into a teeny-tiny Super-Element. Changes can be quickly made to other parts (B). When combined together (C/D), the model as a whole is smaller and faster to solve since A is reused.

This blog post is an update to the earlier post that uses the same technique but takes advantage of two new tools: Condensed Geometry & Mesh Numbering.

To get started, download the Ansys 2019R3 archived file to follow along.
Archived File with RST (177.0MB)   Link or
Archived File without RST (1.5MB)  Link

The rough procedure:
  1. Create and mesh both Analysis A for CMS part and Analysis B for other parts. 
  2. Note down maximum node and element number for Analysis B. 
  3. In Analysis A, use Mesh Numbering to offset the starting number of nodes and elements to be larger than the maximum node and element number of Analysis B. Or use a huge number. This is to avoid conflicting numbers later so that the node numbers persist between analysis. 
  4. In Analysis A, insert Condensed Geometry Object. After generating the condensed part, right click on the Condensed Part in the tree to "Open Solver File Directory". In it, you will see all the files generated including a *.sub file. Note down the directory name and path for use in APDL snippet later. 
  5. Create Analysis C (your intended final analysis, e.g. Modal Analysis).
  6. Connect Analysis A (CMS part) Model to Analysis C Model, THEN double click on Model of Analysis C to start Mechanical (this is critical before the next step). 
  7. Connect Analysis B Model to Analysis C Model. The already-opened Ansys Mechanical Analysis C should automatically update to reflect the added parts. 
  8. In Analysis C, use Solution APDL snippets to perform Modal or Harmonic Analysis that replaces part A with the CMS equivalent. Expansion of results is also included.  

In the toy model in the archived file above, the results are similar to the naked eye.
No CMS: Elapsed time of 94s

With CMS: Elapsed time of 60s

Comments

  1. good job! what makes step6 so important? I have strange result if I dont perform step 6.

    ReplyDelete
    Replies
    1. Step 6 is important as it retains the order of the numbering scheme. By the way, this post is possibly outdated as Ansys R2 2020 has introduced the capability of importing condensed part.

      Delete
    2. Hi Jason,

      Firstly, good job on all the work you have done on this website !

      Secondly, I am working in a relative new company and they have Ansys R2 2020. How exactly do you import condensed part ? Do you know a tutorial explaining step by step how to do it ?

      Thank you!

      Delete
  2. Hi Jason,
    I tried to use 'hbmat' command to extract mass matrix from the *.sub file, but the result mass file is too big. The *.sub file is 118 MB, but the mass file in 'txt' format is 213 MB. Do you know why the mass file is so big and what shoud I do to reduce the size of it?
    Thank you!

    ReplyDelete
    Replies
    1. Hi YangSu, I believe *.sub is a binary file which is more efficient than hbmat text format. Perhaps look into Pyansys to see if dealing with binary files directly will work for you.

      Delete
  3. Hello Jason,

    Could you please share the file with condensed geometry in ANSYS R2021. I am using new version and facing issue with condensed geometry. Thanks.

    ReplyDelete
    Replies
    1. Hi Nilesh,
      I expect this blog post is outdated. Ansys came up with *.cpa condensed part file for export/import. Please see the help files on "Working with Substructures".

      Delete

Post a Comment

Popular posts from this blog

ANSYS User Defined Results

There is an abundant of options in ANSYS classic when one wishes to post process results. ANSYS workbench default pull down menu post processing options are more limited but they can still be accessed via the User Defined Results. One way not commonly used but can come in handy is as follows: Zeroth: Under Analysis Settings, there is "Output Controls" where you can toggle to "Yes" what you would like to save before the solution starts. This is like OUTRES in APDL. Output Controls First: After solving the model, click on Solution in the tree to highlight it. Solution Second: Click on Worksheet in the toolbar. Worksheet Third: In the worksheet, you will see list of results that are saved. Right click on it to create the User Defined Results. Create User Defined Results So here we have it. You could of look up the different expressions in the help document but I find this method of accessing the results convenient.  Example: Aspec...

Export Stiffness Matrix from Ansys

It is sometimes useful to extract the mass and stiffness matrix from Ansys.     *SMAT, MatK, D, IMPORT, FULL, file.full, STIFF       *PRINT, matk, matk, txt Exporting mass matrix would be similar:       *SMAT, MatM, D, import, full, file.full, MASS The above script uses APDL Math to get the job done. (Please see previous post for another example). The ordering of the matrix is unfortunately not concurrently exported. To verify the sequencing is as expected, we will work to replicate a truss example in the  Finite Element Trusses course notes by Bob Greenlee. Figure 1: Truss Problem Setup Model Creation Script to create model: /prep7 !! Creates Model to reflect course notes ! Properties et ,1,1  mp , ex, 1, 29.5e6 r , 1, 1 ! Geometry n ,1 $  n ,2, 40 $  n ,3, 40, 30 $  n ,4, 0, 30 e ,1,2 $  e ,2,3 $  e ,1,3 $  e ,3,4 ! Boundary Conditions d ,1,ux,0 $  d ,1,uy,0 d ,2,uy...

ANSYS APDL Syntax Highlighting editor

Notepad++ with APDL User Defined Language The editor of my choice is Notepad++  with the available User Defined Language Files for APDL. You can install it without administrative privileges via the zip file. The best part of it is, it's FREE! After installing Notepad++, go to "Language>Define Your Language..." then "Import" the XML file downloaded from the above link. Remember to restart Notepad++ so that the language changes will take into effect. Opening up any *.inp or *.ans files should automatically switch highlighting to APDL. I made some minor edits. Here's my XML file: LINK . I also heard Sublime Text and  Ultraedit  has more advance features but they aren't (totally) free.