CoreMechanical¶
petrophys.interpretation.core_analysis.CoreMechanical
- class CoreMechanical(
- depth,
- ucs,
- vp=None,
- vs=None,
- poisson=None,
- extra_scales=<factory>,
- metadata=<factory>,
Core mechanical property measurements.
- Parameters:
depth (np.ndarray) – Measured depth of each sample (m or ft).
ucs (np.ndarray) – Uniaxial Compressive Strength (MPa) at the primary scale.
vp (np.ndarray, optional) – P-wave velocity (m/s).
vs (np.ndarray, optional) – S-wave velocity (m/s).
poisson (np.ndarray, optional) – Dynamic Poisson’s ratio (dimensionless), as delivered.
extra_scales (dict, optional) – Additional UCS arrays at other averaging scales, e.g. {“5cm”: array, “30cm”: array}.
metadata (dict) – Additional header information.
Examples
>>> mech = CoreMechanical.from_las( ... "core_strength.las", ... ucs_mnemonic="UCS_1CM", ... vp_mnemonic="VP_5CM", ... vs_mnemonic="VS_5CM", ... ) >>> moduli = mech.dynamic_moduli(density_gcm3=2.55) >>> print(moduli["young_modulus"])
Attributes
Methods
Compute Poisson's ratio from Vp and Vs.
Compute dynamic elastic moduli from Vp, Vs, and bulk density.
Return a new CoreMechanical filtered to [top, bottom].
Create CoreMechanical from a pandas DataFrame.
Load mechanical properties from a LAS file.
Return a version of this object smoothed over a depth window.
Export to a pandas DataFrame.
Vp/Vs ratio — sensitive to fluid content and lithology.
- classmethod from_las(
- filepath,
- ucs_mnemonic='UCS',
- vp_mnemonic='VP',
- vs_mnemonic='VS',
- poisson_mnemonic=None,
- extra_ucs_mnemonics=None,
- null_value=-999.25,
Load mechanical properties from a LAS file.
Depth is read via
lasio’slas.indexproperty (always the first column, regardless of mnemonic name).- Parameters:
filepath (str or Path)
ucs_mnemonic (str) – Mnemonic for the primary UCS curve.
vp_mnemonic (str, optional) – Mnemonic for P-wave velocity (m/s).
vs_mnemonic (str, optional) – Mnemonic for S-wave velocity (m/s).
poisson_mnemonic (str, optional) – Mnemonic for dynamic Poisson’s ratio.
extra_ucs_mnemonics (dict, optional) – Additional UCS curves keyed by a label, e.g. {“5cm”: “UCS_5CM”, “30cm”: “UCS_30CM”}.
null_value (float) – LAS null value to replace with NaN.
- Return type:
- classmethod from_dataframe(
- df,
- depth_col='DEPTH',
- ucs_col='UCS',
- vp_col=None,
- vs_col=None,
- poisson_col=None,
- extra_ucs_cols=None,
Create CoreMechanical from a pandas DataFrame.
- dynamic_moduli(density_gcm3=2.65)[source]¶
Compute dynamic elastic moduli from Vp, Vs, and bulk density.
- Parameters:
density_gcm3 (float or np.ndarray) – Bulk density in g/cm³. Scalar or depth array. Use RHOB log interpolated to core depths for best results.
- Returns:
poisson_ratio Poisson’s ratio (dimensionless) shear_modulus Shear modulus G (GPa) young_modulus Young’s modulus E (GPa) bulk_modulus Bulk modulus K (GPa)
- Return type:
dict with keys
Notes
Equations (SI units, density in kg/m³, velocities in m/s):
\[ \begin{align}\begin{aligned}\nu = \frac{V_P^2 - 2V_S^2}{2(V_P^2 - V_S^2)}\\G = \rho V_S^2\\E = 2G(1 + \nu)\\K = \rho \left(V_P^2 - \frac{4}{3}V_S^2\right)\end{aligned}\end{align} \]
- computed_poisson()[source]¶
Compute Poisson’s ratio from Vp and Vs.
Use when the LAS file does not contain a Poisson’s ratio or when you want to check it; the loaded
poissonarray is left unchanged.- Return type:
- scale_average(window_m, step_m=None)[source]¶
Return a version of this object smoothed over a depth window.
- Parameters:
window_m (float) – Averaging window in depth units, metres for EpsLog data (e.g. 0.30 for 30 cm). Each output averages the samples within the window centred on its depth, so samples across a depth gap are not mixed in.
step_m (float, optional) – Output sample spacing in depth units. Defaults to the input depths.
- Returns:
New instance with smoothed arrays at the same or coarser spacing.
- Return type: