Re: BUG #4749: trigonometric functions broken

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-bugs(at)postgresql(dot)org
Cc: "Stefano Salvador" <stefano(dot)salvador(at)gmail(dot)com>
Subject: Re: BUG #4749: trigonometric functions broken
Date: 2009-04-05 14:58:46
Message-ID: 200904051758.47081.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Sunday 05 April 2009 13:44:37 Stefano Salvador wrote:
> select sin(pi());
>
> returns: 1.2246
>
> or:
>
> select cos(pi()/2);
>
> returns: 6.123
>
> but sin and cos are limited between -1 and 1 !!!

I get

=> select sin(pi());
sin
----------------------
1.22460635382238e-16
(1 row)

=> select cos(pi()/2);
cos
----------------------
6.12303176911189e-17
(1 row)

Apparently, your interface is truncating the output.

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Euler Taveira de Oliveira 2009-04-05 15:01:14 Re: BUG #4749: trigonometric functions broken
Previous Message Stefano Salvador 2009-04-05 10:44:37 BUG #4749: trigonometric functions broken