The SKIRT project
advanced radiative transfer for astrophysics
Public Member Functions | Protected Member Functions | Private Types | Private Attributes | Friends | List of all members
ParallelProjectionForm Class Reference

#include <ParallelProjectionForm.hpp>

Inheritance diagram for ParallelProjectionForm:
Inheritance graph
[legend]

Public Member Functions

double azimuth () const
 
double centerX () const
 
double centerY () const
 
double fieldOfViewX () const
 
double fieldOfViewY () const
 
double inclination () const
 
int numPixelsX () const
 
int numPixelsY () const
 
int numSampling () const
 
double roll () const
 
void writeQuantity (const ProbeFormBridge *bridge) const override
 
virtual void writeQuantity (const ProbeFormBridge *bridge) const =0
 
- Public Member Functions inherited from SimulationItem
template<class T >
T * find (bool setup=true) const
 
template<class T >
T * interface (int levels=-999999, bool setup=true) const
 
virtual string itemName () const
 
void setup ()
 
string typeAndName () const
 
- Public Member Functions inherited from Item
 Item (const Item &)=delete
 
virtual ~Item ()
 
void addChild (Item *child)
 
const vector< Item * > & children () const
 
virtual void clearItemListProperty (const PropertyDef *property)
 
void destroyChild (Item *child)
 
virtual bool getBoolProperty (const PropertyDef *property) const
 
virtual vector< double > getDoubleListProperty (const PropertyDef *property) const
 
virtual double getDoubleProperty (const PropertyDef *property) const
 
virtual string getEnumProperty (const PropertyDef *property) const
 
virtual int getIntProperty (const PropertyDef *property) const
 
virtual vector< Item * > getItemListProperty (const PropertyDef *property) const
 
virtual ItemgetItemProperty (const PropertyDef *property) const
 
virtual string getStringProperty (const PropertyDef *property) const
 
int getUtilityProperty (string name) const
 
virtual void insertIntoItemListProperty (const PropertyDef *property, int index, Item *item)
 
Itemoperator= (const Item &)=delete
 
Itemparent () const
 
virtual void removeFromItemListProperty (const PropertyDef *property, int index)
 
virtual void setBoolProperty (const PropertyDef *property, bool value)
 
virtual void setDoubleListProperty (const PropertyDef *property, vector< double > value)
 
virtual void setDoubleProperty (const PropertyDef *property, double value)
 
virtual void setEnumProperty (const PropertyDef *property, string value)
 
virtual void setIntProperty (const PropertyDef *property, int value)
 
virtual void setItemProperty (const PropertyDef *property, Item *item)
 
virtual void setStringProperty (const PropertyDef *property, string value)
 
void setUtilityProperty (string name, int value)
 
virtual string type () const
 

Protected Member Functions

 ParallelProjectionForm ()
 
- Protected Member Functions inherited from GenericForm
 GenericForm ()
 
- Protected Member Functions inherited from Form
 Form ()
 
- Protected Member Functions inherited from SimulationItem
 SimulationItem ()
 
virtual bool offersInterface (const std::type_info &interfaceTypeInfo) const
 
virtual void setupSelfAfter ()
 
virtual void setupSelfBefore ()
 
- Protected Member Functions inherited from Item
 Item ()
 

Private Types

using BaseType = GenericForm
 
using ItemType = ParallelProjectionForm
 

Private Attributes

double _azimuth
 
double _centerX
 
double _centerY
 
double _fieldOfViewX
 
double _fieldOfViewY
 
double _inclination
 
int _numPixelsX
 
int _numPixelsY
 
int _numSampling
 
double _roll
 

Friends

class ItemRegistry
 

Detailed Description

ParallelProjectionForm represents a generic probe form. Refer to the ProbeFormBridge class for more information about probes and forms.

This particular form outputs a FITS file representing a projection of the quantity being probed on a plane along a given line of sight. The projection plane is considered to lie well outside of the model. The viewing angle, field of view and pixel resolution are configured in the same way as for a FrameInstrument so that it is easy to obtain a projection matching the position of an instrument.

The FITS file contains a number of image frames corresponding to the number of components in a value of the quantity being probed (i.e. 1 for scalar quantities, 3 for vector quantities, and N for compound quantities). In case of a vector quantity, the three image frames represent the velocity vector components in the frame of the projection, i.e. the two components projected on the x and y axes of the projection plane and the component perpendicular to it, where positive values indicate vectors pointing away from the viewer.

For each pixel of the output array, the class subdivides the pixel into \( N \times N\) regularly positioned subpixels, where \(N\) is the user-supplied oversampling rate. For each of these \(N^2\) subpixels, a ray is sent through the model, calculating the projection by accumulating information along that ray. At the end, the algorithm averages the result of these \(N^2\) calclulations. Higher oversampling rates correspond to higher accuracy, but also increased compuational cost.

This item type is displayed only if the Boolean expression "Level2" evaluates to true after replacing the names by true or false depending on their presence.

Constructor & Destructor Documentation

◆ ParallelProjectionForm()

ParallelProjectionForm::ParallelProjectionForm ( )
inlineprotected

Default constructor for concrete Item subclass ParallelProjectionForm : "parallel projection on a distant plane" .

Member Function Documentation

◆ azimuth()

ParallelProjectionForm::azimuth ( ) const
inline

This function returns the value of the discoverable double property azimuth : "the azimuth angle φ of the projection" .

This property represents a physical quantity of type "posangle" .

The minimum value for this property is "-360 deg" .

The maximum value for this property is "360 deg" .

The default value for this property is given by the conditional value expression "0 deg" .

This property is displayed only if the Boolean expression "Dimension3" evaluates to true after replacing the names by true or false depending on their presence.

◆ centerX()

ParallelProjectionForm::centerX ( ) const
inline

This function returns the value of the discoverable double property centerX : "the center of the frame in the horizontal direction" .

This property represents a physical quantity of type "length" .

The default value for this property is given by the conditional value expression "0" .

This property is displayed only if the Boolean expression "Level2" evaluates to true after replacing the names by true or false depending on their presence.

◆ centerY()

ParallelProjectionForm::centerY ( ) const
inline

This function returns the value of the discoverable double property centerY : "the center of the frame in the vertical direction" .

This property represents a physical quantity of type "length" .

The default value for this property is given by the conditional value expression "0" .

This property is displayed only if the Boolean expression "Level2" evaluates to true after replacing the names by true or false depending on their presence.

◆ fieldOfViewX()

ParallelProjectionForm::fieldOfViewX ( ) const
inline

This function returns the value of the discoverable double property fieldOfViewX : "the total field of view in the horizontal direction" .

This property represents a physical quantity of type "length" .

The minimum value for this property is "]0" .

◆ fieldOfViewY()

ParallelProjectionForm::fieldOfViewY ( ) const
inline

This function returns the value of the discoverable double property fieldOfViewY : "the total field of view in the vertical direction" .

This property represents a physical quantity of type "length" .

The minimum value for this property is "]0" .

◆ inclination()

ParallelProjectionForm::inclination ( ) const
inline

This function returns the value of the discoverable double property inclination : "the inclination angle θ of the projection" .

This property represents a physical quantity of type "posangle" .

The minimum value for this property is "0 deg" .

The maximum value for this property is "180 deg" .

The default value for this property is given by the conditional value expression "0 deg" .

This property is displayed only if the Boolean expression "Dimension2|Dimension3" evaluates to true after replacing the names by true or false depending on their presence.

◆ numPixelsX()

ParallelProjectionForm::numPixelsX ( ) const
inline

This function returns the value of the discoverable integer property numPixelsX : "the number of pixels in the horizontal direction" .

The minimum value for this property is "1" .

The maximum value for this property is "10000" .

The default value for this property is given by the conditional value expression "250" .

◆ numPixelsY()

ParallelProjectionForm::numPixelsY ( ) const
inline

This function returns the value of the discoverable integer property numPixelsY : "the number of pixels in the vertical direction" .

The minimum value for this property is "1" .

The maximum value for this property is "10000" .

The default value for this property is given by the conditional value expression "250" .

◆ numSampling()

ParallelProjectionForm::numSampling ( ) const
inline

This function returns the value of the discoverable integer property numSampling : "the oversampling rate in each direction" .

The minimum value for this property is "1" .

The maximum value for this property is "9" .

The default value for this property is given by the conditional value expression "1" .

◆ roll()

ParallelProjectionForm::roll ( ) const
inline

This function returns the value of the discoverable double property roll : "the roll angle ω of the projection" .

This property represents a physical quantity of type "posangle" .

The minimum value for this property is "-360 deg" .

The maximum value for this property is "360 deg" .

The default value for this property is given by the conditional value expression "0 deg" .

This property is displayed only if the Boolean expression "Level2&(Dimension2|Dimension3)" evaluates to true after replacing the names by true or false depending on their presence.

◆ writeQuantity()

void ParallelProjectionForm::writeQuantity ( const ProbeFormBridge bridge) const
overridevirtual

This function causes the form to output file(s) as described in the class header for the quantity being probed according to the information provided by the specified ProbeFormBridge instance.

Implements Form.


The documentation for this class was generated from the following file: