tag:blogger.com,1999:blog-17482943.post8129237713981062943..comments2023-06-29T19:04:24.128+05:30Comments on rmathew: ICFPC 2008Ranjit Mathewhttp://www.blogger.com/profile/04429610992943896537noreply@blogger.comBlogger5125tag:blogger.com,1999:blog-17482943.post-88691316824131869122008-08-13T19:15:00.000+05:302008-08-13T19:15:00.000+05:30finnw: "rmathew"finnw: "rmathew"Ranjit Mathewhttps://www.blogger.com/profile/04429610992943896537noreply@blogger.comtag:blogger.com,1999:blog-17482943.post-28141347665248723172008-08-13T19:02:00.000+05:302008-08-13T19:02:00.000+05:30rmathew, what's your team name? I'm also a lone J...rmathew, what's your team name? I'm also a lone Java hacker (the Tweezer Minstrels. Just got around to finishing my write-up.)finnwhttps://www.blogger.com/profile/06859388402549977269noreply@blogger.comtag:blogger.com,1999:blog-17482943.post-84630417399582802832008-07-19T10:54:00.000+05:302008-07-19T10:54:00.000+05:30leah/chris: Yes, I should have used Math.atan2( ) ...leah/chris: Yes, I should have used Math.atan2( ) and I feel dumb now.<BR/><BR/>Note that the function returns a value between -π to +π, so to get a "normalised" answer (0 to +2π) you still have to add +2π if the returned value is negative (or just blindly add +2π and take the result modulo +2π).Ranjit Mathewhttps://www.blogger.com/profile/04429610992943896537noreply@blogger.comtag:blogger.com,1999:blog-17482943.post-48017591625162687352008-07-18T21:00:00.000+05:302008-07-18T21:00:00.000+05:30Java Math.atan2 does what you want.Java Math.atan2 does what you want.Unknownhttps://www.blogger.com/profile/17881320840307544570noreply@blogger.comtag:blogger.com,1999:blog-17482943.post-63077125228379729692008-07-18T04:58:00.000+05:302008-07-18T04:58:00.000+05:30Hey, we ran into that problem too! We ended up usi...Hey, we ran into that problem too! We ended up using Math.atan2() because of this inherent problem and *still* ended up having to handle the positive/negative sign weirdness that occurred on the opposite side of the circle. Glad you had fun!Anonymousnoreply@blogger.com