Skip to content
Open
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
12 changes: 7 additions & 5 deletions HCKalmanFilter/HCMatrixObject.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,14 @@ class HCMatrixObject
//MARK: - HCMatrixObject properties

/// Number of Rows in Matrix
private var rows: Int
var rows: Int {
return self.matrix.rows
}

/// Number of Columns in Matrix
private var columns: Int
var columns: Int {
return self.matrix.columns
}

/// Surge Matrix object
var matrix: Matrix<Double>
Expand All @@ -26,9 +30,7 @@ class HCMatrixObject

/// Initailization of matrix with specified numbers of rows and columns
init(rows:Int,columns:Int) {
self.rows = rows;
self.columns = columns;
self.matrix = Matrix<Double>(rows: self.rows, columns: self.columns, repeatedValue: 0.0)
self.matrix = Matrix<Double>(rows: rows, columns: columns, repeatedValue: 0.0)
}

//MARK: - HCMatrixObject functions
Expand Down