(theta, full)
return n, ct, st, rmat
Returns the theta dim, cos and sin, and blank matrix for axis rotation.
Returns the theta dim, cos and sin, and blank matrix for axis rotation.
Returns the theta dim cos and sin and blank matrix for axis rotation .
def _axis_rotation(theta, full):
  """Returns the theta dim, cos and sin, and blank matrix for axis rotation."""
  n = 1 if np.isscalar(theta) else len(theta)
  ct = np.cos(theta)
  st = np.sin(theta)

  if full:
    rmat = np.zeros((n, 4, 4))
    rmat[:, 3, 3] = 1.
  else:
    rmat = np.zeros((n, 3, 3))

  return n, ct, st, rmat
def _axis_rotation ( theta , full ) : n = 1 if np . isscalar ( theta ) else len ( theta ) ct = np . cos ( theta ) st = np . sin ( theta ) if full : rmat = np . zeros ( ( n , 4 , 4 ) ) rmat [ : , 3 , 3 ] = 1. else : rmat = np . zeros ( ( n , 3 , 3 ) ) return n , ct , st , rmat