Batch SPT corrections for one borehole
Field blow counts become N60 (energy and rod-length corrections) and then (N1)60 (overburden correction). Here the rod-length factor Cr is 0.85 and the effective stresses are typed in; a real script would read them from your profile.
import geoeq as ge
# Field SPT blow counts (N) at depth, for one borehole
depths = [1.5, 3.0, 4.5, 6.0] # m
N = [8, 11, 14, 18]
sigma_v_eff = [24, 42, 58, 73] # kPa, effective vertical stress
for z, n, s in zip(depths, N, sigma_v_eff):
n60 = ge.spt_n60(n, ER=60, Cb=1.0, Cs=1.0, Cr=0.85)
n160 = ge.spt_n160(n60, s)
print(f"{z:>4} m N={n:>2} N60={n60:5.1f} (N1)60={n160:5.1f}")
Output
1.5 m N= 8 N60= 6.8 (N1)60= 13.6
3.0 m N=11 N60= 9.3 (N1)60= 14.4
4.5 m N=14 N60= 11.9 (N1)60= 15.6
6.0 m N=18 N60= 15.3 (N1)60= 17.9
Classify a soil from index properties
USCS classification from liquid limit, plastic limit and gradation, following the ASTM D2487 flowchart, plus the plasticity index.
import geoeq as ge
soil = ge.classify_uscs(LL=48, PL=22, gravel=2, sand=18, fines=80)
print(soil)
print("PI =", ge.atterberg(LL=48, PL=22))
Output
{'symbol': 'CL', 'name': 'Lean clay'}
PI = 26.0
Bearing capacity and a parameter sweep
The documented example from the package, followed by a loop over embedment depth. The Meyerhof option is used here; a hand check of the method you choose remains good practice.
import geoeq as ge
res = ge.bearing_capacity(c=25, gamma=18, Df=1.5, B=2, phi=30, method="meyerhof")
print(round(res["q_u"], 1), "kPa")
# Parameter sweep: embedment depth
for Df in (0.5, 1.0, 1.5, 2.0):
q = ge.bearing_capacity(c=25, gamma=18, Df=Df, B=2, phi=30, method="meyerhof")["q_u"]
print(f"Df = {Df} m q_u = {q:7.1f} kPa")
Output
1829.3 kPa
Df = 0.5 m q_u = 1285.8 kPa
Df = 1.0 m q_u = 1550.4 kPa
Df = 1.5 m q_u = 1829.3 kPa
Df = 2.0 m q_u = 2122.6 kPa
A liquefaction triggering check at one depth
Cyclic stress ratio from the design motion, cyclic resistance ratio from (N1)60cs by the NCEER (Youd et al. 2001) equation, and the factor of safety. FS below 1.0 means liquefaction is predicted at that depth.
import geoeq as ge
csr = ge.liquefaction_csr(amax=0.25, sigma_v=110, sigma_v_eff=73, Mw=7.5, z=6.0)
crr = ge.liquefaction_crr(N160cs=18, method="youd_2001")
fos = ge.liquefaction_fos(csr["CSR"], crr["CRR"], Mw=7.5)
print(csr); print(crr); print(fos)
Output
{'CSR': 0.2324061781360049, 'rd': 0.9491273288910969, 'amax_g': 0.25}
{'CRR': 0.19182098765432098, 'method': 'youd_2001'}
{'FS': 0.825492775397813, 'MSF': 1.0001492712300064, 'K_sigma': 1.0, 'K_alpha': 1.0, 'liquefies': True}