man std::complex (Fonctions bibliothèques) -
NAME
std::complex -
SYNOPSIS
Public Types
typedef Type value_type
Value typedef.
Public Member Functions
complex (const Type &=Type(), const Type &=Type())
Unspecified parameters default to 0.
template<typename Up> complex (const complex< Up > &)
Copy constructor.
Type & real ()
Return real part of complex number.
const Type & real () const
Return real part of complex number.
Type & imag ()
Return imaginary part of complex number.
const Type & imag () const
Return imaginary part of complex number.
complex< Type > & operator= (const Type &)
Assign this complex number to scalar t.
complex< Type > & operator+= (const Type &)
Add t to this complex number.
complex< Type > & operator-= (const Type &)
Subtract t from this complex number.
complex< Type > & operator *= (const Type &)
Multiply this complex number by t.
complex< Type > & operator/= (const Type &)
Divide this complex number by t.
template<typename Up> complex< Type > & operator= (const complex< Up > &)
Assign this complex number to complex z.
template<typename Up> complex< Type > & operator+= (const complex< Up > &)
Add z to this complex number.
template<typename Up> complex< Type > & operator-= (const complex< Up > &)
Subtract z from this complex number.
template<typename Up> complex< Type > & operator *= (const complex< Up > &)
Multiply this complex number by z.
template<typename Up> complex< Type > & operator/= (const complex< Up > &)
Divide this complex number by z.
Private Attributes
Type M_real
Type M_imag
Detailed Description
template<typename Type> class std::complex< Type >
Template to represent complex numbers.
Specializations for float, double, and long double are part of the library. Results with any other type are not guaranteed.
Parameters: Tp Type of real and imaginary values.
Definition at line 116 of file complex.
Member Typedef Documentation
template<typename Type> typedef Type std::complex< Type >::value_type
Value typedef.
Definition at line 120 of file complex.
Constructor & Destructor Documentation
template<typename Type> std::complex< Type >::complex (const Type & = Type(), const Type & = Type()) [inline]
Unspecified parameters default to 0.
Definition at line 194 of file complex.
template<typename Type> template<typename Up> std::complex< Type >::complex (const complex< Up > &) [inline]
Copy constructor.
Definition at line 200 of file complex.
Member Function Documentation
template<typename Type> const Type & std::complex< Type >::imag () const [inline]
Return imaginary part of complex number.
Definition at line 190 of file complex.
template<typename Type> Type & std::complex< Type >::imag () [inline]
Return imaginary part of complex number.
Definition at line 186 of file complex.
Referenced by std::abs(), std::arg(), std::complex< double >::complex(), std::conj(), std::cos(), std::cosh(), std::exp(), std::imag(), std::complex< long double >::operator *=(), std::complex< double >::operator *=(), std::complex< float >::operator *=(), std::complex< Type >::operator *=(), std::operator!=(), std::complex< long double >::operator+=(), std::complex< double >::operator+=(), std::complex< float >::operator+=(), std::complex< Type >::operator+=(), std::operator-(), std::complex< long double >::operator-=(), std::complex< double >::operator-=(), std::complex< float >::operator-=(), std::complex< Type >::operator-=(), std::complex< long double >::operator/=(), std::complex< double >::operator/=(), std::complex< float >::operator/=(), std::complex< Type >::operator/=(), std::complex< long double >::operator=(), std::complex< double >::operator=(), std::complex< float >::operator=(), std::complex< Type >::operator=(), std::operator==(), std::pow(), std::Norm_helper<>::S_do_it(), std::sin(), std::sinh(), and std::sqrt().
template<typename Type> template<typename Up> complex< Type > & std::complex< Type >::operator *= (const complex< Up > &)
Multiply this complex number by z.
Definition at line 287 of file complex.
References std::complex< Type >::imag(), and std::complex< Type >::real().
template<typename Type> complex< Type > & std::complex< Type >::operator *= (const Type &)
Multiply this complex number by t.
Definition at line 233 of file complex.
template<typename Type> template<typename Up> complex< Type > & std::complex< Type >::operator+= (const complex< Up > &)
Add z to this complex number.
Definition at line 264 of file complex.
References std::complex< Type >::imag(), and std::complex< Type >::real().
template<typename Type> complex< Type > & std::complex< Type >::operator+= (const Type &) [inline]
Add t to this complex number.
Definition at line 215 of file complex.
template<typename Type> template<typename Up> complex< Type > & std::complex< Type >::operator-= (const complex< Up > &)
Subtract z from this complex number.
Definition at line 275 of file complex.
References std::complex< Type >::imag(), and std::complex< Type >::real().
template<typename Type> complex< Type > & std::complex< Type >::operator-= (const Type &) [inline]
Subtract t from this complex number.
Definition at line 224 of file complex.
template<typename Type> template<typename Up> complex< Type > & std::complex< Type >::operator/= (const complex< Up > &)
Divide this complex number by z.
Definition at line 300 of file complex.
References std::complex< Type >::imag(), std::norm(), and std::complex< Type >::real().
template<typename Type> complex< Type > & std::complex< Type >::operator/= (const Type &)
Divide this complex number by t.
Definition at line 243 of file complex.
template<typename Type> template<typename Up> complex< Type > & std::complex< Type >::operator= (const complex< Up > &)
Assign this complex number to complex z.
Definition at line 253 of file complex.
References std::complex< Type >::imag(), and std::complex< Type >::real().
template<typename Type> complex< Type > & std::complex< Type >::operator= (const Type &)
Assign this complex number to scalar t.
Definition at line 205 of file complex.
template<typename Type> const Type & std::complex< Type >::real () const [inline]
Return real part of complex number.
Definition at line 182 of file complex.
template<typename Type> Type & std::complex< Type >::real () [inline]
Return real part of complex number.
Definition at line 178 of file complex.
Referenced by std::abs(), std::arg(), std::complex< double >::complex(), std::conj(), std::cos(), std::cosh(), std::exp(), std::complex< long double >::operator *=(), std::complex< double >::operator *=(), std::complex< float >::operator *=(), std::complex< Type >::operator *=(), std::operator!=(), std::operator+(), std::complex< long double >::operator+=(), std::complex< double >::operator+=(), std::complex< float >::operator+=(), std::complex< Type >::operator+=(), std::operator-(), std::complex< long double >::operator-=(), std::complex< double >::operator-=(), std::complex< float >::operator-=(), std::complex< Type >::operator-=(), std::complex< long double >::operator/=(), std::complex< double >::operator/=(), std::complex< float >::operator/=(), std::complex< Type >::operator/=(), std::complex< long double >::operator=(), std::complex< double >::operator=(), std::complex< float >::operator=(), std::complex< Type >::operator=(), std::operator==(), std::pow(), std::real(), std::Norm_helper<>::S_do_it(), std::sin(), std::sinh(), and std::sqrt().
Author
Generated automatically by Doxygen for libstdc++-v3 Source from the source code.