Fix BSSN-EM runtime crash
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
|
||||
#ifdef newc
|
||||
#include <sstream>
|
||||
#include <cstdio>
|
||||
#include <map>
|
||||
using namespace std;
|
||||
#include <sstream>
|
||||
#include <cstdio>
|
||||
#include <map>
|
||||
#include <string>
|
||||
using namespace std;
|
||||
#else
|
||||
#include <stdio.h>
|
||||
#include <map.h>
|
||||
@@ -3257,12 +3258,13 @@ void Z4c_class::Interp_Constraint()
|
||||
}
|
||||
}
|
||||
|
||||
ofstream outfile;
|
||||
char filename[50];
|
||||
sprintf(filename, "%s/interp_constraint_%05d.dat", ErrorMonitor->out_dir.c_str(), int(PhysTime / dT + 0.5));
|
||||
// 0.5 for round off
|
||||
|
||||
outfile.open(filename);
|
||||
ofstream outfile;
|
||||
char suffix[64];
|
||||
sprintf(suffix, "/interp_constraint_%05d.dat", int(PhysTime / dT + 0.5));
|
||||
string filename = ErrorMonitor->out_dir + suffix;
|
||||
// 0.5 for round off
|
||||
|
||||
outfile.open(filename.c_str());
|
||||
outfile << "# corrdinate, H_Res, Px_Res, Py_Res, Pz_Res, Gx_Res, Gy_Res, Gz_Res, ...." << endl;
|
||||
for (int i = 0; i < n; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user