Namespaces
Variants
Views
Actions

std::complex::real

From cppreference.com
< cpp‎ | numeric‎ | complex
Revision as of 23:45, 2 November 2012 by P12bot (Talk | contribs)

Template:ddcl list begin <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
T real() const;
</td>

<td > (1) </td> <td class="t-dcl-nopad"> </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
void real( T value );
</td>

<td > (2) </td> <td class="t-dcl-nopad"> </td> </tr> Template:ddcl list end

Accesses the real part of the complex number.

1) Returns the real part.

2) Sets the real part to value.

Parameters

value - the value to set the real part to

See also

Template:cpp/numeric/complex/dcl list imag