Fixed normal_vectors() and removed old pbc_diff

This commit is contained in:
Sebastian Kloth 2023-11-13 16:26:06 +01:00
parent a4c365c4a1
commit 57a492cb48
2 changed files with 0 additions and 15 deletions

View File

@ -565,7 +565,6 @@ def normal_vectors(
vec = np.cross(vectors_a, vectors_b)
if normed:
vec /= np.linalg.norm(vec, axis=-1).reshape(-1, 1)
vec.reference = coords_a
return vec

View File

@ -8,20 +8,6 @@ from itertools import product
from .logging import logger
def pbc_diff_old(v1, v2, box):
"""
Calculate the difference of two vestors, considering optional boundary conditions.
"""
if box is None:
v = v1 - v2
else:
v = v1 % box - v2 % box
v -= (v > box / 2) * box
v += (v < -box / 2) * box
return v
def pbc_diff(v1, v2=None, box=None):
if box is None:
out = v1 - v2