blob: 735f5dd85c001d51d3ed4b5dbdb327152bb5bc85 [file] [log] [blame]
Gael Guennebaudc3f46cf2008-08-23 19:32:13 +00001std::string sep = "\n----------------------------------------\n";
Benoit Jacob8372bd12009-08-14 20:23:13 -04002Matrix3d m1;
Gael Guennebaudbfe86b82008-08-23 19:41:00 +00003m1 << 1.111111, 2, 3.33333, 4, 5, 6, 7, 8.888888, 9;
Gael Guennebaudc3f46cf2008-08-23 19:32:13 +00004
Benoit Jacob8372bd12009-08-14 20:23:13 -04005IOFormat CommaInitFmt(StreamPrecision, DontAlignCols, ", ", ", ", "", "", " << ", ";");
6IOFormat CleanFmt(4, 0, ", ", "\n", "[", "]");
7IOFormat OctaveFmt(StreamPrecision, 0, ", ", ";\n", "", "", "[", "]");
8IOFormat HeavyFmt(FullPrecision, 0, ", ", ";\n", "[", "]", "[", "]");
Gael Guennebaudc3f46cf2008-08-23 19:32:13 +00009
10std::cout << m1 << sep;
11std::cout << m1.format(CommaInitFmt) << sep;
12std::cout << m1.format(CleanFmt) << sep;
13std::cout << m1.format(OctaveFmt) << sep;
14std::cout << m1.format(HeavyFmt) << sep;