Skip to content
Snippets Groups Projects
Commit 156ba3d5 authored by Håvard Daleng's avatar Håvard Daleng
Browse files

Added AffineTransform2D-class and resolved issue with pom.xml.

parent 31beb13b
No related branches found
No related tags found
No related merge requests found
package edu.ntnu.stud.chaosgame;
/**
* Main class for the Chaos Game application.
*/
public class Main {
public static void main(String[] args) {
......
package edu.ntnu.stud.chaosgame.model;
/**
* Class representing an affine transformation in 2D.
*/
public class AffineTransform2D {
/**
* Matrix component of the affine transformation.
*/
private Matrix2x2 matrix;
/**
* Vector component of the affine transformation.
*/
private Vector2D vector;
/**
* Parameterized constructor for the affine transformation.
* @param matrix matrix
* @param vector vector
*/
public AffineTransform2D(Matrix2x2 matrix, Vector2D vector) {
this.matrix = matrix;
this.vector = vector;
}
/**
* Getter for the matrix belonging to the affine transformation.
*
* @return the matrix
*/
public Matrix2x2 getMatrix() {
return matrix;
}
/**
* Setter for the matrix belonging to the affine transformation.
*
* @param matrix the matrix to set
*/
public void setMatrix(Matrix2x2 matrix) {
this.matrix = matrix;
}
/**
* Getter for the vector belonging to the affine transformation.
*
* @return the vector
*/
public Vector2D getVector() {
return vector;
}
/**
* Setter for the vector belonging to the affine transformation.
*
* @param vector the vector to set
*/
public void setVector(Vector2D vector) {
this.vector = vector;
}
}
\ No newline at end of file
......@@ -14,7 +14,7 @@ public class Complex extends Vector2D{
/**
* Get the square root of the complex number.
*
*
* @return The square root of the complex number.
*/
public Complex sqrt() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment