28. section2d — Some functions operating on 2D structures.

Some functions operating on 2D structures.

This is a plugin for pyFormex. (C) 2002 Benedict Verhegghe

See the Section2D example for an example of its use.

class section2d.planeSection(F)

A class describing a general 2D section.

The 2D section is the area inside a closed curve in the (x,y) plane. The curve is decribed by a finite number of points and by straight segments connecting them.

Initialize a plane section.

Initialization can be done either by a list of points or a set of line segments.

By Points
Each point is connected to the following one, and (unless they are very close) the last one back to the first. Traversing the resulting path should rotate positively around the z axis to yield a positive surface.
By Segments
It is the responsibilty of the user to ensure that the segments form a closed curve. If not, the calculated section data will be rather meaningless.

planeSection objects have the following methods:

sectionChar()

Functions defined in the module section2d

section2d.sectionChar(F)

Compute characteristics of plane sections.

The plane sections are described by their circumference, consisting of a sequence of straight segments. The segment end point data are gathered in a plex-2 Formex. The segments should form a closed curve. The z-value of the coordinates does not have to be specified, and will be ignored if it is. The resulting path through the points should rotate positively around the z axis to yield a positive surface.

The return value is a dict with the following characteristics: ‘L’ : circumference, ‘A’ : enclosed surface, ‘Sx’ : first area moment around global x-axis ‘Sy’ : first area moment around global y-axis ‘Ixx’ : second area moment around global x-axis ‘Iyy’ : second area moment around global y-axis ‘Ixy’ : product moment of area around global x,y-axes

section2d.extendedSectionChar(S)

Computes extended section characteristics for the given section.

S is a dict with section basic section characteristics as returned by sectionChar(). This function computes and returns a dict with the following:

  • ‘xG’, ‘yG’ : coordinates of the center of gravity G of the plane section
  • ‘IGxx’, ‘IGyy’, ‘IGxy’ : second area moments and product around axes through G and parallel with the global x,y-axes
  • ‘alpha’ : angle(in radians) between the glabla x,y axes and the principal axes (X,Y) of the section (X and Y always pass through G)
  • ‘IXX’,’IYY’: principal second area moments around X,Y respectively. (The second area product is always zero.)
section2d.princTensor2D(Ixx, Iyy, Ixy)

Compute the principal values and directions of a 2D tensor.

Returns a tuple with three values:

  • alpha: angle (in radians) from x-axis to principal X-axis
  • IXX,IYY: principal values of the tensor

Documentation

Previous topic

27. isopar — Isoparametric transformations

Next topic

29. inertia — inertia.py

This Page