-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathrectanglemodel.cpp
More file actions
52 lines (39 loc) · 896 Bytes
/
rectanglemodel.cpp
File metadata and controls
52 lines (39 loc) · 896 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include "rectanglemodel.h"
#include <armadillo>
#include <vector>
using namespace std;
using namespace arma;
RectangleModel::RectangleModel(int startX, int startY){
this->startX = startX;
this->startY = startY;
}
void RectangleModel::createMatrixX(){
X = mat(vectorX).t();
}
void RectangleModel::addElement(double newElement){
vectorX.push_back(newElement);
}
int RectangleModel::getStartX(){
return startX;
}
void RectangleModel::setStartX(int startX){
this->startX = startX;
}
int RectangleModel::getStartY(){
return startY;
}
void RectangleModel::setStartY(int startY){
this->startY = startY;
}
vector<double> RectangleModel::getVectorX(){
return vectorX;
}
void RectangleModel::setVectorX(vector<double> vectorX){
this->vectorX = vectorX;
}
mat RectangleModel::getX(){
return X;
}
void RectangleModel::setX(mat X){
this->X = X;
}