grama.models package

Submodules

grama.models.cantilever_beam module

grama.models.cantilever_beam.make_cantilever_beam()

Cantilever beam

A standard reliability test-case, often used for benchmarking reliability analysis and design algorithms.

Generally used in the following optimization problem:

min_{w,t} c_area

s.t. P[g_stress <= 0] <= 1.35e-3

P[g_disp <= 0] <= 1.35e-3

1 <= w, t <= 4

Deterministic Variables:
w: Beam width t: Beam thickness
Random Variables:
H: Horizontal applied force V: Vertical applied force E: Elastic modulus Y: Yield stress
Outputs:
c_area: Cost; beam cross-sectional area g_stress: Limit state; stress g_disp: Limit state; tip displacement

References

Wu, Y.-T., Shin, Y., Sues, R., and Cesare, M., “Safety-factor based approach for probability-based design optimization,” American Institute of Aeronautics and Astronautics, Seattle, Washington, April 2001. Sues, R., Aminpour, M., and Shin, Y., “Reliability-based Multi-Disciplinary Optimiation for Aerospace Systems,” American Institute of Aeronautics and Astronautics, Seattle, Washington, April 2001.

grama.models.channel1d module

grama.models.channel1d.make_channel_nondim()

Make 1d channel model; dimensionless form

Instantiates a model for particle and fluid temperature rise; particles are suspended in a fluid with bulk velocity along a square cross-section channel. The walls of said channel are transparent, and radiation heats the particles as they travel down the channel.

References

Banko, A.J. “RADIATION ABSORPTION BY INERTIAL PARTICLES IN A TURBULENT SQUARE DUCT FLOW” (2018) PhD Thesis, Stanford University, Chapter 2

grama.models.channel1d.make_channel()

Make 1d channel model; dimensional form

Instantiates a model for particle and fluid temperature rise; particles are suspended in a fluid with bulk velocity along a square cross-section channel. The walls of said channel are transparent, and radiation heats the particles as they travel down the channel.

Note that this takes the same inputs as the builtin dataset df_channel.

References

Banko, A.J. “RADIATION ABSORPTION BY INERTIAL PARTICLES IN A TURBULENT SQUARE DUCT FLOW” (2018) PhD Thesis, Stanford University, Chapter 2

Examples:

>>> import grama as gr
>>> from grama.data import df_channel
>>> from grama.models import make_channel
>>> md_channel = make_channel()
>>> (
>>>     df_channel
>>>     >> gr.tf_md(md_channel)
>>>     >> gr.ggplot(gr.aes("T_f", "T_norm"))
>>>     + gr.geom_abline(slope=1, intercept=0, linetype="dashed")
>>>     + gr.geom_point()
>>>     + gr.labs(x="1D Model", y="3D DNS")
>>> )

grama.models.circuit_RLC module

grama.models.circuit_RLC.make_prlc()
grama.models.circuit_RLC.make_prlc_rand()

grama.models.ishigami module

grama.models.ishigami.make_ishigami()

Ishigami function

The Ishigami function is commonly used as a test case for estimating Sobol’ indices.

Model definition:

y0 = sin(x1) + a sin(x2)^2 + b x3^4 sin(x1)

x1 ~ U[-pi, +pi]

x2 ~ U[-pi, +pi]

x3 ~ U[-pi, +pi]

Sobol’ index data:

V[y0] = a^2/8 + b pi^4/5 + b^2 pi^8/18 + 0.5

T1 = 0.5(1 + b pi^4/5)^2

T2 = a^2/8

T3 = 0

Tt1 = 0.5(1 + b pi^4/5)^2 + 8 b^2 pi^8/225

Tt2 = a^2/8

Tt3 = 8 b^2 pi^8/225

References

  1. Ishigami and T. Homma, “An importance quantification technique in uncertainty analysis for computer models,” In the First International Symposium on Uncertainty Modeling and Analysis, Maryland, USA, Dec. 3–5, 1990. DOI:10.1109/SUMA.1990.151285

grama.models.linear_normal module

grama.models.linear_normal.make_linear_normal()

grama.models.pareto_random module

grama.models.pareto_random.make_pareto_random(twoDim=True)

Create a model of random points for a pareto frontier evaluation :param twoDim: determines whether to create a 2D or 3D model :type twoDim: bool

grama.models.plane_laminate module

class grama.models.plane_laminate.make_composite_plate_tension(Theta_nom, T_nom=0.001)

Bases: grama.core.Model

grama.models.plate_buckling module

grama.models.plate_buckling.make_plate_buckle()

Initialize a buckling plate model

Variables (deterministic):

w (in): Plate width h (in): Plate height t (in): Plate thickness m (-): Wavenumber L (kips): Applied (compressive) load;

uniformly applied along top and bottom edges
Variables (random):
E (kips/in^2): Elasticity mu (-): Poisson’s ratio
Outputs:

k_cr (-): Prefactor for buckling stress g_buckle (kips/in^2): Buckling limit state:

critical stress - applied stress

grama.models.poly module

grama.models.poly.make_poly()

grama.models.test module

grama.models.test.make_test()

grama.models.time_cantilever module

grama.models.trajectory_linear_drag module

grama.models.trajectory_linear_drag.make_trajectory_linear()

Module contents