OndselSolver can read and write *.asmt files

This commit is contained in:
Aik-Siong Koh
2023-10-19 10:51:51 -06:00
parent 95cd91c9d1
commit 4360daddf3
61 changed files with 1383 additions and 107 deletions

View File

@@ -5,7 +5,8 @@
* *
* See LICENSE file for details about copyright. *
***************************************************************************/
#include <fstream>
#include "ASMTPart.h"
#include "CREATE.h"
#include "ASMTPrincipalMassMarker.h"
@@ -116,3 +117,29 @@ void MbD::ASMTPart::createMbD(std::shared_ptr<System> mbdSys, std::shared_ptr<Un
ASMTSpatialContainer::createMbD(mbdSys, mbdUnits);
if (isFixed) std::static_pointer_cast<Part>(mbdObject)->asFixed();
}
void MbD::ASMTPart::storeOnLevel(std::ofstream& os, int level)
{
storeOnLevelString(os, level, "Part");
storeOnLevelName(os, level + 1);
storeOnLevelPosition(os, level + 1);
storeOnLevelRotationMatrix(os, level + 1);
storeOnLevelVelocity(os, level + 1);
storeOnLevelOmega(os, level + 1);
storeOnLevelString(os, level + 1, "FeatureOrder");
storeOnLevelMassMarker(os, level + 1);
storeOnLevelRefPoints(os, level + 1);
storeOnLevelRefCurves(os, level + 1);
storeOnLevelRefSurfaces(os, level + 1);
}
void MbD::ASMTPart::storeOnLevelMassMarker(std::ofstream& os, int level)
{
principalMassMarker->storeOnLevel(os, level);
}
void MbD::ASMTPart::storeOnTimeSeries(std::ofstream& os)
{
os << "PartSeries\t" << fullName("") << std::endl;
ASMTSpatialContainer::storeOnTimeSeries(os);
}