clifford.tools.omoh

clifford.tools.omoh(A: Frame | List[MultiVector], B: Frame | List[MultiVector]) ndarray[source]

Determines homogenization scaling for two Frames related by a Rotor

This is used as part of the orthoFrames2Versor() algorithm, when the frames are given in CGA. It is required because the model assumes, B = R*A*~R, but if data is given in the original space, only lambda*B' == homo(B) is observable.

We need to determine lambda before the Cartan-based algorithm can be used. The name of this function is the reverse of homo(), which is the method used to homogenize.

Parameters:
  • A (list of vectors, or clifford.Frame) – the set of vectors before the transform

  • B (list of vectors, or clifford.Frame) – the set of vectors after the transform, and homogenzation. ie B=B/(B|einf)

Returns:

out – weights on B, which produce inhomogeneous versions of B. If you multiply the input B by lam, it will fulfill B = R*A*~R

Return type:

array of floats

Examples

>>> lam = omoh(A, B)  
>>> B_ohom = Frame([B[k]*lam[k] for k in range(len(B)])