Topic: Both hypot(x,y) and hypot(x,y,z) should work for std::complex.
Author: 3dw4rd@verizon.net
Date: Fri, 3 Mar 2017 11:26:20 -0800 (PST)
Raw View
------=_Part_850_1143720659.1488569180804
Content-Type: multipart/alternative;
boundary="----=_Part_851_960857994.1488569180804"
------=_Part_851_960857994.1488569180804
Content-Type: text/plain; charset=UTF-8
In order to support generic math algorithms we should add hypots to
<complex>.
float
hypot(std::complex<float> x, std::complex<float> y);
double
hypot(std::complex<double> x, std::complex<double> y);
long double
hypot(std::complex<long double> x, std::complex<long double> y);
// Support mixed precision.
template<typename RealTp, typename RealUp>
fp_promote_t<RealTp, RealUp>
hypot(std::complex<RealTp> x, std::complex<RealUp> y);
And for three args:
float
hypot(std::complex<float> x, std::complex<float> y, std::complex<float> z);
double
hypot(std::complex<double> x, std::complex<double> y, std::complex<double> z
);
long double
hypot(std::complex<long double> x, std::complex<long double> y, std::complex
<long double> z);
// Support mixed precision.
template<typename RealTp, typename RealUp, typename RealVp>
fp_promote_t<RealTp, RealUp, RealVp>
hypot(std::complex<RealTp> x, std::complex<RealUp> y,
std::complex<RealVp> z);
A sane implementation of these for reals should work for complex as well.
I don't care about suffixed or prefixing with c. This is for C++ generic
numerics as far as I'm concerned.
These might magically appear in libstdc++ in std::. ;-).
--
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/19e50de6-e777-4b6d-9145-7e4f40ce8de3%40isocpp.org.
------=_Part_851_960857994.1488569180804
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr"><br>In order to support generic math algorithms we should =
add hypots to <complex>.<br><br><div style=3D"background-color: rgb(2=
50, 250, 250); border-color: rgb(187, 187, 187); border-style: solid; borde=
r-width: 1px; overflow-wrap: break-word;" class=3D"prettyprint"><code class=
=3D"prettyprint"><div class=3D"subprettyprint"><span style=3D"color: #008;"=
class=3D"styled-by-prettify">float</span><span style=3D"color: #000;" clas=
s=3D"styled-by-prettify"><br>hypot</span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">(</span><span style=3D"color: #000;" class=3D"style=
d-by-prettify">std</span><span style=3D"color: #660;" class=3D"styled-by-pr=
ettify">::</span><span style=3D"color: #000;" class=3D"styled-by-prettify">=
complex</span><span style=3D"color: #080;" class=3D"styled-by-prettify"><=
;float></span><span style=3D"color: #000;" class=3D"styled-by-prettify">=
x</span><span style=3D"color: #660;" class=3D"styled-by-prettify">,</span>=
<span style=3D"color: #000;" class=3D"styled-by-prettify"> std</span><span =
style=3D"color: #660;" class=3D"styled-by-prettify">::</span><span style=3D=
"color: #000;" class=3D"styled-by-prettify">complex</span><span style=3D"co=
lor: #080;" class=3D"styled-by-prettify"><float></span><span style=3D=
"color: #000;" class=3D"styled-by-prettify"> y</span><span style=3D"color: =
#660;" class=3D"styled-by-prettify">);</span><span style=3D"color: #000;" c=
lass=3D"styled-by-prettify"><br><br></span><span style=3D"color: #008;" cla=
ss=3D"styled-by-prettify">double</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"><br>hypot</span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">(</span><span style=3D"color: #000;" class=3D"style=
d-by-prettify">std</span><span style=3D"color: #660;" class=3D"styled-by-pr=
ettify">::</span><span style=3D"color: #000;" class=3D"styled-by-prettify">=
complex</span><span style=3D"color: #080;" class=3D"styled-by-prettify"><=
;double></span><span style=3D"color: #000;" class=3D"styled-by-prettify"=
> x</span><span style=3D"color: #660;" class=3D"styled-by-prettify">,</span=
><span style=3D"color: #000;" class=3D"styled-by-prettify"> std</span><span=
style=3D"color: #660;" class=3D"styled-by-prettify">::</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify">complex</span><span style=3D=
"color: #080;" class=3D"styled-by-prettify"><double></span><span styl=
e=3D"color: #000;" class=3D"styled-by-prettify"> y</span><span style=3D"col=
or: #660;" class=3D"styled-by-prettify">);</span><span style=3D"color: #000=
;" class=3D"styled-by-prettify"><br><br></span><span style=3D"color: #008;"=
class=3D"styled-by-prettify">long</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"> </span><span style=3D"color: #008;" class=3D"style=
d-by-prettify">double</span><span style=3D"color: #000;" class=3D"styled-by=
-prettify"><br>hypot</span><span style=3D"color: #660;" class=3D"styled-by-=
prettify">(</span><span style=3D"color: #000;" class=3D"styled-by-prettify"=
>std</span><span style=3D"color: #660;" class=3D"styled-by-prettify">::</sp=
an><span style=3D"color: #000;" class=3D"styled-by-prettify">complex</span>=
<span style=3D"color: #660;" class=3D"styled-by-prettify"><</span><span =
style=3D"color: #008;" class=3D"styled-by-prettify">long</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color=
: #008;" class=3D"styled-by-prettify">double</span><span style=3D"color: #6=
60;" class=3D"styled-by-prettify">></span><span style=3D"color: #000;" c=
lass=3D"styled-by-prettify"> x</span><span style=3D"color: #660;" class=3D"=
styled-by-prettify">,</span><span style=3D"color: #000;" class=3D"styled-by=
-prettify"> std</span><span style=3D"color: #660;" class=3D"styled-by-prett=
ify">::</span><span style=3D"color: #000;" class=3D"styled-by-prettify">com=
plex</span><span style=3D"color: #660;" class=3D"styled-by-prettify"><</=
span><span style=3D"color: #008;" class=3D"styled-by-prettify">long</span><=
span style=3D"color: #000;" class=3D"styled-by-prettify"> </span><span styl=
e=3D"color: #008;" class=3D"styled-by-prettify">double</span><span style=3D=
"color: #660;" class=3D"styled-by-prettify">></span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"> y</span><span style=3D"color: #660;"=
class=3D"styled-by-prettify">);</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"><br><br></span></div></code></div><br><br>// Suppor=
t mixed precision.<br>template<typename RealTp, typename RealUp><br>=
=C2=A0 fp_promote_t<RealTp, RealUp><br>=C2=A0 hypot(std::complex<R=
ealTp> x, std::complex<RealUp> y);<br><br>And for three args:<br><=
br><div style=3D"background-color: rgb(250, 250, 250); border-color: rgb(18=
7, 187, 187); border-style: solid; border-width: 1px; overflow-wrap: break-=
word;" class=3D"prettyprint"><code class=3D"prettyprint"><div class=3D"subp=
rettyprint"><span style=3D"color: #008;" class=3D"styled-by-prettify">float=
</span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>hypot<=
/span><span style=3D"color: #660;" class=3D"styled-by-prettify">(</span><sp=
an style=3D"color: #000;" class=3D"styled-by-prettify">std</span><span styl=
e=3D"color: #660;" class=3D"styled-by-prettify">::</span><span style=3D"col=
or: #000;" class=3D"styled-by-prettify">complex</span><span style=3D"color:=
#080;" class=3D"styled-by-prettify"><float></span><span style=3D"col=
or: #000;" class=3D"styled-by-prettify"> x</span><span style=3D"color: #660=
;" class=3D"styled-by-prettify">,</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"> std</span><span style=3D"color: #660;" class=3D"st=
yled-by-prettify">::</span><span style=3D"color: #000;" class=3D"styled-by-=
prettify">complex</span><span style=3D"color: #080;" class=3D"styled-by-pre=
ttify"><float></span><span style=3D"color: #000;" class=3D"styled-by-=
prettify"> y</span><span style=3D"color: #660;" class=3D"styled-by-prettify=
">,</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> std</s=
pan><span style=3D"color: #660;" class=3D"styled-by-prettify">::</span><spa=
n style=3D"color: #000;" class=3D"styled-by-prettify">complex</span><span s=
tyle=3D"color: #080;" class=3D"styled-by-prettify"><float></span><spa=
n style=3D"color: #000;" class=3D"styled-by-prettify"> z</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">);</span><span style=3D"colo=
r: #000;" class=3D"styled-by-prettify"><br><br></span><span style=3D"color:=
#008;" class=3D"styled-by-prettify">double</span><span style=3D"color: #00=
0;" class=3D"styled-by-prettify"><br>hypot</span><span style=3D"color: #660=
;" class=3D"styled-by-prettify">(</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify">std</span><span style=3D"color: #660;" class=3D"sty=
led-by-prettify">::</span><span style=3D"color: #000;" class=3D"styled-by-p=
rettify">complex</span><span style=3D"color: #080;" class=3D"styled-by-pret=
tify"><double></span><span style=3D"color: #000;" class=3D"styled-by-=
prettify"> x</span><span style=3D"color: #660;" class=3D"styled-by-prettify=
">,</span><span style=3D"color: #000;" class=3D"styled-by-prettify"> std</s=
pan><span style=3D"color: #660;" class=3D"styled-by-prettify">::</span><spa=
n style=3D"color: #000;" class=3D"styled-by-prettify">complex</span><span s=
tyle=3D"color: #080;" class=3D"styled-by-prettify"><double></span><sp=
an style=3D"color: #000;" class=3D"styled-by-prettify"> y</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">,</span><span style=3D"color=
: #000;" class=3D"styled-by-prettify"> std</span><span style=3D"color: #660=
;" class=3D"styled-by-prettify">::</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify">complex</span><span style=3D"color: #080;" class=3D=
"styled-by-prettify"><double></span><span style=3D"color: #000;" clas=
s=3D"styled-by-prettify"> z</span><span style=3D"color: #660;" class=3D"sty=
led-by-prettify">);</span><span style=3D"color: #000;" class=3D"styled-by-p=
rettify"><br><br></span><span style=3D"color: #008;" class=3D"styled-by-pre=
ttify">long</span><span style=3D"color: #000;" class=3D"styled-by-prettify"=
> </span><span style=3D"color: #008;" class=3D"styled-by-prettify">double</=
span><span style=3D"color: #000;" class=3D"styled-by-prettify"><br>hypot</s=
pan><span style=3D"color: #660;" class=3D"styled-by-prettify">(</span><span=
style=3D"color: #000;" class=3D"styled-by-prettify">std</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify">::</span><span style=3D"colo=
r: #000;" class=3D"styled-by-prettify">complex</span><span style=3D"color: =
#660;" class=3D"styled-by-prettify"><</span><span style=3D"color: #008;"=
class=3D"styled-by-prettify">long</span><span style=3D"color: #000;" class=
=3D"styled-by-prettify"> </span><span style=3D"color: #008;" class=3D"style=
d-by-prettify">double</span><span style=3D"color: #660;" class=3D"styled-by=
-prettify">></span><span style=3D"color: #000;" class=3D"styled-by-prett=
ify"> x</span><span style=3D"color: #660;" class=3D"styled-by-prettify">,</=
span><span style=3D"color: #000;" class=3D"styled-by-prettify"> std</span><=
span style=3D"color: #660;" class=3D"styled-by-prettify">::</span><span sty=
le=3D"color: #000;" class=3D"styled-by-prettify">complex</span><span style=
=3D"color: #660;" class=3D"styled-by-prettify"><</span><span style=3D"co=
lor: #008;" class=3D"styled-by-prettify">long</span><span style=3D"color: #=
000;" class=3D"styled-by-prettify"> </span><span style=3D"color: #008;" cla=
ss=3D"styled-by-prettify">double</span><span style=3D"color: #660;" class=
=3D"styled-by-prettify">></span><span style=3D"color: #000;" class=3D"st=
yled-by-prettify"> y</span><span style=3D"color: #660;" class=3D"styled-by-=
prettify">,</span><span style=3D"color: #000;" class=3D"styled-by-prettify"=
> std</span><span style=3D"color: #660;" class=3D"styled-by-prettify">::</s=
pan><span style=3D"color: #000;" class=3D"styled-by-prettify">complex</span=
><span style=3D"color: #660;" class=3D"styled-by-prettify"><</span><span=
style=3D"color: #008;" class=3D"styled-by-prettify">long</span><span style=
=3D"color: #000;" class=3D"styled-by-prettify"> </span><span style=3D"color=
: #008;" class=3D"styled-by-prettify">double</span><span style=3D"color: #6=
60;" class=3D"styled-by-prettify">></span><span style=3D"color: #000;" c=
lass=3D"styled-by-prettify"> z</span><span style=3D"color: #660;" class=3D"=
styled-by-prettify">);</span><span style=3D"color: #000;" class=3D"styled-b=
y-prettify"><br><br></span></div></code></div><br>// Support mixed precisio=
n.<br>template<typename RealTp, typename RealUp, typename RealVp><br>=
=C2=A0 fp_promote_t<RealTp, RealUp, RealVp><br>=C2=A0 hypot(std::comp=
lex<RealTp> x, std::complex<RealUp> y, std::complex<RealVp&g=
t; z);<br><br>A sane implementation of these for reals should work for comp=
lex as well.<br><br>I don't care about suffixed or prefixing with c.=C2=
=A0 This is for C++ generic numerics as far as I'm concerned.<br>These =
might magically appear in libstdc++ in std::.=C2=A0 ;-).<br><br></div>
<p></p>
-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/19e50de6-e777-4b6d-9145-7e4f40ce8de3%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/19e50de6-e777-4b6d-9145-7e4f40ce8de3=
%40isocpp.org</a>.<br />
------=_Part_851_960857994.1488569180804--
------=_Part_850_1143720659.1488569180804--
.
Author: W Brown <webrown.cpp@gmail.com>
Date: Fri, 3 Mar 2017 10:25:19 -1000
Raw View
> On Mar 3, 2017, at 9:26 AM, 3dw4rd@verizon.net wrote:
>
>
> In order to support generic math algorithms we should add hypots to <complex>.
>
> float
> hypot(std::complex<float> x, std::complex<float> y);
>
> double
> hypot(std::complex<double> x, std::complex<double> y);
>
> long double
> hypot(std::complex<long double> x, std::complex<long double> y);
>
>
>
> // Support mixed precision.
> template<typename RealTp, typename RealUp>
> fp_promote_t<RealTp, RealUp>
> hypot(std::complex<RealTp> x, std::complex<RealUp> y);
>
> And for three args:
>
> float
> hypot(std::complex<float> x, std::complex<float> y, std::complex<float> z);
>
> double
> hypot(std::complex<double> x, std::complex<double> y, std::complex<double> z);
>
> long double
> hypot(std::complex<long double> x, std::complex<long double> y, std::complex<long double> z);
>
>
> // Support mixed precision.
> template<typename RealTp, typename RealUp, typename RealVp>
> fp_promote_t<RealTp, RealUp, RealVp>
> hypot(std::complex<RealTp> x, std::complex<RealUp> y, std::complex<RealVp> z);
>
> A sane implementation of these for reals should work for complex as well.
>
> I don't care about suffixed or prefixing with c. This is for C++ generic numerics as far as I'm concerned.
> These might magically appear in libstdc++ in std::. ;-).
Replying privately: I agree. If you'd like to draft a proposal paper, I'd be happy to serve in committee as locum for you.
Best,
-- WEB
--
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/9E59668B-E73A-40D4-A3F8-115322E49855%40gmail.com.
.
Author: Thiago Macieira <thiago@macieira.org>
Date: Fri, 03 Mar 2017 21:16:29 -0800
Raw View
Em sexta-feira, 3 de mar=C3=A7o de 2017, =C3=A0s 11:26:20 PST, 3dw4rd@veriz=
on.net=20
escreveu:
> I don't care about suffixed or prefixing with c. This is for C++ generic
> numerics as far as I'm concerned.
Sounds like you should write a paper stating to that effect that <ccomplex>=
=20
should provide all of the functions without the "c" prefix too. Not just hy=
pot.
--=20
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
Software Architect - Intel Open Source Technology Center
--=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp=
..org/d/msgid/std-proposals/2708823.TC7fPc0agV%40tjmaciei-mobl1.
.
Author: 3dw4rd@verizon.net
Date: Sat, 4 Mar 2017 13:25:21 -0800 (PST)
Raw View
------=_Part_1007_128888109.1488662722038
Content-Type: multipart/alternative;
boundary="----=_Part_1008_1132204997.1488662722038"
------=_Part_1008_1132204997.1488662722038
Content-Type: text/plain; charset=UTF-8
> Sounds like you should write a paper stating to that effect that
> <ccomplex>
> should provide all of the functions without the "c" prefix too. Not just
> hypot.
>
>
Good idea. Separate paper.
But I thought I remember people wanting to kill <ccomplex>.
--
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/11c6cb40-f690-4035-a690-40ca5bd2f3e3%40isocpp.org.
------=_Part_1008_1132204997.1488662722038
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr"><br><blockquote class=3D"gmail_quote" style=3D"margin: 0;m=
argin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;">Sounds li=
ke you should write a paper stating to that effect that <ccomplex>=20
<br>should provide all of the functions without the "c" prefix to=
o. Not just hypot.
<br>
<br></blockquote><div><br>Good idea.=C2=A0 Separate paper.<br>But I thought=
I remember people wanting to kill <ccomplex>.<br><br></div></div>
<p></p>
-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/11c6cb40-f690-4035-a690-40ca5bd2f3e3%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/11c6cb40-f690-4035-a690-40ca5bd2f3e3=
%40isocpp.org</a>.<br />
------=_Part_1008_1132204997.1488662722038--
------=_Part_1007_128888109.1488662722038--
.
Author: 3dw4rd@verizon.net
Date: Mon, 6 Mar 2017 11:07:31 -0800 (PST)
Raw View
------=_Part_161_317419480.1488827251254
Content-Type: multipart/alternative;
boundary="----=_Part_162_1874462341.1488827251254"
------=_Part_162_1874462341.1488827251254
Content-Type: text/plain; charset=UTF-8
Please find the beginnings of a paper and a toy implementation at:
https://github.com/emsr/hypot.git
Let me know of issues, a better tex template (I stole this from draft but
it's too much really), etc.
I'm starting to have mixed feelings about mixed real complex.
hypot(1.0, z)
is rather useful in practice.
Ed
--
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/add1ad1f-a95a-4716-a2d5-05dbedd2113e%40isocpp.org.
------=_Part_162_1874462341.1488827251254
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr">Please find the beginnings of a paper and a toy implementa=
tion at:<br><br>https://github.com/emsr/hypot.git<br><br>Let me know of iss=
ues, a better tex template (I stole this from draft but it's too much r=
eally), etc.<br><br>I'm starting to have mixed feelings about mixed rea=
l complex.<br><div style=3D"background-color: rgb(250, 250, 250); border-co=
lor: rgb(187, 187, 187); border-style: solid; border-width: 1px; overflow-w=
rap: break-word;" class=3D"prettyprint"><code class=3D"prettyprint"><div cl=
ass=3D"subprettyprint"><span style=3D"color: #000;" class=3D"styled-by-pret=
tify">hypot</span><span style=3D"color: #660;" class=3D"styled-by-prettify"=
>(</span><span style=3D"color: #066;" class=3D"styled-by-prettify">1.0</spa=
n><span style=3D"color: #660;" class=3D"styled-by-prettify">,</span><span s=
tyle=3D"color: #000;" class=3D"styled-by-prettify"> z</span><span style=3D"=
color: #660;" class=3D"styled-by-prettify">)</span></div></code></div><br> =
is rather useful in practice.<br><br>Ed<br><br></div>
<p></p>
-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/add1ad1f-a95a-4716-a2d5-05dbedd2113e%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/add1ad1f-a95a-4716-a2d5-05dbedd2113e=
%40isocpp.org</a>.<br />
------=_Part_162_1874462341.1488827251254--
------=_Part_161_317419480.1488827251254--
.
Author: Marc <marc.glisse@gmail.com>
Date: Mon, 13 Mar 2017 02:13:04 -0700 (PDT)
Raw View
------=_Part_1940_1465208015.1489396384159
Content-Type: multipart/alternative;
boundary="----=_Part_1941_897616186.1489396384159"
------=_Part_1941_897616186.1489396384159
Content-Type: text/plain; charset=UTF-8
On Monday, March 6, 2017 at 8:07:31 PM UTC+1, 3dw...@verizon.net wrote:
>
> Please find the beginnings of a paper and a toy implementation at:
>
> https://github.com/emsr/hypot.git
>
> Let me know of issues, a better tex template (I stole this from draft but
> it's too much really), etc.
>
In most places you are talking about sqrt(x*x+y*y), there is just one place
where you acknowledge that for complex numbers, sqrt(norm(x)+norm(y)) may
be more useful (btw, the name "norm" for a function that returns the square
of the norm is not very nice). Assuming that's what you mean, hypot for 2
complex numbers is equivalent to hypot for the 4 real numbers (real and
imaginary parts), but IIRC it was decided not to make hypot variadic and
stop at 3 arguments...
--
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/e75fa8fc-9614-4bdd-911b-41824392962d%40isocpp.org.
------=_Part_1941_897616186.1489396384159
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr">On Monday, March 6, 2017 at 8:07:31 PM UTC+1, 3dw...@veriz=
on.net wrote:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-le=
ft: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><div dir=3D"ltr">=
Please find the beginnings of a paper and a toy implementation at:<br><br><=
a href=3D"https://github.com/emsr/hypot.git" target=3D"_blank" rel=3D"nofol=
low" onmousedown=3D"this.href=3D'https://www.google.com/url?q\x3dhttps%=
3A%2F%2Fgithub.com%2Femsr%2Fhypot.git\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQ=
jCNHBrGpyEjEd3espS7bWx-nQ3Mu-fQ';return true;" onclick=3D"this.href=3D&=
#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Femsr%2Fhypot=
..git\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHBrGpyEjEd3espS7bWx-nQ3Mu-fQ&#=
39;;return true;">https://github.com/emsr/hypot.<wbr>git</a><br><br>Let me =
know of issues, a better tex template (I stole this from draft but it's=
too much really), etc.<br></div></blockquote><div><br>In most places you a=
re talking about sqrt(x*x+y*y), there is just one place where you acknowled=
ge that for complex numbers, sqrt(norm(x)+norm(y)) may be more useful (btw,=
the name "norm" for a function that returns the square of the no=
rm is not very nice). Assuming that's what you mean, hypot for 2 comple=
x numbers is equivalent to hypot for the 4 real numbers (real and imaginary=
parts), but IIRC it was decided not to make hypot variadic and stop at 3 a=
rguments...<br></div></div>
<p></p>
-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<br />
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/a/isocpp.org/d/msgid/std-proposals/e75fa8fc-9614-4bdd-911b-41824392962d%=
40isocpp.org?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.=
com/a/isocpp.org/d/msgid/std-proposals/e75fa8fc-9614-4bdd-911b-41824392962d=
%40isocpp.org</a>.<br />
------=_Part_1941_897616186.1489396384159--
------=_Part_1940_1465208015.1489396384159--
.