Giter VIP home page Giter VIP logo

armageddon's Introduction

ACS-1-Armageddon

Armageddon is a Python package that predicts the fate of small asteroids entering Earth’s atmosphere. The Armageddon package can be used to demonstrate a hazard map for an impact over the UK for known asteroids. It is designed to be appropriate for use in emergency response and evacuation planning.

Each software module is provided with full source code, example of usage, and automated tests.

Overview

The underlying mathematics employs the dynamics of an asteroid in Earth’s atmosphere prior to break-up as a system of ordinary differential equations. It takes into consideration the characteristics of a given asteroid such as its initial mass, speed, trajectory angle, and internal strength. The solutions are then used to predict the airblast damage on the ground. The package returns the postcodes and population affected in England and Wales.

For further information on the project specfication, see refer to the notebooks: ProjectDescription.ipynb, AirburstSolver.ipynb and DamageMapper.ipynb.

Documentation and Usage

See pdf documentation.

See the user_manual.ipynb notebook file for usage demonstrations.

Installation

To install the module and any pre-requisites, from the base directory run

pip install -r requirements.txt
pip install -e .

To download the postcode data for England and Wales, run

python download_data.py

Contents

Repository Architecture

  • armageddon/ All the main functions
  • docs/ Package documentation
  • examples/ Earth example and interface notebooks for users
  • images/ Relevant images for supplementary information
  • resources/ Tables for examples and postcode and population
  • tests/ Automated testing

How the package works

The armageddon folder contains all the main functions for problem computation. The two major calculation functions are solver.py and damage.py, where the former solves the system of ordinary differential equations for a given asteroid and the latter predicts the hazardous impact of such an asteroid.

The solver is capable of implementing two different methods for solving an ODE system, the 4th-Order Runge Kutta and the Forward-Euler algorithms. Then, by employing the trajectory of the asteroid, the tool can predict the airburst events and the airburst energy.

Within the armageddon folder, extension.py demonstrates the following extended capabilities of the solver tool:

  • Use a tabulated atmospheric density profile instead of an exponential atmosphere
  • Determine asteroid parameters that best fit an observed energy deposition curve

The results from the solver tool can be used for hazard analysis with the damage mapper tool. The main cause of damage close to the impact site is a strong pressure in the air, or equivalently, an airblast. The damage mapper tool takes this pressure as a function of explosion energy to measure the degrees of damage.

The package's damage mapper tool also exhibits the following extended capabilities, which are included in mapping.py and damage.py respectively:

  • Present the software output on a map to indicate the area of damage as a circle
  • Perform a simple uncertainty analysis

Example usage

To get started, the user is recommended to use the example dataset which comes with the package.

Within the example folder, see example.py:

python examples/example.py

A demonstration of the asteroid impact risk tool with a scenario of a large asteroid colliding with Earth over the midlands of the UK. See BREAKING_NEWS.ipynb

Automated testing

To run the pytest test suite, from the base directory run

pytest tests/

GUI tool

Use command below to utilize GUI to help you visualize how a specific asteroids would influence the earth.

python gui/interface.py

Copyright and License

Licensed under the MIT license.

See License.

armageddon's People

Contributors

acse-cw1722 avatar acse-xq322 avatar acse-aa3019 avatar acse-wz22 avatar marijanbeg avatar acse-yc2122 avatar github-actions[bot] avatar acse-xl1921 avatar

Stargazers

Chunyang Wang avatar

Watchers

Chunyang Wang 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.