Code Monkey home page Code Monkey logo

Comments (5)

davidklika avatar davidklika commented on July 22, 2024 1

The fix works for me as well, thank you :)

from proj4j.

davidklika avatar davidklika commented on July 22, 2024

Hello
I went throug the code and I think that the bug is in the KrovakProjection class projectInverse method. When the method is called, x and y holds values in degrees and dst in meters (original values). x and y values are totally ignored in the method and the trigonometric functions are called on dst.x and dst.y values in meters.

When I replaced lines 157-158 with this:
ro = hypot(x, y);
eps = atan2(-x, -y);
the results gets much better (just output axes are reversed and not sure about precision).
Such change makes preceding 6 lines and the czech flag redundant, so I am not sure about the consequences.

Can someone help to fix that?

BTW: many calculations does not depend on the input so it can be precomputed in the class constructor and reused.

from proj4j.

rhuitl avatar rhuitl commented on July 22, 2024

#97 fixes this issue for me. Are you @mikimikimikia or @davidklika able to verify it fixes the issue for you?

from proj4j.

rhuitl avatar rhuitl commented on July 22, 2024

@pomadchin I think we can close this ticket now :)

from proj4j.

pomadchin avatar pomadchin commented on July 22, 2024

Thanks! Closed via #97.

from proj4j.

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.