Fibers#

This example demonstrates the generation of fibers for use with OpenSees. Begin by creating a standard AISC shape:

import veux
from xsection.library import from_aisc

shape = from_aisc("W14x211", fillet=True, mesh_scale=1)

veux.draw_shape(shape)
<veux.artist.shape.PlaneArtist at 0x1268c9e20>
../_images/8ae84410da78f39a7f0e5bfeb77e034a35468be3b33e5c5b8c68c3930814124d.png

Next, the create_fibers() method is used to generate fibers. The method generates dictionaries with the following fields:

  • "y", "z" the coordinates of the fiber

  • "area" the area of the fiber

  • "warp" warping shapes and gradients

import matplotlib.pyplot as plt
fig, ax = plt.subplots()
for fiber in shape.create_fibers():
    ax.scatter([fiber["y"]], [fiber["z"]], fiber["area"]*10, marker="s", color='gray')

ax.plot(*shape.exterior().T, color='black')
ax.set_aspect('equal')
ax.axis('off');
../_images/f457866a241f1f52913d1c596efd52a27935b1e4ceb0be7bf2714fd063f0d513.png
veux.ShapeArtist(shape).draw_fibers()
../_images/2fcdcd0b74a49a1701b221d5e8250302a09bbc0d9e80128c37d22f882e90c7d9.png