Source Types

General hierarchy

A gravitational lens can produce multiple images out of a single source. For this reason, Gravity.jl has two main objects types to deal with sources: Gravity.SingleSource, representing a single source, and Gravity.ImageFamily, representing a collection of images originating from the same source.

An Gravity.ImageFamily therefore is essentially a collection of Gravity.SingleSource's. However, for modeling reasons it is sometimes necessary to associate to a source its measurement uncertainties. A Gravity.SingleSource therefore can be either a Gravity.SingleExactSource, defined without measurement errors, or a Gravity.SingleImageMeasurement, that is a single source with its measurements errors included. The former is used to define lens models, the latter observations.

Both kind of sources, exact and measured ones, can be defined in several types. In the simplest situation, we have sources involving only position (astrometric) measurements: these are of the type Gravity.PointSource or Gravity.PointImageMeasurement. In other situations we might want to take into account the luminosity of a source (photometry): we have then a Gravity.LuminousImageMeasurement. In some cases, if the source is variable, we can also measure events appearing in the various images. The corresponding objects are the Gravity.TimeSource and the Gravity.TimeImageMeasurement. In a related case, we can measure time delays, that is, difference of the time-of-fly for different images. The associated objects are Gravity.TimeDelaySource and the Gravity.TimeDelayImageMeasurement. The latter is slightly more complicated, as it include possible correlations among the various time delays measurements. Finally, Gravity.LuminousTimeDelaySource and Gravity.LuminousTimeDelayImageMeasurement are sources that include both magnitudes and time-delays.

We could also have extended sources, where we store the luminosity of each pixel in a suitable grid (still TBD).

Finally, we collect set of sources at the same redshift in a Gravity.SourcePlane: this is the equivalent of a Gravity.LensPlane for sources and is mostly used to speed up cosmological calculations of the relevant angular diameter distances.

The hierarchy of sources is therefore the one described below in the next section.

Abstract types

Gravity.AbstractSourceType

Abstract type AbstractSource, the parent of all sources.

The class hierarchy is the following:

AbstractSource: any source or any combination of sources
├─ SingleSourceFamily: single source, or family of counter-images
│  ├─ SingleSource: single source with or without measurement errors
│  │  ├─ SingleExactSource: single source without measurement errors
│  │  │  ├─ AbstractPointlikeSource: abstract point-like source
│  │  │  │  ├─ PointSource: concrete point source, with only its position as datum
│  │  │  │  ├─ LuminousSource: luminous source, with position and magnitude as data
│  │  │  │  ├─ EllipticalSource: small luminous source with elliptical shape
│  │  │  │  ├─ TimeSource: variable source, with position and time as data
│  │  │  │  ├─ TimeDelaySource: variable source, with position and time delays
│  │  │  │  └─ LuminousTimeDelaySource: as above, with also magnitude
│  │  │  ├─ AbstractExtendedSource: abstract extended parametric source
│  │  │  │  ├─ SkyBackgroundSource: a "source" representing a sky background
│  │  │  │  ├─ CircularExtendedSource: extended source with circular profile
│  │  │  │  ├─ EllipticalExtendedSource: extended source with elliptical profile
│  │  │  │  ├─ CompositeExtendedSource: extended source made of multiple components
│  │  │  │  └─ VelocityExtendedSource: extended disk source, with parametrized
│  │  │  │                             surface brightness and velocity
│  │  │  ├─ AbstractLinearSource: source defined as linear combination of a basis
│  │  │  │  └─ PixeledSource: extended source parametrized by pixels on a grid
│  │  │  └─ AbstractExtendedImage: abstract non-parametric extended image w/o errors
│  │  │     ├─ ExtendedImage: extended image on a rectangular masked grid
│  │  │     ├─ ExtendedVelocity: extended velocity map
│  │  │     ├─ ExtendedLinearImage: extended image, resulting from a linear source
│  │  │     └─ PixeledImage: extended image, resulting from a pixeled source
│  │  └─ SingleImageMeasurement: single source, with measurement errors
│  │     ├─ AbstractPointlikeImageMeasurement: abstract point-like measurement
│  │     │  ├─ PointImageMeasurement: point image measurement with positional error
│  │     │  ├─ LuminousImageMeasurement: luminous image measurement
│  │     │  ├─ EllipticalImageMeasurement: small elliptical luminous image measurement
│  │     │  ├─ TimeImageMeasurement: point-like image with measured time-of-arrival
│  │     │  ├─ TimeDelayImageMeasurement: point-like image with measured time-delay
│  │     │  └─ LuminousTimeDelayImageMeasurement: as above, with also magnitude
│  │     └─ AbstractExtendedImageMeasurement: abstract extended image measurement
│  │        ├─ ExtendedImageMeasurement: extended image measurement used for parametric
│  │        │                            or non-parametric sources
│  │        └─ ExtendedVelocityMeasurement: extended velocity measurement for disk sources
│  └─ ImageFamily: family of images, i.e. the counter-images of a the same source;
│                  each member of the family is a SingleSource
└─ SourcePlane: set of sources or set of families of images located at the same redshift;
                each source of the plane is a SingleSourceFamily
source
Gravity.AbstractLinearSourceType

An abstract linear source.

This kind is the parent of extended sources which can be defined in terms of linear combination of basis functions.

These sources should defined the functions basis_length (to return the length of the basis), source_prior (the associated source prior), and the set_geometry (used to modify the source geometry and position, to accommodate different mapped locations on the source plane).

source