Files
MeanField_SERiF/docs/man/man3/serif_equations_EquationDifference.3

135 lines
4.2 KiB
Groff
Raw Normal View History

.TH "serif::equations::EquationDifference< LeftT, RightT >" 3 "Version v0.0.1a" "SERiF" \" -*- nroff -*-
.ad l
.nh
.SH NAME
serif::equations::EquationDifference< LeftT, RightT > \- Subtract one equation from another\&.
.SH SYNOPSIS
.br
.PP
.PP
\fR#include <arithmetic\&.hpp>\fP
.SS "Public Types"
.in +1c
.ti -1c
.RI "using \fBTest\fP = typename LeftT::Test"
.br
.RI "The test type of the difference equation is the same as the test type of the left equation\&. "
.in -1c
.SS "Public Member Functions"
.in +1c
.ti -1c
.RI "\fBEquationDifference\fP (LeftT left, RightT right)"
.br
.RI "Construct a difference equation\&. "
.ti -1c
.RI "const auto & \fBcontributions\fP () const noexcept"
.br
.RI "Return the contributions of the difference equation\&. "
.in -1c
.SS "Static Public Attributes"
.in +1c
.ti -1c
.RI "static constexpr std::string_view \fBname\fP = 'equation difference'"
.br
.RI "Compile time name for the difference equation, used for debugging and logging\&. "
.in -1c
.SS "Private Attributes"
.in +1c
.ti -1c
.RI "\fBEquationSum\fP< LeftT, \fBEquationScale\fP< RightT > > \fBm_equation\fP"
.br
.RI "The equation representing the difference, which is a sum of the left equation and the scaled right equation (scaled by -1)\&. "
.in -1c
.SH "Detailed Description"
.PP
.SS "template<Equation LeftT, Equation RightT>
.br
requires std::same_as<typename LeftT::Test, typename RightT::Test>
.br
class serif::equations::EquationDifference< LeftT, RightT >"Subtract one equation from another\&.
This class is a compile-time tag that indicates that the weak contributions from the right equation should be subtracted from the weak contributions of the left equation\&. The actual subtraction is performed by the backend\&. A simple example would be if the left equation has a weak contribution of 1 and the right equation has a weak contribution of 2, then the final residual would be -1\&.
.PP
Requirements
.PD 0
.IP "\(bu" 2
The left and right equations must share the same test type, otherwise the subtraction is not well-defined\&.
.PP
.PP
\fBEquation\fP \fBContributions\fP
.PD 0
.IP "\(bu" 2
Residuals to all rows which are shared by the summed equations
.PP
.PP
\fBNote\fP
.RS 4
Only equations sharing a residual row can or should be subtracted from one another\&.
.RE
.PP
\fBTemplate Parameters\fP
.RS 4
\fILeftT\fP The left equation type to subtract from\&.
.br
\fIRightT\fP The right equation type to subtract\&.
.RE
.PP
.SH "Member Typedef Documentation"
.PP
.SS "template<Equation LeftT, Equation RightT> using \fBserif::equations::EquationDifference\fP< LeftT, RightT >::Test = typename LeftT::Test"
.PP
The test type of the difference equation is the same as the test type of the left equation\&.
.SH "Constructor & Destructor Documentation"
.PP
.SS "template<Equation LeftT, Equation RightT> \fBserif::equations::EquationDifference\fP< LeftT, RightT >::EquationDifference (LeftT left, RightT right)\fR [inline]\fP, \fR [explicit]\fP"
.PP
Construct a difference equation\&.
.PP
\fBParameters\fP
.RS 4
\fIleft\fP The left equation to subtract from\&.
.br
\fIright\fP The right equation to subtract\&.
.RE
.PP
.SH "Member Function Documentation"
.PP
.SS "template<Equation LeftT, Equation RightT> const auto & \fBserif::equations::EquationDifference\fP< LeftT, RightT >::contributions () const\fR [inline]\fP, \fR [nodiscard]\fP, \fR [noexcept]\fP"
.PP
Return the contributions of the difference equation\&.
.PP
\fBReturns\fP
.RS 4
A tuple containing the contributions of the difference equation\&.
.RE
.PP
.SH "Member Data Documentation"
.PP
.SS "template<Equation LeftT, Equation RightT> \fBEquationSum\fP<LeftT, \fBEquationScale\fP<RightT> > \fBserif::equations::EquationDifference\fP< LeftT, RightT >::m_equation\fR [private]\fP"
.PP
The equation representing the difference, which is a sum of the left equation and the scaled right equation (scaled by -1)\&.
.SS "template<Equation LeftT, Equation RightT> std::string_view \fBserif::equations::EquationDifference\fP< LeftT, RightT >::name = 'equation difference'\fR [static]\fP, \fR [constexpr]\fP"
.PP
Compile time name for the difference equation, used for debugging and logging\&.
.SH "Author"
.PP
Generated automatically by Doxygen for SERiF from the source code\&.