This repository contains the code and documentation for assignment 1 Decide, written by group 22. The assignment is part of the course DD2480 Software Engineering Fundamentals.
The Decide program is a part of a hypothetical anti-ballistic missile system, and determines whether an interceptor should be launched based upon the inputed radar tracking information. The program only allows a launch if all the requirments set in the configuration files are meet.
- Erik Svensson
- Felipe Ignacio Vicencio Neumann
- Nils Streijffert
- Pablo Javier Aravena Núñez
- Converted the original code skeleton from C to Java
- Wrote the third test case for the Decide program
- Implemented Launch Interceptor Conditions 0, 1, 3 and 14
- Implemented Launch Interceptor Conditions 2, 5, 8, 9, 11 and 13
- Implemented Launch Interceptor Conditions 6 and 7
- Wrote the
IOHandler
,Parameters
andConnectors
classes - Implemented the
DecideProgram
class - Setup the Maven project
- Setup Travis
- Setup CodeCov
- Setup JavaDoc
- Setup JUnit
- Wrote documentation
- Implemented Launch Interceptor Conditions 4, 10 and 12
- Added the Travis bot to Slack
- Java JDK 8
- Apache Maven 3.6.3
- Compile the project:
mvn compile
- Run the program:
mvn exec:java -Dexec.mainClass=Main
You can suppress the Maven output by running the the program with the -q
flag. The command then becomes:
mvn exec:java -Dexec.mainClass=Main -q
If you want to run a specific test from the resources folder you can specify it by passing an application argument
using the -Dexec.args
flag. Valid arguments are the numbers of the test file (program_test_#), you can specify more
than one file at a time.
Example run test file 1 and 3:
mvn exec:java -Dexec.mainClass=Main -Dexec.args="1 3"
- Compile the project:
mvn compile
- Run tests:
mvn test
- Compile the project:
mvn compile
- Generate documentation:
mvn javadoc:javadoc
- To view the documentation open the file
target/site/apidocs/index.html
in a web browser.
The Decide program configuration file lets the user easily configure the input parameters to the program.
The first line is a integer N
(3 <= N <= 100
) and defines the number of data points. Then there is N
rows of
coordinates which are pairs of doubles. After the coordinates there are eight rows of doubles which represent the
following parameters: epsilon
, length1
, length2
, radius1
, radius2
, area1
, area2
, dist
. Then there is
eleven rows of integers which represent the parameters: qPts
, quads
,nPts
, kPts
, aPts
, bPts
, cPts
, dPts
,
ePts
, fPts
, gPts
. After the parameters there is fifteen rows of fifteen space separated Strings (only one space between each String) with either of the values ANND
, NOTUSED
or ORR
, these rows form the Logical Connector Matrix. The final fifteen rows of the file are boolean values either true
or false
, these values form the Preliminary Unlocking Vector.
Example: Config file