Giter Site home page Giter Site logo

calculix-post's Introduction

Post-processing for expanded elements in Calculix

Date: 2019-03-23
tags:calculix, Python 3
Author: Roland Smith

Introduction

Calculix expands 2D shell elements into 3D elements. For example, S6 elements are expanded into C3D15 elements.

Before Calculix 2.15, that expansion was printed to standard output. From 2.15 it is captured in a .12d file.

The reporting in the frd file does not contain the expanded elments. This has no consequence for the displacements; they will still be reported properly. But the stresses and strains in the expanded elements are averaged when reported in 2D form. This means that bending stresses and strains are not reported properly.

How does it work

The purpose of this program is to read the .12d file and the .dat file, and insert the displacements for the expanded nodes into the .frd file.

At this moment it only works for S6 elements, expanded into C3D15.

Note that currently the expansion is simple and crude. The displacements of the original nodes from the 2D S6 elements are simply copied to the correct expanded nodes.

It should be slightly more accurate to calculate a normal vector of the displaced element, and use that (scaled to 1/2 the element's thickness) to create the offset displacments. This might be implemented later.

Calculix input file

The calculix input file should contain the following:

*NODE FILE,OUTPUT=3D,NSET=Nall
U,RF
*NODE PRINT,NSET=Nall
U
  • The OUTPUT=3D option in the *NODE FILE card is required for element expansion.
  • The U belonging to the *NODE FILE card is required to make sure that the header for the displacements is present in the .frd results file. This is necessary for splicing in the displacments later.
  • The *NODE PRINT card followed by U is required so that the expanded node displacements are written to a .dat file.

Invocation

After running calculix, the program should be started from the directory that contains the results.

python3 post.py <foo>

Where <foo> is the name of the input and output files without extension. After the run, the amended results are found in a file <foo>-post.frd.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.