Documentation fix regarding atan2

Поиск
Список
Период
Сортировка
Искать
От
Andrew Maclean
Тема
Documentation fix regarding atan2
Дата
Msg-id
e7ddbec60709041737h56f7e385xf3c622ca7b407a2b@mail.gmail.com
Список
Дерево обсуждения
Documentation fix regarding atan2 "Andrew Maclean" <andrew.amaclean@gmail.com>
Re: Documentation fix regarding atan2 Bruno Wolff III <bruno@wolff.to>
Re: Documentation fix regarding atan2 "Andrew Maclean" <a.maclean@cas.edu.au>
Re: Documentation fix regarding atan2 Tom Lane <tgl@sss.pgh.pa.us>
Re: Documentation fix regarding atan2 Bruce Momjian <bruce@momjian.us>
Re: Documentation fix regarding atan2 "Andrew Maclean" <andrew.amaclean@gmail.com>
In Table 9.4 of the documentation atan2 is described as follows:
atan2(x, y)inverse tangent of x/y
 
I am sure it should read as:
atan2(y, x)inverse tangent of y/x
 
This looks to be the standard C++/c atan2(y,x) function.
 
You can easily test this:
If y = 2, x = 1, then degrees(atan(y/x)) =63.4 but if we proceed according to the documentation; degrees(atan2(x,y))=degrees(atan2(1,2))=25.6 which is not the same as degrees(atan(y/x)).
So it must be degrees(atan2(y,x))=degrees(atan2(2,1))=63.4.
 

Thanks
   Andrew

--
___________________________________________
Andrew J. P. Maclean
Centre for Autonomous Systems
The Rose Street Building J04
The University of Sydney  2006  NSW
AUSTRALIA
Ph: +61 2 9351 3283
Fax: +61 2 9351 7474
URL: http://www.acfr.usyd.edu.au/
___________________________________________
В списке pgsql-general по дате отправления
От: Steve Crawford
Дата:
Сообщение: psql hanging
От: Martin Langhoff
Дата:
FAQ