Distances

Atsushi Yamaji

The purpose of this program is to compute the angular stress distances between reduced stress tensors. This program was developed in MATLAB (R2023a), and to use it, you need an environment to run MATLAB programs.

This program package consists of the following files:

main.m (main program)
axesPhi2veca.m
azpl2spherical.m
spherical2uvec.m
Uvecs_and_Phi2Sigmavec.m
sample_data.csv
readme.txt

INSTORATION

Download distances.zip and expand it in a folder.
Store all the files in one folder.

DATA FILE

Make a data file with a CSV format which this program can read. The file has the list of reduced stress tensors, for which the angular stress distances are computed. Each of the tensors are denoted by the sigma1- and sigma3-orientations and a stress ratio. Each row of the list is composed of
azimuth of the sigma1-orientation
plunge of the sigma1-orientation
azimuth of the sigma3-orientation
plunge of the sigma3-orientation
stress ratio
which are separated by commas. The file, sample_data.csv, is an example (Fig. 1).

Fig. 1. The content of 'sample_data.csv.' Six tensors are written in this file.


EXECUTION

When you launch the main program (Fig. 2), a dialog box will appear for you to select a CSV data file, so choose a file.

Fig. 2. Console window


The sigma1- and sigma3-orientations should be perpendicular to each other. Since the orientations in a data file have errors to some extent, they usually meet an angle near 90 degrees. The program displays the angles in the console window. Data with the angles smaller than, e.g., 85 degrees or greater than, e.g., 95 degrees should be regarded to be inaccurate. Irrespectively of such inaccuracy, the orienations are orthogonalized in the subprogram, axesPhi2veca.m, to compute angular stress distances.

The program outputs two CSV format files, Thetas.csv and 5d_uvecs.csv, both of which are stored in the folder that 'main.m' is contained. Note that if those files already exist, they are renewed. 'Thetas.csv' contains the list of angular stress distances between the reduced stress tensors written in the data file (Fig. 3). This list consists N rows and N columns, where N is the number of the tensors. The distance between the i-th and j-th tensors is stored in the ij-th entry of this list. The diagonal cells of this list are filled with 'NaN.' The i-th row of the list in '5d_uvecs.csv' denotes the five components of the five-dimensional unit vector corresponding to the i-th stress condition in the input file (Fig. 4), where the tensors are transformed to such vectors through the first equation of the following paper.

Yamaji & Sato (2020) Errata to "Stress inversion meets plasticity theory: A review of the theories of fault-slip analysis from the perspective of the deviatoric stress-strain space" [J. Struct. Geol. 125, 296–310]. Journal of Structural Geology, 134, 104025, https://doi.org/10.1016/j.jsg.2020.104025 .

Fig. 3. Angular stress distances of the six stresses in Fig. 1.

Fig. 4. The components of the five-dimensional unit vectors corresponding to the six tensors in Fig. 1.