From 3ae04059f307cf46535289eaa0a510898f5c6c28 Mon Sep 17 00:00:00 2001 From: Harry Moffat Date: Thu, 13 Nov 2008 23:23:40 +0000 Subject: [PATCH] Fixed the LJ diameter read statement to be arbitrary precision instead of just precision 2. Note, this change does cause the GRI30 mechanism to produce different results. --- Cantera/src/converters/ck2ct.cpp | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/Cantera/src/converters/ck2ct.cpp b/Cantera/src/converters/ck2ct.cpp index a779d7ecb..ce1d81b35 100644 --- a/Cantera/src/converters/ck2ct.cpp +++ b/Cantera/src/converters/ck2ct.cpp @@ -198,7 +198,18 @@ namespace pip { case 1: fprintf(f," geom = \"linear\",\n"); break; case 2: fprintf(f," geom = \"nonlinear\",\n"); break; } - fprintf(f," diam = %8.2f,\n",td.diam); +#define FULL_TRANSPORT_PARAMETER_PRECISION +#ifdef FULL_TRANSPORT_PARAMETER_PRECISION + fprintf(f," diam = %g,\n",td.diam); + fprintf(f," well_depth = %g",td.welldepth); + if (td.polar != 0.0) + fprintf(f,",\n polar = %g",td.polar); + if (td.dipole != 0.0) + fprintf(f,",\n dipole = %g",td.dipole); + if (td.rot != 0.0) + fprintf(f,",\n rot_relax = %g",td.rot); +#else + fprintf(f," diam = %8.2f,\n",td.diam); fprintf(f," well_depth = %8.2f",td.welldepth); if (td.polar != 0.0) fprintf(f,",\n polar = %8.2f",td.polar); @@ -206,6 +217,7 @@ namespace pip { fprintf(f,",\n dipole = %8.2f",td.dipole); if (td.rot != 0.0) fprintf(f,",\n rot_relax = %8.2f",td.rot); +#endif fprintf(f,")"); }