#include "FGMatrix33.h"
#include "FGColumnVector3.h"
+#include <sstream>
+#include <iomanip>
+
+#include <iostream>
+
+using namespace std;
namespace JSBSim {
static const char *IdSrc = "$Id$";
static const char *IdHdr = ID_MATRIX33;
-using std::cout;
-using std::endl;
-
/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
CLASS IMPLEMENTATION
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
data[0] = data[1] = data[2] = data[3] = data[4] = data[5] =
data[6] = data[7] = data[8] = 0.0;
- Debug(0);
+ // Debug(0);
+}
+
+//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+string FGMatrix33::Dump(const string& delimiter) const
+{
+ ostringstream buffer;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(1,1) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(1,2) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(1,3) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(2,1) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(2,2) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(2,3) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(3,1) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(3,2) << delimiter;
+ buffer << std::setw(18) << std::setprecision(16) << Entry(3,3);
+ return buffer.str();
}
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-std::ostream& operator<<(std::ostream& os, const FGMatrix33& M)
+ostream& operator<<(ostream& os, const FGMatrix33& M)
{
for (unsigned int i=1; i<=M.Rows(); i++) {
for (unsigned int j=1; j<=M.Cols(); j++) {
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-std::istream& operator>>(std::istream& is, FGMatrix33& M)
+istream& operator>>(istream& is, FGMatrix33& M)
{
for (unsigned int i=1; i<=M.Rows(); i++) {
for (unsigned int j=1; j<=M.Cols(); j++) {