first good build. Part, PartFrame, Matrix

This commit is contained in:
Aik-Siong Koh
2023-05-02 10:22:37 -06:00
parent 5c4b08606d
commit 697aad4db9
39 changed files with 453 additions and 99 deletions

View File

@@ -1,15 +1,31 @@
#pragma once
#include <string>
#include <sstream>
#include "Vector.h"
#include "FullMatrix.h"
namespace MbD {
template <typename T>
class FullColumn : public Vector<T>
{
public:
FullColumn(int i) : Vector<T>(i) {}
FullColumn(std::initializer_list<T> list) : Vector<T>{ list } {}
std::string toString();
};
template <typename T>
class FullColumn : public Vector<T>
{
public:
FullColumn(int i) : Vector<T>(i) {}
FullColumn(std::initializer_list<T> list) : Vector<T>{ list } {}
std::string toString()
{
std::stringstream ss;
ss << "FullColumn { ";
for (int i = 0; i < this->size() - 1; i++) {
ss << this->at(i) << ", ";
}
ss << this->back() << " }";
return ss.str();
}
};
typedef std::shared_ptr<FullColumn<double>> FullColDptr;
//typedef std::shared_ptr<FullColumn<std::shared_ptr<FullMatrix<double>>>> FullColFMptr;
}
typedef std::shared_ptr<MbD::FullColumn<double>> FullColDptr;