PoreMS 0.2
  • API
  • Process
  • Molecule
  • Pore
  • Workflow
  • Site
    • Page
        • Sphere.normal

    Sphere.normal¶

    Sphere.normal(self, pos)¶

    Calculate unit normal vector on surface for a given position

    \[\begin{split}\frac{\partial\Phi}{\partial\theta}(r,\phi,\theta)\times \frac{\partial\Phi}{\partial\phi}(r,\phi,\theta)= \begin{bmatrix} -r^2\cos(\phi)\sin(\theta)^2\\ r^2\sin(\phi)\sin(\theta)^2\\ -r^2\sin(\theta)\cos(\theta)\left[\sin(\phi)^2-\cos(\phi)^2\right]\\ \end{bmatrix}\end{split}\]

    with radius \(r\), polar angle \(\phi\) and cylinder length \(z\).

    Parameters:
    pos : list

    Position

    Returns:
    normal : list

    Normal vector

    Back to top

    © Copyright 2021, Hamzeh Kraus.
    Created using Sphinx 1.6.6.