-
Notifications
You must be signed in to change notification settings - Fork 1
/
steel.py
36 lines (28 loc) · 959 Bytes
/
steel.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import numpy as np
def raynor(Es,fy,fsu,esh,esu,dels,C1,Ey):
es = np.linspace(0,esu,int(esu/dels+1))
fs = es*0
ey = fy/Es;
fsh = fy + (esh-ey)*Ey
for i in range(len(es)):
if es[i] < ey:
fs[i] = Es*es[i]
if es[i] >= ey and es[i] <= esh:
fs[i] = fy+(es[i]-ey)*Ey
if es[i] > esh:
fs[i] = fsu-(fsu-fsh)*(((esu-es[i])/(esu-esh))**C1)
return es, fs
def king(Es,fy,fsu,esh,esu,dels):
r = esu - esh
m = ((fsu/fy)*((30*r+1)**2)-60*r-1)/(15*(r**2))
es = np.linspace(0,esu,int(esu/dels+1))
fs = es*0
ey = fy/Es
for i in range(len(es)):
if es[i] < ey:
fs[i] = Es*es[i]
if es[i] >= ey and es[i] <= esh:
fs[i] = fy
if es[i] > esh:
fs[i] = ((m*(es[i]-esh)+2)/(60*(es[i]-esh)+2) + (es[i]-esh)*(60-m)/(2*((30*r+1)**2)))*fy
return es, fs