[cig-commits] commit: Fix the origin when NY==2*NN

Mercurial hg at geodynamics.org
Fri Feb 10 16:00:41 PST 2012


changeset:   40:fa1aec3271c8
user:        Walter Landry <wlandry at caltech.edu>
date:        Wed Feb 08 12:19:45 2012 -0800
files:       write_vtk.hxx
description:
Fix the origin when NY==2*NN


diff -r 54b516de9219 -r fa1aec3271c8 write_vtk.hxx
--- a/write_vtk.hxx	Wed Feb 08 04:23:49 2012 -0800
+++ b/write_vtk.hxx	Wed Feb 08 12:19:45 2012 -0800
@@ -9,7 +9,7 @@ void write_vtk(const std::string &name, 
   boost::filesystem::ofstream initial("output/"+name+".vtk");
 
   const double spacing(1.0/N);
-  const double origin[]={(NX==N ? spacing/2:0),(NY==N ? spacing/2:0)};
+  const double origin[]={(NX==N ? spacing/2:0),(NY==2*N ? spacing/2:0)};
 
   initial << "# vtk DataFile Version 2.0\n"
           << name << "\n"



More information about the CIG-COMMITS mailing list