GithubHelp home page GithubHelp logo

cirium-tech-test's Introduction

Cirium Tech Test

This project contains some basic classes required to simulate a flight travelling along a pre-determined route. Exposing class members to calculate the current (estimated/pre-planned) location of a flight, and ascertain whether it is/will pass through a given airspace.

Assumptions

Speed of flight:

This code assumes that the aircraft will travel at a constant speed throughout the entire flight (For this I have used the crusing speed of a 737): While this is not true to life, it allows for a far simpler calculation of the current flight location (and subsequent intersects).

In order to overcome this, we would need to extend the FlightPathSegment type to include a velocity/speed parameter, indicating the expected duration of each segment/leg of a flight.

External factors:

We also assume that there are no other external factors which may delay a flight once in the air, in order to take a total duration calculation of the flight, and move this forward/backward in time to account for delays.

Floating point calculation accuracy

Being native Javascript, there are flaws in floating point calculations. For the sake of simplicity I have not addressed these, however we do run into some innacuracies when calculating distance. If an end solution was to be written in JS/TS, then something like DecimalJS would be needed to ensure precision.

Improvements

As stated above there are a few compromises which need to be made in order to simulate a flight without the use of real world data. In an ideal world we would need a few more data points to accurately calculate the location/time.

In order to acheive a complete solution, we would need to know the tail number of the aircraft. With this we would be able to find the last known transponder location of the flight. From which we could see if the flight was ahead/behind schedule, as well as know the progress along the planned route and current/upcoming intersects.

cirium-tech-test's People

Contributors

dlospreyfs avatar

Watchers

Dan Lincoln avatar

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.