Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

module submission: 1870-Schliemann-001 #22

Merged
merged 6 commits into from
Feb 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added 1870-Schliemann-001/.DS_Store
Binary file not shown.
2 changes: 2 additions & 0 deletions 1870-Schliemann-001/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
__pycache__/
*.pyc
2 changes: 2 additions & 0 deletions 1870-Schliemann-001/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
## 1.0.0
- Creation of the module.
21 changes: 21 additions & 0 deletions 1870-Schliemann-001/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) <YEAR> <COPYRIGHT HOLDER>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
70 changes: 70 additions & 0 deletions 1870-Schliemann-001/NASSA.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
id: 1870-Schliemann-001
nassaVersion: 0.5.0
moduleType: Algorithm
title: (DUMMY EXAMPLE) TroyDestroy. Bronze Age siege and its destructive effect on settlement
moduleVersion: 1.0.0
contributors:
- name: Schliemann, Heinrich
roles: [ "Author", "Copyright Holder" ]
email: [email protected]
orcid: 0000-0002-1825-0097
- name: Angourakis, Andreas
roles: [ "Author", "Copyright Holder", "Creator" ]
email: [email protected]
orcid: 0000-0002-9946-8142
lastUpdateDate: 1871-10-20
description: >
This module takes the strength of two armies, one aggressor and another defender, and calculates the level of destruction of the defenders' city. The destructive effect over the defenders' city is proportional to the two contending strengths and a constant rate per unit of strength of the aggressor matched by the defender.
relatedModules: [ 1874-Schliemann-001 ]
references:
moduleReferences: [ homer_iliad_1865 ]
useExampleReferences: [ nassa_guide_submissions ]
domainKeywords:
regions:
- Global
- Eastern Mediterranean
periods:
- Bronze Age
- Mycenaean
subjects:
- war
modellingKeywords:
- agent
- calculation
programmingKeywords:
- Functional
- Object-oriented
implementations:
- language: NetLogo
softwareDependencies:
- NetLogo >= v6.1.1
- gis (NetLogo extension)
- language: Python
softwareDependencies:
- Python >= v.3.9
- math (Python module)
- random (Python module)
docsDir: documentation/
inputs:
- name: greeks-strength, GREEKS_STRENGTH
type: integer
unit: army strength
description: The strength of the Greek army (attackers), measured in number of soldiers, units, etc.
- name: trojans-strength, TROJANS_STRENGTH
type: integer
unit: army strength
description: The strength of the Trojan army (defenders), measured in number of soldiers, units, etc.
- name: destruction-rate, DESTRUCTION_RATE
type: float
unit: city health / army strength
description: The rate of destruction per unit of attacker strength
- name: init-troy-health, TROY_HEALTH
type: float
unit: city health
description: The general state of the defenders city, measured in population, structures, etc.
outputs:
- name: troy-health, health, City.health
type: float
unit: city health
description: The general state of the defenders city, measured in population, structures, etc.
license: MIT
25 changes: 25 additions & 0 deletions 1870-Schliemann-001/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# (DUMMY EXAMPLE) TroyDestroy. Bronze Age siege and its destructive effect on settlement

*by Heinrich "Dummy" Schliemann* (NASSA submission :rocket:)

This module takes the strength of two armies, one aggressor and another defender, and calculates the level of destruction of the defenders' city. The destructive effect over the defenders' city is proportional to the two contending strengths and a constant rate per unit of strength of the aggressor matched by the defender.

## License

**MIT**

## References

Homer. 1865. The Iliad of Homer. J. Murray (trad.).

## Further information

<a title="Unknown Corinthian pottery maker BCE, Public domain, via Wikimedia Commons" href="https://commons.wikimedia.org/wiki/File:Corinthian_aryballos_depicting_the_trojan_war_from_1887_jahrbuchdeskaiserich_1200x500.jpg"><img width="512" alt="Corinthian aryballos depicting the trojan war from 1887 jahrbuchdeskaiserich 1200x500" src="https://upload.wikimedia.org/wikipedia/commons/thumb/3/35/Corinthian_aryballos_depicting_the_trojan_war_from_1887_jahrbuchdeskaiserich_1200x500.jpg/512px-Corinthian_aryballos_depicting_the_trojan_war_from_1887_jahrbuchdeskaiserich_1200x500.jpg"></a>

This model is a algorithm implemented in NetLogo and Python 3. Disclaimer: the code might require updates since it was written in the 19th century.

Overview of the algorithm:

$$warEffect=-destructionRate*\frac{(attackerStrength)^2}{defenderStrength} $$

See full list of documentation resources in [`documentation`](documentation/tableOfContents.md).
21 changes: 21 additions & 0 deletions 1870-Schliemann-001/documentation/designDetails.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Design details

This module takes the strength of two armies, one aggressor and another defender, and calculates the level of destruction of the defenders' city.

## Inputs

Four input variables or parameters are required:
- Strength of the attacker's army
- Strength of the defender's army
- Destruction rate modulating how fast the city looses its health during the war
- Health of the defender's city, before the war

## Output

- Health of the defender's city, after the war

## Core algorithm

The destructive effect over the defenders' city is proportional to the two contending strengths and a constant rate per unit of strength of the aggressor matched by the defender. The specific mathematical formulation is:

$$warEffect=-destructionRate*\frac{(attackerStrength)^2}{defenderStrength} $$
9 changes: 9 additions & 0 deletions 1870-Schliemann-001/documentation/tableOfContents.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
(DUMMY EXAMPLE) TroyDestroy. Bronze Age siege and its destructive effect on settlement
# General documentation
## Table of contents

- [`designDetails.md`](designDetails.md) : free format document describing the module process, beyond the level of implementation.

- [NetLogo implementation](/netlogo_implementation/documentation/tableOfContents.md) : documentation specific to the NetLogo implementation.

- [Python implementation](/python_implementation/documentation/tableOfContents.md) : documentation specific to the Python implementation.
Loading
Loading