BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
Profile2DVoigtItem Class Reference

Description

Definition at line 129 of file ProfileItems.h.

Inheritance diagram for Profile2DVoigtItem:
[legend]
Collaboration diagram for Profile2DVoigtItem:
[legend]

Public Member Functions

 Profile2DVoigtItem ()
 
std::unique_ptr< IProfile2D > createProfile () const override
 
DoubleDescriptor eta () const
 
DoubleDescriptor gamma () const
 
DoubleDescriptor omegaX () const
 
DoubleDescriptor omegaY () const
 
void serialize (Streamer &s) override
 
void setEta (double eta)
 
void setGamma (double gamma)
 
void setOmegaX (double omega_x)
 
void setOmegaY (double omega_y)
 
DoubleDescriptors valueDescriptors () const override
 

Protected Attributes

DoubleProperty m_gamma
 
DoubleProperty m_omegaX
 
DoubleProperty m_omegaY
 

Private Attributes

DoubleProperty m_eta
 

Constructor & Destructor Documentation

◆ Profile2DVoigtItem()

Profile2DVoigtItem::Profile2DVoigtItem ( )

Definition at line 192 of file ProfileItems.cpp.

193 {
194  m_eta.init("Eta", "Parameter [0,1] to balance between Cauchy (eta=0.0) and Gauss (eta=1.0)",
195  0.5, Unit::unitless, 3, RealLimits::limited(0.0, 1.0), "eta");
196 }
@ unitless
void init(const QString &label, const QString &tooltip, double value, const variant< QString, Unit > &unit, const QString &persistentTag)
DoubleProperty m_eta
Definition: ProfileItems.h:141

References DoubleProperty::init(), m_eta, and unitless.

Here is the call graph for this function:

Member Function Documentation

◆ createProfile()

std::unique_ptr< IProfile2D > Profile2DVoigtItem::createProfile ( ) const
overridevirtual

Implements Profile2DItem.

Definition at line 198 of file ProfileItems.cpp.

199 {
200  return std::make_unique<Profile2DVoigt>(omegaX(), omegaY(), Units::deg2rad(gamma()), m_eta);
201 }
DoubleDescriptor omegaX() const
DoubleDescriptor gamma() const
DoubleDescriptor omegaY() const

References Profile2DItem::gamma(), m_eta, Profile2DItem::omegaX(), and Profile2DItem::omegaY().

Here is the call graph for this function:

◆ eta()

DoubleDescriptor Profile2DVoigtItem::eta ( ) const

Definition at line 212 of file ProfileItems.cpp.

213 {
214  return m_eta;
215 }

References m_eta.

Referenced by setEta(), and valueDescriptors().

◆ gamma()

◆ omegaX()

◆ omegaY()

◆ serialize()

void Profile2DVoigtItem::serialize ( Streamer s)
overridevirtual

Reimplemented from Profile2DItem.

Definition at line 203 of file ProfileItems.cpp.

204 {
205  s.assertVersion(0);
210 }
void assertVersion(unsigned expectedVersion) const
As reader, throws DeserializationException unless the expected version is read. As writer,...
Definition: Streamer.cpp:26
void rwProperty(Streamer &s, DoubleProperty &d)

References Streamer::assertVersion(), m_eta, Profile2DItem::m_gamma, Profile2DItem::m_omegaX, Profile2DItem::m_omegaY, and Serialize::rwProperty().

Here is the call graph for this function:

◆ setEta()

void Profile2DVoigtItem::setEta ( double  eta)

Definition at line 217 of file ProfileItems.cpp.

218 {
219  m_eta.set(eta);
220 }
void set(double d)
Set the contained value.
DoubleDescriptor eta() const

References eta(), m_eta, and DoubleProperty::set().

Here is the call graph for this function:

◆ setGamma()

void Profile2DItem::setGamma ( double  gamma)
inherited

Definition at line 152 of file ProfileItems.cpp.

153 {
154  m_gamma.set(gamma);
155 }

References Profile2DItem::gamma(), Profile2DItem::m_gamma, and DoubleProperty::set().

Here is the call graph for this function:

◆ setOmegaX()

void Profile2DItem::setOmegaX ( double  omega_x)
inherited

Definition at line 132 of file ProfileItems.cpp.

133 {
134  m_omegaX.set(omega_x);
135 }

References Profile2DItem::m_omegaX, and DoubleProperty::set().

Here is the call graph for this function:

◆ setOmegaY()

void Profile2DItem::setOmegaY ( double  omega_y)
inherited

Definition at line 142 of file ProfileItems.cpp.

143 {
144  m_omegaY.set(omega_y);
145 }

References Profile2DItem::m_omegaY, and DoubleProperty::set().

Here is the call graph for this function:

◆ valueDescriptors()

DoubleDescriptors Profile2DVoigtItem::valueDescriptors ( ) const
overridevirtual

Reimplemented from Profile2DItem.

Definition at line 222 of file ProfileItems.cpp.

223 {
224  return {omegaX(), omegaY(), eta(), gamma()};
225 }

References eta(), Profile2DItem::gamma(), Profile2DItem::omegaX(), and Profile2DItem::omegaY().

Here is the call graph for this function:

Member Data Documentation

◆ m_eta

DoubleProperty Profile2DVoigtItem::m_eta
private

Definition at line 141 of file ProfileItems.h.

Referenced by Profile2DVoigtItem(), createProfile(), eta(), serialize(), and setEta().

◆ m_gamma

DoubleProperty Profile2DItem::m_gamma
protectedinherited

◆ m_omegaX

DoubleProperty Profile2DItem::m_omegaX
protectedinherited

◆ m_omegaY

DoubleProperty Profile2DItem::m_omegaY
protectedinherited

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