From: Daniel M. German <dmg@uv...>  20070114 08:00:23

Hi Michael, Thanks a lot for all the work you have done on this projection! It is not trivial at all (compared to this projection the rest are piece of cake). I tried to use your code but run into a problem. I got a tiny, little image :) Would you mind sending the script you are using to test the projection? Also, how do you compute the mp>distance parameter? it is supposed to be the number of pixels per radiant in the output. b contains the number of radiants in the desired fieldofview, and width is the width of the desired output image. I noticed that in your implementation of the albers it always assumes that the desired fieldofview is 360 degrees (hence it ignores b).  daniel Michael> Erik Krause wrote: >> I'm pretty sure you and Michael know this already  just in case...: >> http://www.helpfeeds.com/showthread.php?p=1489664 Michael> I read this before. As far as I understand Abramowitz/Stegun 17.3.24 Michael> does not apply here because we have an incomplete elliptic integral and Michael> the 17.3. chapter is about complete elliptic integrals. However the Michael> inverse of the elliptic integral is no problem, as this is the Jacobi Michael> Function and can be easily calculated with the help of Numerical Recipes Michael> (sncndn). Michael> The problems start later when inverting all those equations full of sin Michael> and cos functions. Maple can invert it but the results are full of Michael> square roots so you have multiple results (as far as I understand these Michael> are the quadrants). Michael> In my first trials I did try to use the equations I get from Maple but I Michael> introduced some bugs I couldn't find and I gave up with this approach. Michael> After reading your mail I decided to give it another chance and now it Michael> works: Michael> Because I don't understand what Maple does when solving the equations, I Michael> can't tell which signs are right. So I have to try all combinations of Michael> signs  for each sqrt on time +1.0*sqrt and one time 1.0*sqrt. As there Michael> are 12 sqrts there are 2^12 = 4096 combinations. After I get a Michael> lambda/phi of one combination I put the result into the forward function Michael> and compare the resulting x and y. Michael> This solution is of course much better than the Michael> interpolation/minimization approach I did before. It is also a lot faster: Michael> http://mdgrosse.net/pano/peircequincuncial.c Michael> Michael  Daniel M. German http://turingmachine.org/ http://silvernegative.com/ dmg (at) uvic (dot) ca replace (at) with @ and (dot) with . 