You are on page 1of 1

import numpy as np

import matplotlib as plt


import math as math
a = np.array([[324,296,1],[386,176,1],[428,225,1]])
b = np.array([[56,296,1],[286,176,1],[114,225,1]])
c = np.array([[56,324,1],[286,386,1],[114,428,1]])
d = np.array([[56, 324,296],[286,386,176],[114,428,225]])
detA = np.linalg.det(a)
detB = np.linalg.det(b)*-1
detC = np.linalg.det(c)
detD = np.linalg.det(d)*-1
strike = np.arctan((-detB)/(detA))
strike_degree = strike*(180)/math.pi
dip = np.arctan(np.sqrt((detA**2+detB**2)/(detC**2)))
dip_degree = dip*(180)/math.pi
print (dip_degree)

strike = -49.23494329307587
dip = 31.329201303316808

You might also like