Template Function brille::utils::euclidean_angle

Function Documentation

template<class I, class T>
T brille::utils::euclidean_angle(const I n, const std::complex<T> *A, const std::complex<T> *B)

The general n-dimensional Euclidean angle between two complex-valued vectors.

Calculate and return the Euclidean angle between to vectors in a complex vector space Vᶜ(≃Cₙ, n∈N, n≥2) given by

cos(θᵣ) = <A,B>/|A||B|

where the real inner product of two complex vectors is performed in the real vector space Vʳ (≃R₂ₙ) isometric to Vᶜ.

Return

θᵣ

Parameters
  • n: The dimensionality of the complex vector space Vᶜ

  • A: A pointer to the first complex vector

  • B: A pointer to the second complex vector