Index: tests/GuiChecks/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/testsuite-analysis-dipole-angular-correlation-periodic-boundaries.at
===================================================================
--- tests/GuiChecks/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/testsuite-analysis-dipole-angular-correlation-periodic-boundaries.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/testsuite-analysis-dipole-angular-correlation-periodic-boundaries.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,75 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### dipole angular correlation analysis
+
+AT_SETUP([Analysis - dipole angular correlation on PDBs with CONECT and periodic BC, zero change])
+AT_KEYWORDS([analysis dipole correlation pdb dipole-angular-correlation periodic])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/pre/watermulti_X.pdb .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_X.pdb -o pdb --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation-periodic-boundaries.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation-periodic-boundaries.py >session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_histogram_X.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_values_X.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole angular correlation on PDBs with CONECT and periodic BC, true change])
+AT_KEYWORDS([analysis dipole correlation pdb dipole-angular-correlation periodic])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/pre/watermulti_Y.pdb .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_Y.pdb -o pdb --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation-periodic-boundaries.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation-periodic-boundaries.py >session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_histogram_Y.$step.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_values_Y.$step.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole angular correlation on XYZs and periodic BC, zero change])
+AT_KEYWORDS([analysis dipole correlation xyz dipole-angular-correlation periodic])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/pre/watermulti_X.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_X.xyz -o xyz -I --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation-periodic-boundaries.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation-periodic-boundaries.py >session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_histogram_X.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_values_X.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole angular correlation on XYZs and periodic BC, true change])
+AT_KEYWORDS([analysis dipole correlation xyz dipole-angular-correlation])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/pre/watermulti_Y.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_Y.xyz -o xyz -I --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation-periodic-boundaries.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation-periodic-boundaries.py >session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation-periodic-boundaries_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_histogram_Y.$step.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation-PeriodicBoundaries/post/water_values_Y.$step.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
Index: tests/GuiChecks/Analysis/DipoleAngularCorrelation/testsuite-analysis-dipole-angular-correlation.at
===================================================================
--- tests/GuiChecks/Analysis/DipoleAngularCorrelation/testsuite-analysis-dipole-angular-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/DipoleAngularCorrelation/testsuite-analysis-dipole-angular-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,75 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### dipole angular correlation analysis
+
+AT_SETUP([Analysis - dipole angular correlation on PDBs with CONECT, zero change])
+AT_KEYWORDS([analysis dipole correlation pdb dipole-angular-correlation])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/pre/watermulti_X.pdb .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_X.pdb -o pdb --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation.py >session-analysis-dipole-angular-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_histogram_X.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_values_X.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole angular correlation on PDBs with CONECT, true change])
+AT_KEYWORDS([analysis dipole correlation pdb dipole-angular-correlation])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/pre/watermulti_Y.pdb .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_Y.pdb -o pdb --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation.py >session-analysis-dipole-angular-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_histogram_Y.$step.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_values_Y.$step.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole angular correlation on XYZs, zero change])
+AT_KEYWORDS([analysis dipole correlation xyz dipole-angular-correlation])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/pre/watermulti_X.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_X.xyz -o xyz -I --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation.py >session-analysis-dipole-angular-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_histogram_X.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_values_X.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole angular correlation on XYZs, true change])
+AT_KEYWORDS([analysis dipole correlation xyz dipole-angular-correlation])
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/pre/watermulti_Y.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -v 4 -i watermulti_Y.xyz -o xyz -I --dipole-angular-correlation H2O --bin-start -5 --bin-width 10. --bin-end 184.5 --time-step-zero 0 --output-file water_values --bin-output-file water_histogram --no-dry-run --store-session session-analysis-dipole-angular-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-angular-correlation.py >session-analysis-dipole-angular-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-angular-correlation_new.py], 0, [stdout], [stderr])
+i=0; while test $i -ne 36; do 
+	step=`printf %04d $i`
+	AT_CHECK([diff water_histogram.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_histogram_Y.$step.dat], 0, [ignore], [ignore])
+	AT_CHECK([diff water_values.$step.dat ${abs_top_srcdir}/tests/regression/Analysis/DipoleAngularCorrelation/post/water_values_Y.$step.dat], 0, [ignore], [ignore])
+	let i=$i+1
+done
+AT_CLEANUP
+
Index: tests/GuiChecks/Analysis/DipoleCorrelation-DiscreteAngles/testsuite-analysis-dipole-correlation-discrete-angles.at
===================================================================
--- tests/GuiChecks/Analysis/DipoleCorrelation-DiscreteAngles/testsuite-analysis-dipole-correlation-discrete-angles.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/DipoleCorrelation-DiscreteAngles/testsuite-analysis-dipole-correlation-discrete-angles.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,50 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### dipole correlation - discrete angles
+
+AT_SETUP([Analysis - dipole correlation - same aligned])
+AT_KEYWORDS([analysis correlation dipole-correlation])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleCorrelation-DiscreteAngles/pre/water.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -i waterbox.xyz -o xyz -B "10, 0., 10, 0, 0, 10" -l water.xyz --select-molecule-by-order -1 --fill-regular-grid --mesh-size 3 3 3 --mesh-offset "0.,0.,0." --min-distance "1." --DoRotate 0 --no-dry-run --store-session session-analysis-dipole-correlation-discrete-angles.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-discrete-angles.py >session-analysis-dipole-correlation-discrete-angles_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-discrete-angles_new.py], 0, [stdout], [stderr])
+AT_CHECK([../../molecuilder --dry-run -i waterbox.xyz -o xyz -I --select-all-molecules --dipole-correlation --bin-start -0.5 --bin-width 1. --bin-end 359.5 --output-file waterbox_values.dat --bin-output-file waterbox_histogram.dat --no-dry-run --store-session session-analysis-dipole-correlation-discrete-angles.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-discrete-angles.py >session-analysis-dipole-correlation-discrete-angles_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-discrete-angles_new.py], 0, [stdout], [stderr])
+AT_CHECK([file=waterbox_histogram.dat; diff $file ${abs_top_srcdir}/tests/regression/Analysis/DipoleCorrelation-DiscreteAngles/post/waterbox_histogram.dat], 0, [ignore], [ignore])
+
+AT_CLEANUP
+
+
+AT_SETUP([Analysis - dipole correlation - same aligned but one])
+AT_KEYWORDS([analysis correlation dipole-correlation])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/DipoleCorrelation-DiscreteAngles/pre/water.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -i waterbox-mirrored.xyz -o xyz -B "10, 0., 10, 0, 0, 10" -l water.xyz --select-molecule-by-order -1 --fill-regular-grid --mesh-size 3 3 3 --mesh-offset "0.5,0.5,0.5" --min-distance "1." --DoRotate 0 --no-dry-run --store-session session-analysis-dipole-correlation-discrete-angles.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-discrete-angles.py >session-analysis-dipole-correlation-discrete-angles_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-discrete-angles_new.py], 0, [stdout], [stderr])
+AT_CHECK([../../molecuilder --dry-run -i waterbox-mirrored.xyz -I -v 3  --create-shape --shape-name "sphere1" --shape-type "sphere" --translation "5.,5.,5.5" --stretch "0.2,0.2,0.2" --select-shape-by-name "sphere1" --select-atoms-inside-volume --select-atoms-molecules --rotate-around-self 180 --axis "0,1,0" --no-dry-run --store-session session-analysis-dipole-correlation-discrete-angles.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-discrete-angles.py >session-analysis-dipole-correlation-discrete-angles_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-discrete-angles_new.py], 0, [stdout], [stderr])
+AT_CHECK([../../molecuilder --dry-run -i waterbox-mirrored.xyz -o xyz -I --select-all-molecules --dipole-correlation --bin-start -0.5 --bin-width 1. --bin-end 359.5 --output-file waterbox-mirrored_values.dat --bin-output-file waterbox-mirrored_histogram.dat --no-dry-run --store-session session-analysis-dipole-correlation-discrete-angles.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-discrete-angles.py >session-analysis-dipole-correlation-discrete-angles_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-discrete-angles_new.py], 0, [stdout], [stderr])
+AT_CHECK([file=waterbox-mirrored_histogram.dat; diff $file ${abs_top_srcdir}/tests/regression/Analysis/DipoleCorrelation-DiscreteAngles/post/waterbox-mirrored_histogram.dat], 0, [ignore], [ignore])
+
+AT_CLEANUP
Index: tests/GuiChecks/Analysis/DipoleCorrelation-Empty/testsuite-analysis-dipole-correlation-empty.at
===================================================================
--- tests/GuiChecks/Analysis/DipoleCorrelation-Empty/testsuite-analysis-dipole-correlation-empty.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/DipoleCorrelation-Empty/testsuite-analysis-dipole-correlation-empty.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,40 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### dipole correlation - empty
+
+AT_SETUP([Analysis - dipole correlation - Empty domain])
+AT_KEYWORDS([analysis correlation dipole-correlation])
+AT_CHECK([../../molecuilder --dry-run -i emptybox.xyz -o xyz --select-molecules-by-formula H2O --dipole-correlation --bin-start 0 --bin-width 1. --bin-end 359 --output-file emptybox_values.dat --bin-output-file emptybox_histogram.dat --no-dry-run --store-session session-analysis-dipole-correlation-empty.py --session-type python], 0, [ignore], [ignore])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-empty.py >session-analysis-dipole-correlation-empty_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-empty_new.py], 0, [ignore], [ignore])
+AT_CHECK([file=emptybox_histogram.dat; diff $file ${abs_top_srcdir}/tests/regression/Analysis/DipoleCorrelation-Empty/post/emptybox_histogram.dat], 0, [ignore], [ignore])
+AT_CLEANUP
+
+AT_SETUP([Analysis - dipole correlation - Domain filled with hydrogen])
+AT_KEYWORDS([analysis correlation dipole-correlation])
+AT_CHECK([../../molecuilder --dry-run -i hydrogen.xyz -o xyz --add-atom 1 --domain-position "0,0,0" --no-dry-run --store-session session-analysis-dipole-correlation-empty.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-empty.py >session-analysis-dipole-correlation-empty_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-empty_new.py], 0, [stdout], [stderr])
+AT_CHECK([../../molecuilder --dry-run -i hydrogenbox.xyz -B "18.6, 0., 18.6, 0, 0, 18.6" -o xyz -l hydrogen.xyz --select-molecule-by-order -1 --fill-regular-grid --mesh-size 6 6 6 --mesh-offset "0.,0.,0." --DoRotate 0 --no-dry-run --store-session session-analysis-dipole-correlation-empty.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-empty.py >session-analysis-dipole-correlation-empty_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-empty_new.py], 0, [stdout], [stderr])
+AT_CHECK([../../molecuilder --dry-run -i hydrogenbox.xyz -o xyz --select-molecules-by-formula H2O --dipole-correlation --bin-start 0 --bin-width 1. --bin-end 359 --output-file hydrogenbox_values.dat --bin-output-file hydrogenbox_histogram.dat --no-dry-run --store-session session-analysis-dipole-correlation-empty.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-dipole-correlation-empty.py >session-analysis-dipole-correlation-empty_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-dipole-correlation-empty_new.py], 0, [stdout], [stderr])
+AT_CHECK([file=hydrogenbox_histogram.dat; diff $file ${abs_top_srcdir}/tests/regression/Analysis/DipoleCorrelation-Empty/post/hydrogenbox_histogram.dat], 0, [ignore], [ignore])
+AT_CLEANUP
Index: tests/GuiChecks/Analysis/PairCorrelation-RangeTest/testsuite-analysis-pair-correlation-range-test.at
===================================================================
--- tests/GuiChecks/Analysis/PairCorrelation-RangeTest/testsuite-analysis-pair-correlation-range-test.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/PairCorrelation-RangeTest/testsuite-analysis-pair-correlation-range-test.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,44 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### pair correlation analysis - range test
+
+AT_SETUP([Analysis - pair correlation range test])
+AT_KEYWORDS([analysis correlation pair-correlation])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/pre/test.conf .], 0)
+AT_CHECK([../../molecuilder --dry-run -i test.conf  -v 3 --set-boundary-conditions Wrap Wrap Wrap --pair-correlation --elements 1 8 --output-file output-5.csv --bin-output-file bin_output-5.csv --bin-start 0 --bin-end 5 --no-dry-run --store-session session-analysis-pair-correlation-range-test.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-pair-correlation-range-test.py >session-analysis-pair-correlation-range-test_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-pair-correlation-range-test_new.py], 0, [stdout], [stderr])
+#AT_CHECK([file=output-5.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/post/output-5.csv], 0, [ignore], [ignore])
+AT_CHECK([file=bin_output-5.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/post/bin_output-5.csv], 0, [ignore], [ignore])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/pre/test.conf .], 0)
+AT_CHECK([../../molecuilder --dry-run -i test.conf  -v 3 --set-boundary-conditions Wrap Wrap Wrap --pair-correlation --elements 1 8 --output-file output-10.csv --bin-output-file bin_output-10.csv --bin-start 5 --bin-end 10 --no-dry-run --store-session session-analysis-pair-correlation-range-test.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-pair-correlation-range-test.py >session-analysis-pair-correlation-range-test_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-pair-correlation-range-test_new.py], 0, [stdout], [stderr])
+#AT_CHECK([file=output-10.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/post/output-10.csv], 0, [ignore], [ignore])
+AT_CHECK([file=bin_output-10.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/post/bin_output-10.csv], 0, [ignore], [ignore])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/pre/test.conf .], 0)
+AT_CHECK([../../molecuilder --dry-run -i test.conf  -v 3 --set-boundary-conditions Wrap Wrap Wrap --pair-correlation --elements 1 8 --output-file output-20.csv --bin-output-file bin_output-20.csv --bin-start 10 --bin-end 20 --no-dry-run --store-session session-analysis-pair-correlation-range-test.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-pair-correlation-range-test.py >session-analysis-pair-correlation-range-test_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-pair-correlation-range-test_new.py], 0, [stdout], [stderr])
+#AT_CHECK([file=output-20.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/post/output-20.csv], 0, [ignore], [ignore])
+AT_CHECK([file=bin_output-20.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation-RangeTest/post/bin_output-20.csv], 0, [ignore], [ignore])
+
+AT_CLEANUP
Index: tests/GuiChecks/Analysis/PairCorrelation/testsuite-analysis-pair-correlation.at
===================================================================
--- tests/GuiChecks/Analysis/PairCorrelation/testsuite-analysis-pair-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/PairCorrelation/testsuite-analysis-pair-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,37 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### pair correlation analysis
+
+AT_SETUP([Analysis - pair correlation])
+AT_KEYWORDS([analysis correlation pair-correlation])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation/pre/test.conf .], 0)
+AT_CHECK([../../molecuilder --dry-run -i test.conf  -v 3 --set-boundary-conditions Wrap Wrap Wrap --pair-correlation --elements 1 8 --output-file output.csv --bin-output-file bin_output.csv --bin-start 0 --bin-end 20 --no-dry-run --store-session session-analysis-pair-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-pair-correlation.py >session-analysis-pair-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-pair-correlation_new.py], 0, [stdout], [stderr])
+#AT_CHECK([file=output.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation/post/output.csv], 0, [ignore], [ignore])
+AT_CHECK([file=bin_output.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PairCorrelation/post/bin_output.csv], 0, [ignore], [ignore])
+sum=0;
+for num in `tail -n 41 bin_output.csv | awk -F" " {'print $4'}`; do 
+	let sum=$sum+$num; 
+done; 
+# 31 oxygens on 62 hydrogens yields 1922 values
+AT_CHECK([test $sum -eq 1922], 0, [ignore], [ignore])
+
+AT_CLEANUP
+
Index: tests/GuiChecks/Analysis/PointCorrelation/testsuite-analysis-point-correlation.at
===================================================================
--- tests/GuiChecks/Analysis/PointCorrelation/testsuite-analysis-point-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/PointCorrelation/testsuite-analysis-point-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,30 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### pair correlation analysis to point
+
+AT_SETUP([Analysis - point correlation])
+AT_KEYWORDS([analysis correlation point-correlation])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/PointCorrelation/pre/test.conf .], 0)
+AT_CHECK([../../molecuilder --dry-run -i test.conf  -v 7 --select-all-molecules --point-correlation --elements 1 --position "10., 10., 10." --output-file output.csv --bin-output-file bin_output.csv --bin-start 0 --bin-end 20 --no-dry-run --store-session session-analysis-point-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-point-correlation.py >session-analysis-point-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-point-correlation_new.py], 0, [stdout], [stderr])
+#AT_CHECK([file=output.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PointCorrelation/post/output.csv], 0, [ignore], [ignore])
+AT_CHECK([file=bin_output.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/PointCorrelation/post/bin_output.csv], 0, [ignore], [ignore])
+
+AT_CLEANUP
Index: tests/GuiChecks/Analysis/PrincipalAxisSystem/testsuite-analysis-principal-axis-system.at
===================================================================
--- tests/GuiChecks/Analysis/PrincipalAxisSystem/testsuite-analysis-principal-axis-system.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/PrincipalAxisSystem/testsuite-analysis-principal-axis-system.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,28 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### principal axis system
+
+AT_SETUP([Analysis - Principal Axis System])
+AT_KEYWORDS([analysis correlation principal-axis-system])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/PrincipalAxisSystem/pre/water.xyz .], 0)
+AT_CHECK([../../molecuilder --dry-run -i water.xyz -v 3 --select-all-molecules --principal-axis-system --no-dry-run --store-session session-analysis-principal-axis-system.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-principal-axis-system.py >session-analysis-principal-axis-system_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-principal-axis-system_new.py], 0, [stdout], [stderr])
+
+AT_CLEANUP
Index: tests/GuiChecks/Analysis/SurfaceCorrelation/testsuite-analysis-surface-correlation.at
===================================================================
--- tests/GuiChecks/Analysis/SurfaceCorrelation/testsuite-analysis-surface-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/SurfaceCorrelation/testsuite-analysis-surface-correlation.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,30 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+### pair correlation analysis to surface
+
+AT_SETUP([Analysis - surface correlation])
+AT_KEYWORDS([analysis correlation surface-correlation])
+
+AT_CHECK([/bin/cp -f ${abs_top_srcdir}/tests/regression/Analysis/SurfaceCorrelation/pre/test.conf .], 0)
+AT_CHECK([../../molecuilder --dry-run -i test.conf  -v 3 -I --select-molecule-by-id 0 --select-molecules-atoms --unselect-all-molecules --select-all-molecules --unselect-molecules-by-formula C3H8 --surface-correlation --elements 1 --output-file output.csv --bin-output-file bin_output.csv --bin-start 0 --bin-width 1. --bin-end 20 --no-dry-run --store-session session-analysis-surface-correlation.py --session-type python], 0, [stdout], [stderr])
+AT_CHECK([grep -v "Command.*DryRun" session-analysis-surface-correlation.py >session-analysis-surface-correlation_new.py], 0, [ignore], [ignore])
+AT_CHECK([../../molecuilderguitest session-analysis-surface-correlation_new.py], 0, [stdout], [stderr])
+#AT_CHECK([file=output.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/SurfaceCorrelation/post/output.csv], 0, [ignore], [ignore])
+AT_CHECK([file=bin_output.csv; diff $file ${abs_top_srcdir}/tests/regression/Analysis/SurfaceCorrelation/post/bin_output.csv], 0, [ignore], [ignore])
+
+AT_CLEANUP
Index: tests/GuiChecks/Analysis/testsuite-analysis.at
===================================================================
--- tests/GuiChecks/Analysis/testsuite-analysis.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
+++ tests/GuiChecks/Analysis/testsuite-analysis.at	(revision dd6c07d2c5d563c8e46c0a4b01a0de11563eb584)
@@ -0,0 +1,45 @@
+#
+#    MoleCuilder - creates and alters molecular systems
+#    Copyright (C) 2008-2012 University of Bonn
+#
+#    This program is free software: you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation, either version 3 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#
+AT_BANNER([MoleCuilder - Analysis])
+
+# pair correlation analysis
+m4_include(Analysis/PairCorrelation/testsuite-analysis-pair-correlation.at)
+
+# pair correlation analysis - range test
+m4_include(Analysis/PairCorrelation-RangeTest/testsuite-analysis-pair-correlation-range-test.at)
+
+# pair correlation analysis to point
+m4_include(Analysis/PointCorrelation/testsuite-analysis-point-correlation.at)
+
+# pair correlation analysis to surface
+m4_include(Analysis/SurfaceCorrelation/testsuite-analysis-surface-correlation.at)
+
+# principal axis system
+m4_include(Analysis/PrincipalAxisSystem/testsuite-analysis-principal-axis-system.at)
+
+# dipole angular correlation
+m4_include(Analysis/DipoleAngularCorrelation/testsuite-analysis-dipole-angular-correlation.at)
+
+# dipole angular correlation with periodic boundaries
+m4_include(Analysis/DipoleAngularCorrelation-PeriodicBoundaries/testsuite-analysis-dipole-angular-correlation-periodic-boundaries.at)
+
+# dipole correlation - empty
+m4_include(Analysis/DipoleCorrelation-Empty/testsuite-analysis-dipole-correlation-empty.at)
+
+# dipole correlation - discrete angles
+m4_include(Analysis/DipoleCorrelation-DiscreteAngles/testsuite-analysis-dipole-correlation-discrete-angles.at)
