--- /dev/null
+//------------------------ grid_in_tecplot.cc -----------------------
+// $Id: grid_in.cc 11749 2005-11-09 19:11:20Z wolf $
+// Version: $Name$
+//
+// Copyright (C) 2002, 2003, 2004, 2005 by the deal.II authors
+//
+// This file is subject to QPL and may not be distributed
+// without copyright and license information. Please refer
+// to the file deal.II/doc/license.html for the text and
+// further information on this license.
+//
+//------------------------ grid_in_tecplot.cc -----------------------
+
+#include "../tests.h"
+#include <dofs/dof_handler.h>
+#include <grid/tria.h>
+#include <grid/grid_out.h>
+#include <grid/grid_in.h>
+#include <base/logstream.h>
+
+#include <fstream>
+#include <string>
+
+std::ofstream logfile("grid_in_tecplot/output");
+
+
+template <int dim>
+void test (const std::string &infilename)
+{
+ Triangulation<dim> tria;
+ GridIn<dim> gi;
+ gi.attach_triangulation (tria);
+ gi.read (infilename);
+
+ logfile<<"------------------------------------------"<<std::endl
+ <<"output for grid in "<<infilename<<std::endl;
+
+ GridOut grid_out;
+ grid_out.write_ucd (tria, logfile);
+}
+
+int main ()
+{
+ test<2> ("grid_tec_1.dat");
+ test<2> ("grid_tec_2.dat");
+ test<2> ("grid_tec_3.dat");
+ test<2> ("grid_tec_4.dat");
+}
+
--- /dev/null
+------------------------------------------
+output for grid in grid_tec_1.dat
+# This file was generated by the deal.II library.
+
+
+#
+# For a description of the UCD format see the AVS Developer's guide.
+#
+8 4 0 0 0
+1 1 0 0
+2 0 1 0
+3 -1 0 0
+4 0 -1 0
+5 2 0 0
+6 0 2 0
+7 -2 0 0
+8 0 -2 0
+1 0 quad 1 5 6 2
+2 0 quad 2 6 7 3
+3 0 quad 3 7 8 4
+4 0 quad 4 8 5 1
+------------------------------------------
+output for grid in grid_tec_2.dat
+# This file was generated by the deal.II library.
+
+
+#
+# For a description of the UCD format see the AVS Developer's guide.
+#
+8 4 0 0 0
+1 1 0 0
+2 0 1 0
+3 -1 0 0
+4 0 -1 0
+5 2 0 0
+6 0 2 0
+7 -2 0 0
+8 0 -2 0
+1 0 quad 1 5 6 2
+2 0 quad 2 6 7 3
+3 0 quad 3 7 8 4
+4 0 quad 4 8 5 1
+------------------------------------------
+output for grid in grid_tec_3.dat
+# This file was generated by the deal.II library.
+
+
+#
+# For a description of the UCD format see the AVS Developer's guide.
+#
+8 4 0 0 0
+1 1 0 0
+2 0 1 0
+3 -1 0 0
+4 0 -1 0
+5 2 0 0
+6 0 2 0
+7 -2 0 0
+8 0 -2 0
+1 0 quad 1 5 6 2
+2 0 quad 2 6 7 3
+3 0 quad 3 7 8 4
+4 0 quad 4 8 5 1
+------------------------------------------
+output for grid in grid_tec_4.dat
+# This file was generated by the deal.II library.
+
+
+#
+# For a description of the UCD format see the AVS Developer's guide.
+#
+8 4 0 0 0
+1 1 0 0
+2 0 1 0
+3 -1 0 0
+4 0 -1 0
+5 2 0 0
+6 0 2 0
+7 -2 0 0
+8 0 -2 0
+1 0 quad 1 5 6 2
+2 0 quad 2 6 7 3
+3 0 quad 3 7 8 4
+4 0 quad 4 8 5 1
--- /dev/null
+# coordinates x and y
+# new format of keys
+# unstructured data
+
+TITLE = "quad Mesh File"
+VARIABLES = "X", "Y"
+ZONE T="Zone-4" N=8 E=4 C=BLACK DATAPACKING=POINT ZONETYPE=FEQUADRILATERAL
+DT=(SINGLE SINGLE)
+1 0
+0 1
+-1 0
+0 -1
+2 0
+0 2
+-2 0
+0 -2
+
+1 5 6 2
+2 6 7 3
+3 7 8 4
+4 8 5 1
--- /dev/null
+# coordinates to use: x and z
+# old format of keys
+# unstructured data, point format
+TITLE = "quad Mesh File"
+VARIABLES = "X", "Y",
+ "Z"
+ZONE T="Zone-4" N= 8 E=4 C=BLACK F=FEPOINT
+DT=(SINGLE SINGLE SINGLE )
+1 0 0
+0 0 1
+-1 0 0
+0 0 -1
+2 0 0
+0 0 2
+-2 0 0
+0 0 -2
+
+1 5 6 2
+2 6 7 3
+3 7 8 4
+4 8 5 1
--- /dev/null
+# coordinates x and y
+# new format of keys
+# structured data (duplicated vertices), block format
+
+TITLE = "quad Mesh File"
+VARIABLES = "X", "Y"
+ZONE T="Zone-4" I=5 J=2 C=BLACK DATAPACKING=BLOCK ZONETYPE=ORDERED
+DT=(SINGLE SINGLE)
+1 0 -1 0 1
+2
+0
+-2
+0 2
+
+0 1 0 -1 0
+0
+2
+ 0 -2
+0
--- /dev/null
+# coordinates to use: x and z
+# old format of keys
+# unstructured data, block format
+TITLE = "quad Mesh File"
+VARIABLES = "X", "Y",
+ "Z"
+ZONE T="Zone-4" N= 8 E=4 C=BLACK F=FEBlock
+DT=(SINGLE SINGLE SINGLE )
+1 0 -1 0
+2 0 -2 0
+0 0 0 0 0 0 0 0
+0 1 0 -1
+0 2 0 -2
+
+1 5 6 2
+2 6 7 3
+3 7 8 4
+4 8 5 1