37 TagType type{TagType::FINAL};
41 Species cia_2nd_species{Species::FINAL};
45 Index cia_dataset_index{-1};
47 constexpr Tag()
noexcept =
default;
58 [[nodiscard]]
String Name()
const;
64 ARTS_ASSERT(ind < 0,
"Bad species extracted from: ", ir)
68 [[nodiscard]]
constexpr Numeric Mass()
const noexcept {
return Isotopologue().mass;}
74 [[nodiscard]]
String FullName()
const noexcept {
return Isotopologue().FullName();}
76 [[nodiscard]]
constexpr Species Spec()
const noexcept {
return Isotopologue().spec;}
78 [[nodiscard]]
constexpr TagType Type()
const noexcept {
return type;}
80 friend std::ostream&
operator<<(std::ostream& os,
const Tag& ot) {
return os << ot.Name();}
82 constexpr bool operator==(
const Tag& other)
const noexcept {
83 return other.spec_ind == spec_ind and
84 other.lower_freq == lower_freq and
85 other.upper_freq == upper_freq and
86 other.type == type and
87 other.cia_2nd_species == cia_2nd_species and
88 other.cia_dataset_index == cia_dataset_index;
91 constexpr bool operator!=(
const Tag& other)
const noexcept {
114 std::fill(this->begin(), this->
end(), x);
118 this->resize(A.size());
119 std::copy(A.begin(), A.end(), this->begin());
131 for (
auto& x: ot) {
if (not first) os <<
' ';
else first =
false; os << x;}
137 ARTS_ASSERT(size() not_eq 0,
"Invalid ArrayOfSpeciesTag without any species")
143 ARTS_ASSERT(size() not_eq 0,
"Invalid ArrayOfSpeciesTag without any species")
144 return operator[](0).Type();
147 [[nodiscard]]
String Name() const;
149 [[nodiscard]]
bool Plain() const noexcept {
150 return std::any_of(cbegin(), cend(), [](
auto& spec){
return spec.Type() == Species::TagType::Plain;});
153 [[nodiscard]]
bool Zeeman() const noexcept {
154 return std::any_of(cbegin(), cend(), [](
auto& spec){
return spec.Type() == Species::TagType::Zeeman;});
157 [[nodiscard]]
bool RequireLines() const noexcept {
158 return Plain() or
Zeeman();
161 [[nodiscard]]
bool FreeElectrons() const noexcept {
162 return std::any_of(cbegin(), cend(), [](
auto& spec){
return spec.Type() == Species::TagType::FreeElectrons;});
165 [[nodiscard]]
bool Particles() const noexcept {
166 return std::any_of(cbegin(), cend(), [](
auto& spec){
return spec.Type() == Species::TagType::Particles;});
std::ostream & operator<<(std::ostream &os, const ArrayOfAbsorptionLines &aol)
This file contains the definition of Array.
ArrayOfSpeciesTag() noexcept
ArrayOfSpeciesTag(ArrayOfSpeciesTag &&A) noexcept
ArrayOfSpeciesTag & operator=(SpeciesTag x)
ArrayOfSpeciesTag & operator=(ArrayOfSpeciesTag &&A) noexcept
friend std::ostream & operator<<(std::ostream &os, const ArrayOfSpeciesTag &ot)
ArrayOfSpeciesTag(const ArrayOfSpeciesTag &A)=default
Species::Species Species() const ARTS_NOEXCEPT
ArrayOfSpeciesTag(Index n, const SpeciesTag &fillvalue)
ArrayOfSpeciesTag(std::vector< SpeciesTag > x)
ArrayOfSpeciesTag & operator=(const ArrayOfSpeciesTag &A)
ArrayOfSpeciesTag(Index n)
This can be used to make arrays out of anything.
const SpeciesTag & operator[](const Index n) const
Constant index operator.
Array & operator=(base x)
Assignment from base type (fill entire Array with this value).
#define ARTS_ASSERT(condition,...)
Implementation of Matrix, Vector, and such stuff.
NUMERIC Numeric
The type to use for all floating point numbers.
INDEX Index
The type to use for all integer numbers and indices.
void copy(ConstComplexIterator1D origin, const ConstComplexIterator1D &end, ComplexIterator1D target)
Copy data between begin and end to target.
This file contains the definition of String, the ARTS string class.
constexpr Numeric dQdT(Numeric T, const Species::IsotopeRecord &ir)
constexpr Numeric Q(Numeric T, const Species::IsotopeRecord &ir)
VectorView std(VectorView std, const Vector &y, const ArrayOfVector &ys, const Index start, const Index end_tmp)
Compute the standard deviation of the ranged ys.
ENUMCLASS(TagType, unsigned char, Plain, Zeeman, PredefinedLegacy, PredefinedModern, Cia, FreeElectrons, Particles, HitranXsec, NoLines) struct Tag
constexpr bool is_predefined_model(const IsotopeRecord &ir) noexcept
constexpr std::array Isotopologues
A list of all ARTS isotopologues, note how the species enum class input HAS to be sorted.
Numeric first_vmr(const ArrayOfArrayOfSpeciesTag &abs_species, const Vector &rtp_vmr, const Species spec) ARTS_NOEXCEPT
constexpr Index find_species_index(const Species spec, const std::string_view isot) noexcept
Implements Zeeman modeling.
constexpr Rational end(Rational Ju, Rational Jl, Polarization type) noexcept
Gives the largest M for a polarization type of this transition.
constexpr bool operator!=(const Rational a, const Rational b) noexcept
Inequality.
constexpr bool operator==(const Rational a, const Rational b) noexcept
Equality.
Struct containing all information needed about one isotope.