
Stress-Strain Curve
Displays mechanical stress versus strain from tensile testing, annotating elastic modulus, yield point, ultimate tensile strength, and fracture.
Sample code / prompt
import matplotlib.pyplot as plt
import numpy as np
np.random.seed(42)
strain = np.linspace(0, 0.5, 1000)
E = 200e3 # Young's modulus MPa
yield_s = 350
UTS = 500
elastic = E * strain
plastic_start = yield_s / E


