QiangF / pygccx

A python framework to build, solve and postprocess finite element models made out of 3D solid elements using Gmsh and CalculiX.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

What is Pygccx

Pygccx is a python framework to build, solve and postprocess finite element models made out of 3D solid elements using Gmsh and CalculiX.

After instantiating a pygccx model you can use the included Gmsh-Python-API to build your geometry, mesh it and define physical groups (sets). For the usage of the Gmsh API look at http://gmsh.info//doc/texinfo/gmsh.html#Gmsh-API

The gmsh mesh can then be converted to a pygccx mesh object, which is more closely related to CalculiX. All nodes and solid elements which are at least in one physical group will be converted and all physical groups to node- or element sets.

Finally you have to define the keywords for the ccx input file.
Each Keyword is represented by a class. Each class takes the parameters and data the keyword needs.
So your model basically consist of the mesh object and a list of keyword objects.

When the model is complete you can either export the CCX input file or solve the model directly in pygccx.

Look in the examples folder for a quick start and to learn more about how to use pygccx. The best way to explore pygccx is by using an IDE like VS Code or PyCharm with auto completion, intellysense and static type checking switched on. So you can see all the members, parameters, types and doc strings. In the folder docs/pygccx you can find an auto generated html documentation of all classes.

Install Pygccx

Capabilities of Pygccx:

  • Static analysis of 3D structures (only solid elements, no shells or beams)
  • Build geometry and mesh using Gmsh-Python API
  • Read and convert 3D mesh (only nodes, sets and solid elements) from GMSH to CCX
  • Add additional abstract elements (SPRING, GAP, MASS) to model
  • Writing of CCX input file
    • Implemented model keywords:
      • *AMPLIUTUDE
      • *BOUNDARY (homogenous)
      • *CLEARANCE
      • *CONTACT PAIR
      • *COUPLING
      • *DEFORMATION PLASTICITY
      • *DENSITY
      • *DISTRIBUTING COUPLING
      • *DLOAD
      • *EALSTIC
      • *EQUATION
      • *FRICTION
      • *GAP
      • *HYPERELASTIC
      • *INCLUDE (also for step keywords)
      • *MASS
      • *MATERIAL
      • *MPC
      • *ORIENTATION
      • *PLASTIC
      • *PRE-TENSION SECTION
      • *RIGID BODY
      • *SOLID SECTION
      • *SPRING
      • *SURFACE BEHAVIOR
      • *SURFACE INTERACTION
      • *TIE
      • *TRANSFORM
    • Implemented step keywords:
      • *BOUNDARY (inhomogeneous)
      • *CLOAD
      • *CONTACT FILE
      • *CONTACT OUTPUT
      • *CONTACT PRINT
      • *ELEMENT OUTPUT
      • *EL FILE
      • *EL PRINT
      • *GREEN
      • *NODE FILE
      • *NODE OUTPUT
      • *NODE PRINT
      • *STATIC
      • *STEP
      • *TIME POINTS
  • Show CCX input file in CGX
  • Solve CCX input file
  • Show result file in CGX
  • Create result object from *.frd or *.dat files for postprocessing
  • Tools for calculate invariant stresses (Mises, Principals, etc.)
  • Tools for transformation of coordinates, vectors or tensors between coordinate systems
  • Tool for generating preloaded bolts consisting of solid elements and tools for postprocessing of section forces and moments

Planned capabilities of Pygccx:

  • Support of all CCX keywords for static analysis
  • Postpro in GMSH
  • Read mesh from *.frd file

Prerequisites

  • Python 3.10

About

A python framework to build, solve and postprocess finite element models made out of 3D solid elements using Gmsh and CalculiX.

License:GNU General Public License v3.0


Languages

Language:Python 100.0%