Class/Object

com.sparkcorr.Tiling

SARSPix

Related Docs: object SARSPix | package Tiling

Permalink

class SARSPix extends CubedSphere

The SimilAr Radius Sphere pixelization

based on this paper (also available in the doc directory). This is not the full construction but the one described at the very beginning of section 3.3.

It relies on the projection of the faces of an inscribed cube that are further subdivided into 4 quadrants. Althought not having exact same areas pixels have quite compact inner and outer radii (see note).

The face numbering convention is the following :

The quadrant numbering convention (on face 0) is

| 2 | 0 |
|---|---|
| 3 | 1 |

There are 6 Nbase2 pixels per face and 6 Nbase2 pixels on the entire sphere

Author:

Stephane Plaszczynski

Example:
  1. val c=new SARSPix(10)
    for (ipix<-c.pixNums) {
        val Array(theta,phi)=c.pix2ang(ipix)
        val ipixb=c.ang2pix(theta,phi)
        require(ipix==ipixb)
    }
Note

https://arxiv.org/abs/2012.08455

Linear Supertypes
CubedSphere, Serializable, SphereTiling, AnyRef, Any
Type Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. SARSPix
  2. CubedSphere
  3. Serializable
  4. SphereTiling
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new SARSPix(nbase: Int)

    Permalink

    creates SARSpix tiling with resolution nbase

    creates SARSpix tiling with resolution nbase

    nbase

    Number of points on one face in one dimension (even number)

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val N: Int

    Permalink

    shorthand for Nbase

    shorthand for Nbase

    Attributes
    protected
    Definition Classes
    CubedSphere
  5. val Nbase: Int

    Permalink

    Number of points on a face in one dimension (even number).

    Number of points on a face in one dimension (even number).

    Definition Classes
    CubedSphereSphereTiling
  6. val Npix: Long

    Permalink

    number of pixels

    number of pixels

    Definition Classes
    CubedSphereSphereTiling
  7. def ang2LocalIndex(face: Int, theta: Double, phi: Double): (Int, Int)

    Permalink

    given face and angles returns the local index

    given face and angles returns the local index

    Definition Classes
    CubedSphere
  8. def ang2pix(theta: Double, phi: Double): Int

    Permalink

    pixel index from angles on the sphere

    pixel index from angles on the sphere

    theta

    colatitude (0<theta<Pi)

    phi

    azimuth (0<phi<2Pi)

    returns

    pixel index

    Definition Classes
    SARSPixCubedSphereSphereTiling
  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. def coord2pix(f: Int, i: Int, j: Int): Int

    Permalink

    transformation from local CubedSphere coordinates to pixel number

    transformation from local CubedSphere coordinates to pixel number

    Definition Classes
    CubedSphere
  12. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  14. def face2localBinIndex(I: Int, J: Int): (Int, Int, Int)

    Permalink

    convert face (I,J) coordinates to local (q,i,j) ones for bin numbers

  15. def face2localNodeIndex(I: Int, J: Int): (Int, Int, Int)

    Permalink

    convert face (I,J) coordinates to local (q,i,j) ones for nodes numbers

  16. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  17. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  18. def getFace(p: Point3D): Int

    Permalink

    get face number from Point on the sphere

    get face number from Point on the sphere

    Definition Classes
    CubedSphere
  19. def getFace(theta: Double, phi: Double): Int

    Permalink

    get face number from angles

    get face number from angles

    Definition Classes
    CubedSphere
  20. def getFaceQuadrant(p: Point3D): (Int, Int)

    Permalink

    get face and quadrant numbers for point p

  21. def getLocalIndex(p: Point3D): (Int, Int, Int, Int)

    Permalink

    get local coordinates (f,q,i,j) for point p

  22. def getQuadrant(face: Int, p: Point3D): Int

    Permalink

    get quadrant number from point p and face

  23. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  24. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  25. def isValidPix(ipix: Int): Boolean

    Permalink

    check pixel number is valid

    check pixel number is valid

    Definition Classes
    CubedSphere
  26. def local2faceBinIndex(q: Int, i: Int, j: Int): (Int, Int)

    Permalink

    convert local (q,i,j) coordinates to face ones (I,J) for bin numbers

  27. def local2faceNodeIndex(q: Int, i: Int, j: Int): (Int, Int)

    Permalink

    convert local (q,i,j) coordinates to face ones (I,J) for nodes

  28. val maxIndex: Long

    Permalink

    Largest possible index of the pixelization .

    Largest possible index of the pixelization . Do not use to access data. use CubedSphere.pixNums instead

    Definition Classes
    CubedSphere
  29. val nbase: Int

    Permalink

    Number of points on one face in one dimension (even number)

  30. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  31. def neighbours(ipix: Int): Array[Int]

    Permalink

    List of neighbour indices

    List of neighbour indices

    ipix

    pixel index

    returns

    Array of pixel indices (variable size)

    Definition Classes
    CubedSphereSphereTiling
  32. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  33. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  34. def pix2ang(ipix: Int): Array[Double]

    Permalink

    pixel center angles for a given index

    pixel center angles for a given index

    ipix

    pixel index

    returns

    size 2 Array of angles [theta,phi] (see header for conventions)

    Definition Classes
    SARSPixCubedSphereSphereTiling
  35. def pix2coord(ipix: Int): (Int, Int, Int)

    Permalink

    transformation from pixel number to local coordinates

    transformation from pixel number to local coordinates

    Definition Classes
    CubedSphere
  36. def pixNums: IndexedSeq[Int]

    Permalink

    list of valid pixel indices for this pixelization (do not assume it is contiguous)

    list of valid pixel indices for this pixelization (do not assume it is contiguous)

    returns

    an indexedseq of indices

    Definition Classes
    CubedSphereSphereTiling
  37. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  38. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  39. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  41. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  42. def writeCenters(fn: String): Unit

    Permalink

    output pixel centers into file

    output pixel centers into file

    fn

    filename

    Definition Classes
    CubedSphere
  43. def writeNeighbours(ipix: Int): Unit

    Permalink

    given a pixel number write all neigbour indices into a file named "neighbours.txt"

    given a pixel number write all neigbour indices into a file named "neighbours.txt"

    Definition Classes
    CubedSphere

Deprecated Value Members

  1. def neighbours8(ipix: Int): Array[Int]

    Permalink

    automatic translation to 8 neighbouring indices putting -1 if there is less.

    automatic translation to 8 neighbouring indices putting -1 if there is less.

    undefined behaviour if more than 8

    Definition Classes
    SphereTiling
    Deprecated

Inherited from CubedSphere

Inherited from Serializable

Inherited from SphereTiling

Inherited from AnyRef

Inherited from Any

Ungrouped