Uni20
Asynchronous tensor and runtime library.
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | List of all members
uni20::log_gamma_context< R > Class Template Reference

Immutable reusable right-half-plane log-Gamma and real-shift log-ratio context. More...

#include <complex_log_gamma.hpp>

Public Types

using complex_type = complex< R >
 

Public Member Functions

 log_gamma_context (log_gamma_options options={})
 Construct at the fixed scalar's native precision.
 
 log_gamma_context (Precision p, log_gamma_options options={})
 Prepare coefficients at explicit finite precision p.
 
log_gamma_result< R > log_gamma_ratio_right (complex_type const &input, R const &shift) const
 Evaluate log Gamma(z+h)-log Gamma(z), h real and both real parts positive.
 
log_gamma_result< R > log_gamma_right (complex_type const &input) const
 Evaluate analytic log Gamma(z) on finite Re(z)>0.
 
Precision precision () const
 Requested output precision.
 

Detailed Description

template<detail::LogGammaReal R>
class uni20::log_gamma_context< R >

Immutable reusable right-half-plane log-Gamma and real-shift log-ratio context.

The branch is analytic for finite Re(z)>0 and real on the positive axis, not the principal logarithm of Gamma(z). MPFR uses 64 guard bits; fixed types retain native arithmetic. No ambient precision or exponent range is changed. Inputs must be exact or have the context's precision. Concurrent calls own their scratch and share coefficients.

Exceptions
std::invalid_argumentfor invalid precision, domain or term budget; std::runtime_error if the recurrence/series budget is exhausted; std::overflow_error for unrepresentable arithmetic or diagnostics.

Member Typedef Documentation

◆ complex_type

template<detail::LogGammaReal R>
using uni20::log_gamma_context< R >::complex_type = complex<R>

Constructor & Destructor Documentation

◆ log_gamma_context() [1/2]

template<detail::LogGammaReal R>
uni20::log_gamma_context< R >::log_gamma_context ( log_gamma_options  options = {})
inlineexplicit

Construct at the fixed scalar's native precision.

◆ log_gamma_context() [2/2]

template<detail::LogGammaReal R>
uni20::log_gamma_context< R >::log_gamma_context ( Precision  p,
log_gamma_options  options = {} 
)
inlineexplicit

Prepare coefficients at explicit finite precision p.

Member Function Documentation

◆ log_gamma_ratio_right()

template<detail::LogGammaReal R>
log_gamma_result< R > uni20::log_gamma_context< R >::log_gamma_ratio_right ( complex_type const &  input,
R const &  shift 
) const
inline

Evaluate log Gamma(z+h)-log Gamma(z), h real and both real parts positive.

Forms paired differences before rounding, retaining a small shift even when z+h rounds back to z. Does not subtract two log-Gamma results. A zero shift returns exact zero at the output precision.

◆ log_gamma_right()

template<detail::LogGammaReal R>
log_gamma_result< R > uni20::log_gamma_context< R >::log_gamma_right ( complex_type const &  input) const
inline

Evaluate analytic log Gamma(z) on finite Re(z)>0.

◆ precision()

template<detail::LogGammaReal R>
Precision uni20::log_gamma_context< R >::precision ( ) const
inline

Requested output precision.


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