Skip to content

Commit

Permalink
Fix #27 - Better naming and type constructor ergonomics
Browse files Browse the repository at this point in the history
  • Loading branch information
jtlap committed Sep 22, 2023
1 parent 1cc4b88 commit e2ce76b
Show file tree
Hide file tree
Showing 347 changed files with 6,734 additions and 1,099 deletions.
6 changes: 3 additions & 3 deletions include/kyosu/complex/acos.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acos{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,9 +67,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns [elementwise](@ref glossary_elementwise) the complex principal value
//! 2. Returns elementwise the complex principal value
//! of the arc cosine of the input.
//! Branch cuts exist outside the interval \f$[-1, +1]\f$ along the real axis.
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acosh.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acosh{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the complex arc hyperbolic sine of z, in the range of a half-strip mathematically
//! unbounded along the real axis and in the interval \f$i\times[-\pi/2, \pi/2]\f$ along
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acospi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acospi{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns `pi(as(z))*acos(z)`
//!
Expand Down
6 changes: 3 additions & 3 deletions include/kyosu/complex/acot.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acot{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,9 +67,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns [elementwise](@ref glossary_elementwise) the complex principal value
//! 2. Returns elementwise the complex principal value
//! of the arc cotangent of the input as the arc tangent of the inverse of the input.
//!
//! @groupheader{Example}
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acoth.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acoth{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the complex arc hyperbolic cotangent of z, computed as \f$\mathop{\mathrm{atanh}}(1/z)\f$.
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acotpi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acotpi{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns `pi(as(z))*acot(z)`
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acsc.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns [elementwise](@ref glossary_elementwise) \f$\mathop{\mathrm{asin}}(1/z)\f$.
//! 2. Returns elementwise \f$\mathop{\mathrm{asin}}(1/z)\f$.
//!
//! @groupheader{Example}
//!
Expand Down
6 changes: 3 additions & 3 deletions include/kyosu/complex/acsch.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acsch{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,9 +67,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns [elementwise](@ref glossary_elementwise) \f$\mathop{\mathrm{asinh}}(1/z)\f$.
//! 2. Returns elementwise \f$\mathop{\mathrm{asinh}}(1/z)\f$.
//!
//! @groupheader{Example}
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acscpi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_acscpi{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns `pi(as(z))*acsc(z)`
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/acsh.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_atanh{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the complex arc hyperbolic sine of z, in the range of a half-strip mathematically
//! unbounded along the real axis and in the interval \f$i\times[-\pi/2, \pi/2]\f$ along
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/asec.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns [elementwise](@ref glossary_elementwise) \f$\mathop{\mathrm{acos}}(1/z)\f$.
//! 2. Returns elementwise \f$\mathop{\mathrm{acos}}(1/z)\f$.
//!
//! @groupheader{Example}
//!
Expand Down
6 changes: 3 additions & 3 deletions include/kyosu/complex/asech.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_asech{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,9 +67,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns [elementwise](@ref glossary_elementwise) \f$\mathop{\mathrm{acosh}}(1/z)\f$.
//! 2. Returns elementwise \f$\mathop{\mathrm{acosh}}(1/z)\f$.
//!
//! @groupheader{Example}
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/asecpi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_asecpi{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns `pi(as(z))*asec(z)`
//!
Expand Down
6 changes: 3 additions & 3 deletions include/kyosu/complex/asin.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_asin{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,9 +67,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the [elementwise](@ref glossary_elementwise) the complex principal value
//! 2. Returns the elementwise the complex principal value
//! of the arc sine of the input in the range of a strip unbounded along the imaginary axis
//! and in the interval \f$[-\pi/2, \pi/2]\f$ along the real axis.
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/asinh.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_asinh{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the complex arc hyperbolic sine of z, with branch cuts outside the interval
//! \f$i\times[-\pi/2, \pi/2]\f$ along the imaginary axis.
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/asinpi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_asinpi{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns `pi(as(z))*asin(z)`
//!
Expand Down
6 changes: 3 additions & 3 deletions include/kyosu/complex/atan.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_atan{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,9 +67,9 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the [elementwise](@ref glossary_elementwise) the complex principal value
//! 2. Returns the elementwise the complex principal value
//! of the arc tangent of the input in the range of a strip unbounded along the imaginary axis
//! and in the interval \f$[-\pi/2, \pi/2]\f$ along the real axis.
//!
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/atanh.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_atanh{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns the complex arc hyperbolic sine of z, in the range of a half-strip mathematically
//! unbounded along the real axis and in the interval \f$i\times[-\pi/2, \pi/2]\f$ along
Expand Down
4 changes: 2 additions & 2 deletions include/kyosu/complex/atanpi.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace kyosu::tags
static KYOSU_FORCEINLINE auto deferred_call(auto, T const& v) noexcept
{
auto fn = callable_atanpi{};
return fn(v);
return fn(complex(v));
}

template<typename T>
Expand Down Expand Up @@ -67,7 +67,7 @@ namespace kyosu
//!
//! **Return value**
//!
//! 1. a real input z is treated as if to_complex(z) was entered.
//! 1. a real input z is treated as if complex(z) was entered.
//!
//! 2. Returns `pi(as(z))*atan(z)`
//!
Expand Down
Loading

0 comments on commit e2ce76b

Please sign in to comment.