23 const std::string& plotTitle,
24 const std::vector<std::string> &names,
27 ofstream f(fname.c_str());
29 throw CanteraError(
"writePlotFile",
"could not open file "+fname+
35 }
else if (fmt ==
"XL" || fmt ==
"CSV") {
40 "unsupported plot type:" + fmt);
54 void outputTEC(std::ostream& s,
const std::string& title,
55 const std::vector<std::string>& names,
59 int npts =
static_cast<int>(data.
nColumns());
60 int nv =
static_cast<int>(data.
nRows());
61 s <<
"TITLE = \"" + title +
"\"" << endl;
62 s <<
"VARIABLES = " << endl;
63 for (i = 0; i < nv; i++) {
64 s <<
"\"" << names[i] <<
"\"" << endl;
66 s <<
"ZONE T=\"zone1\"" << endl;
67 s <<
" I=" << npts <<
",J=1,K=1,F=POINT" << endl;
69 for (i = 0; i < nv; i++) {
73 for (i = 0; i < npts; i++) {
74 for (j = 0; j < nv; j++) {
75 s << data(j,i) <<
" ";
92 const std::vector<std::string>& names,
96 int npts =
static_cast<int>(data.
nColumns());
97 int nv =
static_cast<int>(data.
nRows());
98 s << title +
"," << endl;
99 for (i = 0; i < nv; i++) {
106 for (i = 0; i < npts; i++) {
107 for (j = 0; j < nv; j++) {