GithubHelp home page GithubHelp logo

Comments (8)

icemagno avatar icemagno commented on May 26, 2024 1

I see. Then I think we can close. Many thanks and BRAVO ZULU.

from open-dis-java.

leif81 avatar leif81 commented on May 26, 2024

Hi @icemagno

There is a unit test here that does the round trip check. A small amount of acceptable error had to be identified to get it to pass. I did not see an issue with elevation though in the sample data. Maybe you found a corner case?

https://github.com/open-dis/open-dis-java/blob/master/src/test/java/edu/nps/moves/disutil/CoordinateConversionsTest.java

from open-dis-java.

leif81 avatar leif81 commented on May 26, 2024

Do you mean this value? -9.313225746154785E-10

That's a very small number right, close to 0.

from open-dis-java.

leif81 avatar leif81 commented on May 26, 2024

I plugged your values into the unit test in PR #72 and it passed.

Maybe i'm overlooking something, but I think the coordinate conversion is working OK.

from open-dis-java.

icemagno avatar icemagno commented on May 26, 2024

Well I think -9 meters is a little far from zero. In my case I have to simulate airplanes and this may crash someone in land or a mountain. Or just cause a missile to miss the target.

Im using RPR FOM and data comming from other source as LAT, LON, ALT. So I must convert it to Spatial data (XYZ) and send to RTI. Then I need to get it back to the original values in others federates and this is when I get the different values. So my original source tells me the airplane is landed at zero meters and the federates understand -9 meters for example.

I've checked others values and the error is different every time. For example there is no error with elevation 10. You can try a loop passing values from zero to 100 and check the recalculated value to verify.

My test case was just convert to XYZ and back again to LAT LON ALT using the output values.

The coordinates are ok indeed but depending on the elevation value passed as source we may get less or more error in decimals leading to the "GPS imprecision effect" when the object position is not accurate in small scales.

I mean... if a helicopter is standing at ground and constantly passing its position as LAT,LON,ALT to be converted to XYZ and then converted again we may see the helicopter changing its position when we change only its elevation. I'm working on military simulations and don't know if these small errors are allowed.

If you tell me it is ok then I'm fine. Sorry about my english. You can ask me to clarify if you don't get something.

from open-dis-java.

leif81 avatar leif81 commented on May 26, 2024

Unless I'm misreading the value, the elevation is not -9, it's -0.0000000009. It's presented in scientific notation.

from open-dis-java.

leif81 avatar leif81 commented on May 26, 2024

If you want to be certain, plug your values into the unit test and see if it passes.

from open-dis-java.

joshserrin avatar joshserrin commented on May 26, 2024

Sounds like your federate code is parsing -9.313225746154785E-10 as -9 instead of -9E-10. Doesn't appear to be an issue with open-dis.

from open-dis-java.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.