> On 10 Jun 2009, at 20:55, Torsten Dreyer wrote:
> > The ridge_lift is now also using the SGGeodesy methods, making the
> > code much
> > cleaner, too.
>
> A word of caution - looking at the code, it seems like you're mixing
> geocentric (SGGeoc) and geodetic (SGGeod) co-ordinates. I haven't
> looked at the code in detail, just the cvs diff, though.

Yeah - I was hoping nobody would have noticed ;-)

Here is my petty excuse:
The original code uses the geodetic properties /position/XXXitude-deg for 
geocentric calculations of other positions by applying heading and distance 
and used the result as geodetic positions to get ground elevation.
Since this was a quite complex formula, nobody noticed. Now, it is obvious 
just by looking at the class names SGGeoc and SGGeod.

I will do some performance tests to see how much cpu power it costs to convert 
from SGGeoc to SGGeod before fetching ground elevation and I will calculate 
the error in the calculation of the slopes if the systems are mixed. 

Consequently one could ask, if spheric trigonometry is adequate for short 
distances up to 2000m (6500ft) or if it is acceptable that earth can be 
assumed to be flat for short distances. This could spare many cpu cycles at 
the price of small displacement of the probes.

I'll check this, too.

For now, there is a note in the source, that this mixture is by intention, not 
by accident.

Torsten

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to