[hkl] 01/06: New upstream version 5.0.0.2428

Frédéric-Emmanuel Picca picca at moszumanska.debian.org
Mon Dec 4 07:06:59 UTC 2017


This is an automated email from the git hooks/post-receive script.

picca pushed a commit to branch master
in repository hkl.

commit 092256cc7a017571d8900f3a0d979255a02c1588
Author: Picca Frédéric-Emmanuel <picca at debian.org>
Date:   Sat Dec 2 17:29:04 2017 +0100

    New upstream version 5.0.0.2428
---
 ChangeLog                                          | 3080 +++++++++++++++++++-
 Documentation/Makefile.am                          |    7 +-
 Documentation/Makefile.in                          |   12 +-
 Documentation/api/Makefile.in                      |   86 +-
 Documentation/api/html/annotation-glossary.html    |    4 +-
 Documentation/api/html/api-index-full.html         |  648 +++-
 Documentation/api/html/ch01.html                   |    4 +-
 Documentation/api/html/deprecated-api-index.html   |    4 +-
 Documentation/api/html/hkl-array-size.html         |    4 +-
 Documentation/api/html/hkl-autodata.html           |    4 +-
 Documentation/api/html/hkl-build-assert.html       |    4 +-
 Documentation/api/html/hkl-check-type.html         |    4 +-
 Documentation/api/html/hkl-compiler.html           |    4 +-
 Documentation/api/html/hkl-container-of.html       |    4 +-
 Documentation/api/html/hkl-darray.html             |   41 +-
 Documentation/api/html/hkl-hkl-axis-private.html   |   86 +-
 .../api/html/hkl-hkl-detector-private.html         |    8 +-
 .../api/html/hkl-hkl-factory-private.html          |    4 +-
 .../api/html/hkl-hkl-geometry-private.html         |  231 +-
 .../api/html/hkl-hkl-interval-private.html         |    4 +-
 .../api/html/hkl-hkl-lattice-private.html          |    4 +-
 Documentation/api/html/hkl-hkl-macros-private.html |    4 +-
 Documentation/api/html/hkl-hkl-matrix-private.html |    4 +-
 .../api/html/hkl-hkl-parameter-private.html        |   99 +-
 .../api/html/hkl-hkl-pseudoaxis-auto-private.html  |   12 +-
 ...kl-hkl-pseudoaxis-common-eulerians-private.html |    4 +-
 .../hkl-hkl-pseudoaxis-common-hkl-private.html     |   26 +-
 .../hkl-hkl-pseudoaxis-common-psi-private.html     |   80 +-
 .../html/hkl-hkl-pseudoaxis-common-q-private.html  |   71 +-
 .../api/html/hkl-hkl-pseudoaxis-private.html       |   10 +-
 .../api/html/hkl-hkl-quaternion-private.html       |    8 +-
 Documentation/api/html/hkl-hkl-sample-private.html |    5 +-
 Documentation/api/html/hkl-hkl-source-private.html |    4 +-
 Documentation/api/html/hkl-hkl-type-builtins.html  |   13 +-
 Documentation/api/html/hkl-hkl-types.html          |    4 +-
 Documentation/api/html/hkl-hkl-unit-private.html   |   81 +-
 Documentation/api/html/hkl-hkl-vector-private.html |    4 +-
 Documentation/api/html/hkl-hkl.html                |   40 +-
 Documentation/api/html/hkl-list.html               |    4 +-
 Documentation/api/html/hkl-noerr.html              |    4 +-
 Documentation/api/html/hkl-ptr-valid.html          |    4 +-
 Documentation/api/html/hkl-str-debug.html          |    4 +-
 Documentation/api/html/hkl-str.html                |    4 +-
 Documentation/api/html/hkl.devhelp2                |   49 +-
 Documentation/api/html/home.png                    |  Bin 256 -> 256 bytes
 Documentation/api/html/index.html                  |    4 +-
 Documentation/api/html/left-insensitive.png        |  Bin 395 -> 395 bytes
 Documentation/api/html/left.png                    |  Bin 262 -> 262 bytes
 Documentation/api/html/object-tree.html            |    4 +-
 Documentation/api/html/right-insensitive.png       |  Bin 373 -> 373 bytes
 Documentation/api/html/right.png                   |  Bin 261 -> 261 bytes
 Documentation/api/html/up-insensitive.png          |  Bin 374 -> 374 bytes
 Documentation/api/html/up.png                      |  Bin 260 -> 260 bytes
 Documentation/css/style.css                        |  445 +++
 Documentation/figures/3S+1D.png                    |  Bin 138201 -> 142786 bytes
 Documentation/figures/4S+2D.png                    |  Bin 165279 -> 172674 bytes
 Documentation/figures/4S+2D_reciprocal.png         |  Bin 200891 -> 283563 bytes
 Documentation/figures/4S+2D_reciprocal2.png        |  Bin 193284 -> 276519 bytes
 Documentation/figures/4S+2D_reciprocal3.png        |  Bin 191481 -> 274773 bytes
 Documentation/figures/4S+2D_reciprocal4.png        |  Bin 204865 -> 293774 bytes
 Documentation/figures/B_a.asy                      |    2 +
 Documentation/figures/B_a.png                      |  Bin 16664 -> 19065 bytes
 Documentation/figures/B_b.asy                      |    3 +
 Documentation/figures/B_b.png                      |  Bin 16197 -> 14029 bytes
 Documentation/figures/B_b3_y.png                   |  Bin 16617 -> 19022 bytes
 Documentation/figures/Makefile.am                  |   48 +-
 Documentation/figures/Makefile.in                  |  239 +-
 Documentation/figures/crystal.png                  |  Bin 40637 -> 45364 bytes
 Documentation/figures/e2k_1.png                    |  Bin 157772 -> 182053 bytes
 Documentation/figures/e2k_2.png                    |  Bin 137757 -> 161626 bytes
 Documentation/figures/e2k_3.png                    |  Bin 168475 -> 192301 bytes
 Documentation/figures/e2k_4.png                    |  Bin 161113 -> 179107 bytes
 Documentation/figures/k4cv.png                     |  Bin 99279 -> 102524 bytes
 Documentation/figures/k6c.png                      |  Bin 125411 -> 132688 bytes
 Documentation/figures/m1-101.dat                   |  103 +
 Documentation/figures/m1-11.dat                    |   13 +
 Documentation/figures/m2-101.dat                   |  103 +
 Documentation/figures/m2-11.dat                    |   13 +
 Documentation/figures/med2_3_slits.png             |  Bin 56301 -> 62470 bytes
 Documentation/figures/qper_qpar.asy                |    3 +
 Documentation/figures/qper_qpar.png                |  Bin 48355 -> 33997 bytes
 Documentation/figures/s1-101.dat                   |  103 +
 Documentation/figures/s1-11.dat                    |   13 +
 Documentation/figures/s2-101.dat                   |  103 +
 Documentation/figures/s2-11.dat                    |   13 +
 Documentation/figures/sirius.c                     |  208 ++
 Documentation/figures/traj_n.dat                   |  102 +
 Documentation/figures/zaxis.asy                    |    5 +-
 Documentation/figures/zaxis.png                    |  Bin 201176 -> 328356 bytes
 Documentation/hkl-default.el                       |   37 +-
 Documentation/hkl.html                             |  900 ++++--
 Documentation/hkl.org.in                           |  199 +-
 Documentation/sphinx/Makefile.in                   |    5 +-
 INSTALL                                            |  320 +-
 Makefile.am                                        |   17 +-
 Makefile.in                                        |   34 +-
 aclocal.m4                                         |   62 +-
 config/config.guess                                |   28 +-
 config/config.sub                                  |   22 +-
 config/depcomp                                     |    6 +-
 configure                                          |   67 +-
 configure.ac                                       |    3 +
 contrib/Makefile.in                                |    5 +-
 contrib/sixs/Makefile.in                           |    5 +-
 contrib/sixs/hkl3d.c                               |    2 +-
 data/Makefile.in                                   |    5 +-
 gtk-doc.make                                       |   82 +-
 gui/Makefile.in                                    |    5 +-
 gui/hkl-gui-3d.c                                   |    2 +-
 gui/hkl-gui-3d.h                                   |    2 +-
 gui/hkl-gui-macros.h                               |    2 +-
 gui/hkl-gui.c                                      |  166 +-
 gui/hkl-gui.h                                      |    2 +-
 hkl.h                                              |  108 +-
 hkl/Makefile.am                                    |    5 +-
 hkl/Makefile.in                                    |   40 +-
 hkl/api2/Makefile.am                               |   14 +
 {tests/tap => hkl/api2}/Makefile.in                |  101 +-
 hkl/api2/hkl2.c                                    |  326 +++
 hkl/api2/hkl2.h                                    |  306 ++
 hkl/ccan/Makefile.am                               |   10 +-
 hkl/ccan/Makefile.in                               |   48 +-
 hkl/ccan/alignof/alignof.h                         |   20 +
 hkl/ccan/autodata/autodata.c                       |    2 +-
 hkl/ccan/ccan_config.h                             |    6 +-
 hkl/ccan/configurator.c                            |  256 +-
 hkl/ccan/coroutine/coroutine.c                     |  229 ++
 hkl/ccan/coroutine/coroutine.h                     |  260 ++
 hkl/ccan/cppmagic/cppmagic.h                       |  191 ++
 hkl/ccan/darray/darray.h                           |   76 +-
 hkl/ccan/generator/generator.c                     |   55 +
 hkl/ccan/generator/generator.h                     |  220 ++
 hkl/ccan/list/list.h                               |   23 +-
 hkl/ccan/ptr_valid/ptr_valid.c                     |   11 +-
 hkl/ccan/ptrint/ptrint.h                           |   35 +
 hkl/ccan/str/str.h                                 |    2 +-
 hkl/ccan/typesafe_cb/typesafe_cb.h                 |  134 +
 hkl/hkl-axis-private.h                             |   27 +-
 hkl/hkl-axis.c                                     |  262 +-
 hkl/hkl-binding-private.h                          |    2 +-
 hkl/hkl-binding.c                                  |    2 +-
 hkl/hkl-detector-factory.c                         |    2 +-
 hkl/hkl-detector-private.h                         |    2 +-
 hkl/hkl-detector.c                                 |    6 +-
 hkl/hkl-engine-2c.c                                |    8 +-
 hkl/hkl-engine-e4c.c                               |   44 +-
 hkl/hkl-engine-e6c.c                               |   16 +-
 hkl/hkl-engine-k4c.c                               |   12 +-
 hkl/hkl-engine-k6c.c                               |   37 +-
 hkl/hkl-engine-petra3-p08-lisa.c                   |  693 +++++
 hkl/hkl-engine-petra3-p09-eh2.c                    |   18 +-
 hkl/hkl-engine-soleil-sirius-turret.c              |   18 +-
 hkl/hkl-engine-soleil-sixs-med.c                   |   48 +-
 hkl/hkl-engine-template.c                          |   16 +-
 hkl/hkl-engine-zaxis.c                             |   14 +-
 hkl/hkl-factory-private.h                          |    2 +-
 hkl/hkl-factory.c                                  |    2 +-
 hkl/hkl-geometry-private.h                         |   96 +-
 hkl/hkl-geometry.c                                 |  191 +-
 hkl/hkl-interval-private.h                         |    2 +-
 hkl/hkl-interval.c                                 |    2 +-
 hkl/hkl-lattice-private.h                          |    2 +-
 hkl/hkl-lattice.c                                  |    6 +-
 hkl/hkl-macros-private.h                           |    2 +-
 hkl/hkl-macros.c                                   |    2 +-
 hkl/hkl-matrix-private.h                           |    2 +-
 hkl/hkl-matrix.c                                   |    2 +-
 hkl/hkl-parameter-private.h                        |   29 +-
 hkl/hkl-parameter.c                                |   31 +-
 hkl/hkl-pseudoaxis-auto-private.h                  |    2 +-
 hkl/hkl-pseudoaxis-auto.c                          |    2 +-
 hkl/hkl-pseudoaxis-common-eulerians-private.h      |    2 +-
 hkl/hkl-pseudoaxis-common-eulerians.c              |    2 +-
 hkl/hkl-pseudoaxis-common-hkl-private.h            |    4 +-
 hkl/hkl-pseudoaxis-common-hkl.c                    |  100 +-
 hkl/hkl-pseudoaxis-common-psi-private.h            |    2 +-
 hkl/hkl-pseudoaxis-common-psi.c                    |   24 +-
 hkl/hkl-pseudoaxis-common-q-private.h              |    2 +-
 hkl/hkl-pseudoaxis-common-q.c                      |   26 +-
 hkl/hkl-pseudoaxis-common-readonly-private.h       |    2 +-
 hkl/hkl-pseudoaxis-common-readonly.c               |   29 +-
 hkl/hkl-pseudoaxis-common-tth-private.h            |    2 +-
 hkl/hkl-pseudoaxis-common-tth.c                    |    6 +-
 hkl/hkl-pseudoaxis-private.h                       |   44 +-
 hkl/hkl-pseudoaxis.c                               |    8 +-
 hkl/hkl-quaternion-private.h                       |    2 +-
 hkl/hkl-quaternion.c                               |    2 +-
 hkl/hkl-sample-private.h                           |    3 +-
 hkl/hkl-sample.c                                   |   33 +-
 hkl/hkl-source-private.h                           |    2 +-
 hkl/hkl-source.c                                   |    2 +-
 hkl/hkl-trajectory-private.h                       |   61 +
 hkl/hkl-trajectory.c                               |  139 +
 hkl/hkl-type-builtins.c                            |    5 -
 hkl/hkl-types.c                                    |    2 +-
 hkl/hkl-types.h                                    |    2 +-
 hkl/hkl-unit-private.h                             |   41 +-
 hkl/hkl-unit.c                                     |  142 +-
 hkl/hkl-vector-private.h                           |    2 +-
 hkl/hkl-vector.c                                   |    2 +-
 hkl3d/Makefile.in                                  |    5 +-
 hkl3d/hkl3d.cpp                                    |   49 +-
 hkl3d/hkl3d.h                                      |   53 +-
 tests/Makefile.am                                  |   18 +-
 tests/Makefile.in                                  |   84 +-
 tests/bindings/Makefile.in                         |    5 +-
 tests/hkl-axis-t.c                                 |  135 +-
 tests/hkl-bench-t.c                                |    2 +-
 tests/hkl-detector-t.c                             |   10 +-
 tests/hkl-geometry-t.c                             |  187 +-
 tests/hkl-interval-t.c                             |    2 +-
 tests/hkl-lattice-t.c                              |   16 +-
 tests/hkl-matrix-t.c                               |    2 +-
 tests/hkl-parameter-t.c                            |    2 +-
 tests/hkl-pseudoaxis-e4ch-t.c                      |   96 +-
 tests/hkl-pseudoaxis-e4cv-t.c                      |   82 +-
 tests/hkl-pseudoaxis-e6c-t.c                       |   94 +-
 tests/hkl-pseudoaxis-k4cv-t.c                      |   29 +-
 tests/hkl-pseudoaxis-k6c-t.c                       |   40 +-
 tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c       |  102 +
 tests/hkl-pseudoaxis-soleil-sixs-med-t.c           |   69 +-
 tests/hkl-pseudoaxis-t.c                           |    4 +-
 tests/hkl-pseudoaxis-zaxis-t.c                     |   37 +-
 tests/hkl-quaternion-t.c                           |    2 +-
 tests/hkl-sample-t.c                               |    2 +-
 tests/hkl-source-t.c                               |    2 +-
 tests/hkl-unit-t.c                                 |    2 +-
 tests/hkl-vector-t.c                               |    2 +-
 tests/hkl3d-test-t.c                               |   35 +-
 tests/tap/Makefile.in                              |    5 +-
 tests/tap/basic.h                                  |   18 +-
 tests/tap/hkl-tap.h                                |    3 +-
 232 files changed, 11710 insertions(+), 2547 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 6af55cb..f06b5cf 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,3015 @@
 # Generated by Makefile. Do not edit.
 
+commit fe6aedad472f4fbfc5709619350538f72fdb870f
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 16:18:06 2017 +0100
+
+    [doc] fix figure generation with asy
+
+ Documentation/figures/B_a.asy       | 2 ++
+ Documentation/figures/B_b.asy       | 3 +++
+ Documentation/figures/qper_qpar.asy | 3 +++
+ Documentation/figures/zaxis.asy     | 5 +++--
+ 4 files changed, 11 insertions(+), 2 deletions(-)
+
+commit eb16beb5e964af0dd7f65b0a83e06b092caff539
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 15:03:29 2017 +0100
+
+    [buildsys] fix the release target
+
+ Makefile.am | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+commit c5f86fd4c795b1dfc99fb120c45f25e25538a7d5
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 14:24:30 2017 +0100
+
+    pre-release
+
+ gui/hkl-gui.c                    | 164 ++++++++---------
+ hkl/hkl-axis.c                   |  10 +-
+ hkl/hkl-engine-petra3-p08-lisa.c | 386 +++++++++++++++++++--------------------
+ hkl/hkl-parameter.c              |   2 +-
+ tests/hkl-lattice-t.c            |  14 +-
+ tests/tap/basic.h                |  18 +-
+ 6 files changed, 297 insertions(+), 297 deletions(-)
+
+commit b1c0c09be0f119d4b696bb84c1179cf7857d37b6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 13:40:02 2017 +0100
+
+    [contrib][six] restore at the right place
+
+ contrib/{python => }/sixs/Makefile.am | 0
+ contrib/{python => }/sixs/hkl3d.c     | 0
+ 2 files changed, 0 insertions(+), 0 deletions(-)
+
+commit 59c950a08f70aaa9151a5442abe1da61d072373a
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 12:38:35 2017 +0100
+
+    [hkl] updated ccan
+
+ hkl/ccan/Makefile.am     | 34 +++++++++++-----------
+ hkl/ccan/configurator.c  |  2 ++
+ hkl/ccan/darray/darray.h | 76 ++++++++++++++++++++++++++----------------------
+ 3 files changed, 61 insertions(+), 51 deletions(-)
+
+commit 228b4e0cb1849f683be6483707140c31d62756aa
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 12:33:53 2017 +0100
+
+    [hkl] updated INSTALL file
+
+ INSTALL | 320 ++++++++++++++++++++++++++++++++--------------------------------
+ 1 file changed, 159 insertions(+), 161 deletions(-)
+
+commit 7c53552f451edca75fc5635fdd3537d58ed0e46c
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Dec 2 12:33:37 2017 +0100
+
+    [hkl] remove an useless fprintf
+
+ hkl/api2/hkl2.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit df37f0e7e9a9dc5fc304195cba74dff3cfa2731b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 21 16:35:38 2017 +0100
+
+    [contrib][diffabs] add the 20170063 project
+
+ contrib/python/20170063.py | 254 +++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 254 insertions(+)
+
+commit 62f28309a5aa1fcf2ced1cf0321dd8a2d4984d31
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 21 13:52:54 2017 +0100
+
+    [contrib][mars] integrate the samples.
+
+ contrib/python/mars.py | 218 ++++++++++++++++++++++++++-----------------------
+ 1 file changed, 117 insertions(+), 101 deletions(-)
+
+commit dd6e94d2a10ddcd5114b19b4c2c392b6b406f98e
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 21 10:38:49 2017 +0100
+
+    [contrib][python] reorganise with the common part
+
+ contrib/python/{cristal => }/common.py       | 0
+ contrib/python/{mars/20160800.py => mars.py} | 0
+ contrib/python/{cristal => }/mythen.py       | 0
+ 3 files changed, 0 insertions(+), 0 deletions(-)
+
+commit 1e4df1afecf9f05d86bb8b1e89443a926a74f43f
+Author: akira <akira at cristal4.exp.synchrotron-soleil.fr>
+Date:   Thu Nov 16 21:21:56 2017 +0100
+
+    [contrib][cristal] add the mythen calibration
+
+ contrib/python/cristal/common.py |  68 +++++++++
+ contrib/python/cristal/mythen.py | 306 +++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 374 insertions(+)
+
+commit 1b5cffc92d57c179d575a0ff5d44cd07f16fbf0c
+Author: akira <akira at cristal4.exp.synchrotron-soleil.fr>
+Date:   Thu Nov 16 10:50:22 2017 +0100
+
+    [contrib][python] reorganize has a python module
+
+ contrib/{ => python}/cirpad/blender_pyfai.py |   0
+ contrib/{ => python}/mars/20160800.py        |   0
+ contrib/{ => python}/sixs/Makefile.am        |   0
+ contrib/{ => python}/sixs/hkl3d.c            |   0
+ contrib/{ => python}/swing/pinhole1.smv      | Bin
+ contrib/{ => python}/swing/plot.py           |   0
+ 6 files changed, 0 insertions(+), 0 deletions(-)
+
+commit 7c4c84036c59ddd28976f8423cd8efd7cacb2a22
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 14 15:08:11 2017 +0100
+
+    [contrib][mars] more type hinting and create a MultiCalib class
+
+ contrib/mars/20160800.py | 201 +++++++++++++++++++++++++++--------------------
+ 1 file changed, 115 insertions(+), 86 deletions(-)
+
+commit 30aca20d61aabdc2d07612dbca2045b07ddbdc2d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Nov 13 16:32:22 2017 +0100
+
+    [contrib][mars] reworked the mars script in order to use H5PathWithAttribute
+
+ contrib/mars/20160800.py | 129 +++++++++++++++++++++++------------------------
+ 1 file changed, 63 insertions(+), 66 deletions(-)
+
+commit 559df55fa251e09792efa31900ff797aa6cf3872
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Oct 18 10:36:56 2017 +0200
+
+    [contrib][diffabs] add hamon scripts using pyFAI multicalib
+
+ contrib/diffabs/hamon.py | 311 +++++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 311 insertions(+)
+
+commit 882b2df2cfa30674edff45bc1bb71650ef3df7eb
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 16 19:20:30 2017 +0200
+
+    [contrib][mars] use get_item for tx
+
+ contrib/mars/20160800.py | 48 ++++++++++++++++++++++--------------------------
+ 1 file changed, 22 insertions(+), 26 deletions(-)
+
+commit f969a2c0a9721ee25c7f7f12ce336aa801ba3871
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 16 19:02:17 2017 +0200
+
+    [contrib][mars] rename H5OptionalItemValue -> H5PathOptionalItemValue
+
+ contrib/mars/20160800.py | 15 ++++++++-------
+ 1 file changed, 8 insertions(+), 7 deletions(-)
+
+commit 9081ac75a27468872b7c7ef8f71868ac32f5b2ad
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 16 18:53:52 2017 +0200
+
+    [contrib][mars] rework in order to use the DataSource
+
+ contrib/mars/20160800.py | 52 ++++++++++++++++++++++++------------------------
+ 1 file changed, 26 insertions(+), 26 deletions(-)
+
+commit 40f4c93297f3f12d560b3b91331b52ebef0cedfc
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 16 18:02:13 2017 +0200
+
+    [contrib][mars] wip integrate
+
+ contrib/mars/20160800.py | 44 +++++++++++++++++++++++++++++++++++++-------
+ 1 file changed, 37 insertions(+), 7 deletions(-)
+
+commit 5e6d45c63ad18920df02b3cc798d0754983885b9
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 16 17:15:01 2017 +0200
+
+    [contrib][mars] add the first working version for the tx,tz calibration
+
+ contrib/mars/20160800.py | 54 ++++++++++++++++++++++++++++++------------------
+ 1 file changed, 34 insertions(+), 20 deletions(-)
+
+commit d7fd84e1b7bd1eb411812f25161b51fc9a6d5d8c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 16 16:31:33 2017 +0200
+
+    [contrib][mars] add the 20160800 project
+
+ contrib/mars/20160800.py | 285 +++++++++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 285 insertions(+)
+
+commit aa14402d9485335904f62970974eaf2afda80769
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Tue Aug 15 10:40:21 2017 +0200
+
+    [hkl] remove a bunch of warnings
+
+ hkl/hkl-engine-soleil-sixs-med.c |  4 ----
+ hkl/hkl-geometry-private.h       | 16 ++++++++--------
+ hkl/hkl-geometry.c               |  2 ++
+ 3 files changed, 10 insertions(+), 12 deletions(-)
+
+commit c18ea35f9b8563d521b077cd576dc45515ec8f03
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Aug 14 19:05:29 2017 +0200
+
+    wip petra3 p01
+
+ Documentation/figures/sirius.c               |  7 +++--
+ hkl/api2/hkl2.c                              | 43 +++++++++++++++++-----------
+ hkl/api2/hkl2.h                              | 13 +++++++--
+ hkl/hkl-engine-e4c.c                         | 10 +++----
+ tests/hkl-pseudoaxis-e4ch-t.c                | 35 +++++++++++++++++++++-
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 12 ++++----
+ 6 files changed, 87 insertions(+), 33 deletions(-)
+
+commit eb4d5398e340416f69cbf137cfb75e0ac4cea434
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Aug 14 10:52:29 2017 +0200
+
+    [doc] update changelog
+
+ Documentation/hkl.org.in | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+commit 98573f2933dca2ca2ef5f2973b2ca8c47bdb0cfa
+Merge: d39a9ed5 568d17d2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Aug 14 10:33:01 2017 +0200
+
+    Merge branch 'maint' into next
+    
+    # Conflicts:
+    #       Documentation/Makefile.am
+    #       hkl/pom.xml
+
+commit 568d17d2334c3ac01e6da3c21c95248a65c73fde
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 17 19:19:24 2016 +0200
+
+    [buildsys] add a publish target for the org-mode documentation
+
+ Documentation/Makefile.am | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+commit 94f91ddbcd15785c134491ed68adffa389b1fad6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Aug 13 11:03:50 2017 +0200
+
+    [hkl3d] fix FTBFS with 2.86.1
+
+ hkl3d/hkl3d.cpp      | 43 ++++++++++---------------------------------
+ tests/hkl3d-test-t.c | 33 ++++++++++++++++++++-------------
+ 2 files changed, 30 insertions(+), 46 deletions(-)
+
+commit 2a58a31c5f81e23dd97ed10dad5c3284910475d6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Aug 13 10:47:41 2017 +0200
+
+    [hkl3d] use HKL_ARG_NONNULL and HKLAPI like for hkl library
+
+ hkl3d/hkl3d.cpp |  6 ------
+ hkl3d/hkl3d.h   | 51 +++++++++++++++++++++++++++------------------------
+ 2 files changed, 27 insertions(+), 30 deletions(-)
+
+commit d39a9ed5a2985c528fbd3614e95566aa47ee2c73
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Jun 29 18:39:50 2017 +0200
+
+    [contrib][haskell] use Glob to find all .nxs in a directory.
+
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs | 137 ++---------------------
+ 1 file changed, 8 insertions(+), 129 deletions(-)
+
+commit ee31085e466d2c4c76c6a52299e7fa6f876fc551
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 22:46:43 2017 +0200
+
+    [contrib][haskell] Hkl.Script
+
+ contrib/haskell/src/Hkl/Script.hs | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+commit bca44b6c9baeace6904c6d0ac2283be81c3a0000
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 21:54:04 2017 +0200
+
+    [contrib][haskell] Hkl.Nxs
+
+ contrib/haskell/src/Hkl/Nxs.hs | 34 ++++++++++++++++++++++------------
+ 1 file changed, 22 insertions(+), 12 deletions(-)
+
+commit 681717d49e07d9ed4a7a68b8eec8fbd04cdb9bb4
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 21:38:14 2017 +0200
+
+    [contrib][haskell] Hkl.Flat
+
+ contrib/haskell/src/Hkl/Flat.hs | 23 +++++++++++++++--------
+ 1 file changed, 15 insertions(+), 8 deletions(-)
+
+commit 60afa70dacd29ba8e70b8834fe516d1257d1bc46
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 20:24:14 2017 +0200
+
+    [contrib][haskell] Hkl.Edf
+
+ contrib/haskell/src/Hkl/Edf.hs | 20 ++++++++++++++------
+ 1 file changed, 14 insertions(+), 6 deletions(-)
+
+commit 9f28f0872cf07d8e299eeae2ee66e9898b6d5eb8
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 20:13:50 2017 +0200
+
+    [contrib][haskell] Hkl.Xrd.Calibration
+
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 66 ++++++++++++++++++++++++++----
+ 1 file changed, 58 insertions(+), 8 deletions(-)
+
+commit 5dbb21169bb85680ed4c7c5ad91b7966fb750941
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 20:13:35 2017 +0200
+
+    [contrib][haskell] Hkl.Xrd.OneD
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 68 ++++++++++++++++++++++++++-----------
+ 1 file changed, 49 insertions(+), 19 deletions(-)
+
+commit 45418c9cf5c5d8c4f09a188b83cf95c8a23e90a2
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:04:42 2017 +0200
+
+    [contrib][haskell] Hkl.Xrd.ZeroD
+
+ contrib/haskell/src/Hkl/Xrd/ZeroD.hs | 39 ++++++++++++++++++------------------
+ 1 file changed, 19 insertions(+), 20 deletions(-)
+
+commit 87295997e5d4b95e38886b43fb3943f0ceafd10b
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:04:25 2017 +0200
+
+    [contrib][haskell] Hkl.Xrd.OneD
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 20 ++++++--------------
+ 1 file changed, 6 insertions(+), 14 deletions(-)
+
+commit 3050d7e1b769938c613a9762802618993d1b0635
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:04:07 2017 +0200
+
+    [contrib][haskell] Hkl.Utils
+
+ contrib/haskell/src/Hkl/Utils.hs | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+commit 0222249d79a8ffa6b9c09fe01eba4d4de6232ace
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:03:51 2017 +0200
+
+    [contrib][haskell] Hkl.Types.Parameter
+
+ contrib/haskell/src/Hkl/Types/Parameter.hsc | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 7f90b886bd626d443c3dacb941f10d30793b95e7
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:03:26 2017 +0200
+
+    [contrib][haskell] PyFAI.Detector
+
+ contrib/haskell/src/Hkl/PyFAI/Detector.hs | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+commit 4239c73402e9872416990b6ea683605e7a723fe6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:03:12 2017 +0200
+
+    [contrib][haskell] Calib
+
+ contrib/haskell/src/Hkl/PyFAI/Calib.hs | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+commit d5812a81a8024e21b435e26f856e3061565e7ec6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:02:58 2017 +0200
+
+    [contrib][haskell] Sixs
+
+ contrib/haskell/src/Hkl/Projects/Sixs.hs | 25 +++++++++++++++++++------
+ 1 file changed, 19 insertions(+), 6 deletions(-)
+
+commit 10caaf9554da3836ce690e2bdd61b7db64805870
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:02:41 2017 +0200
+
+    [contrib][haskell] H5
+
+ contrib/haskell/src/Hkl/H5.hs | 33 +++++++++++++--------------------
+ 1 file changed, 13 insertions(+), 20 deletions(-)
+
+commit 94d12d8a40a060dcbdde06f71be38e95064f67b6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:02:26 2017 +0200
+
+    [contrib][haskell] Engine
+
+ contrib/haskell/src/Hkl/Engine.hs | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+commit 0bd92effc2cdcef781d4f5a9381489f66a85c2b8
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 19:02:09 2017 +0200
+
+    [contrib][haskell] Detector
+
+ contrib/haskell/src/Hkl/Detector.hs | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+commit 3badbf01ac770b6c8f8e3f42e3c3757c5f83fa77
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Jul 30 11:43:13 2017 +0200
+
+    [contrib][haskell] use a bunch of other -Wxxx options
+    
+    -Wincomplete-uni-patterns -Wincomplete-record-updates -Wmissing-import-lists
+
+ contrib/haskell/hkl.cabal            | 2 +-
+ contrib/haskell/src/Hkl/C/Sample.hsc | 2 --
+ 2 files changed, 1 insertion(+), 3 deletions(-)
+
+commit 882473b16e80188f6fb1b6c0ac49f2f4576fd7ba
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Jun 30 16:40:24 2017 +0200
+
+    [contrib][haskell] better dummy filter for the charlier data's
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Charlier.hs | 6 +++++-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                  | 4 ++--
+ contrib/haskell/src/xrd.hs                           | 4 ++--
+ 3 files changed, 9 insertions(+), 5 deletions(-)
+
+commit 8f5f4b051f7b9b89f7057b96f3cafd3cb2122ac8
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Jun 30 15:49:03 2017 +0200
+
+    [contrib][haskell] more todo for melle
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Melle.hs | 24 ++++++++++++++++-------
+ contrib/haskell/src/xrd.hs                        |  4 ++--
+ 2 files changed, 19 insertions(+), 9 deletions(-)
+
+commit 8af786da2cf25eb7c321f051111409c31b0f13e0
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Jun 29 16:20:29 2017 +0200
+
+    [contrib][haskell] add more images for romeden
+
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs | 21 +++++++++++++++------
+ 1 file changed, 15 insertions(+), 6 deletions(-)
+
+commit 0d2cd9ef6a5b51bfc23b2cab7944d2649ffe0ad2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Jun 29 10:21:22 2017 +0200
+
+    [contrib][haskell] simplify romeden using nxEntries function
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Melle.hs |  8 +---
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs  | 50 +++++++++++------------
+ contrib/haskell/src/xrd.hs                        |  4 +-
+ 3 files changed, 29 insertions(+), 33 deletions(-)
+
+commit 0afaeb821cad4ccc127297852059543a38a47b44
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Jun 28 15:33:50 2017 +0200
+
+    [contrib][haskell] work on the h5iterate
+
+ contrib/haskell/src/Hkl/H5.hs                     | 75 ++++++++++++++++++++---
+ contrib/haskell/src/Hkl/Projects/Diffabs/Melle.hs |  8 ++-
+ 2 files changed, 72 insertions(+), 11 deletions(-)
+
+commit 121b90bf82223d60520022285f57241086b237f7
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jun 27 17:46:14 2017 +0200
+
+    [contrib][haskell] add the melle session4 calibration.
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Melle.hs | 99 ++++++++++++++++++++++-
+ 1 file changed, 96 insertions(+), 3 deletions(-)
+
+commit 2c1bbfbcade7d1e096e303778316644b2c5f43ff
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jun 27 11:58:20 2017 +0200
+
+    [contrib][haskell] add the melle scans
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Melle.hs | 101 ++++++++++++----------
+ 1 file changed, 57 insertions(+), 44 deletions(-)
+
+commit 27c20af75ee6f5a7eaee59540437b45102029fb4
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jun 27 11:05:05 2017 +0200
+
+    [contrib][haskell] start to work on the melle project
+
+ contrib/haskell/hkl.cabal                         |   1 +
+ contrib/haskell/src/Hkl/H5.hs                     |  26 ++-
+ contrib/haskell/src/Hkl/Projects/Diffabs.hs       |   2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Melle.hs | 271 ++++++++++++++++++----
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs  |  16 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs               |   2 +-
+ contrib/haskell/src/xrd.hs                        |   6 +-
+ 7 files changed, 259 insertions(+), 65 deletions(-)
+
+commit 7f33cd9da27e41d6d1461602644e30867f5e48cb
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Jun 22 16:10:41 2017 +0200
+
+    [contrib][haskell] use juicipixels in order to extract file as tiff
+
+ contrib/haskell/hkl.cabal                        |  3 +
+ contrib/haskell/src/Hkl.hs                       |  1 +
+ contrib/haskell/src/Hkl/Nxs.hs                   | 53 ++++++++++++++++-
+ contrib/haskell/src/Hkl/Projects/Mars.hs         |  1 +
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs | 76 ++++++++++++++++++------
+ contrib/haskell/src/Hkl/Tiff.hs                  | 10 ++++
+ contrib/haskell/src/xrd.hs                       |  3 +-
+ 7 files changed, 124 insertions(+), 23 deletions(-)
+
+commit c4b8b6fd74eb7adb70870c8ff16a4edd90e4f06a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Jun 19 10:36:43 2017 +0200
+
+    [contrib][haskell] add more todo
+
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs | 13 ++++++++++---
+ 1 file changed, 10 insertions(+), 3 deletions(-)
+
+commit 07dfe473004f6c78c0105a421c574cea91e00b09
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Jun 16 15:53:52 2017 +0200
+
+    [contrib][haskell] add the Romeden project todo
+
+ contrib/haskell/src/Hkl/Projects/Mars/Romeden.hs | 116 +++++++++++++++++++++++
+ 1 file changed, 116 insertions(+)
+
+commit 8e1595ade3953526027b71b290c6568d56210d4d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Jun 16 15:24:13 2017 +0200
+
+    [contrib][haskell] add the Mars Schlegel project
+
+ contrib/haskell/hkl.cabal                         |   3 +
+ contrib/haskell/src/Hkl/Edf.hs                    |  48 +--------
+ contrib/haskell/src/Hkl/Nxs.hs                    |   5 +
+ contrib/haskell/src/Hkl/Projects.hs               |   1 +
+ contrib/haskell/src/Hkl/Projects/Mars.hs          |   3 +
+ contrib/haskell/src/Hkl/Projects/Mars/Schlegel.hs | 110 ++++++++++++++++++++
+ contrib/haskell/src/Hkl/PyFAI/Calibrant.hs        |   3 +-
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs             |   3 +
+ contrib/haskell/src/Hkl/Xrd.hs                    |   1 +
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs        |  27 ++---
+ contrib/haskell/src/Hkl/Xrd/OneD.hs               |   2 +-
+ contrib/haskell/src/Hkl/Xrd/ZeroD.hs              | 119 ++++++++++++++++++++++
+ contrib/haskell/src/xrd.hs                        |   3 +-
+ 13 files changed, 268 insertions(+), 60 deletions(-)
+
+commit cd1852360bfbb3dbda14a2bc42ec8eb4166f6dfb
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jun 6 14:08:06 2017 +0200
+
+    [contrib][haskell] the calibration function is now customizable
+
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 63 ++++++++++++++++++------------
+ 1 file changed, 37 insertions(+), 26 deletions(-)
+
+commit f4f018f84fe9a13c8b7fc277c0ce294d1c71d538
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 30 12:17:27 2017 +0200
+
+    [contrib][haskell] convert the Pose type into a data type
+
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs        |  2 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs    |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hamon.hs   |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs   |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs   |  2 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs  |  2 +-
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs               |  4 ++--
+ contrib/haskell/src/Hkl/PyFAI/PoniExt.hs            |  5 +++--
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs          | 17 +++++++++--------
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                 | 12 +++++++-----
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                 | 21 +++++++++++----------
+ 11 files changed, 38 insertions(+), 33 deletions(-)
+
+commit d2e2f7bbfa32925aaee0cbd8550feb8aa278276a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 30 11:27:49 2017 +0200
+
+    [contrib][haskell] rename OutputBaseDir -> AbsDirPath
+    
+    in order to prepare for ghc path module
+
+ contrib/haskell/src/Hkl/Types.hs           |  7 +++----
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs |  8 ++++----
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs        |  8 ++++----
+ contrib/haskell/src/Hkl/Xrd/OneD.hs        | 18 ++++++++----------
+ 4 files changed, 19 insertions(+), 22 deletions(-)
+
+commit 8dd21dfaccb1d66948da3a5a59bfe8840920b8c2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 30 11:07:56 2017 +0200
+
+    [contrib][haskell] move OutputBaseDir and SampleName into Types.hs
+
+ contrib/haskell/src/Hkl/Types.hs           | 8 ++++++++
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 4 ++--
+ contrib/haskell/src/Hkl/Xrd/OneD.hs        | 3 ---
+ 3 files changed, 10 insertions(+), 5 deletions(-)
+
+commit 38b675a53309c0496a294fd653d666882718c8a8
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 30 09:26:31 2017 +0200
+
+    [contrib][haskell] use applicative where it makes sense
+
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 24 +++++++++++++-----------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs        | 16 +++++++++-------
+ 2 files changed, 22 insertions(+), 18 deletions(-)
+
+commit 2e6f994e89071f94dc527cb0ce4e86be65e788ff
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Mon May 29 18:32:27 2017 +0200
+
+    [contrib][haskell] remove an useless variable
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 2 --
+ 1 file changed, 2 deletions(-)
+
+commit afa7fc11a91ce262967a7d47b498aeaf3461f036
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 24 16:03:55 2017 +0200
+
+    [control][haskell] todo
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+commit 30b36050ea3d5a675c1c3931619f5f7c106841cd
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 24 12:02:32 2017 +0200
+
+    [contrib][haskell] use an ADetector in the PoniFile
+
+ contrib/haskell/hkl.cabal                 |  1 +
+ contrib/haskell/src/Hkl/PyFAI.hs          |  1 +
+ contrib/haskell/src/Hkl/PyFAI/Calib.hs    |  5 +--
+ contrib/haskell/src/Hkl/PyFAI/Detector.hs | 18 +++++++++++
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs     | 51 ++++++++++++++++++++++++-------
+ 5 files changed, 63 insertions(+), 13 deletions(-)
+
+commit 743ad246cb4f5dfc290bd66c6489e6f30cffbc5c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 24 09:04:34 2017 +0200
+
+    [contrib][haskell] use the WaveLength type in the Poni
+
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+commit b3fbbf580890cc546d30eb231485cd3eb7138f8a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 24 08:53:46 2017 +0200
+
+    [contrib][haskell] typo
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hamon.hs | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+commit e870eaad6f96f8c0b11925705c7c7de0c87b1ef4
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 23 16:11:06 2017 +0200
+
+    [contrib][haskell] rework a bit the calib script
+
+ contrib/haskell/src/Hkl/PyFAI/Calib.hs     |  3 +++
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 14 ++++++++------
+ 2 files changed, 11 insertions(+), 6 deletions(-)
+
+commit d8fbd7fdb8536d169711e71a1e6c256cde752b18
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 23 15:44:41 2017 +0200
+
+    [contrib][haskell] read the wavelength from the enxus file during calibration
+
+ contrib/haskell/src/Hkl/PyFAI/Calib.hs     |  6 ++++++
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 30 ++++++++++++++++++++++++++----
+ 2 files changed, 32 insertions(+), 4 deletions(-)
+
+commit 3cf3a1caa2c04bc21182f588c404fe98605aebdc
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 23 13:36:38 2017 +0200
+
+    [contrib][haskell] add a Calibrant to the XrdCalibration
+
+ contrib/haskell/hkl.cabal                               |  3 ++-
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs            |  1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Charlier.hs    |  1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hamon.hs       |  1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hercules.hs    |  1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs       |  1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs       |  1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Martinetto.hs  |  1 +
+ contrib/haskell/src/Hkl/PyFAI.hs                        |  3 ++-
+ contrib/haskell/src/Hkl/PyFAI/{Detector.hs => Calib.hs} |  6 +++++-
+ contrib/haskell/src/Hkl/PyFAI/Calibrant.hs              |  9 +++++++++
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs              | 11 ++++++-----
+ 12 files changed, 31 insertions(+), 8 deletions(-)
+
+commit c6003b7916715c741aedc8fb3c976c003701b30a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 23 13:10:51 2017 +0200
+
+    [contrib][haskell] put the detector in the XRDCalibration data
+
+ contrib/haskell/hkl.cabal                          |  1 +
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  5 ++--
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  5 ++--
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hamon.hs  |  5 ++--
+ .../haskell/src/Hkl/Projects/Diffabs/Hercules.hs   |  5 ++--
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  5 ++--
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  5 ++--
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  5 ++--
+ contrib/haskell/src/Hkl/PyFAI.hs                   |  1 +
+ contrib/haskell/src/Hkl/PyFAI/Detector.hs          | 15 ++++++++++++
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         | 27 +++++++++++-----------
+ 11 files changed, 52 insertions(+), 27 deletions(-)
+
+commit e72e1c7a53d9df9d12d3f92e03f2c5d02a18c30f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 23 11:10:35 2017 +0200
+
+    [contrib][haskell] save the scripts with the right FileMode
+
+ contrib/haskell/hkl.cabal         |  1 +
+ contrib/haskell/src/Hkl/Script.hs | 14 +++++++++-----
+ 2 files changed, 10 insertions(+), 5 deletions(-)
+
+commit 68b133fe8761147f7b09e827e7619973d934f32f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon May 22 16:51:29 2017 +0200
+
+    [contrib][haskell] add the Hamon project
+
+ contrib/haskell/hkl.cabal                         |   1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs.hs       |   1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hamon.hs | 133 ++++++++++++++++++++++
+ contrib/haskell/src/Hkl/Script.hs                 |   6 +-
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs        |  25 +++-
+ contrib/haskell/src/xrd.hs                        |   3 +-
+ 6 files changed, 162 insertions(+), 7 deletions(-)
+
+commit aefcceed718b0b7f28aea73b245d76aee434f5c3
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat May 20 15:23:21 2017 +0200
+
+    [doc] use a simpler css and add the right mathjax cdn
+    
+    in ordert o use an https adress
+
+ Documentation/Makefile.am    |   2 +-
+ Documentation/css/style.css  | 445 +++++++++++++++++++++++++++++++++++++++++++
+ Documentation/hkl-default.el |  18 +-
+ Documentation/hkl.org.in     |  10 +-
+ 4 files changed, 462 insertions(+), 13 deletions(-)
+
+commit b38e28a8dbef1b859382d2ad32298d762fed9402
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 17 18:42:27 2017 +0200
+
+    [hkl] add the hkl_geometry_[ki/kf]_get method
+    
+    The purpose is to factorize the pseudo axes computation for
+    each diffractometers.
+
+ hkl/hkl-engine-k6c.c                 |  2 +-
+ hkl/hkl-engine-petra3-p08-lisa.c     | 60 ++++++++++++++++++++++++++----------
+ hkl/hkl-geometry-private.h           | 33 +++++++++++++++++++-
+ hkl/hkl-geometry.c                   | 11 +++++++
+ hkl/hkl-pseudoaxis-common-hkl.c      | 32 +++++++++----------
+ hkl/hkl-pseudoaxis-common-psi.c      | 22 +++++++------
+ hkl/hkl-pseudoaxis-common-q.c        | 24 ++++++++-------
+ hkl/hkl-pseudoaxis-common-readonly.c |  4 +--
+ hkl/hkl-pseudoaxis-common-tth.c      |  4 +--
+ 9 files changed, 132 insertions(+), 60 deletions(-)
+
+commit 40f6c6aa3532d2f8886e06db23e11d89f6d39d70
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon May 15 18:42:31 2017 +0200
+
+    [hkl] add vtable to HklGeometry and add [sample|detector]_holder_get
+    
+    The idea is to let the geometry declare what is the sample detector
+    and what is the detector holder.
+
+ hkl/hkl-detector.c                    |  4 +--
+ hkl/hkl-engine-2c.c                   |  2 +-
+ hkl/hkl-engine-e4c.c                  |  6 ++--
+ hkl/hkl-engine-e6c.c                  |  2 +-
+ hkl/hkl-engine-k4c.c                  |  2 +-
+ hkl/hkl-engine-k6c.c                  |  9 ++---
+ hkl/hkl-engine-petra3-p08-lisa.c      | 27 ++++++++++++---
+ hkl/hkl-engine-petra3-p09-eh2.c       |  2 +-
+ hkl/hkl-engine-soleil-sirius-turret.c |  2 +-
+ hkl/hkl-engine-soleil-sixs-med.c      |  6 ++--
+ hkl/hkl-engine-template.c             |  2 +-
+ hkl/hkl-engine-zaxis.c                |  2 +-
+ hkl/hkl-geometry-private.h            | 38 ++++++++++++++++++++-
+ hkl/hkl-geometry.c                    | 24 ++++++++++---
+ hkl/hkl-pseudoaxis-common-hkl.c       | 63 +++++++++++++++++++----------------
+ hkl/hkl-pseudoaxis-common-readonly.c  |  6 ++--
+ hkl/hkl-sample-private.h              |  1 +
+ hkl/hkl-sample.c                      | 15 ++++++---
+ tests/hkl-detector-t.c                |  4 +--
+ tests/hkl-geometry-t.c                | 24 ++++++-------
+ 20 files changed, 162 insertions(+), 79 deletions(-)
+
+commit b6e722920a70af0b036ab205e0e6f9c6789801dd
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat May 6 11:34:37 2017 +0200
+
+    [hkl] remove a bunch of warning (gcc-6)
+
+ hkl/hkl-pseudoaxis-private.h | 42 +++++++++++++++++++++---------------------
+ 1 file changed, 21 insertions(+), 21 deletions(-)
+
+commit a1cf790ccfc187a49c5dd91556d146461c4243d0
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri May 5 16:11:08 2017 +0200
+
+    [hkl] add an hkl_translation_transformation_apply
+    
+    This allow to create a generic way to compute geometry transformations.
+    It was necessary to add a new HklRotationWithOrigin HklParameter type
+
+ hkl/hkl-axis-private.h           |  20 ++++-
+ hkl/hkl-axis.c                   | 159 +++++++++++++++++++++++++++++++++++----
+ hkl/hkl-engine-petra3-p08-lisa.c |  10 +--
+ hkl/hkl-geometry-private.h       |   9 +++
+ hkl/hkl-geometry.c               |  33 ++++++++
+ hkl/hkl-parameter-private.h      |  13 +++-
+ hkl/hkl-parameter.c              |  13 ++++
+ hkl/hkl-pseudoaxis-common-hkl.c  |   1 +
+ 8 files changed, 235 insertions(+), 23 deletions(-)
+
+commit 5a742729f9d21ef63c5f6b01359cebd955dc398e
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu May 4 16:07:51 2017 +0200
+
+    [hkl] factorize the hkl_geometry_add_[rotation|translation] -> axis
+
+ hkl/hkl-geometry.c          | 77 ++++++++++-----------------------------------
+ hkl/hkl-parameter-private.h |  2 +-
+ hkl/hkl-parameter.c         |  4 +--
+ 3 files changed, 20 insertions(+), 63 deletions(-)
+
+commit af3e7ff0ebd2627eb7bd39b362e8e31a462b1f98
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu May 4 15:21:47 2017 +0200
+
+    [hkl] add the hkl_parameter_transformation_cmp method
+    
+    this allow to compare the translation rotation and tell if they are
+    compatible
+
+ hkl/hkl-axis.c              | 25 +++++++++++++++++++++++--
+ hkl/hkl-parameter-private.h | 12 +++++++++++-
+ hkl/hkl-parameter.c         | 14 ++++++++++++++
+ tests/hkl-axis-t.c          | 36 ++++++++++++++++++++++++++++++++++--
+ 4 files changed, 82 insertions(+), 5 deletions(-)
+
+commit 8fd6c235cc17b571d4842341c7a6a10403308fd2
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed May 3 22:27:38 2017 +0200
+
+    [hkl] remove a bunch of gcc-6 warnings
+
+ Documentation/figures/Makefile.am |  3 ++-
+ hkl/hkl-geometry.c                |  3 ---
+ hkl/hkl-sample.c                  | 16 +---------------
+ 3 files changed, 3 insertions(+), 19 deletions(-)
+
+commit 73109f5b5082b96abcdafb1cf50d24a33d21e2eb
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Mon Apr 17 10:05:08 2017 +0200
+
+    [hkl] fix compilator warnings
+
+ hkl/hkl-lattice.c    | 4 ----
+ hkl/hkl-pseudoaxis.c | 2 --
+ 2 files changed, 6 deletions(-)
+
+commit 8ddf5407fec893c8bdebda2f22a51a651d8cb003
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 3 17:04:17 2017 +0200
+
+    [hkl] fix the lisa hkl computation by using SI values.
+    
+    beware the si parameterrs should be compatible with the wavelength value
+
+ hkl/hkl-engine-petra3-p08-lisa.c | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+commit c06414491a3c95b9e1f69bf2d70ec9628766f92f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed May 3 16:52:51 2017 +0200
+
+    [test] add the test for the translations and correct a bunch of errors
+    
+    now the hkl_geometry_update take into account only rotation before a
+    translation.
+    Add an hkl_unit_length_meter unit
+    
+    rename hkl_holder_add_rotation_axis -> hkl_holder_add_rotation
+    and change the signature. Now we need to give the user unit of each axis.
+
+ hkl.h                                 | 102 ++++++++++-----------
+ hkl/hkl-axis.c                        |   1 +
+ hkl/hkl-engine-2c.c                   |   4 +-
+ hkl/hkl-engine-e4c.c                  |  24 ++---
+ hkl/hkl-engine-e6c.c                  |  12 +--
+ hkl/hkl-engine-k4c.c                  |   8 +-
+ hkl/hkl-engine-k6c.c                  |  24 ++---
+ hkl/hkl-engine-petra3-p08-lisa.c      |  10 +--
+ hkl/hkl-engine-petra3-p09-eh2.c       |  14 +--
+ hkl/hkl-engine-soleil-sirius-turret.c |  14 +--
+ hkl/hkl-engine-soleil-sixs-med.c      |  36 ++++----
+ hkl/hkl-engine-template.c             |  12 +--
+ hkl/hkl-engine-zaxis.c                |  10 +--
+ hkl/hkl-geometry-private.h            |  20 ++---
+ hkl/hkl-geometry.c                    |  63 ++++++-------
+ hkl/hkl-parameter-private.h           |   2 +-
+ hkl/hkl-unit-private.h                |   1 +
+ tests/hkl-axis-t.c                    |  99 +++++++++++++--------
+ tests/hkl-detector-t.c                |   4 +-
+ tests/hkl-geometry-t.c                | 161 ++++++++++++++++++++--------------
+ 20 files changed, 335 insertions(+), 286 deletions(-)
+
+commit d0b47d0b03da3206c7fb61b670154772e1321d79
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 2 15:48:50 2017 +0200
+
+    [hkl] factorization of the hkl_holder_add_xxx
+    
+    created a common hkl_holder_add_axis_if_not_present method.
+
+ hkl/hkl-geometry.c | 52 ++++++++++++++++++++++++----------------------------
+ 1 file changed, 24 insertions(+), 28 deletions(-)
+
+commit 1982ad71107af6bd9bee73e45a4cbb3dba01d90a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 2 15:10:03 2017 +0200
+
+    [hkl] nwo the translation should works for the petra3 p08 lisa gonio
+
+ hkl/hkl-engine-petra3-p08-lisa.c |  2 +-
+ hkl/hkl-geometry-private.h       |  6 ++++
+ hkl/hkl-geometry.c               | 64 ++++++++++++++++++++++++++++++++++++++++
+ 3 files changed, 71 insertions(+), 1 deletion(-)
+
+commit ca72d8a283eecf10089b2be17432151c40265a99
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue May 2 14:53:02 2017 +0200
+
+    [hkl] add the HklTranslation parameter type and its constructor
+    
+    hkl_parameter_new_translation
+
+ hkl/hkl-axis-private.h |  7 +++++
+ hkl/hkl-axis.c         | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 88 insertions(+)
+
+commit 1a83e5dc1be03ba13dc2f2e04c15d4c3dee06058
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Apr 27 17:23:56 2017 +0200
+
+    [hkl] rename hkl_parameter_new_axis -> hkl_parameter_new_rotation
+    
+    We will prepare the arrival of translation in the code in order
+    to deal with the p08 lisa setup
+
+ hkl/hkl-axis-private.h |  2 +-
+ hkl/hkl-axis.c         |  2 +-
+ hkl/hkl-geometry.c     |  8 ++------
+ tests/hkl-axis-t.c     | 14 +++++++-------
+ 4 files changed, 11 insertions(+), 15 deletions(-)
+
+commit ca732979bfde95db48b090cb6373281d2d076598
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Apr 27 15:35:36 2017 +0200
+
+    [hkl] rewrite the unit code and add a milli meter unit for petra3 p08 lisa
+
+ hkl/hkl-unit-private.h |  38 +++++++++-----
+ hkl/hkl-unit.c         | 140 +++++++++++++------------------------------------
+ 2 files changed, 59 insertions(+), 119 deletions(-)
+
+commit b6d13c33fcdcbee0133b0404317dc408dd6d3b7e
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Apr 27 09:50:17 2017 +0200
+
+    [hkl] it is better to get the axis via there names.
+
+ hkl/hkl-engine-petra3-p08-lisa.c | 28 ++++++++--------------------
+ 1 file changed, 8 insertions(+), 20 deletions(-)
+
+commit b97aee13b4e8f91ca82dc290094648731204d977
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Apr 26 16:40:58 2017 +0200
+
+    [hkl] the hkl read part of petra3 p08 lisa should be ok
+
+ hkl.h                            |  4 +++
+ hkl/hkl-engine-petra3-p08-lisa.c | 56 +++++++++++++++++++++++++++++-----------
+ 2 files changed, 45 insertions(+), 15 deletions(-)
+
+commit 93c0be8496238504d58ede1ad852ab06026bbd2d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Apr 26 11:40:56 2017 +0200
+
+    [hkl] add mode lisa informations
+
+ hkl/hkl-engine-petra3-p08-lisa.c | 12 ++++++++++--
+ 1 file changed, 10 insertions(+), 2 deletions(-)
+
+commit fb9f00cab7d805d9f4522f7063925b8350ad3058
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Apr 26 10:43:57 2017 +0200
+
+    [hkl] add a few lisa informations
+
+ hkl/hkl-engine-petra3-p08-lisa.c | 22 ++++++++++++++++------
+ 1 file changed, 16 insertions(+), 6 deletions(-)
+
+commit 2ab09f8e9c70965194dad127e2d4fec2c7eada0d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Apr 26 10:16:16 2017 +0200
+
+    [doc] fix the sirius starting point for the 2nd solution.
+
+ Documentation/figures/sirius.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 67d79a55cdaff0cba2117f02601340f0e2fc6684
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Apr 25 11:25:59 2017 +0200
+
+    [hkl] wip P08 lisa on the hkl read part
+
+ hkl/Makefile.am                         |   1 +
+ hkl/hkl-engine-petra3-p08-lisa.c        | 298 +++++++++++++++-----------------
+ hkl/hkl-pseudoaxis-common-hkl-private.h |   2 +
+ hkl/hkl-pseudoaxis-common-hkl.c         |   2 +-
+ 4 files changed, 144 insertions(+), 159 deletions(-)
+
+commit 93c9cd03799a4802518b24cc46e1fda7f4d32057
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Apr 24 16:15:09 2017 +0200
+
+    [doc] add a plot showing trajectories of different number of steps.
+
+ Documentation/figures/Makefile.am |  4 +-
+ Documentation/figures/sirius.c    | 85 ++++++++++++++++++++++++++++++++++++++-
+ Documentation/hkl.org.in          | 13 ++++++
+ 3 files changed, 98 insertions(+), 4 deletions(-)
+
+commit b321fcc07051fa0dba84c64b47fd9de18fe34c6f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Apr 24 15:01:29 2017 +0200
+
+    [hkl] remove memory leaks
+
+ hkl/api2/hkl2.c                      |  3 ++-
+ hkl/hkl-pseudoaxis-common-readonly.c | 17 +++++++++++++++++
+ 2 files changed, 19 insertions(+), 1 deletion(-)
+
+commit 4303a459783b6891fcfddb98a513ab319a19f3c1
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Apr 24 13:58:57 2017 +0200
+
+    [doc] put the gnuplot files into the org file
+
+ Documentation/figures/Makefile.am      | 18 ++++-----------
+ Documentation/figures/sirius-m.gnuplot | 10 ---------
+ Documentation/figures/sirius-s.gnuplot | 10 ---------
+ Documentation/hkl-default.el           |  3 ++-
+ Documentation/hkl.org.in               | 41 ++++++++++++++++++++++++++++++----
+ 5 files changed, 43 insertions(+), 39 deletions(-)
+
+commit bfb2c5d97af94e4cd35bbee74ec083f26d25087b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Apr 24 11:14:04 2017 +0200
+
+    [hkl] add comments to the petra3 p08 lisa code.
+
+ hkl/hkl-engine-petra3-p08-lisa.c | 296 +++++++++++++++++++++++++++++++++------
+ 1 file changed, 255 insertions(+), 41 deletions(-)
+
+commit 3e6e1a53d8d002c31bba75a9a7a25a0f945b0fb2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Apr 21 17:11:25 2017 +0200
+
+    [hkl] add an api2 and pass the distcheck
+
+ Documentation/figures/Makefile.am            |  49 ++++-
+ Documentation/figures/sirius.c               | 126 +++++++++++
+ configure.ac                                 |   1 +
+ hkl/Makefile.am                              |   2 +-
+ hkl/api2/Makefile.am                         |  14 ++
+ hkl/api2/hkl2.c                              | 314 +++++++++++++++++++++++++++
+ hkl/api2/hkl2.h                              | 299 +++++++++++++++++++++++++
+ tests/Makefile.am                            |   1 +
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 237 +-------------------
+ tests/tap/hkl-tap.c                          | 127 -----------
+ tests/tap/hkl-tap.h                          | 207 +-----------------
+ 11 files changed, 805 insertions(+), 572 deletions(-)
+
+commit bc140f9935db85cbd199b20f7d4a8ac215498646
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Apr 21 14:19:36 2017 +0200
+
+    [hkl] It is important to move the diffractometer during a trajectory calculation.
+
+ Documentation/figures/Makefile.am                  | 13 +++++---
+ Documentation/figures/sirius-m.gnuplot             | 10 ++++++
+ .../figures/{sirius.gnuplot => sirius-s.gnuplot}   |  6 ++--
+ Documentation/hkl.org.in                           |  5 ++-
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c       | 37 ++++++++++++++++++----
+ 5 files changed, 56 insertions(+), 15 deletions(-)
+
+commit d75b3d16b25b82036244288699f424394189c4df
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Apr 21 11:33:34 2017 +0200
+
+    [hkl] add the trajectory plot when moving the diffractometer
+
+ Documentation/figures/Makefile.am            |   9 ++-
+ Documentation/figures/sirius.gnuplot         |  10 +++
+ Documentation/hkl.org.in                     |   6 +-
+ Makefile.am                                  |   2 +-
+ configure.ac                                 |   2 +
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 105 ++++++++++++++++++++++++---
+ 6 files changed, 120 insertions(+), 14 deletions(-)
+
+commit 880e3a1e9c860873e98f6b45562fd7b4ed7982ab
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Apr 20 11:53:53 2017 +0200
+
+    [hkl] use a generator for the trajectory test
+
+ INSTALL                                      |  12 +-
+ Makefile.am                                  |   8 +-
+ hkl/ccan/Makefile.am                         |  32 +-
+ hkl/ccan/alignof/LICENSE                     |   1 +
+ hkl/ccan/alignof/alignof.h                   |  20 ++
+ hkl/ccan/coroutine/LICENSE                   |   1 +
+ hkl/ccan/coroutine/coroutine.c               | 229 ++++++++++++
+ hkl/ccan/coroutine/coroutine.h               | 260 ++++++++++++++
+ hkl/ccan/cppmagic/LICENSE                    |   1 +
+ hkl/ccan/cppmagic/cppmagic.h                 | 191 ++++++++++
+ hkl/ccan/generator/LICENSE                   |   1 +
+ hkl/ccan/generator/generator.c               |  55 +++
+ hkl/ccan/generator/generator.h               | 220 ++++++++++++
+ hkl/ccan/ptrint/LICENSE                      |   1 +
+ hkl/ccan/ptrint/ptrint.h                     |  35 ++
+ hkl/ccan/typesafe_cb/LICENSE                 |   1 +
+ hkl/ccan/typesafe_cb/typesafe_cb.h           | 134 +++++++
+ hkl/hkl-geometry-private.h                   |   2 +-
+ hkl/hkl-geometry.c                           |   2 +-
+ hkl/licenses/LGPL-2.1                        | 510 +++++++++++++++++++++++++++
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 148 +++++---
+ 21 files changed, 1798 insertions(+), 66 deletions(-)
+
+commit 50f5e5e2226f7f100bb01b8e8cc00258d9c53621
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 24 16:54:29 2017 +0100
+
+    [contrib][haskell] work on the sirius bug
+
+ Documentation/hkl.org.in            | 47 ++++++++++----------
+ contrib/haskell/src/Hkl/Detector.hs |  3 ++
+ contrib/haskell/src/ghkl.hs         | 87 +++++++++++++++++--------------------
+ 3 files changed, 67 insertions(+), 70 deletions(-)
+
+commit 25ec0763ed8c80bb232cb3f5b39dbe5ff810ade0
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 24 10:19:19 2017 +0100
+
+    [contrib][haskell] comment
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 1 -
+ 1 file changed, 1 deletion(-)
+
+commit a0e5eb801509154cbbcac75a4e8e9b8b081986ad
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Apr 18 15:23:05 2017 +0200
+
+    [hkl] simulate the trajectory by moving the diffracotmeter between each step.
+
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+commit 334b57f6d0e64962957c3835853f2e12a21fe101
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Apr 18 10:41:28 2017 +0200
+
+    [hkl] put the trajectory code in its own hkl-trajectory files.
+    
+    This API is for now only private.
+
+ hkl/Makefile.am                              |   2 +
+ hkl/hkl-trajectory-private.h                 |  61 ++++++++++++
+ hkl/hkl-trajectory.c                         | 139 ++++++++++++++++++++++++++
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 144 +--------------------------
+ 4 files changed, 204 insertions(+), 142 deletions(-)
+
+commit 1f73a245c770c1deed25c4fce3796d6db359922d
+Author: teresa <tnunez at mail.desy.de>
+Date:   Wed Apr 5 11:35:56 2017 +0200
+
+    Template for petra3-p08-lisa engine
+
+ hkl/hkl-engine-petra3-p08-lisa.c | 424 +++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 424 insertions(+)
+
+commit 2985a2fd2899010b474ca1ebecdb3b99c789f6c8
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Apr 6 13:35:04 2017 +0200
+
+    [wip] trajectory
+
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 46 +++++++++++++++++++++++++---
+ 1 file changed, 42 insertions(+), 4 deletions(-)
+
+commit 5a3bfbf98dab2b58914e404be4caa1958bbf081b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 31 18:11:31 2017 +0200
+
+    [tests] add stats in order to check if a trajectory is ok.
+
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 113 ++++++++++++++++++++++++++-
+ 1 file changed, 112 insertions(+), 1 deletion(-)
+
+commit 6a2381b53026029dd4db2880dd5489f624bdb577
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 31 14:53:23 2017 +0200
+
+    [tests] add Engine and Mode type
+
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 77 ++++++++++++++++++++++++----
+ 1 file changed, 66 insertions(+), 11 deletions(-)
+
+commit 573b3932e5afd2d424924dd3ac1de7d6152ecbf4
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 31 11:16:06 2017 +0200
+
+    [ccan] updated
+
+ hkl/ccan/autodata/autodata.c   |   2 +-
+ hkl/ccan/configurator.c        | 254 ++++++++++++++++++++++++++---------------
+ hkl/ccan/list/list.h           |  23 +++-
+ hkl/ccan/ptr_valid/ptr_valid.c |  11 +-
+ hkl/ccan/str/str.h             |   2 +-
+ 5 files changed, 193 insertions(+), 99 deletions(-)
+
+commit 82098a03d934ba73b0b13b18e04e19a728e29e54
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Apr 5 18:46:41 2017 +0200
+
+    [contrib][haskell] do not expose a bunch of modules
+
+ contrib/haskell/src/Hkl/C.hsc | 10 ++++------
+ 1 file changed, 4 insertions(+), 6 deletions(-)
+
+commit 4171ad7c851760a35b8aaeb40d2707f6263ce709
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Apr 5 18:41:42 2017 +0200
+
+    [contrib][haskell] add the Hkl.C.EngineList module
+
+ contrib/haskell/hkl.cabal                |  1 +
+ contrib/haskell/src/Hkl/C.hsc            | 36 +------------------
+ contrib/haskell/src/Hkl/C/EngineList.hsc | 60 ++++++++++++++++++++++++++++++++
+ 3 files changed, 62 insertions(+), 35 deletions(-)
+
+commit b6bddad8aa9581278b618e2340ac34fc8eca782e
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Apr 5 17:41:01 2017 +0200
+
+    [contrib][haskell] add the Hkl.C.Engine
+
+ contrib/haskell/hkl.cabal            |  1 +
+ contrib/haskell/src/Hkl/C.hsc        | 60 ++------------------------
+ contrib/haskell/src/Hkl/C/Engine.hsc | 81 ++++++++++++++++++++++++++++++++++++
+ 3 files changed, 85 insertions(+), 57 deletions(-)
+
+commit 48c6f17eeb32ad8e580f394609aea5eea6f9e594
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Apr 5 17:23:06 2017 +0200
+
+    [contrib][haskell] add Hkl.C.Detector and Hkl.C.GeometryList
+
+ contrib/haskell/hkl.cabal                  |   2 +
+ contrib/haskell/src/Hkl/C.hsc              | 112 +--------------------------
+ contrib/haskell/src/Hkl/C/Detector.hsc     |  41 ++++++++++
+ contrib/haskell/src/Hkl/C/Geometry.hsc     |   2 -
+ contrib/haskell/src/Hkl/C/GeometryList.hsc | 120 +++++++++++++++++++++++++++++
+ 5 files changed, 166 insertions(+), 111 deletions(-)
+
+commit e5b824cc295476a107bcbe19cb671e3ec008c68a
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Apr 5 15:27:52 2017 +0200
+
+    [contrib][haskell] add the Hkl.C.Sample module
+
+ contrib/haskell/hkl.cabal            |  1 +
+ contrib/haskell/src/Hkl/C.hsc        | 67 +-------------------------
+ contrib/haskell/src/Hkl/C/Sample.hsc | 93 ++++++++++++++++++++++++++++++++++++
+ 3 files changed, 96 insertions(+), 65 deletions(-)
+
+commit dca88928cc4595dfdd8ea62da45b1f94864ab4e3
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Apr 5 14:56:33 2017 +0200
+
+    [contrib][haskell] add the Hkl.C.Lattice module
+
+ contrib/haskell/hkl.cabal              |   1 +
+ contrib/haskell/src/Hkl/C.hsc          |  78 +-----------------------
+ contrib/haskell/src/Hkl/C/Geometry.hsc |   4 +-
+ contrib/haskell/src/Hkl/C/Lattice.hsc  | 106 +++++++++++++++++++++++++++++++++
+ 4 files changed, 111 insertions(+), 78 deletions(-)
+
+commit d3bcb70c9fdb7622800c8c1502393309dfa57658
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 15:10:29 2017 +0200
+
+    [tests] add the hkl-pseudoaxis-soleil-sirius-kappa tests
+
+ tests/Makefile.am                            | 15 +++--
+ tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c | 96 ++++++++++++++++++++++++++++
+ tests/tap/hkl-tap.c                          | 16 +++--
+ tests/tap/hkl-tap.h                          | 18 ++++++
+ 4 files changed, 132 insertions(+), 13 deletions(-)
+
+commit df1f08dc680fcf1486c77ad39b997378a7704329
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 14:10:11 2017 +0200
+
+    [tests] add the Zaxis constructor
+
+ tests/hkl-pseudoaxis-zaxis-t.c | 16 ++++------------
+ tests/tap/hkl-tap.c            |  4 ++++
+ tests/tap/hkl-tap.h            | 16 ++++++++++++++++
+ 3 files changed, 24 insertions(+), 12 deletions(-)
+
+commit ce1ad09520d99cd1562fbb086e1a6ea24ca792d0
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 14:00:47 2017 +0200
+
+    [tests] add the K6c constructor
+
+ tests/hkl-pseudoaxis-k6c-t.c | 30 ++++++++++++------------------
+ tests/tap/hkl-tap.c          |  4 ++++
+ tests/tap/hkl-tap.h          | 18 ++++++++++++++++++
+ 3 files changed, 34 insertions(+), 18 deletions(-)
+
+commit 47635a274d91938c8b7d0e3b785c9d1716e67505
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 13:48:40 2017 +0200
+
+    [tests] add the K4cv and K4ch constructors
+
+ tests/hkl-pseudoaxis-k4cv-t.c | 21 +++++++++------------
+ tests/tap/hkl-tap.c           |  8 ++++++++
+ tests/tap/hkl-tap.h           | 32 ++++++++++++++++++++++++++++++++
+ 3 files changed, 49 insertions(+), 12 deletions(-)
+
+commit fb7aa6122863497313703dfe2e223cc2df3aa763
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 13:33:33 2017 +0200
+
+    [test] add the E6c constructor
+
+ tests/hkl-pseudoaxis-e6c-t.c | 39 +++++++++++++++------------------------
+ tests/tap/hkl-tap.c          |  4 ++++
+ tests/tap/hkl-tap.h          | 20 +++++++++++++++++++-
+ 3 files changed, 38 insertions(+), 25 deletions(-)
+
+commit 7a2891a0ff780d14f45ed80658e89f3048532350
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 13:18:03 2017 +0200
+
+    [test] add the E4ch and E4cv geometry constructors
+    
+    remove also plenty of uninitialized warnings
+
+ tests/hkl-pseudoaxis-e4ch-t.c | 47 ++++++++++++------------------
+ tests/hkl-pseudoaxis-e4cv-t.c | 68 ++++++++++++++++++-------------------------
+ tests/tap/hkl-tap.c           | 49 ++++++++++++++++++-------------
+ tests/tap/hkl-tap.h           | 51 ++++++++++++++++++++++----------
+ 4 files changed, 112 insertions(+), 103 deletions(-)
+
+commit 263952aeb01cf35f3cefdea7edfc270cb5ed8d2d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 30 10:28:30 2017 +0200
+
+    [test] add a newEngines method
+
+ tests/hkl-pseudoaxis-soleil-sixs-med-t.c | 13 ++-----------
+ tests/tap/hkl-tap.c                      | 13 +++++++++++++
+ tests/tap/hkl-tap.h                      |  4 ++++
+ 3 files changed, 19 insertions(+), 11 deletions(-)
+
+commit 94c18d0b5cbe393846b5c8f15d862f3f027d1917
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 29 15:05:53 2017 +0200
+
+    [tests] add struct Geometry in order to factorize tests.
+
+ tests/hkl-pseudoaxis-soleil-sixs-med-t.c | 23 +++++++-------
+ tests/tap/hkl-tap.c                      | 35 +++++++++++++++++----
+ tests/tap/hkl-tap.h                      | 53 +++++++++++++++++++++++++++-----
+ 3 files changed, 86 insertions(+), 25 deletions(-)
+
+commit 099a5fb4f4a353a912f87265dc18676810ba4d34
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Mar 29 09:12:29 2017 +0200
+
+    [tests] create a struct Sample in order to setup a sample easily
+
+ tests/Makefile.am                        |  2 +-
+ tests/hkl-pseudoaxis-e4ch-t.c            | 12 +++----
+ tests/hkl-pseudoaxis-e4cv-t.c            | 12 +++----
+ tests/hkl-pseudoaxis-e6c-t.c             | 49 +++++++++++----------------
+ tests/hkl-pseudoaxis-k4cv-t.c            |  6 ++--
+ tests/hkl-pseudoaxis-k6c-t.c             |  8 ++---
+ tests/hkl-pseudoaxis-soleil-sixs-med-t.c | 39 +++++++++++----------
+ tests/hkl-pseudoaxis-t.c                 |  2 +-
+ tests/hkl-pseudoaxis-zaxis-t.c           | 21 +++++-------
+ tests/tap/hkl-tap.c                      | 58 ++++++++++++++++++++++++++++++++
+ tests/tap/hkl-tap.h                      | 40 ++++++++++++++++++++++
+ 11 files changed, 167 insertions(+), 82 deletions(-)
+
+commit 02a796458f9fb0ee79078bee7a67672ff577fbe6
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Mar 25 12:42:20 2017 +0100
+
+    [contrib][haskell] Storable instance for Geometry
+
+ contrib/haskell/src/Hkl/C.hsc          |  4 +-
+ contrib/haskell/src/Hkl/C/Geometry.hsc | 84 +++++++++++++++++-----------------
+ 2 files changed, 45 insertions(+), 43 deletions(-)
+
+commit b2c145afd2720f1adf85b4212f2acb7ad6c6cc71
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Mar 25 09:02:23 2017 +0100
+
+    [contrib][haskell] add a DArray type
+
+ contrib/haskell/hkl.cabal              |  1 +
+ contrib/haskell/src/Hkl/C.hsc          | 45 +++++++++++-----------------------
+ contrib/haskell/src/Hkl/C/DArray.hsc   | 25 +++++++++++++++++++
+ contrib/haskell/src/Hkl/C/Geometry.hsc | 38 +++++++++++-----------------
+ 4 files changed, 54 insertions(+), 55 deletions(-)
+
+commit 9f024dd0d5fddbb455c067c49f824d8006c67779
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Mar 25 08:23:12 2017 +0100
+
+    [contrib][haskell] add peek/poke for Source
+
+ contrib/haskell/src/Hkl/C/Geometry.hsc | 19 ++++++++++++++-----
+ 1 file changed, 14 insertions(+), 5 deletions(-)
+
+commit 68c1c2e567b6424e8afcbbe3c4c5561c08f06fc2
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Mar 25 08:03:20 2017 +0100
+
+    [contrib][haskell] no more HklGeometry type
+
+ contrib/haskell/src/Hkl/C.hsc          |  8 ++++----
+ contrib/haskell/src/Hkl/C/Geometry.hsc | 28 +++++++++++++---------------
+ 2 files changed, 17 insertions(+), 19 deletions(-)
+
+commit 7441f294128b7244612f1f82e2ec09de2e0653dd
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Mar 25 07:55:00 2017 +0100
+
+    [contrib][haskell] create the Hkl.C.Geometry module
+
+ contrib/haskell/hkl.cabal              |   1 +
+ contrib/haskell/src/Hkl/C.hsc          | 108 +------------------
+ contrib/haskell/src/Hkl/C/Geometry.hsc | 189 +++++++++++++++++++++++++++++++++
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs  |   5 +-
+ contrib/haskell/src/Hkl/Types.hs       |  34 ------
+ 5 files changed, 196 insertions(+), 141 deletions(-)
+
+commit 7a5f4b0b1551af6728a2ca9c4b4e23584e1bc5e2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 23 14:13:43 2017 +0100
+
+    [contrib][haskell] reduce duplication in Laure.hs
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 70 ++++++++---------------
+ 1 file changed, 24 insertions(+), 46 deletions(-)
+
+commit 2092d944de6b9f3871b0c284ed0d93b11f4a34f3
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 23 13:40:17 2017 +0100
+
+    [contrib][haskell] set a poni with initial values
+    
+    In order to simplify the xrd calibration. It can be necessary to set the
+    initial values of the reference PoniExt. First time used by the Hercules
+    project.
+
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  2 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  2 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Hercules.hs   | 36 +++++++++++++---------
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  2 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  2 +-
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs              | 31 +++++++++++++++----
+ contrib/haskell/src/Hkl/PyFAI/PoniExt.hs           | 31 +++++++++++++++----
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                |  2 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                |  8 ++---
+ 10 files changed, 81 insertions(+), 37 deletions(-)
+
+commit f11944170dfdd65a64a3c99ba3056fbec1309aef
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 23 10:45:23 2017 +0100
+
+    [contrib][haskell] reorganisation of the poni part
+
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs      | 81 ++++++++++++++++++++++++++----
+ contrib/haskell/src/Hkl/PyFAI/PoniExt.hs   | 56 ++++-----------------
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs | 20 --------
+ 3 files changed, 81 insertions(+), 76 deletions(-)
+
+commit ea745dd71016f58ea726cfd051b370a58ace8b79
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 22 15:23:16 2017 +0100
+
+    fix all display errors in the documentation
+
+ Documentation/hkl.org.in | 99 ++++++++++++++++++++++++------------------------
+ 1 file changed, 49 insertions(+), 50 deletions(-)
+
+commit f7019a0b3ae8c1338775e0b094c34b98aa307f65
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 22 14:47:26 2017 +0100
+
+    [contrib][haskell] add missing data's from Hercules
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hercules.hs | 1 +
+ 1 file changed, 1 insertion(+)
+
+commit 2fb311babb6f80d901e316b7e39575142ca7cc8b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 22 14:46:02 2017 +0100
+
+    created a doc-publish target in order to publish the doc
+
+ Documentation/Makefile.am    |  5 +++++
+ Documentation/hkl-default.el | 22 +++++++++++++++++++++-
+ Documentation/hkl.org.in     |  1 -
+ 3 files changed, 26 insertions(+), 2 deletions(-)
+
+commit e2d916815f3054124ebf65b5d292c21dc1662302
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 22 10:45:32 2017 +0100
+
+    [contrib][haskell] factorize beamlineUpper
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Charlier.hs   | 5 -----
+ contrib/haskell/src/Hkl/Projects/Diffabs/Hercules.hs   | 4 ----
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs      | 4 ----
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs      | 4 ----
+ contrib/haskell/src/Hkl/Projects/Diffabs/Martinetto.hs | 4 ----
+ contrib/haskell/src/Hkl/Types.hs                       | 6 ++++++
+ 6 files changed, 6 insertions(+), 21 deletions(-)
+
+commit 9fc2d73c7105f5f31a100b1d1a005479439918ac
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 22 10:39:41 2017 +0100
+
+    [contrib][haskell] add the Hercules project.
+    
+    Add also the script extractEdf used to extract the images
+    for the calibration.
+
+ contrib/haskell/hkl.cabal                          |   1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs.hs        |   1 +
+ .../haskell/src/Hkl/Projects/Diffabs/Hercules.hs   | 163 +++++++++++++++++++++
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         |  56 ++++++-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                |   3 +
+ contrib/haskell/src/xrd.hs                         |   9 +-
+ 6 files changed, 227 insertions(+), 6 deletions(-)
+
+commit c01cffc0aee7d48e1ba585f31e1cc15869830e55
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 20 13:44:53 2017 +0100
+
+    [contrib][haskell] fix the dummy code
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 10 +++++-----
+ contrib/haskell/src/xrd.hs          |  6 +++---
+ 2 files changed, 8 insertions(+), 8 deletions(-)
+
+commit fae54231ab5dc4eb90866f8df725b3c47df98182
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 20 09:50:07 2017 +0100
+
+    [contrib][haskell] added an PyVal class in order to simplify python scripting
+
+ contrib/haskell/hkl.cabal           |  1 +
+ contrib/haskell/src/Hkl/Flat.hs     | 14 ++++-----
+ contrib/haskell/src/Hkl/Python.hs   | 30 +++++++++++++++++++
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs | 20 ++++++-------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 60 ++++++++++++++++++-------------------
+ 5 files changed, 78 insertions(+), 47 deletions(-)
+
+commit e04a40ee3ad6390595ea3f79131afc761a0e652f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 17 14:13:43 2017 +0100
+
+    [contrib][haskell] factorize the mesh python script
+
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs | 109 ++++++++++++------------------------
+ 1 file changed, 37 insertions(+), 72 deletions(-)
+
+commit 06955450ce2105bbdc03f55618e12b6fa493b090
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Mar 17 13:57:10 2017 +0100
+
+    [contrib][haskell] use dummies in order to improve speed
+
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  4 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  4 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  6 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  4 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  4 +-
+ .../haskell/src/Hkl/PyFAI/AzimuthalIntegrator.hs   |  2 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 32 +++++----
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 83 +++++++++++++---------
+ contrib/haskell/src/xrd.hs                         |  6 +-
+ 9 files changed, 82 insertions(+), 63 deletions(-)
+
+commit a401ce7f4415c6b89664f6abd16c4a3026d6cbdc
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 16 15:40:46 2017 +0100
+
+    [contrib][haskell] add bench for a fly mesh
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs | 2 ++
+ 1 file changed, 2 insertions(+)
+
+commit 0ee095b1400790514c94299e59859ed9b2ee420c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 16 15:20:48 2017 +0100
+
+    [contrib][haskell] fix the mesh python script
+
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+commit 229166421d867dc02774fb9c5e9f6bb92fef0be7
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 16 09:24:38 2017 +0100
+
+    add emergence to e4cv diffractometers
+
+ Documentation/hkl.org.in | 2 ++
+ hkl/hkl-engine-e4c.c     | 2 ++
+ hkl/pom.xml              | 2 +-
+ 3 files changed, 5 insertions(+), 1 deletion(-)
+
+commit 8996421ff7f4d44d122efd97f5ccf6e2c8f521ac
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Mar 16 08:41:25 2017 +0100
+
+    [contrib][haskell] add the XrdMeshFly (to test)
+
+ contrib/haskell/hkl.cabal                         |   3 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs |   6 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs               | 266 ++++++++++++----------
+ contrib/haskell/src/xrd.hs                        |   7 +-
+ 4 files changed, 155 insertions(+), 127 deletions(-)
+
+commit 789e8244e6ded09c9557a8565016b67b56143d52
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 14 15:26:18 2017 +0100
+
+    [contrib][haskell] take into account the length of the lists.
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+commit 590424e1b1b4e400dd12db2fa54881ecc07b76a7
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 14 14:13:24 2017 +0100
+
+    [contrib][haskell] idem for the integrateMesh method
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Charlier.hs |  3 +--
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs    |  3 +--
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                  | 16 ++++++++++------
+ 3 files changed, 12 insertions(+), 10 deletions(-)
+
+commit aee1ceb8403dbcd62f30c8ebfd398e35ec39f69f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 14 14:00:33 2017 +0100
+
+    [contrib][haskell] simplify the user script by hiding the map calls
+
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  4 +--
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  5 ++--
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  8 +++---
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 29 ++++++++++++----------
+ 4 files changed, 23 insertions(+), 23 deletions(-)
+
+commit 4ffe0c18c8c19487906fd34bf2e554c67d726083
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 14 13:50:45 2017 +0100
+
+    [contrib][haskell] do a profilling of all the python scripts
+
+ contrib/haskell/data/gprof2dot.py                 | 3293 +++++++++++++++++++++
+ contrib/haskell/hkl.cabal                         |    2 +
+ contrib/haskell/src/Hkl/Flat.hs                   |    1 -
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs |    1 -
+ contrib/haskell/src/Hkl/Script.hs                 |   29 +-
+ 5 files changed, 3318 insertions(+), 8 deletions(-)
+
+commit 4fdb6233e744b3efffa9bbe7c54d1ad674320239
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 14 10:19:41 2017 +0100
+
+    [contrib][haskell] factorize the substract python script
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 80 +++++++++++++------------------------
+ 1 file changed, 27 insertions(+), 53 deletions(-)
+
+commit 97f9fea556a160127f4a8991d45a82d61f975a07
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 13 16:30:43 2017 +0100
+
+    [contrib][haskell] add the substractMulti method
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs |  7 +--
+ contrib/haskell/src/Hkl/Xrd/OneD.hs               | 66 +++++++++++++++++++++++
+ 2 files changed, 68 insertions(+), 5 deletions(-)
+
+commit 06c856d6af6177e6109608c61e3d468da8ff08e2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 13 15:04:58 2017 +0100
+
+    [contrib][haskell] fix the flat correction also for integrate
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs |  2 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs               | 23 ++++++++++++++---------
+ 2 files changed, 15 insertions(+), 10 deletions(-)
+
+commit 6d6797268a8ea5564fab2396616c1479f4fa3a88
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 13 14:05:17 2017 +0100
+
+    [contrib][haskell] save a gnuplot file also for the substraction
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 27 ++++++++++++++-------------
+ 1 file changed, 14 insertions(+), 13 deletions(-)
+
+commit 8d9b527043c39e51e7f9485d8e12dd939047d23d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 13 13:40:23 2017 +0100
+
+    [contrib][haskell] implement the substract method
+
+ contrib/haskell/hkl.cabal                         |   2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs |   6 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs               | 100 +++++++++++++++++++---
+ 3 files changed, 93 insertions(+), 15 deletions(-)
+
+commit ca25897bd5e874952e2ba0c0abeedd0348804156
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Mar 11 11:36:48 2017 +0100
+
+    [contrib][haskell] use GADTs for the Lattice
+
+ contrib/haskell/hkl.cabal           |  1 +
+ contrib/haskell/src/Hkl.hs          |  1 +
+ contrib/haskell/src/Hkl/C.hsc       | 27 +++++++++-------
+ contrib/haskell/src/Hkl/Lattice.hs  | 63 +++++++++++++++++++++++++++++++++++++
+ contrib/haskell/src/Hkl/Types.hs    | 44 ++++----------------------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs |  2 +-
+ contrib/haskell/src/ghkl.hs         |  2 +-
+ 7 files changed, 88 insertions(+), 52 deletions(-)
+
+commit 3ccf125cec5278934b147ef90dba8a6c485e8532
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 29 15:56:35 2016 +0100
+
+    [contrib][haskell] add test from sirius for numeric stability
+
+ Documentation/hkl.org.in      | 22 +++++++++++++++++
+ contrib/haskell/src/Hkl/C.hsc |  7 ++++++
+ contrib/haskell/src/ghkl.hs   | 57 ++++++++++++++++++++++++++++++++++++++++---
+ 3 files changed, 82 insertions(+), 4 deletions(-)
+
+commit 87dcf531cdf8051b0a5f8c8002ed6488f000281a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 29 15:08:16 2016 +0100
+
+    [contib][haskell] add the SoleilSiriusKappa geometry
+
+ contrib/haskell/src/Hkl/Types.hs | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+commit b8f28c8adc33de6a4ffeead923c9b1e19e5b53c8
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Nov 27 18:07:43 2016 +0100
+
+    fix logging
+
+ hkl/hkl-pseudoaxis.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit d41c365eb8ceba97d031fa34954afed622727559
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Apr 26 16:48:00 2016 +0200
+
+    update the pom.xml file with the ICA version
+
+ hkl/pom.xml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 2621b21dedc84b954c7648c393a44fd969948bf9
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 7 17:40:54 2017 +0100
+
+    [contrib][haskell] reorg
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 30 ++++++++++++-----------
+ 1 file changed, 16 insertions(+), 14 deletions(-)
+
+commit 6e2adbe49faa83ed9c8299c982d3dab49783172a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 7 16:41:16 2017 +0100
+
+    [contrib][haskell] use the Gnuplot script type
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 34 ++++++++++++++++++++++------------
+ 1 file changed, 22 insertions(+), 12 deletions(-)
+
+commit dc16d8781f492ee05832eae8b5bd605788058362
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 7 16:38:50 2017 +0100
+
+    [contrib][haskell] add the gnuplot script type
+
+ contrib/haskell/src/Hkl/Script.hs | 37 +++++++++++++++++++++++--------------
+ 1 file changed, 23 insertions(+), 14 deletions(-)
+
+commit bc57f41c725019383be27d75f270dc461ab5ec0a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 7 10:18:12 2017 +0100
+
+    [contrib][haskell] prepare for the air substraction
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 95 ++++++++++++-----------
+ 1 file changed, 50 insertions(+), 45 deletions(-)
+
+commit 7c2046889b3484cbd836b5a26d6733f156d9d121
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 7 09:28:04 2017 +0100
+
+    [contrib][haskell] use the XrdMeshParams type
+
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  2 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 27 ++++++++++++----------
+ 3 files changed, 17 insertions(+), 14 deletions(-)
+
+commit ce142bc2bffdc6426b52228219a8dde36fe2dc36
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Mar 7 09:21:14 2017 +0100
+
+    [contrib][haskell] use the XrdOneDParams
+
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  7 ++--
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  6 +--
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  2 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 46 +++++++++++-----------
+ 4 files changed, 30 insertions(+), 31 deletions(-)
+
+commit 6e9a4bef900c89612349b2d684a0d8f7a73527f2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 6 17:11:38 2017 +0100
+
+    [contrib][haskell] integrate parameters has a type XrdOneDParams
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  3 ++-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  5 ++--
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 31 ++++++++++++----------
+ 3 files changed, 21 insertions(+), 18 deletions(-)
+
+commit 1eba2e28c6e7eb2d9f05a35b1ef783b05e0134d8
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 6 16:51:57 2017 +0100
+
+    [contrib][haskell] add the possibility to select the pyFAI integration method
+
+ contrib/haskell/hkl.cabal                          |  1 +
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  3 ++-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  3 ++-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  9 ++++++-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  3 ++-
+ contrib/haskell/src/Hkl/PyFAI.hs                   |  1 +
+ .../haskell/src/Hkl/PyFAI/AzimuthalIntegrator.hs   | 18 +++++++++++++
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 30 +++++++++++++---------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 24 ++++++++---------
+ 9 files changed, 64 insertions(+), 28 deletions(-)
+
+commit 97adef304924bdcfa92bdbb8c27821a1084365d4
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 6 13:11:06 2017 +0100
+
+    [contrib][haskell] parallelize integrate
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 6ec6a155262ac93d218f8a006071108c79a6579c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 6 11:30:54 2017 +0100
+
+    [contirb][haskell] update the integrate multi in order to have a list of mask instead of the same mask
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 19 ++++++++++---------
+ 1 file changed, 10 insertions(+), 9 deletions(-)
+
+commit cd6e8ea5fb327e0d67f3a95a3e011f78ff04a005
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Mar 6 10:27:09 2017 +0100
+
+    [contrib][haskell] add the flat everywhere
+
+ contrib/haskell/src/Hkl/Flat.hs                    |  9 ++-
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  3 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  3 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  4 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  | 31 +++++----
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  6 +-
+ contrib/haskell/src/Hkl/Script.hs                  |  9 ++-
+ contrib/haskell/src/Hkl/Utils.hs                   |  2 -
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 22 ++++---
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 77 ++++++++++++----------
+ 10 files changed, 98 insertions(+), 68 deletions(-)
+
+commit a9be5efacbbc30762a7dd40c40722246bc8aa892
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 1 16:18:44 2017 +0100
+
+    [contrib][haskell] replace saveScript by hasContent
+
+ contrib/haskell/src/Hkl/Utils.hs    | 44 ++++++-------------------------------
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs |  2 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs |  6 ++---
+ 3 files changed, 11 insertions(+), 41 deletions(-)
+
+commit 65bc38ebf30f99cc1a2e74ee48b32ff6f04be98f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 1 16:05:50 2017 +0100
+
+    [contrib][haskell] use the SCript type everywhere
+
+ contrib/haskell/src/Hkl/Flat.hs     |   3 +-
+ contrib/haskell/src/Hkl/Script.hs   |   6 ++
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs |  98 ++++++++++++++++----------------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 109 ++++++++++++++++--------------------
+ 4 files changed, 103 insertions(+), 113 deletions(-)
+
+commit 3fe59dd13ab5291b103f9ebf763d287a67d6cf3c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Mar 1 13:44:18 2017 +0100
+
+    [contrib][haskell] add the Flat computation
+
+ contrib/haskell/hkl.cabal                         |  2 +
+ contrib/haskell/src/Hkl.hs                        |  2 +
+ contrib/haskell/src/Hkl/Flat.hs                   | 71 ++++++++++++++++++++
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 82 ++++++++++++-----------
+ contrib/haskell/src/Hkl/Script.hs                 | 61 +++++++++++++++++
+ 5 files changed, 180 insertions(+), 38 deletions(-)
+
+commit 441f2f7615c351fa18c01560c7d09d01f3ccabdb
+Author: Picca FrÃÂÂà[...]
+Date:   Sun Mar 5 10:24:19 2017 +0100
+
+    [contrib][haskell] migrate the glade ui files to Gtk3
+
+ contrib/haskell/data/3d3.ui     |  251 ++++
+ contrib/haskell/data/ghkl3.ui   | 2537 +++++++++++++++++++++++++++++++++++++++
+ contrib/haskell/data/pseudo3.ui |  240 ++++
+ contrib/haskell/hkl.cabal       |    3 +
+ 4 files changed, 3031 insertions(+)
+
+commit 6b6e5e4d28fb975593d7fcd6fe8cea9405717897
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Feb 28 15:10:51 2017 +0100
+
+    [contrib][haskell] add the Laure flat informations
+
+ contrib/haskell/src/Hkl/Nxs.hs                    |  3 +++
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 29 ++++++++++++++++-------
+ 2 files changed, 23 insertions(+), 9 deletions(-)
+
+commit 2745591df24cc3b794647a7b7a08098e85ed6ba0
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Feb 28 13:57:13 2017 +0100
+
+    [contrib][haskell] move all the DataFrameH5Path -> H5 managment into Nxs
+
+ contrib/haskell/src/Hkl/Nxs.hs      | 80 +++++++++++++++++++++++++++++++++++++
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs | 51 -----------------------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 28 +------------
+ 3 files changed, 81 insertions(+), 78 deletions(-)
+
+commit 505bc84b15aab3c39ba1103e1d5e921e3aafea5c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Feb 27 16:16:57 2017 +0100
+
+    [contrib][haskell] use Nxs in Mesh
+
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  30 +--
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |   8 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 206 +++++++++++----------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                |   6 +-
+ 4 files changed, 135 insertions(+), 115 deletions(-)
+
+commit cb83fb4db387581d42a9c5b06ccf3aa0d64599d9
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Feb 26 19:08:06 2017 +0100
+
+    [contrib][haskell] prepare for the Nxs migration of the Mesh code
+
+ contrib/haskell/src/Hkl/Nxs.hs                     | 35 +++++++++++-
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  4 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  4 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 66 +++++++++++-----------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                |  2 +-
+ 5 files changed, 73 insertions(+), 38 deletions(-)
+
+commit ef4735b0d7a071b2f8e1dcd05f7c7f8a14cc4ec5
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Feb 24 16:58:14 2017 +0100
+
+    [contrib][haskell] create the Hkl.Nxs module
+
+ contrib/haskell/hkl.cabal                          |  1 +
+ contrib/haskell/src/Hkl.hs                         |  1 +
+ contrib/haskell/src/Hkl/Nxs.hs                     | 59 ++++++++++++++++++++++
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  4 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  4 +-
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         |  3 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                |  1 +
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 52 ++-----------------
+ 10 files changed, 75 insertions(+), 54 deletions(-)
+
+commit f686eb5eeacf8859bddc1788a8ebf2ce4ee15177
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Feb 24 15:02:54 2017 +0100
+
+    [contrib][haskell] prepare the flat calculation.
+
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  6 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs |  4 +-
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         |  4 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 66 ++++++++++++++--------
+ 6 files changed, 50 insertions(+), 34 deletions(-)
+
+commit a15deeaa42e1b5f042c20d205d0876058441e27e
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Feb 24 13:57:45 2017 +0100
+
+    [contrib][haskell] reorg
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+commit 0c8d60d6351042d626aa9fa893fb264b23dc2fe5
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Feb 23 16:16:13 2017 +0100
+
+    [contrib][haskell] remove the NxEntry field in the Nxs type
+    
+    use only the mkNxs "constructor" instead of the default constructor
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  27 ++---
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |   8 +-
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs | 124 ++++++++++-----------
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         |   2 +-
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                |  16 +--
+ 5 files changed, 79 insertions(+), 98 deletions(-)
+
+commit ada19d628e8424c4a85d251ff6cc4f14036e6219
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Feb 23 15:07:02 2017 +0100
+
+    [contrib][haskell] merge the withH5File into the withDataFrameH5
+
+ contrib/haskell/src/Hkl/H5.hs       |  6 ++++
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 58 +++++++++++++++++++------------------
+ 2 files changed, 36 insertions(+), 28 deletions(-)
+
+commit aebe23fac90cebdab3a392865883d48022181e1b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Feb 23 14:38:25 2017 +0100
+
+    [contrib][haskell] put also the File in the DataFrameH5
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 8 +++++---
+ 1 file changed, 5 insertions(+), 3 deletions(-)
+
+commit eb24a6e644ca9be1970a8c97a160dd911e9b529c
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Feb 21 14:51:37 2017 +0100
+
+    [contrib][haskell] skip also for multi geometry
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 29 +++++++++++++++++------------
+ 1 file changed, 17 insertions(+), 12 deletions(-)
+
+commit fabb24463ae9caa56b7e4d6b04443bbbbbb0109b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Feb 21 14:25:34 2017 +0100
+
+    [contrib][haskell] add the capability to skip frames in integrate'
+
+ contrib/haskell/src/Hkl/Projects/D2AM/XRD.hs       |  5 +++-
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  |  5 +++-
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs  |  7 +++--
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs | 33 ++++++++++++----------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 29 +++++++++++++------
+ 5 files changed, 52 insertions(+), 27 deletions(-)
+
+commit f0a961e34073720aa6d69e46b0707003b3b90b0d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Feb 21 10:11:05 2017 +0100
+
+    [contrib][haskell] add all the Laure samples
+
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 169 +++++++++++-----------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs               |   8 +-
+ 2 files changed, 90 insertions(+), 87 deletions(-)
+
+commit 10b9544022daca4f5d9d8fe71a1c82ecd229f91f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Feb 3 13:52:12 2017 +0100
+
+    [contrib][haskell] wip flyscan mesh
+
+ contrib/haskell/hkl.cabal                         |   1 +
+ contrib/haskell/src/Hkl/DataSource.hs             |   5 +
+ contrib/haskell/src/Hkl/Projects/Diffabs.hs       |   1 +
+ contrib/haskell/src/Hkl/Projects/Diffabs/Laure.hs | 205 ++++++++++++++++++++++
+ contrib/haskell/src/xrd.hs                        |   3 +-
+ 5 files changed, 214 insertions(+), 1 deletion(-)
+
+commit da4f50c22fc7d1f3e811320d44f43a98b49393a9
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Feb 19 14:36:33 2017 +0100
+
+    [contrib][haskell] refactor the DataFrameH5Path
+    
+    remove all accessor for now
+
+ .../haskell/src/Hkl/Projects/Diffabs/Charlier.hs   | 10 +++---
+ contrib/haskell/src/Hkl/Projects/Diffabs/IRDRx.hs  | 10 +++---
+ .../haskell/src/Hkl/Projects/Diffabs/Martinetto.hs | 36 +++++++++++-----------
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         | 10 +++---
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                | 19 ++++++------
+ 5 files changed, 42 insertions(+), 43 deletions(-)
+
+commit 918a6e9c946af6f092350f71f33a1d7c332224ce
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Feb 19 14:10:51 2017 +0100
+
+    [contrib][hakell] use Datasource in Hkl.Xrd.OneD
+
+ contrib/haskell/src/Hkl/Xrd/OneD.hs | 62 +++++++++++++++----------------------
+ 1 file changed, 25 insertions(+), 37 deletions(-)
+
+commit 8bd13dd94e72c891b63085616a2bc22f459a6aa4
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Feb 19 13:45:40 2017 +0100
+
+    [contrib][haskell] use Datasource
+
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs | 32 ++++++++++----------------------
+ 1 file changed, 10 insertions(+), 22 deletions(-)
+
+commit 76be94f1497bc9d203bf01e9d129af81b1634e24
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Feb 19 13:37:11 2017 +0100
+
+    [contrib][haskell] move all projects under the Hkl.Projects module
+
+ contrib/haskell/hkl.cabal                          |  16 +--
+ contrib/haskell/src/Hkl.hs                         |   6 +-
+ contrib/haskell/src/Hkl/D2AM.hs                    |   3 -
+ contrib/haskell/src/Hkl/Diffabs.hs                 |   6 -
+ contrib/haskell/src/Hkl/Projects.hs                |   5 +
+ contrib/haskell/src/Hkl/Projects/D2AM.hs           |   3 +
+ contrib/haskell/src/Hkl/{ => Projects}/D2AM/XRD.hs |   2 +-
+ contrib/haskell/src/Hkl/Projects/Diffabs.hs        |   6 +
+ .../src/Hkl/{ => Projects}/Diffabs/Charlier.hs     |  10 +-
+ .../src/Hkl/{ => Projects}/Diffabs/IRDRx.hs        |  12 +-
+ .../src/Hkl/{ => Projects}/Diffabs/Martinetto.hs   |   9 +-
+ .../src/Hkl/{ => Projects}/Diffabs/Melle.hs        |   9 +-
+ contrib/haskell/src/Hkl/Projects/Sixs.hs           | 128 ++++++++++++++++++++
+ contrib/haskell/src/Hkl/PyFAI.hs                   |   1 +
+ contrib/haskell/src/Hkl/Sixs.hs                    | 131 ---------------------
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs         |   1 -
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                |   1 -
+ contrib/haskell/src/Hkl/Xrd/OneD.hs                |   1 -
+ contrib/haskell/src/hkl3d.hs                       |   2 +-
+ contrib/haskell/src/xrd.hs                         |   2 +-
+ 20 files changed, 166 insertions(+), 188 deletions(-)
+
+commit fef3c94e8a9c28529b95bd74f4791369ff7caea2
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Feb 19 09:02:40 2017 +0100
+
+    [contrib][haskell] add the DataSource type
+
+ contrib/haskell/hkl.cabal                     |   2 +-
+ contrib/haskell/src/Hkl.hs                    |   1 -
+ contrib/haskell/src/Hkl/Calibration.hs        | 132 --------------------------
+ contrib/haskell/src/Hkl/DataSource.hs         |  46 +++++++++
+ contrib/haskell/src/Hkl/Diffabs/Charlier.hs   |   1 +
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      |   1 +
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |   1 +
+ contrib/haskell/src/Hkl/H5.hs                 |   4 +
+ contrib/haskell/src/Hkl/Sixs.hs               |   2 +
+ contrib/haskell/src/Hkl/Types.hs              |  18 ----
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs    |   1 +
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs           |   1 +
+ contrib/haskell/src/Hkl/Xrd/OneD.hs           |  21 ++--
+ 13 files changed, 69 insertions(+), 162 deletions(-)
+
+commit d476011bef2cf955ca8c3d67ead9d406483f612d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Feb 3 09:44:48 2017 +0100
+
+    [contrib][haskell] wip flyscan mesh
+
+ contrib/haskell/src/Hkl/Calibration.hs        |  35 ++--
+ contrib/haskell/src/Hkl/Diffabs/Charlier.hs   |  29 ++--
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      |  64 +++++--
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  16 +-
+ contrib/haskell/src/Hkl/Diffabs/Melle.hs      |   2 +-
+ contrib/haskell/src/Hkl/H5.hs                 |   3 +
+ contrib/haskell/src/Hkl/Sixs.hs               |  35 ++--
+ contrib/haskell/src/Hkl/Types.hs              |  17 +-
+ contrib/haskell/src/Hkl/Xrd/Calibration.hs    |   5 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs           | 233 ++++++++++++++++++--------
+ contrib/haskell/src/Hkl/Xrd/OneD.hs           |  15 +-
+ contrib/haskell/src/xrd.hs                    |   4 +-
+ 12 files changed, 300 insertions(+), 158 deletions(-)
+
+commit 872af31b5964a6128b478655228f2e9656e0c4d3
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Jan 26 15:25:38 2017 +0100
+
+    [contrib][haskell] first working mesh
+
+ contrib/haskell/src/Hkl/Diffabs/Charlier.hs |  34 +++-
+ contrib/haskell/src/Hkl/Types.hs            |   7 +-
+ contrib/haskell/src/Hkl/Utils.hs            |  38 ++++-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs         | 233 +++++++++++++---------------
+ 4 files changed, 179 insertions(+), 133 deletions(-)
+
+commit be67f14aa56966173857ca05921edccc98aa1472
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jan 24 11:08:50 2017 +0100
+
+    [contrib][haskell] rename and reoganise XRD -> Xrd
+
+ contrib/haskell/hkl.cabal                          |   6 +-
+ contrib/haskell/src/Hkl/D2AM/XRD.hs                |   3 +-
+ contrib/haskell/src/Hkl/Diffabs/Charlier.hs        |   5 +-
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs           |   3 +-
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs      |   3 +-
+ contrib/haskell/src/Hkl/Xrd.hs                     |   5 +
+ .../haskell/src/Hkl/{XRD => Xrd}/Calibration.hs    |   4 +-
+ contrib/haskell/src/Hkl/Xrd/Mesh.hs                | 222 +++++++++++++++++++++
+ contrib/haskell/src/Hkl/{XRD.hs => Xrd/OneD.hs}    | 168 +---------------
+ 9 files changed, 243 insertions(+), 176 deletions(-)
+
+commit 6e5056c441cb81f95dc357bf5ebe3bd6d7741e8b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jan 24 10:27:48 2017 +0100
+
+    wip mesh
+
+ contrib/haskell/hkl.cabal                   |   3 +-
+ contrib/haskell/src/Hkl/Diffabs.hs          |   3 +-
+ contrib/haskell/src/Hkl/Diffabs/Charlier.hs | 147 +++++++++++++++
+ contrib/haskell/src/Hkl/Diffabs/Melle.hs    |  65 ++++---
+ contrib/haskell/src/Hkl/H5.hs               |  14 ++
+ contrib/haskell/src/Hkl/XRD.hs              | 277 +++++++++++++++++-----------
+ contrib/haskell/src/xrd.hs                  |   3 +-
+ 7 files changed, 369 insertions(+), 143 deletions(-)
+
+commit 2c173825f5ebf1844c86537f6c61aa5ba5e05644
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Jan 17 14:03:42 2017 +0100
+
+    [contrib][haskell] start to work on the non aborted scans.
+    
+    these scans contain Nan values at the end.
+    So we just need to break the stream when we encounter a Nan
+
+ contrib/haskell/hkl.cabal                     | 12 +++--
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  7 +--
+ contrib/haskell/src/Hkl/Diffabs/Melle.hs      | 32 +++++++-------
+ contrib/haskell/src/Hkl/XRD.hs                | 64 ++++++++++++++++-----------
+ contrib/haskell/src/xrd.hs                    |  4 +-
+ 5 files changed, 65 insertions(+), 54 deletions(-)
+
+commit af91414c7644610d166acbdb8a6c2696bfb02cb9
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Mon Jan 2 11:25:15 2017 +0100
+
+    upgrading copyright year from 2016 to 2017
+
+ Documentation/hkl-default.el                  | 2 +-
+ contrib/haskell/src/hkl.hs                    | 2 +-
+ contrib/sixs/hkl3d.c                          | 2 +-
+ gui/hkl-gui-3d.c                              | 2 +-
+ gui/hkl-gui-3d.h                              | 2 +-
+ gui/hkl-gui-macros.h                          | 2 +-
+ gui/hkl-gui.c                                 | 2 +-
+ gui/hkl-gui.h                                 | 2 +-
+ hkl.h                                         | 2 +-
+ hkl/hkl-axis-private.h                        | 2 +-
+ hkl/hkl-axis.c                                | 2 +-
+ hkl/hkl-binding-private.h                     | 2 +-
+ hkl/hkl-binding.c                             | 2 +-
+ hkl/hkl-detector-factory.c                    | 2 +-
+ hkl/hkl-detector-private.h                    | 2 +-
+ hkl/hkl-detector.c                            | 2 +-
+ hkl/hkl-engine-2c.c                           | 2 +-
+ hkl/hkl-engine-e4c.c                          | 2 +-
+ hkl/hkl-engine-e6c.c                          | 2 +-
+ hkl/hkl-engine-k4c.c                          | 2 +-
+ hkl/hkl-engine-k6c.c                          | 2 +-
+ hkl/hkl-engine-petra3-p09-eh2.c               | 2 +-
+ hkl/hkl-engine-soleil-sirius-turret.c         | 2 +-
+ hkl/hkl-engine-soleil-sixs-med.c              | 2 +-
+ hkl/hkl-engine-template.c                     | 2 +-
+ hkl/hkl-engine-zaxis.c                        | 2 +-
+ hkl/hkl-factory-private.h                     | 2 +-
+ hkl/hkl-factory.c                             | 2 +-
+ hkl/hkl-geometry-private.h                    | 2 +-
+ hkl/hkl-geometry.c                            | 2 +-
+ hkl/hkl-interval-private.h                    | 2 +-
+ hkl/hkl-interval.c                            | 2 +-
+ hkl/hkl-lattice-private.h                     | 2 +-
+ hkl/hkl-lattice.c                             | 2 +-
+ hkl/hkl-macros-private.h                      | 2 +-
+ hkl/hkl-macros.c                              | 2 +-
+ hkl/hkl-matrix-private.h                      | 2 +-
+ hkl/hkl-matrix.c                              | 2 +-
+ hkl/hkl-parameter-private.h                   | 2 +-
+ hkl/hkl-parameter.c                           | 2 +-
+ hkl/hkl-pseudoaxis-auto-private.h             | 2 +-
+ hkl/hkl-pseudoaxis-auto.c                     | 2 +-
+ hkl/hkl-pseudoaxis-common-eulerians-private.h | 2 +-
+ hkl/hkl-pseudoaxis-common-eulerians.c         | 2 +-
+ hkl/hkl-pseudoaxis-common-hkl-private.h       | 2 +-
+ hkl/hkl-pseudoaxis-common-hkl.c               | 2 +-
+ hkl/hkl-pseudoaxis-common-psi-private.h       | 2 +-
+ hkl/hkl-pseudoaxis-common-psi.c               | 2 +-
+ hkl/hkl-pseudoaxis-common-q-private.h         | 2 +-
+ hkl/hkl-pseudoaxis-common-q.c                 | 2 +-
+ hkl/hkl-pseudoaxis-common-readonly-private.h  | 2 +-
+ hkl/hkl-pseudoaxis-common-readonly.c          | 2 +-
+ hkl/hkl-pseudoaxis-common-tth-private.h       | 2 +-
+ hkl/hkl-pseudoaxis-common-tth.c               | 2 +-
+ hkl/hkl-pseudoaxis-private.h                  | 2 +-
+ hkl/hkl-pseudoaxis.c                          | 2 +-
+ hkl/hkl-quaternion-private.h                  | 2 +-
+ hkl/hkl-quaternion.c                          | 2 +-
+ hkl/hkl-sample-private.h                      | 2 +-
+ hkl/hkl-sample.c                              | 2 +-
+ hkl/hkl-source-private.h                      | 2 +-
+ hkl/hkl-source.c                              | 2 +-
+ hkl/hkl-types.c                               | 2 +-
+ hkl/hkl-types.h                               | 2 +-
+ hkl/hkl-unit-private.h                        | 2 +-
+ hkl/hkl-unit.c                                | 2 +-
+ hkl/hkl-vector-private.h                      | 2 +-
+ hkl/hkl-vector.c                              | 2 +-
+ hkl3d/hkl3d.h                                 | 2 +-
+ tests/hkl-axis-t.c                            | 2 +-
+ tests/hkl-bench-t.c                           | 2 +-
+ tests/hkl-detector-t.c                        | 2 +-
+ tests/hkl-geometry-t.c                        | 2 +-
+ tests/hkl-interval-t.c                        | 2 +-
+ tests/hkl-lattice-t.c                         | 2 +-
+ tests/hkl-matrix-t.c                          | 2 +-
+ tests/hkl-parameter-t.c                       | 2 +-
+ tests/hkl-pseudoaxis-e4ch-t.c                 | 2 +-
+ tests/hkl-pseudoaxis-e4cv-t.c                 | 2 +-
+ tests/hkl-pseudoaxis-e6c-t.c                  | 2 +-
+ tests/hkl-pseudoaxis-k4cv-t.c                 | 2 +-
+ tests/hkl-pseudoaxis-k6c-t.c                  | 2 +-
+ tests/hkl-pseudoaxis-t.c                      | 2 +-
+ tests/hkl-pseudoaxis-zaxis-t.c                | 2 +-
+ tests/hkl-quaternion-t.c                      | 2 +-
+ tests/hkl-sample-t.c                          | 2 +-
+ tests/hkl-source-t.c                          | 2 +-
+ tests/hkl-unit-t.c                            | 2 +-
+ tests/hkl-vector-t.c                          | 2 +-
+ tests/hkl3d-test-t.c                          | 2 +-
+ tests/tap/hkl-tap.h                           | 2 +-
+ 91 files changed, 91 insertions(+), 91 deletions(-)
+
+commit 81485b556a45c8c8e6f5c30575017e171d28796e
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Wed Dec 14 18:43:01 2016 +0100
+
+    pom.xml 5.1.1
+
+ hkl/pom.xml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit e5837cd2a368dce083cf7f4ca42049dc4dffdf1f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Dec 14 16:25:49 2016 +0100
+
+    [contrib][haskell] create the multi.py script for edf files
+
+ contrib/haskell/src/Hkl/XRD.hs | 58 +++++++++++++++++++++++++++++++++---------
+ 1 file changed, 46 insertions(+), 12 deletions(-)
+
+commit 5e6a691789eabfb9710cce4d37dc898aa1092aef
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Dec 14 15:03:33 2016 +0100
+
+    [contrib][haskell] add a generic saveScript method and use it
+
+ contrib/haskell/hkl.cabal           |  1 +
+ contrib/haskell/src/Hkl/D2AM/XRD.hs |  2 +-
+ contrib/haskell/src/Hkl/Utils.hs    | 16 +++++++++++++++
+ contrib/haskell/src/Hkl/XRD.hs      | 39 ++++++++++++++++++++-----------------
+ 4 files changed, 39 insertions(+), 19 deletions(-)
+
+commit 779abdc061065ff7205919bf58f67fcfb268f8b7
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Dec 13 14:54:10 2016 +0100
+
+    wip [contrib][haskell] add the multi integration for Edf
+
+ contrib/haskell/src/Hkl/D2AM/XRD.hs | 35 +++++++++++++++++++++++++++--------
+ 1 file changed, 27 insertions(+), 8 deletions(-)
+
+commit 7035339ee1e2d9f0b499d834079175a7042da768
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Dec 13 14:30:05 2016 +0100
+
+    [contrib][haskell] prepare for multi integration with edf
+
+ contrib/haskell/src/Hkl/D2AM/XRD.hs           | 12 +++++++++---
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      | 15 ++++++++++-----
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs | 15 ++++++++++-----
+ contrib/haskell/src/Hkl/XRD.hs                | 25 ++++++++++++++++++-------
+ contrib/haskell/src/Hkl/XRD/Calibration.hs    |  1 -
+ 5 files changed, 47 insertions(+), 21 deletions(-)
+
+commit f283378db94f69508d2a13e265813a87b7c35ceb
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Dec 13 13:42:56 2016 +0100
+
+    [contrib][haskell] add the xrd calibration with edf files
+
+ contrib/haskell/hkl.cabal                     |   2 +
+ contrib/haskell/src/Hkl.hs                    |   1 +
+ contrib/haskell/src/Hkl/D2AM.hs               |   3 +
+ contrib/haskell/src/Hkl/D2AM/XRD.hs           |  76 ++++++++
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      |   8 +-
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |   8 +-
+ contrib/haskell/src/Hkl/Diffabs/Melle.hs      | 247 +++++++++++++-------------
+ contrib/haskell/src/Hkl/Edf.hs                |  29 ++-
+ contrib/haskell/src/Hkl/XRD.hs                | 226 ++++++++++++-----------
+ contrib/haskell/src/Hkl/XRD/Calibration.hs    |  30 ++--
+ contrib/haskell/src/xrd.hs                    |   3 +-
+ 11 files changed, 372 insertions(+), 261 deletions(-)
+
+commit 2e4a099cb2609653f259ce7a4486c80c66e651c2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Dec 9 16:38:57 2016 +0100
+
+    [contrib][haskell] wip
+    
+    Signed-off-by: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+
+ contrib/haskell/hkl.cabal                     |   3 +-
+ contrib/haskell/src/Hkl/Diffabs.hs            |   3 +-
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      |   8 ++
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |   4 +
+ contrib/haskell/src/Hkl/Diffabs/Melle.hs      | 147 ++++++++++++++++++++++++++
+ contrib/haskell/src/Hkl/XRD.hs                | 105 +++++++++++++++++-
+ contrib/haskell/src/xrd.hs                    |   5 +-
+ 7 files changed, 269 insertions(+), 6 deletions(-)
+
+commit 25a2e7ce845e1adf918ec5955be5dcab0f15061e
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Dec 6 11:42:57 2016 +0100
+
+    [contrib][swing] ccd calibration
+
+ contrib/swing/pinhole1.smv | Bin 0 -> 33554944 bytes
+ contrib/swing/plot.py      |  12 ++++++++++++
+ 2 files changed, 12 insertions(+)
+
+commit 4cc275d37ac63944accc970e83a356aee781517a
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Dec 5 15:51:12 2016 +0100
+
+    [contrib][haskell] reorganisation before XRD mesh work
+
+ contrib/haskell/src/Hkl/XRD.hs | 131 +++++++++++++++++++++--------------------
+ 1 file changed, 66 insertions(+), 65 deletions(-)
+
+commit af0df2f97d3c7f700ec12f8c624f7609efafc7ee
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Dec 5 15:35:48 2016 +0100
+
+    [contrib][haskell] no more Bin
+
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      |  4 ++--
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  4 ++--
+ contrib/haskell/src/Hkl/XRD.hs                | 16 ++++++----------
+ 3 files changed, 10 insertions(+), 14 deletions(-)
+
+commit bd5341b818c2022d8ecb968bcdec5778e5b3aa36
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Dec 5 15:31:39 2016 +0100
+
+    [contrib][haskell] use DIM1 instead of Bin to express the array size
+
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      | 40 ++++---------------------
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  5 ++--
+ contrib/haskell/src/Hkl/XRD.hs                | 42 +++++++++++++--------------
+ contrib/haskell/src/xrd.hs                    |  4 +--
+ 4 files changed, 32 insertions(+), 59 deletions(-)
+
+commit 74acd6952297ac150a226fe59f661f603f172c85
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Dec 5 14:23:39 2016 +0100
+
+    [contrib][haskell] start to use the repa shape
+    
+    In order to prepare the diftomo for multi dimension scans.
+    Start to use the Repa.Shape.
+
+ contrib/haskell/hkl.cabal      |  1 +
+ contrib/haskell/src/Hkl/XRD.hs | 43 +++++++++++++++++++++---------------------
+ 2 files changed, 23 insertions(+), 21 deletions(-)
+
+commit a911d2ad5b34b4944e2eb2843bc4942000a053b3
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Dec 11 11:06:06 2016 +0100
+
+    [contrib][haskell] add Edf support
+
+ contrib/haskell/hkl.cabal      |  10 ++--
+ contrib/haskell/src/Hkl/Edf.hs | 106 +++++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 112 insertions(+), 4 deletions(-)
+
+commit fbec2c073d3961473ec23921237785cbff3dbd18
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Nov 27 18:07:43 2016 +0100
+
+    fix logging
+
+ hkl/hkl-pseudoaxis.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit f63e22c969450a26e12cf6267118c484a17e442b
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 22 18:05:29 2016 +0100
+
+    [contrib][haskell] TODO deal with the radial_range ???
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs | 2 ++
+ contrib/haskell/src/Hkl/XRD.hs                | 2 +-
+ 2 files changed, 3 insertions(+), 1 deletion(-)
+
+commit 6c4e03837ad5675b8172aa1d361182a0676e8577
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 22 11:56:01 2016 +0100
+
+    [contrib][haskell] add the MultiGeometry support
+
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      |   5 +-
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  51 +++++++------
+ contrib/haskell/src/Hkl/XRD.hs                | 104 +++++++++++++++++++++++---
+ contrib/haskell/src/xrd.hs                    |   9 ++-
+ 4 files changed, 131 insertions(+), 38 deletions(-)
+
+commit ec380a4ab31b619542eb03ad78c9316d9a93ab76
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Nov 15 11:23:06 2016 +0100
+
+    [contrib][haskell] add the irdrx files
+
+ contrib/haskell/hkl.cabal                     |   1 +
+ contrib/haskell/src/Hkl/Diffabs.hs            |   1 +
+ contrib/haskell/src/Hkl/Diffabs/IRDRx.hs      | 144 ++++++++++++++++++++++++++
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |   4 +-
+ contrib/haskell/src/Hkl/XRD.hs                |   9 +-
+ contrib/haskell/src/xrd.hs                    |   3 +-
+ 6 files changed, 156 insertions(+), 6 deletions(-)
+
+commit 3a3ef8d33abfbdc0409180038fbcce39f3543a51
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Nov 3 15:11:20 2016 +0100
+
+    [contrib][haskell] use StandAloneDeriving for GADTs
+
+ contrib/haskell/src/Hkl/Detector.hs | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+commit 9728dc969ab58ba0041ccdc7794f5709ea0f83a1
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Fri Oct 28 15:45:40 2016 +0200
+
+    [contrib][haskell] support hmatrix 0.15 -> 0.17
+
+ contrib/haskell/src/Hkl/XRD/Calibration.hs | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+commit 7d4d7c4cf70dc3fa49e1051a1f6d474d5edb3340
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Oct 25 18:34:38 2016 +0200
+
+    [contrib][haskell] add the a26, f30 and r35n1 samples
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs | 63 ++++++++++++++++++++++-----
+ 1 file changed, 51 insertions(+), 12 deletions(-)
+
+commit e87f09bab21f1846bf9505a036be841d67bb9a75
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 24 10:43:14 2016 +0200
+
+    [contrib][haskell] integrate also the CeO2 sample
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs | 101 ++++++++++++--------------
+ 1 file changed, 48 insertions(+), 53 deletions(-)
+
+commit 751155d57f917bfecb001e5c04a37537e18b0da2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 24 10:42:57 2016 +0200
+
+    [contrib][haskell] simplify xrd
+
+ contrib/haskell/src/xrd.hs | 62 ----------------------------------------------
+ 1 file changed, 62 deletions(-)
+
+commit 6a239f471c78f095ebd0c1dbf87082c739135966
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 24 10:42:15 2016 +0200
+
+    [contrib][haskell] open the NeXuS file in read-only mode
+    
+    some files are read-only and opening them in 'rw' failed.
+
+ contrib/haskell/src/Hkl/XRD.hs | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+commit 36624b707f25bf0d16edcc3a67d22db6964e5209
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 24 10:13:03 2016 +0200
+
+    [contrib][haskell] fix for ghc < 7.10
+
+ contrib/haskell/src/Hkl/XRD.hs             | 2 +-
+ contrib/haskell/src/Hkl/XRD/Calibration.hs | 7 ++++++-
+ 2 files changed, 7 insertions(+), 2 deletions(-)
+
+commit 745e98f87183193b97a988f3ec895c6afd9f0c9f
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 24 10:07:32 2016 +0200
+
+    [contrib][haskell] xrf -> xrd
+
+ contrib/haskell/hkl.cabal              | 4 ++--
+ contrib/haskell/src/{xrf.hs => xrd.hs} | 0
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+commit ed42a9066637357c31d67842dbd1ac14c072ed57
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Oct 10 11:00:08 2016 +0200
+
+    [contrib][haskell] fix the gnuplot file generation
+
+ contrib/haskell/src/Hkl/XRD.hs | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
+commit 8b3d5405a8ed7e07c7bf52f422455111058b4415
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Oct 23 14:15:13 2016 +0200
+
+    [contrib][haskell] add the ZAXIS diffractometer
+
+ contrib/haskell/src/Hkl.hs       |   1 +
+ contrib/haskell/src/Hkl/Types.hs |   4 +-
+ contrib/haskell/src/ghkl.hs      | 109 +++++++++++++++++----------------------
+ 3 files changed, 50 insertions(+), 64 deletions(-)
+
+commit 99f650d9ccc6160288fa6f3094cc2d99e0591d56
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Oct 23 13:44:00 2016 +0200
+
+    [contrib][haskell] add the xrf executable
+
+ contrib/haskell/hkl.cabal  | 23 +++++++++++++++
+ contrib/haskell/src/xrf.hs | 71 ++++++++++++++++++++++++++++++++++++++++++++++
+ 2 files changed, 94 insertions(+)
+
+commit df7a73b03718aaf30a547a8becb316e309c1a87f
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sun Oct 23 09:22:31 2016 +0200
+
+    [contrib][haskell] compile with hmatrix >= 0.17
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs | 4 ++--
+ contrib/haskell/src/Hkl/MyMatrix.hs           | 2 +-
+ contrib/haskell/src/Hkl/XRD/Calibration.hs    | 7 +------
+ 3 files changed, 4 insertions(+), 9 deletions(-)
+
+commit 3b653ae3513f2b0241c848b189b2a2cee40b4b77
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Oct 4 18:32:07 2016 +0200
+
+    [contrib][haskell] more implicite imports
+
+ contrib/haskell/src/Hkl/Calibration.hs     |   1 +
+ contrib/haskell/src/Hkl/H5.hs              |   1 -
+ contrib/haskell/src/Hkl/Sixs.hs            |   1 +
+ contrib/haskell/src/Hkl/XRD.hs             | 142 +++++++++++++++--------------
+ contrib/haskell/src/Hkl/XRD/Calibration.hs |   1 +
+ 5 files changed, 79 insertions(+), 67 deletions(-)
+
+commit 67a62257ab83daac7cc146db997ee8f7346461d2
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Oct 4 18:10:17 2016 +0200
+
+    [contrib][haskell] explicite imports
+
+ contrib/haskell/src/Hkl/XRD/Calibration.hs | 75 ++++++++++++++++++------------
+ 1 file changed, 44 insertions(+), 31 deletions(-)
+
+commit d218c0352b2997f409aa364fae0b4c7136a12457
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Oct 1 15:14:15 2016 +0200
+
+    [contrib][haskell] comment
+
+ contrib/haskell/src/Hkl/Detector.hs | 2 ++
+ 1 file changed, 2 insertions(+)
+
+commit 08fff431279373daf2e6911b526160021abbda73
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Oct 1 15:09:54 2016 +0200
+
+    [contrib][haskell] hlint
+
+ contrib/haskell/src/Hkl/XRD/Calibration.hs | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+commit c94c006a9332fe31f75de103c31f366e9d517d77
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Oct 1 15:08:56 2016 +0200
+
+    [contrib][haskell] Xpad pixels size is always 130e-6
+
+ contrib/haskell/src/Hkl/Detector.hs | 36 +++++++++++++++++++-----------------
+ 1 file changed, 19 insertions(+), 17 deletions(-)
+
+commit 0244df1b114e666dd92086d857e16746e5ead711
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Oct 1 13:29:58 2016 +0200
+
+    [contrib][haskell] Add the ImXpadS140 detector
+
+ contrib/haskell/src/Hkl/C.hsc       |  6 +--
+ contrib/haskell/src/Hkl/Detector.hs | 83 ++++++++++++++++++-------------------
+ 2 files changed, 44 insertions(+), 45 deletions(-)
+
+commit 9342820d871e70ce50fe993e60b3b88bece64866
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Sep 30 20:27:24 2016 +0200
+
+    [contrib][haskell] reorganisation of the code
+
+ contrib/haskell/hkl.cabal                     |   1 +
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |   3 +-
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs         |  46 +++---
+ contrib/haskell/src/Hkl/XRD.hs                | 163 ++--------------------
+ contrib/haskell/src/Hkl/XRD/Calibration.hs    | 194 ++++++++++++++++++++++++++
+ 5 files changed, 230 insertions(+), 177 deletions(-)
+
+commit 7bd8cba87f1ed399592871684762ff6e7caa6acb
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Sep 30 14:33:59 2016 +0200
+
+    [contrib][haskell] doc
+
+ contrib/haskell/src/Hkl/XRD.hs | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+commit 2f1e7bbbc5f82eef1b5d33b210f4e6070ec4eee7
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Sep 29 08:43:48 2016 +0200
+
+    [contrib][haskell] create types for the calibration optimisation
+
+ contrib/haskell/src/Hkl/XRD.hs | 22 ++++++++++++++--------
+ 1 file changed, 14 insertions(+), 8 deletions(-)
+
+commit c2071dfbfa3b1f96a07636ba530289cf0d3858c6
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Thu Sep 29 08:31:40 2016 +0200
+
+    [contrib][haskll] reduce the number of lines :)
+
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs |  4 ++--
+ contrib/haskell/src/Hkl/XRD.hs        | 11 ++++-------
+ 2 files changed, 6 insertions(+), 9 deletions(-)
+
+commit 0b09c11e8582a420c301c5fc065a3990c101e95e
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Sep 28 17:59:28 2016 +0200
+
+    [contrib][haskell] continu improving the calibration speed
+
+ contrib/haskell/src/Hkl/XRD.hs | 73 ++++++++++++++++++++++--------------------
+ 1 file changed, 38 insertions(+), 35 deletions(-)
+
+commit 81364da3b04063902a884335b33b6ce658d47bbd
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Sep 28 16:14:35 2016 +0200
+
+    [contrib][haskell] interpolate the detector coordinates
+
+ contrib/haskell/src/Hkl/Detector.hs | 17 ++++++++++++++++-
+ 1 file changed, 16 insertions(+), 1 deletion(-)
+
+commit cf1715ee90046452552ccf010ac71221a6ccc6dd
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Sep 28 14:48:41 2016 +0200
+
+    [contrib][haskell] more simplification
+
+ contrib/haskell/src/Hkl/Detector.hs | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+commit f3d2d4ab222e2778c7d04c4a7d21f10040a0bb6d
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Wed Sep 28 14:14:53 2016 +0200
+
+    [contrib][haskell] fix the width of the Xpad32 and improve the speed
+
+ contrib/haskell/src/Hkl/Detector.hs           | 76 +++++----------------------
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  2 +-
+ 2 files changed, 13 insertions(+), 65 deletions(-)
+
+commit 851124553c77d0fc2e6a99a05648ae064b440820
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Tue Sep 27 21:13:09 2016 +0200
+
+    [contrib][haskell] add the useHMatrixGsl option and simplify profiling
+
+ contrib/haskell/hkl.cabal | 72 ++++++++++++++++++-----------------------------
+ 1 file changed, 28 insertions(+), 44 deletions(-)
+
+commit 5a0c86c5231aed06cd97964c1e014cd9a8253731
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Sep 27 16:24:30 2016 +0200
+
+    [contrib][haskell] improve the calibration time
+
+ contrib/haskell/hkl.cabal           | 31 +++++++++++++++++++++++-----
+ contrib/haskell/src/Hkl/Detector.hs | 40 ++++++++++++++++++++++++++++++++++++-
+ contrib/haskell/src/Hkl/XRD.hs      |  9 +++++----
+ 3 files changed, 70 insertions(+), 10 deletions(-)
+
+commit d6398df0643125477d8eede07a1265e67bfc1f56
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Sep 27 09:51:04 2016 +0200
+
+    [contrib][haskell] optimize the calibration
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  2 +-
+ contrib/haskell/src/Hkl/XRD.hs                | 58 ++++++++++++++-------------
+ 2 files changed, 32 insertions(+), 28 deletions(-)
+
+commit 293a0c6f0c02db8bf6587bcc7075f5c3e601b5c1
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Sep 26 15:55:10 2016 +0200
+
+    [contrib][haskell] optimise by using the minimizeV method
+
+ contrib/haskell/src/Hkl/XRD.hs | 30 ++++++++++++++++++------------
+ 1 file changed, 18 insertions(+), 12 deletions(-)
+
+commit 658c2c199fb2dde48b043071525a0e6a2662fcea
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Sep 26 14:32:48 2016 +0200
+
+    [contrib][haskell] first calibration with all the images.
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |  3 ++-
+ contrib/haskell/src/Hkl/XRD.hs                | 10 ++++++++--
+ contrib/haskell/src/ghkl.hs                   |  4 ++--
+ 3 files changed, 12 insertions(+), 5 deletions(-)
+
+commit 1ae47f9d369e1c049c29a2da31144e4a7a148564
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Mon Sep 26 10:15:14 2016 +0200
+
+    [contrib][haskell] fix for hmatrix < 0.17
+
+ contrib/haskell/hkl.cabal      |  2 +-
+ contrib/haskell/src/Hkl/XRD.hs | 21 +++++++++++++--------
+ 2 files changed, 14 insertions(+), 9 deletions(-)
+
+commit 6bbac0b6df73822023b722002fbf3c9873bb7ad2
+Author: Picca Frédéric-Emmanuel <picca at debian.org>
+Date:   Sat Sep 24 16:36:50 2016 +0200
+
+    [contrib][haskell] make it compiles on Debian unstable
+
+ contrib/haskell/hkl.cabal           |  1 +
+ contrib/haskell/src/Hkl/Detector.hs | 32 ++++++++++++---------
+ contrib/haskell/src/Hkl/XRD.hs      | 57 +++++++++++++++++++++----------------
+ 3 files changed, 52 insertions(+), 38 deletions(-)
+
+commit a10dde3df1efa8aa2b5d2df5b7e6bda1ac334f21
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Fri Sep 23 15:06:52 2016 +0200
+
+    [contrib][haskell] generate a gnuplot script for each sample.
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs |   3 +-
+ contrib/haskell/src/Hkl/XRD.hs                | 164 +++++++++++++++++---------
+ 2 files changed, 107 insertions(+), 60 deletions(-)
+
+commit 9919923416fc99c0cea8ce6646b3394e3b7aefdd
+Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+Date:   Tue Sep 20 13:45:53 2016 +0200
+
+    [contrib][haskell] the integration is back to normal.
+    
+    Now that the Xpad_flat was corrected we have very nice spectra
+
+ contrib/haskell/src/Hkl/Diffabs/Martinetto.hs | 3 ++-
+ contrib/haskell/src/Hkl/PyFAI/Poni.hs         | 4 ++--
+ contrib/haskell/src/ghkl.hs                   | 4 ++--
+ 3 files changed, 6 insertions(+), 5 deletions(-)
+
 commit e3215664bebb2c37020499c6636ebed4f65566c7
-Merge: 764f78d 8ae5f1f
+Merge: 764f78d7 8ae5f1fc
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Mon Sep 19 22:18:12 2016 +0200
 
@@ -998,7 +4006,7 @@ Date:   Thu Apr 28 08:59:18 2016 +0200
  1 file changed, 1 insertion(+)
 
 commit 764f78d732d5a0181902bc11029fafad80ef1bbd
-Merge: 3748498 140965b
+Merge: 37484987 140965b3
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Wed Apr 27 09:05:13 2016 +0200
 
@@ -1106,7 +4114,7 @@ Date:   Fri Apr 15 18:13:14 2016 +0200
  9 files changed, 219 insertions(+), 3 deletions(-)
 
 commit 1901ca074ec3dce4432e99cd9b6c8ac3079ef6c7
-Merge: 18999cb 49fb23d
+Merge: 18999cbd 49fb23d4
 Author: System User <picca at synchrotron-soleil.fr>
 Date:   Tue Apr 12 14:25:13 2016 +0200
 
@@ -2029,7 +5037,7 @@ Date:   Thu Feb 4 11:10:59 2016 +0100
  3 files changed, 62 insertions(+), 29 deletions(-)
 
 commit d0ecf7598f1aa6c49f98fa42d95964ad45811aba
-Merge: d508aab 0f55f42
+Merge: d508aab9 0f55f422
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Thu Feb 4 10:34:55 2016 +0100
 
@@ -2372,7 +5380,7 @@ Date:   Wed Nov 4 11:30:01 2015 +0100
  2 files changed, 74 insertions(+)
 
 commit cf2d96018b8501e3c5f07244015addb2e52b79ec
-Merge: c0e7868 9ddaabb
+Merge: c0e78687 9ddaabb8
 Author: System User <picca at synchrotron-soleil.fr>
 Date:   Wed Oct 7 15:33:02 2015 +0200
 
@@ -4636,7 +7644,7 @@ Date:   Fri Oct 10 16:43:13 2014 +0200
  4 files changed, 42 insertions(+), 14 deletions(-)
 
 commit 1f2928a9a6f3d2c4550bbce6dc3b4763ab6d1a49
-Merge: b2c4731 db07452
+Merge: b2c47317 db074524
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Wed Oct 8 21:23:52 2014 +0200
 
@@ -4811,7 +7819,7 @@ Date:   Mon Sep 22 14:46:00 2014 +0200
  4 files changed, 242 insertions(+), 1 deletion(-)
 
 commit b3c9d6029fc81d973ae027750a47f1b9f9996bb1
-Merge: ce4c831 79e3766
+Merge: ce4c831e 79e37666
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Mon Sep 15 16:38:07 2014 +0200
 
@@ -6380,7 +9388,7 @@ Date:   Thu Feb 27 22:04:36 2014 +0100
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 commit bc01bb4eb17b8e817ab3f930cb2508e1515b7c5c
-Merge: c66e437 50622f4
+Merge: c66e4376 50622f45
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Thu Feb 27 16:57:24 2014 +0100
 
@@ -6993,7 +10001,7 @@ Date:   Mon Jan 6 08:42:57 2014 +0100
  3 files changed, 366 insertions(+), 753 deletions(-)
 
 commit 7311dfb420a77fb0218c7f27c20cc77264b40be9
-Merge: 8688c93 c66e437
+Merge: 8688c93a c66e4376
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Sun Jan 5 15:58:30 2014 +0100
 
@@ -7054,7 +10062,7 @@ Date:   Sun Dec 29 14:21:45 2013 +0100
  9 files changed, 17 insertions(+), 16 deletions(-)
 
 commit 29dd8a7e44a384ecb01f3f387f764434a90f0202
-Merge: f5c116a 7c302b9
+Merge: f5c116a1 7c302b91
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Sun Dec 29 11:31:38 2013 +0100
 
@@ -8905,7 +11913,7 @@ Date:   Mon Feb 4 17:35:58 2013 +0100
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 commit 9dce659205905d1336bb70d73dd497f249177df9
-Merge: 8650548 776b325
+Merge: 86505487 776b3257
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Mon Feb 4 17:26:13 2013 +0100
 
@@ -9140,7 +12148,7 @@ Date:   Mon Jan 14 17:35:23 2013 +0100
  109 files changed, 109 insertions(+), 109 deletions(-)
 
 commit 349b0c37f04f1d0253ec135ca4e5f4a67ce45801
-Merge: 11247a9 0720588
+Merge: 11247a9d 07205880
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Mon Jan 14 12:28:22 2013 +0100
 
@@ -11122,7 +14130,7 @@ Date:   Tue Jul 24 11:53:12 2012 +0200
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 commit adc13e2193dd6e3322c95502fd6354a4ed0d7c26
-Merge: c0ed0ce 50a84fb
+Merge: c0ed0cea 50a84fb0
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Tue Jul 24 10:54:14 2012 +0200
 
@@ -11182,7 +14190,7 @@ Date:   Tue Jul 17 17:12:17 2012 +0200
  5 files changed, 238 insertions(+), 13 deletions(-)
 
 commit c0ed0cea56675b26ff81ea7c289a5ede9ffff665
-Merge: 4450288 86d308a
+Merge: 44502889 86d308a7
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Sun Jun 17 23:05:42 2012 +0200
 
@@ -11201,7 +14209,7 @@ Date:   Sun Jun 17 23:05:42 2012 +0200
             test/hkl/pseudoaxis-t.c
 
 commit 445028891e4d52770bf77d0a798fd32276e95965
-Merge: 36c0c65 8c599b9
+Merge: 36c0c659 8c599b9e
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Sun Jun 17 21:00:31 2012 +0200
 
@@ -11231,7 +14239,7 @@ Date:   Sun Jun 17 21:00:31 2012 +0200
             test/hkl/pseudoaxis-t.c
 
 commit 86d308a76f2aed87bfb96ab8f408814b0cfb20ed
-Merge: fc27d4d 8c599b9
+Merge: fc27d4da 8c599b9e
 Author: Picca Frédéric-Emmanuel <picca at debian.org>
 Date:   Sat Jun 16 15:18:12 2012 +0200
 
@@ -11960,7 +14968,7 @@ Date:   Fri Jun 10 14:42:43 2011 +0200
  3 files changed, 102 insertions(+), 13 deletions(-)
 
 commit a4d3afde63abf984647bef6748542e59b2b6f78e
-Merge: 31f04fb e771ad5
+Merge: 31f04fb7 e771ad5e
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Thu Jun 9 17:43:24 2011 +0200
 
@@ -12128,7 +15136,7 @@ Date:   Tue May 31 16:03:40 2011 +0200
  9 files changed, 1897 insertions(+), 1 deletion(-)
 
 commit 31f04fb7386f340c276f29152460dcbe3590a0c8
-Merge: ac1155f 19fea11
+Merge: ac1155fa 19fea118
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Tue May 10 11:24:35 2011 +0200
 
@@ -12144,7 +15152,7 @@ Date:   Tue May 10 11:24:26 2011 +0200
  1 file changed, 1 insertion(+)
 
 commit ac1155fac104a7152cfb1f7579eeb72633783624
-Merge: 75c0154 bd8933b
+Merge: 75c01548 bd8933b8
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Tue May 10 11:23:16 2011 +0200
 
@@ -12217,7 +15225,7 @@ Date:   Sun May 1 19:53:40 2011 +0200
  21 files changed, 2 insertions(+), 9102 deletions(-)
 
 commit 5347e4ba57784be8d9024aa0337c4041b7c589d1
-Merge: 41c90a4 2165cc9
+Merge: 41c90a4c 2165cc97
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Sun May 1 18:41:24 2011 +0200
 
@@ -12922,7 +15930,7 @@ Date:   Thu Feb 24 17:25:38 2011 +0100
  10 files changed, 430 insertions(+), 20 deletions(-)
 
 commit 2ee1e2d7ec73f8c074124e7d4ba69c13e72fc0a9
-Merge: a432c89 33a1243
+Merge: a432c89e 33a1243c
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Thu Feb 24 14:27:52 2011 +0100
 
@@ -12985,7 +15993,7 @@ Date:   Wed Feb 16 13:31:16 2011 +0100
  3 files changed, 55 insertions(+), 11 deletions(-)
 
 commit 02f318c9ba5070cb033e4c5ed61662943e578515
-Merge: 5cde3bf e4dae97
+Merge: 5cde3bfb e4dae97e
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Wed Feb 16 11:43:46 2011 +0100
 
@@ -13741,7 +16749,7 @@ Date:   Sat Sep 18 09:42:17 2010 +0200
  15 files changed, 3274 insertions(+), 348 deletions(-)
 
 commit 8e6fc58522ecef974258b508fadf7ba3a20a9f72
-Merge: 66cdb7e 7402e4e
+Merge: 66cdb7ec 7402e4e7
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Thu Sep 16 23:03:21 2010 +0200
 
@@ -15902,7 +18910,7 @@ Date:   Fri Jun 18 13:55:21 2010 +0200
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 commit b8259f1a807cb13edbfe5d16ed36158a3658b8cd
-Merge: 6869615 7cf255f
+Merge: 6869615a 7cf255f8
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Fri Jun 18 13:48:03 2010 +0200
 
@@ -16053,7 +19061,7 @@ Date:   Mon Jun 7 11:22:09 2010 +0200
  1 file changed, 6 insertions(+)
 
 commit db50c61277ad813e9c82672173e972274c8cf63b
-Merge: e453046 338f69c
+Merge: e4530461 338f69cd
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Sun Jun 6 09:56:39 2010 +0200
 
@@ -16083,7 +19091,7 @@ Date:   Sun Jun 6 09:45:08 2010 +0200
  2 files changed, 6 insertions(+), 1 deletion(-)
 
 commit e4530461ec51477a05c80434cec378b36c047614
-Merge: dba1999 fc66cc6
+Merge: dba19995 fc66cc69
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Sun Jun 6 09:40:15 2010 +0200
 
@@ -16124,7 +19132,7 @@ Date:   Sun Jun 6 09:08:00 2010 +0200
  6 files changed, 20 insertions(+), 79 deletions(-)
 
 commit dba19995009ac71e7671b422a2feeb7d364dce97
-Merge: f92337d 1c7c172
+Merge: f92337db 1c7c172f
 Author: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
 Date:   Sat Jun 5 15:52:33 2010 +0200
 
@@ -16574,7 +19582,7 @@ Date:   Fri May 21 12:17:03 2010 +0200
  2 files changed, 14 insertions(+), 8 deletions(-)
 
 commit 7c75685d6ad85649b91d358903c3cf8091eaccea
-Merge: 44e36d5 031ac8b
+Merge: 44e36d54 031ac8b8
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Mon May 17 17:51:39 2010 +0200
 
@@ -16606,7 +19614,7 @@ Date:   Mon May 17 14:20:25 2010 +0200
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 commit 77fd2b9461a87b21be5712f7a4726107ddf9f4c4
-Merge: 2f3a1dc af18474
+Merge: 2f3a1dc1 af18474e
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Mon May 17 11:19:41 2010 +0200
 
@@ -16632,7 +19640,7 @@ Date:   Mon May 17 09:19:44 2010 +0200
  5 files changed, 7 insertions(+), 22 deletions(-)
 
 commit 2f3a1dc17ae8581ce6266f2d3743b9218defb325
-Merge: 2f445b8 ee5f6d0
+Merge: 2f445b8d ee5f6d02
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Mon May 17 09:09:29 2010 +0200
 
@@ -16741,7 +19749,7 @@ Date:   Mon May 10 16:47:26 2010 +0200
  1 file changed, 10 insertions(+), 10 deletions(-)
 
 commit 98f1775e1b21c80cf84b451782b6e4e2321686ea
-Merge: be6187a 5764e2c
+Merge: be6187a2 5764e2c6
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Mon May 10 16:23:24 2010 +0200
 
@@ -19551,7 +22559,7 @@ Date:   Sat Oct 24 14:29:10 2009 +0200
  14 files changed, 1132 insertions(+), 250 deletions(-)
 
 commit 504e27f5b84999bfc4f3bb92e6e92a1688b4c1a6
-Merge: 36e3710 7876bc0
+Merge: 36e37104 7876bc05
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Fri Oct 23 11:33:39 2009 +0200
 
@@ -19766,7 +22774,7 @@ Date:   Thu Jul 16 14:43:06 2009 +0200
  4 files changed, 32 insertions(+), 36 deletions(-)
 
 commit 36e37104c318d56670e42e1f578a4d0ff81e357e
-Merge: af1efa9 0717452
+Merge: af1efa92 07174529
 Author: System User <picca at b1181-srv2.diffabs.rcl>
 Date:   Wed Jul 15 18:52:43 2009 +0200
 
@@ -23678,7 +26686,7 @@ Date:   Tue Jun 10 09:43:28 2008 +0200
  1 file changed, 1 deletion(-)
 
 commit 92c8bf89b4020498d845e355964498ca3e797756
-Merge: 6da710f 7b690cb
+Merge: 6da710f4 7b690cbb
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Fri Jun 6 18:20:32 2008 +0200
 
@@ -26273,7 +29281,7 @@ Date:   Fri Sep 14 18:54:38 2007 +0200
  34 files changed, 695 insertions(+), 1872 deletions(-)
 
 commit 583660448352c5f4890c94844b5e6b68954f8583
-Merge: 008cf44 8e803aa
+Merge: 008cf44e 8e803aaf
 Author: Frédéric-Emmanuel PICCA <picca at synchrotron-soleil.fr>
 Date:   Wed Sep 12 10:32:07 2007 +0200
 
@@ -32096,7 +35104,7 @@ Date:   Thu Feb 2 14:30:23 2006 +0100
  1 file changed, 9 insertions(+), 5 deletions(-)
 
 commit a221387369dfe8df34030e213d19708b3a7844c3
-Merge: ef99b4b db5768a
+Merge: ef99b4b0 db5768a4
 Author: picca <picca at grisette.localdomain>
 Date:   Thu Feb 2 11:30:48 2006 +0100
 
diff --git a/Documentation/Makefile.am b/Documentation/Makefile.am
index c009fbe..30200a3 100644
--- a/Documentation/Makefile.am
+++ b/Documentation/Makefile.am
@@ -11,7 +11,7 @@ hkl.html: hkl.org $(srcdir)/hkl-default.el
 	$(LIBTOOL) --mode=execute -dlopen $(AM_LDFLAGS) \
 	$(EMACS) $< --batch -q --load $(srcdir)/hkl-default.el -f org-html-export-to-html --debug-init --kill
 
-EXTRA_DIST=hkl-default.el
+EXTRA_DIST=hkl-default.el css/style.css
 
 CLEANFILES=hkl.html
 
@@ -23,4 +23,9 @@ doc-edit:
 doc-show: hkl.html
 	sensible-browser $(builddir)/hkl.html
 
+doc-publish: hkl.html
+	env GI_TYPELIB_PATH=$(top_builddir)/hkl \
+	$(LIBTOOL) --mode=execute -dlopen $(AM_LDFLAGS) \
+	$(EMACS) $< --batch -q --load $(srcdir)/hkl-default.el -f org-publish-all --debug-init --kill
+
 .PHONY: doc-edit doc-show
diff --git a/Documentation/Makefile.in b/Documentation/Makefile.in
index 5a64d98..c515719 100644
--- a/Documentation/Makefile.in
+++ b/Documentation/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -260,6 +260,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -391,7 +392,7 @@ SUBDIRS = api figures sphinx
 dist_man_MANS = ghkl.1
 AM_LDFLAGS = $(top_builddir)/hkl/libhkl.la
 dist_html_DATA = hkl.html
-EXTRA_DIST = hkl-default.el
+EXTRA_DIST = hkl-default.el css/style.css
 CLEANFILES = hkl.html
 all: all-recursive
 
@@ -792,6 +793,11 @@ doc-edit:
 doc-show: hkl.html
 	sensible-browser $(builddir)/hkl.html
 
+doc-publish: hkl.html
+	env GI_TYPELIB_PATH=$(top_builddir)/hkl \
+	$(LIBTOOL) --mode=execute -dlopen $(AM_LDFLAGS) \
+	$(EMACS) $< --batch -q --load $(srcdir)/hkl-default.el -f org-publish-all --debug-init --kill
+
 .PHONY: doc-edit doc-show
 
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
diff --git a/Documentation/api/Makefile.in b/Documentation/api/Makefile.in
index c840a37..5522c31 100644
--- a/Documentation/api/Makefile.in
+++ b/Documentation/api/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -171,6 +171,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -428,34 +429,34 @@ CLEANFILES = $(SCANOBJ_FILES) $(REPORT_FILES) $(DOC_STAMPS) gtkdoc-check.test
 @GTK_DOC_BUILD_PDF_TRUE at PDF_BUILD_STAMP = pdf-build.stamp
 
 #### setup ####
-GTK_DOC_V_SETUP = $(GTK_DOC_V_SETUP_$(V))
-GTK_DOC_V_SETUP_ = $(GTK_DOC_V_SETUP_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_SETUP = $(GTK_DOC_V_SETUP_ at AM_V@)
+GTK_DOC_V_SETUP_ = $(GTK_DOC_V_SETUP_ at AM_DEFAULT_V@)
 GTK_DOC_V_SETUP_0 = @echo "  DOC   Preparing build";
 
 #### scan ####
-GTK_DOC_V_SCAN = $(GTK_DOC_V_SCAN_$(V))
-GTK_DOC_V_SCAN_ = $(GTK_DOC_V_SCAN_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_SCAN = $(GTK_DOC_V_SCAN_ at AM_V@)
+GTK_DOC_V_SCAN_ = $(GTK_DOC_V_SCAN_ at AM_DEFAULT_V@)
 GTK_DOC_V_SCAN_0 = @echo "  DOC   Scanning header files";
-GTK_DOC_V_INTROSPECT = $(GTK_DOC_V_INTROSPECT_$(V))
-GTK_DOC_V_INTROSPECT_ = $(GTK_DOC_V_INTROSPECT_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_INTROSPECT = $(GTK_DOC_V_INTROSPECT_ at AM_V@)
+GTK_DOC_V_INTROSPECT_ = $(GTK_DOC_V_INTROSPECT_ at AM_DEFAULT_V@)
 GTK_DOC_V_INTROSPECT_0 = @echo "  DOC   Introspecting gobjects";
 
 #### xml ####
-GTK_DOC_V_XML = $(GTK_DOC_V_XML_$(V))
-GTK_DOC_V_XML_ = $(GTK_DOC_V_XML_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_XML = $(GTK_DOC_V_XML_ at AM_V@)
+GTK_DOC_V_XML_ = $(GTK_DOC_V_XML_ at AM_DEFAULT_V@)
 GTK_DOC_V_XML_0 = @echo "  DOC   Building XML";
 
 #### html ####
-GTK_DOC_V_HTML = $(GTK_DOC_V_HTML_$(V))
-GTK_DOC_V_HTML_ = $(GTK_DOC_V_HTML_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_HTML = $(GTK_DOC_V_HTML_ at AM_V@)
+GTK_DOC_V_HTML_ = $(GTK_DOC_V_HTML_ at AM_DEFAULT_V@)
 GTK_DOC_V_HTML_0 = @echo "  DOC   Building HTML";
-GTK_DOC_V_XREF = $(GTK_DOC_V_XREF_$(V))
-GTK_DOC_V_XREF_ = $(GTK_DOC_V_XREF_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_XREF = $(GTK_DOC_V_XREF_ at AM_V@)
+GTK_DOC_V_XREF_ = $(GTK_DOC_V_XREF_ at AM_DEFAULT_V@)
 GTK_DOC_V_XREF_0 = @echo "  DOC   Fixing cross-references";
 
 #### pdf ####
-GTK_DOC_V_PDF = $(GTK_DOC_V_PDF_$(V))
-GTK_DOC_V_PDF_ = $(GTK_DOC_V_PDF_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_PDF = $(GTK_DOC_V_PDF_ at AM_V@)
+GTK_DOC_V_PDF_ = $(GTK_DOC_V_PDF_ at AM_DEFAULT_V@)
 GTK_DOC_V_PDF_0 = @echo "  DOC   Building PDF";
 
 # Files not to distribute
@@ -680,38 +681,38 @@ $(REPORT_FILES): sgml-build.stamp
 
 setup-build.stamp:
 	-$(GTK_DOC_V_SETUP)if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
-	    files=`echo $(SETUP_FILES) $(DOC_MODULE).types`; \
-	    if test "x$$files" != "x" ; then \
-	        for file in $$files ; do \
-	            destdir=`dirname $(abs_builddir)/$$file`; \
-	            test -d "$$destdir" || mkdir -p "$$destdir"; \
-	            test -f $(abs_srcdir)/$$file && \
-	                cp -pf $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
-	        done; \
-	    fi; \
+	  files=`echo $(SETUP_FILES) $(DOC_MODULE).types`; \
+	  if test "x$$files" != "x" ; then \
+	    for file in $$files ; do \
+	      destdir=`dirname $(abs_builddir)/$$file`; \
+	      test -d "$$destdir" || mkdir -p "$$destdir"; \
+	      test -f $(abs_srcdir)/$$file && \
+	        cp -pf $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
+	    done; \
+	  fi; \
 	fi
 	$(AM_V_at)touch setup-build.stamp
 
 scan-build.stamp: setup-build.stamp $(HFILE_GLOB) $(CFILE_GLOB)
 	$(GTK_DOC_V_SCAN)_source_dir='' ; \
 	for i in $(DOC_SOURCE_DIR) ; do \
-	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
+	  _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
 	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES)
 	$(GTK_DOC_V_INTROSPECT)if grep -l '^..*$$' $(DOC_MODULE).types > /dev/null 2>&1 ; then \
-	    scanobj_options=""; \
-	    gtkdoc-scangobj 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
-	    if test "$$?" = "0"; then \
-	        if test "x$(V)" = "x1"; then \
-	            scanobj_options="--verbose"; \
-	        fi; \
+	  scanobj_options=""; \
+	  gtkdoc-scangobj 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
+	  if test "$$?" = "0"; then \
+	    if test "x$(V)" = "x1"; then \
+	      scanobj_options="--verbose"; \
 	    fi; \
-	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
-	    gtkdoc-scangobj $(SCANGOBJ_OPTIONS) $$scanobj_options --module=$(DOC_MODULE); \
+	  fi; \
+	  CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
+	  gtkdoc-scangobj $(SCANGOBJ_OPTIONS) $$scanobj_options --module=$(DOC_MODULE); \
 	else \
-	    for i in $(SCANOBJ_FILES) ; do \
-	        test -f $$i || touch $$i ; \
-	    done \
+	  for i in $(SCANOBJ_FILES) ; do \
+	    test -f $$i || touch $$i ; \
+	  done \
 	fi
 	$(AM_V_at)touch scan-build.stamp
 
@@ -721,7 +722,7 @@ $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)
 sgml-build.stamp: setup-build.stamp $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(HFILE_GLOB) $(CFILE_GLOB) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt $(expand_content_files) xml/gtkdocentities.ent
 	$(GTK_DOC_V_XML)_source_dir='' ; \
 	for i in $(DOC_SOURCE_DIR) ; do \
-	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
+	  _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
 	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)
 	$(AM_V_at)touch sgml-build.stamp
@@ -756,12 +757,9 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files) $(expand_con
 	cd html && gtkdoc-mkhtml $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
 	- at test "x$(HTML_IMAGES)" = "x" || \
 	for file in $(HTML_IMAGES) ; do \
-	  if test -f $(abs_srcdir)/$$file ; then \
-	    cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
-	  fi; \
-	  if test -f $(abs_builddir)/$$file ; then \
-	    cp $(abs_builddir)/$$file $(abs_builddir)/html; \
-	  fi; \
+	  test -f $(abs_srcdir)/$$file && cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
+	  test -f $(abs_builddir)/$$file && cp $(abs_builddir)/$$file $(abs_builddir)/html; \
+	  test -f $$file && cp $$file $(abs_builddir)/html; \
 	done;
 	$(GTK_DOC_V_XREF)gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
 	$(AM_V_at)touch html-build.stamp
diff --git a/Documentation/api/html/annotation-glossary.html b/Documentation/api/html/annotation-glossary.html
index e232550..64955b0 100644
--- a/Documentation/api/html/annotation-glossary.html
+++ b/Documentation/api/html/annotation-glossary.html
@@ -7,7 +7,7 @@
 <link rel="home" href="index.html" title="hkl Reference Manual">
 <link rel="up" href="index.html" title="hkl Reference Manual">
 <link rel="prev" href="deprecated-api-index.html" title="Index of deprecated API">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -41,6 +41,6 @@
 <dd class="glossdef"><p>Don't free data after the code is done.</p></dd>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/api-index-full.html b/Documentation/api/html/api-index-full.html
index c8e2a4f..314ddd5 100644
--- a/Documentation/api/html/api-index-full.html
+++ b/Documentation/api/html/api-index-full.html
@@ -8,7 +8,7 @@
 <link rel="up" href="index.html" title="hkl Reference Manual">
 <link rel="prev" href="object-tree.html" title="Object Hierarchy">
 <link rel="next" href="deprecated-api-index.html" title="Index of deprecated API">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -39,8 +39,6 @@
                      <span class="dim">|</span> 
                   <a class="shortcut" href="#idxN">N</a>
                      <span class="dim">|</span> 
-                  <a class="shortcut" href="#idxO">O</a>
-                     <span class="dim">|</span> 
                   <a class="shortcut" href="#idxP">P</a>
                      <span class="dim">|</span> 
                   <a class="shortcut" href="#idxQ">Q</a>
@@ -55,7 +53,9 @@
                      <span class="dim">|</span> 
                   <a class="shortcut" href="#idxV">V</a>
                      <span class="dim">|</span> 
-                  <a class="shortcut" href="#idxW">W</a></span></td>
+                  <a class="shortcut" href="#idxW">W</a>
+                     <span class="dim">|</span> 
+                  <a class="shortcut" href="#idxZ">Z</a></span></td>
 <td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
 <td><img src="up-insensitive.png" width="16" height="16" border="0"></td>
 <td><a accesskey="p" href="object-tree.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
@@ -66,11 +66,11 @@
 <a name="api-index-full"></a>API Index</h1></div></div></div>
 <a name="idx"></a><a name="idxA"></a><h3 class="title">A</h3>
 <dt>
-a, variable in testLits
+<a class="link" href="hkl-hkl-parameter-private.html#alea" title="alea">alea</a>, variable in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-parameter-private.html#alea" title="alea">alea</a>, variable in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
+ALIGNOF, macro in alignof
 </dt>
 <dd></dd>
 <dt>
@@ -160,6 +160,10 @@ CCAN_COMPILER, macro in ccan_config
 </dt>
 <dd></dd>
 <dt>
+CCAN_OUTPUT_EXE_CFLAG, macro in ccan_config
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-auto-private.html#CHECK-NAN:CAPS" title="CHECK_NAN()">CHECK_NAN</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-auto-private.html" title="hkl-pseudoaxis-auto-private">hkl-pseudoaxis-auto-private</a>
 </dt>
 <dd></dd>
@@ -208,7 +212,179 @@ CCAN_COMPILER, macro in ccan_config
 </dt>
 <dd></dd>
 <dt>
-create_opaque_blob, function in helper
+COROUTINE_AVAILABLE, macro in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_init, macro in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_init_, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+COROUTINE_MIN_STKSZ, macro in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack, struct in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack_alloc, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack_check, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack_from_metadata, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack_init, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+COROUTINE_STACK_MAGIC_ALLOC, macro in coroutine
+</dt>
+<dd></dd>
+<dt>
+COROUTINE_STACK_MAGIC_BUF, macro in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack_release, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_stack_size, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_state, struct in coroutine
+</dt>
+<dd></dd>
+<dt>
+COROUTINE_STK_OVERHEAD, macro in coroutine
+</dt>
+<dd></dd>
+<dt>
+coroutine_switch, function in coroutine
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_1ST, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_2MAP, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_2ND, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_DEFER1, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_DEFER2, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL1, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL1024, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL128, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL16, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL2, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL256, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL32, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL4, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL512, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL64, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_EVAL8, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_GLUE2, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_IFELSE, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_ISEMPTY, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_ISZERO, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_JOIN, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_MAP, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_NONEMPTY, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_NONZERO, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_NOTHING, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+CPPMAGIC_STRINGIFY, macro in cppmagic
+</dt>
+<dd></dd>
+<dt>
+Cubic, macro in hkl2
 </dt>
 <dd></dd>
 <a name="idxD"></a><h3 class="title">D</h3>
@@ -257,6 +433,10 @@ create_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
+darray_double, typedef in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-darray.html#darray-empty" title="darray_empty()">darray_empty</a>, macro in <a class="link" href="hkl-darray.html" title="darray">darray</a>
 </dt>
 <dd></dd>
@@ -297,6 +477,10 @@ create_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
+darray_geometry, typedef in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-darray.html#darray-growalloc" title="darray_growalloc()">darray_growalloc</a>, macro in <a class="link" href="hkl-darray.html" title="darray">darray</a>
 </dt>
 <dd></dd>
@@ -309,6 +493,10 @@ create_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-darray.html#darray-insert" title="darray_insert()">darray_insert</a>, macro in <a class="link" href="hkl-darray.html" title="darray">darray</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-darray.html#darray-int" title="darray_int">darray_int</a>, typedef in <a class="link" href="hkl-darray.html" title="darray">darray</a>
 </dt>
 <dd></dd>
@@ -405,6 +593,10 @@ create_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
+darray_sizet, typedef in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl.html#darray-string" title="darray_string">darray_string</a>, typedef in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
 </dt>
 <dd></dd>
@@ -437,10 +629,6 @@ create_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
-destroy_opaque_blob, function in helper
-</dt>
-<dd></dd>
-<dt>
 <a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector">HklDetector</a>, struct in <a class="link" href="hkl-hkl-detector-private.html" title="hkl-detector-private">hkl-detector-private</a>
 </dt>
 <dd></dd>
@@ -457,15 +645,43 @@ destroy_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-geometry-private.html#detector-holder" title="detector_holder">detector_holder</a>, variable in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-detector-private.html#hkl-detector-new" title="hkl_detector_new ()">hkl_detector_new</a>, function in <a class="link" href="hkl-hkl-detector-private.html" title="hkl-detector-private">hkl-detector-private</a>
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-unit-private.html#HklDLength" title="HklDLength">HklDLength</a>, macro in <a class="link" href="hkl-hkl-unit-private.html" title="hkl-unit-private">hkl-unit-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-unit-private.html#HklDPlaneAngle" title="HklDPlaneAngle">HklDPlaneAngle</a>, macro in <a class="link" href="hkl-hkl-unit-private.html" title="hkl-unit-private">hkl-unit-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-parameter-private.html#dup" title="dup">dup</a>, variable in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
 </dt>
 <dd></dd>
 <a name="idxE"></a><h3 class="title">E</h3>
 <dt>
+E4ch, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+E4cv, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+E6c, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+Engine, struct in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine">HklEngine</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
@@ -486,6 +702,10 @@ destroy_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
+EngineHkl, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#HklEngineHkl" title="struct HklEngineHkl">HklEngineHkl</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">hkl-pseudoaxis-common-hkl-private</a>
 </dt>
 <dd></dd>
@@ -506,15 +726,11 @@ destroy_opaque_blob, function in helper
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#HklEnginePsi" title="struct HklEnginePsi">HklEnginePsi</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html" title="hkl-pseudoaxis-common-psi-private">hkl-pseudoaxis-common-psi-private</a>
-</dt>
-<dd></dd>
-<dt>
 HklEngineTth2, struct in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
-hkl_engine_emergence_new, function in hkl-pseudoaxis-common-readonly-private
+engine_e, enum in hkl2
 </dt>
 <dd></dd>
 <dt>
@@ -526,39 +742,35 @@ hkl_engine_emergence_new, function in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-engine-hkl-new" title="hkl_engine_hkl_new ()">hkl_engine_hkl_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">hkl-pseudoaxis-common-hkl-private</a>
+Engine_fprintf, function in hkl2
 </dt>
 <dd></dd>
 <dt>
-hkl_engine_incidence_new, function in hkl-pseudoaxis-common-readonly-private
+Engine_header, function in hkl2
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-ENGINE-INFO:CAPS" title="HKL_ENGINE_INFO()">HKL_ENGINE_INFO</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
-</dt>
-<dd></dd>
-<dt>
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-ENGINE-LIST-ERROR:CAPS" title="HKL_ENGINE_LIST_ERROR">HKL_ENGINE_LIST_ERROR</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
+<a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-engine-hkl-new" title="hkl_engine_hkl_new ()">hkl_engine_hkl_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">hkl-pseudoaxis-common-hkl-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-ENGINE-OPERATIONS-DEFAULTS:CAPS" title="HKL_ENGINE_OPERATIONS_DEFAULTS">HKL_ENGINE_OPERATIONS_DEFAULTS</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
+<a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-ENGINE-INFO:CAPS" title="HKL_ENGINE_INFO()">HKL_ENGINE_INFO</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#hkl-engine-psi-new" title="hkl_engine_psi_new ()">hkl_engine_psi_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html" title="hkl-pseudoaxis-common-psi-private">hkl-pseudoaxis-common-psi-private</a>
+<a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-ENGINE-LIST-ERROR:CAPS" title="HKL_ENGINE_LIST_ERROR">HKL_ENGINE_LIST_ERROR</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-q2-new" title="hkl_engine_q2_new ()">hkl_engine_q2_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html" title="hkl-pseudoaxis-common-q-private">hkl-pseudoaxis-common-q-private</a>
+<a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-ENGINE-OPERATIONS-DEFAULTS:CAPS" title="HKL_ENGINE_OPERATIONS_DEFAULTS">HKL_ENGINE_OPERATIONS_DEFAULTS</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-qper-qpar-new" title="hkl_engine_qper_qpar_new ()">hkl_engine_qper_qpar_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html" title="hkl-pseudoaxis-common-q-private">hkl-pseudoaxis-common-q-private</a>
+Engine_save_as_dat, function in hkl2
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-q-new" title="hkl_engine_q_new ()">hkl_engine_q_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html" title="hkl-pseudoaxis-common-q-private">hkl-pseudoaxis-common-q-private</a>
+Engine_solve, function in hkl2
 </dt>
 <dd></dd>
 <dt>
@@ -599,6 +811,10 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
+fn, user_function in coroutine
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-parameter-private.html#fprintf" title="fprintf ()">fprintf</a>, function in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
 </dt>
 <dd></dd>
@@ -612,6 +828,98 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 <dd></dd>
 <a name="idxG"></a><h3 class="title">G</h3>
 <dt>
+generator_, struct in generator
+</dt>
+<dd></dd>
+<dt>
+generator_argfield_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_argstruct_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_args_pack_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_args_unpack_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_arg_pack_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_arg_unpack_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_declare, function in hkl2
+</dt>
+<dd></dd>
+<dt>
+generator_def, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_def_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_def_static, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_free, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_free_, function in generator
+</dt>
+<dd></dd>
+<dt>
+generator_next, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_next_val, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_parms_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_parms_inner_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_parms_outer_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_parm_, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_state_, function in generator
+</dt>
+<dd></dd>
+<dt>
+generator_t, macro in generator
+</dt>
+<dd></dd>
+<dt>
+generator_yield, macro in generator
+</dt>
+<dd></dd>
+<dt>
+Geometry, struct in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry">HklGeometry</a>, struct in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
@@ -632,6 +940,10 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-geometry-private.html#HklGeometryOperations" title="struct HklGeometryOperations">HklGeometryOperations</a>, struct in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-add-holder" title="hkl_geometry_add_holder ()">hkl_geometry_add_holder</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
@@ -640,6 +952,10 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-detector-holder-get" title="hkl_geometry_detector_holder_get ()">hkl_geometry_detector_holder_get</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-distance" title="hkl_geometry_distance ()">hkl_geometry_distance</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
@@ -648,6 +964,10 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
+geometry_e, enum in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-geometry-private.html#HKL-GEOMETRY-ERROR:CAPS" title="HKL_GEOMETRY_ERROR">HKL_GEOMETRY_ERROR</a>, macro in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
@@ -672,6 +992,14 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-kf-get" title="hkl_geometry_kf_get ()">hkl_geometry_kf_get</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-ki-get" title="hkl_geometry_ki_get ()">hkl_geometry_ki_get</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-list-add" title="hkl_geometry_list_add ()">hkl_geometry_list_add</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
@@ -728,10 +1056,26 @@ hkl_engine_tth2_new, function in hkl-pseudoaxis-common-tth-private
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-geometry-private.html#HKL-GEOMETRY-OPERATIONS-DEFAULTS:CAPS" title="HKL_GEOMETRY_OPERATIONS_DEFAULTS">HKL_GEOMETRY_OPERATIONS_DEFAULTS</a>, macro in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-operations-defaults" title="hkl_geometry_operations_defaults">hkl_geometry_operations_defaults</a>, variable in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-sample-holder-get" title="hkl_geometry_sample_holder_get ()">hkl_geometry_sample_holder_get</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-update" title="hkl_geometry_update ()">hkl_geometry_update</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
 <dt>
+getModeName, function in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-macros-private.html#G-GNUC-PRINTF:CAPS" title="G_GNUC_PRINTF()">G_GNUC_PRINTF</a>, macro in <a class="link" href="hkl-hkl-macros-private.html" title="hkl-macros-private">hkl-macros-private</a>
 </dt>
 <dd></dd>
@@ -961,6 +1305,10 @@ HAVE_SYS_TERMIOS_H, macro in ccan_config
 </dt>
 <dd></dd>
 <dt>
+HAVE_SYS_UNISTD_H, macro in ccan_config
+</dt>
+<dd></dd>
+<dt>
 HAVE_TYPEOF, macro in ccan_config
 </dt>
 <dd></dd>
@@ -985,6 +1333,10 @@ HAVE_WARN_UNUSED_RESULT, macro in ccan_config
 </dt>
 <dd></dd>
 <dt>
+Hexagonal, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder">HklHolder</a>, struct in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
@@ -993,20 +1345,32 @@ HAVE_WARN_UNUSED_RESULT, macro in ccan_config
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-axis" title="hkl_holder_add_rotation_axis ()">hkl_holder_add_rotation_axis</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation" title="hkl_holder_add_rotation ()">hkl_holder_add_rotation</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-axis-with-punit" title="hkl_holder_add_rotation_axis_with_punit ()">hkl_holder_add_rotation_axis_with_punit</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-with-origin" title="hkl_holder_add_rotation_with_origin ()">hkl_holder_add_rotation_with_origin</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
-<a name="idxI"></a><h3 class="title">I</h3>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#i" title="i">i</a>, variable in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-translation" title="hkl_holder_add_translation ()">hkl_holder_add_translation</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
 </dt>
 <dd></dd>
 <dt>
-if_blobs_know_the_secret, function in helper
+<a class="link" href="hkl-hkl-geometry-private.html#HKL-HOLDER-DETECTOR-IDX:CAPS" title="HKL_HOLDER_DETECTOR_IDX">HKL_HOLDER_DETECTOR_IDX</a>, macro in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-geometry-private.html#HKL-HOLDER-SAMPLE-IDX:CAPS" title="HKL_HOLDER_SAMPLE_IDX">HKL_HOLDER_SAMPLE_IDX</a>, macro in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-transformation-apply" title="hkl_holder_transformation_apply ()">hkl_holder_transformation_apply</a>, function in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
+<a name="idxI"></a><h3 class="title">I</h3>
+<dt>
+<a class="link" href="hkl-hkl-pseudoaxis-private.html#i" title="i">i</a>, variable in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
 <dt>
@@ -1145,21 +1509,49 @@ if_blobs_know_the_secret, function in helper
 <a class="link" href="hkl-compiler.html#IS-COMPILE-CONSTANT:CAPS" title="IS_COMPILE_CONSTANT()">IS_COMPILE_CONSTANT</a>, macro in <a class="link" href="hkl-compiler.html" title="compiler">compiler</a>
 </dt>
 <dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-is-reachable" title="hkl_is_reachable ()">hkl_is_reachable</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">hkl-pseudoaxis-common-hkl-private</a>
+</dt>
+<dd></dd>
 <a name="idxK"></a><h3 class="title">K</h3>
 <dt>
+K4ch, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+K4cv, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+K6c, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-common-eulerians-private.html#kappa-2-kappap" title="kappa_2_kappap ()">kappa_2_kappap</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-eulerians-private.html" title="hkl-pseudoaxis-common-eulerians-private">hkl-pseudoaxis-common-eulerians-private</a>
 </dt>
 <dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-geometry-private.html#kf" title="kf">kf</a>, variable in <a class="link" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">hkl-geometry-private</a>
+</dt>
+<dd></dd>
 <a name="idxL"></a><h3 class="title">L</h3>
 <dt>
 <a class="link" href="hkl-hkl.html#HklLattice" title="HklLattice">HklLattice</a>, struct in <a class="link" href="hkl-hkl-lattice-private.html" title="hkl-lattice-private">hkl-lattice-private</a>
 </dt>
 <dd></dd>
 <dt>
+Lattice, struct in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-lattice-private.html#HklLatticeError" title="enum HklLatticeError">HklLatticeError</a>, enum in <a class="link" href="hkl-hkl-lattice-private.html" title="hkl-lattice-private">hkl-lattice-private</a>
 </dt>
 <dd></dd>
 <dt>
+lattice_e, enum in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-lattice-private.html#HKL-LATTICE-ERROR:CAPS" title="HKL_LATTICE_ERROR">HKL_LATTICE_ERROR</a>, macro in <a class="link" href="hkl-hkl-lattice-private.html" title="hkl-lattice-private">hkl-lattice-private</a>
 </dt>
 <dd></dd>
@@ -1176,10 +1568,6 @@ if_blobs_know_the_secret, function in helper
 </dt>
 <dd></dd>
 <dt>
-len, variable in testLits
-</dt>
-<dd></dd>
-<dt>
 <a class="link" href="hkl-list.html#list-add" title="list_add()">list_add</a>, macro in <a class="link" href="hkl-list.html" title="list">list</a>
 </dt>
 <dd></dd>
@@ -1417,6 +1805,10 @@ len, variable in testLits
 </dt>
 <dd></dd>
 <dt>
+Mode, struct in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-auto-private.html#HklModeAutoInfo" title="struct HklModeAutoInfo">HklModeAutoInfo</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-auto-private.html" title="hkl-pseudoaxis-auto-private">hkl-pseudoaxis-auto-private</a>
 </dt>
 <dd></dd>
@@ -1429,19 +1821,19 @@ len, variable in testLits
 </dt>
 <dd></dd>
 <dt>
-HklModeIncidence, struct in hkl-pseudoaxis-common-readonly-private
+ModeHklBissectorVertical, macro in hkl2
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#HklModeInfo" title="struct HklModeInfo">HklModeInfo</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
+ModeHklE4CHConstantPhi, macro in hkl2
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#HklModeOperations" title="struct HklModeOperations">HklModeOperations</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
+<a class="link" href="hkl-hkl-pseudoaxis-private.html#HklModeInfo" title="struct HklModeInfo">HklModeInfo</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#HklModePsi" title="struct HklModePsi">HklModePsi</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html" title="hkl-pseudoaxis-common-psi-private">hkl-pseudoaxis-common-psi-private</a>
+<a class="link" href="hkl-hkl-pseudoaxis-private.html#HklModeOperations" title="struct HklModeOperations">HklModeOperations</a>, struct in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
 <dt>
@@ -1473,7 +1865,7 @@ HklModeIncidence, struct in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
-hkl_mode_emergence_new, function in hkl-pseudoaxis-common-readonly-private
+mode_e, enum in hkl2
 </dt>
 <dd></dd>
 <dt>
@@ -1481,10 +1873,6 @@ hkl_mode_emergence_new, function in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
-hkl_mode_incidence_new, function in hkl-pseudoaxis-common-readonly-private
-</dt>
-<dd></dd>
-<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-private.html#HKL-MODE-INFO:CAPS" title="HKL_MODE_INFO()">HKL_MODE_INFO</a>, macro in <a class="link" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">hkl-pseudoaxis-private</a>
 </dt>
 <dd></dd>
@@ -1533,10 +1921,6 @@ HKL_MODE_INFO_incidence_DEFAULTS, macro in hkl-pseudoaxis-common-readonly-privat
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#hkl-mode-psi-new" title="hkl_mode_psi_new ()">hkl_mode_psi_new</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html" title="hkl-pseudoaxis-common-psi-private">hkl-pseudoaxis-common-psi-private</a>
-</dt>
-<dd></dd>
-<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-mode-set-hkl-real" title="hkl_mode_set_hkl_real ()">hkl_mode_set_hkl_real</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">hkl-pseudoaxis-common-hkl-private</a>
 </dt>
 <dd></dd>
@@ -1546,16 +1930,23 @@ HKL_MODE_INFO_incidence_DEFAULTS, macro in hkl-pseudoaxis-common-readonly-privat
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-compiler.html#NORETURN:CAPS" title="NORETURN">NORETURN</a>, macro in <a class="link" href="hkl-hkl-macros-private.html" title="hkl-macros-private">hkl-macros-private</a>
+newEngines, function in hkl2
+</dt>
+<dd></dd>
+<dt>
+newGeometry, function in hkl2
 </dt>
 <dd></dd>
-<a name="idxO"></a><h3 class="title">O</h3>
 <dt>
-opaque, struct in helper
+newLattice, function in hkl2
 </dt>
 <dd></dd>
 <dt>
-opaque_t, typedef in helper
+newSample, function in hkl2
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-compiler.html#NORETURN:CAPS" title="NORETURN">NORETURN</a>, macro in <a class="link" href="hkl-hkl-macros-private.html" title="hkl-macros-private">hkl-macros-private</a>
 </dt>
 <dd></dd>
 <a name="idxP"></a><h3 class="title">P</h3>
@@ -1616,7 +2007,15 @@ P99_PROTECT, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-axis" title="hkl_parameter_new_axis ()">hkl_parameter_new_axis</a>, function in <a class="link" href="hkl-hkl-axis-private.html" title="hkl-axis-private">hkl-axis-private</a>
+<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-rotation" title="hkl_parameter_new_rotation ()">hkl_parameter_new_rotation</a>, function in <a class="link" href="hkl-hkl-axis-private.html" title="hkl-axis-private">hkl-axis-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-rotation-with-origin" title="hkl_parameter_new_rotation_with_origin ()">hkl_parameter_new_rotation_with_origin</a>, function in <a class="link" href="hkl-hkl-axis-private.html" title="hkl-axis-private">hkl-axis-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-translation" title="hkl_parameter_new_translation ()">hkl_parameter_new_translation</a>, function in <a class="link" href="hkl-hkl-axis-private.html" title="hkl-axis-private">hkl-axis-private</a>
 </dt>
 <dd></dd>
 <dt>
@@ -1624,6 +2023,14 @@ P99_PROTECT, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-parameter-private.html#hkl-parameter-transformation-apply" title="hkl_parameter_transformation_apply ()">hkl_parameter_transformation_apply</a>, function in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-parameter-private.html#hkl-parameter-transformation-cmp" title="hkl_parameter_transformation_cmp ()">hkl_parameter_transformation_cmp</a>, function in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-parameter-private.html#hkl-parameter-value-get-closest" title="hkl_parameter_value_get_closest ()">hkl_parameter_value_get_closest</a>, function in <a class="link" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">hkl-parameter-private</a>
 </dt>
 <dd></dd>
@@ -1644,6 +2051,10 @@ P99_PROTECT, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
+ptrint_t, typedef in ptrint
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-ptr-valid.html#ptr-valid" title="ptr_valid ()">ptr_valid</a>, function in <a class="link" href="hkl-ptr-valid.html" title="ptr_valid">ptr_valid</a>
 </dt>
 <dd></dd>
@@ -1697,10 +2108,6 @@ P99_PROTECT, macro in hkl-pseudoaxis-common-readonly-private
 <dd></dd>
 <a name="idxQ"></a><h3 class="title">Q</h3>
 <dt>
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#qmax" title="qmax ()">qmax</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html" title="hkl-pseudoaxis-common-q-private">hkl-pseudoaxis-common-q-private</a>
-</dt>
-<dd></dd>
-<dt>
 <a class="link" href="hkl-hkl.html#HklQuaternion" title="struct HklQuaternion">HklQuaternion</a>, struct in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
 </dt>
 <dd></dd>
@@ -1774,6 +2181,10 @@ REGISTER_READONLY_INCIDENCE, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="hkl-hkl-axis-private.html#HklRotationWithOrigin" title="struct HklRotationWithOrigin">HklRotationWithOrigin</a>, struct in <a class="link" href="hkl-hkl-axis-private.html" title="hkl-axis-private">hkl-axis-private</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#RUBh-minus-Q" title="RUBh_minus_Q ()">RUBh_minus_Q</a>, function in <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">hkl-pseudoaxis-common-hkl-private</a>
 </dt>
 <dd></dd>
@@ -1783,6 +2194,10 @@ REGISTER_READONLY_INCIDENCE, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
+Sample, struct in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-sample-private.html#HklSampleError" title="enum HklSampleError">HklSampleError</a>, enum in <a class="link" href="hkl-hkl-sample-private.html" title="hkl-sample-private">hkl-sample-private</a>
 </dt>
 <dd></dd>
@@ -1823,6 +2238,14 @@ REGISTER_READONLY_INCIDENCE, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
+SoleilSiriusKappa, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+SoleilSixsMed2_3, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-source-private.html#HklSource" title="struct HklSource">HklSource</a>, struct in <a class="link" href="hkl-hkl-source-private.html" title="hkl-source-private">hkl-source-private</a>
 </dt>
 <dd></dd>
@@ -1976,7 +2399,7 @@ SURFACE_PARAMETERS, macro in hkl-pseudoaxis-common-readonly-private
 </dt>
 <dd></dd>
 <dt>
-testsPassed, variable in testLits
+Tetragonal, macro in hkl2
 </dt>
 <dd></dd>
 <dt>
@@ -1984,6 +2407,86 @@ testsPassed, variable in testLits
 </dt>
 <dd></dd>
 <dt>
+Trajectory, struct in hkl2
+</dt>
+<dd></dd>
+<dt>
+TrajectoryHklFromTo, macro in hkl2
+</dt>
+<dd></dd>
+<dt>
+HklTrajectoryResult, struct in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+HklTrajectoryStats, struct in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_add_geometry, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+trajectory_e, enum in hkl2
+</dt>
+<dd></dd>
+<dt>
+Trajectory_len, function in hkl2
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_result_free, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_result_new, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+Trajectory_solve, function in hkl2
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_stats_add, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_stats_fprintf, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_stats_free, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+hkl_trajectory_stats_new, function in hkl-trajectory-private
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl-axis-private.html#HklTranslation" title="struct HklTranslation">HklTranslation</a>, struct in <a class="link" href="hkl-hkl-axis-private.html" title="hkl-axis-private">hkl-axis-private</a>
+</dt>
+<dd></dd>
+<dt>
+typesafe_cb, macro in typesafe_cb
+</dt>
+<dd></dd>
+<dt>
+typesafe_cb_cast, macro in typesafe_cb
+</dt>
+<dd></dd>
+<dt>
+typesafe_cb_cast3, macro in typesafe_cb
+</dt>
+<dd></dd>
+<dt>
+typesafe_cb_postargs, macro in typesafe_cb
+</dt>
+<dd></dd>
+<dt>
+typesafe_cb_preargs, macro in typesafe_cb
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="hkl-hkl-type-builtins.html#HKL-TYPE-DETECTOR-TYPE:CAPS" title="HKL_TYPE_DETECTOR_TYPE">HKL_TYPE_DETECTOR_TYPE</a>, macro in <a class="link" href="hkl-hkl-type-builtins.html" title="hkl-type-builtins">hkl-type-builtins</a>
 </dt>
 <dd></dd>
@@ -2060,7 +2563,7 @@ testsPassed, variable in testLits
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-type-builtins.html#HKL-TYPE-UNIT-ENUM:CAPS" title="HKL_TYPE_UNIT_ENUM()">HKL_TYPE_UNIT_ENUM</a>, macro in <a class="link" href="hkl-hkl-type-builtins.html" title="hkl-type-builtins">hkl-type-builtins</a>
+<a class="link" href="hkl-hkl-type-builtins.html#HKL-TYPE-UNIT-ENUM:CAPS" title="HKL_TYPE_UNIT_ENUM">HKL_TYPE_UNIT_ENUM</a>, macro in <a class="link" href="hkl-hkl-type-builtins.html" title="hkl-type-builtins">hkl-type-builtins</a>
 </dt>
 <dd></dd>
 <a name="idxU"></a><h3 class="title">U</h3>
@@ -2069,11 +2572,11 @@ testsPassed, variable in testLits
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl.html#HklUnitEnum" title="enum HklUnitEnum">HklUnitEnum</a>, enum in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
+<a class="link" href="hkl-hkl-unit-private.html#HklUnitDimension" title="struct HklUnitDimension">HklUnitDimension</a>, struct in <a class="link" href="hkl-hkl-unit-private.html" title="hkl-unit-private">hkl-unit-private</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="hkl-hkl-unit-private.html#HklUnitType" title="enum HklUnitType">HklUnitType</a>, enum in <a class="link" href="hkl-hkl-unit-private.html" title="hkl-unit-private">hkl-unit-private</a>
+<a class="link" href="hkl-hkl.html#HklUnitEnum" title="enum HklUnitEnum">HklUnitEnum</a>, enum in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
 </dt>
 <dd></dd>
 <dt>
@@ -2225,6 +2728,18 @@ testsPassed, variable in testLits
 <a class="link" href="hkl-hkl-vector-private.html#hkl-vector-vectorial-product" title="hkl_vector_vectorial_product ()">hkl_vector_vectorial_product</a>, function in <a class="link" href="hkl-hkl-vector-private.html" title="hkl-vector-private">hkl-vector-private</a>
 </dt>
 <dd></dd>
+<dt>
+<a class="link" href="hkl-hkl.html#HKL-VECTOR-X:CAPS" title="HKL_VECTOR_X">HKL_VECTOR_X</a>, macro in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl.html#HKL-VECTOR-Y:CAPS" title="HKL_VECTOR_Y">HKL_VECTOR_Y</a>, macro in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
+</dt>
+<dd></dd>
+<dt>
+<a class="link" href="hkl-hkl.html#HKL-VECTOR-Z:CAPS" title="HKL_VECTOR_Z">HKL_VECTOR_Z</a>, macro in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
+</dt>
+<dd></dd>
 <a name="idxW"></a><h3 class="title">W</h3>
 <dt>
 <a class="link" href="hkl-hkl.html#HKL-WARN-UNUSED-RESULT:CAPS" title="HKL_WARN_UNUSED_RESULT">HKL_WARN_UNUSED_RESULT</a>, macro in <a class="link" href="hkl-hkl.html" title="hkl">hkl</a>
@@ -2234,8 +2749,13 @@ testsPassed, variable in testLits
 <a class="link" href="hkl-compiler.html#WARN-UNUSED-RESULT:CAPS" title="WARN_UNUSED_RESULT">WARN_UNUSED_RESULT</a>, macro in <a class="link" href="hkl-compiler.html" title="compiler">compiler</a>
 </dt>
 <dd></dd>
+<a name="idxZ"></a><h3 class="title">Z</h3>
+<dt>
+Zaxis, macro in hkl2
+</dt>
+<dd></dd>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/ch01.html b/Documentation/api/html/ch01.html
index 588352f..7a5d98f 100644
--- a/Documentation/api/html/ch01.html
+++ b/Documentation/api/html/ch01.html
@@ -8,7 +8,7 @@
 <link rel="up" href="index.html" title="hkl Reference Manual">
 <link rel="prev" href="index.html" title="hkl Reference Manual">
 <link rel="next" href="hkl-array-size.html" title="array_size">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -131,6 +131,6 @@
 </dl></div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/deprecated-api-index.html b/Documentation/api/html/deprecated-api-index.html
index 21a9b0c..5c47aa0 100644
--- a/Documentation/api/html/deprecated-api-index.html
+++ b/Documentation/api/html/deprecated-api-index.html
@@ -8,7 +8,7 @@
 <link rel="up" href="index.html" title="hkl Reference Manual">
 <link rel="prev" href="api-index-full.html" title="API Index">
 <link rel="next" href="annotation-glossary.html" title="Annotation Glossary">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -25,6 +25,6 @@
 <a name="idx"></a>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-array-size.html b/Documentation/api/html/hkl-array-size.html
index 202e59c..8bbf281 100644
--- a/Documentation/api/html/hkl-array-size.html
+++ b/Documentation/api/html/hkl-array-size.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="ch01.html" title="[Insert title here]">
 <link rel="next" href="hkl-autodata.html" title="autodata">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -62,6 +62,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-autodata.html b/Documentation/api/html/hkl-autodata.html
index 2257f76..c43d9ff 100644
--- a/Documentation/api/html/hkl-autodata.html
+++ b/Documentation/api/html/hkl-autodata.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-array-size.html" title="array_size">
 <link rel="next" href="hkl-build-assert.html" title="build_assert">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -173,6 +173,6 @@ autodata_make_table (<em class="parameter"><code>const <span class="type">void</
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-build-assert.html b/Documentation/api/html/hkl-build-assert.html
index e9f991d..1e3a851 100644
--- a/Documentation/api/html/hkl-build-assert.html
+++ b/Documentation/api/html/hkl-build-assert.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-autodata.html" title="autodata">
 <link rel="next" href="hkl-check-type.html" title="check_type">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -74,6 +74,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-check-type.html b/Documentation/api/html/hkl-check-type.html
index 059354a..22cf46f 100644
--- a/Documentation/api/html/hkl-check-type.html
+++ b/Documentation/api/html/hkl-check-type.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-build-assert.html" title="build_assert">
 <link rel="next" href="hkl-compiler.html" title="compiler">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -74,6 +74,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-compiler.html b/Documentation/api/html/hkl-compiler.html
index 2e870b5..6966737 100644
--- a/Documentation/api/html/hkl-compiler.html
+++ b/Documentation/api/html/hkl-compiler.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-check-type.html" title="check_type">
 <link rel="next" href="hkl-container-of.html" title="container_of">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -164,6 +164,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-container-of.html b/Documentation/api/html/hkl-container-of.html
index ca13781..93e440c 100644
--- a/Documentation/api/html/hkl-container-of.html
+++ b/Documentation/api/html/hkl-container-of.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-compiler.html" title="compiler">
 <link rel="next" href="hkl-darray.html" title="darray">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -107,6 +107,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-darray.html b/Documentation/api/html/hkl-darray.html
index d5e77d6..9ff4af6 100644
--- a/Documentation/api/html/hkl-darray.html
+++ b/Documentation/api/html/hkl-darray.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-container-of.html" title="container_of">
 <link rel="next" href="hkl-hkl.html" title="hkl">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -102,6 +102,12 @@
 <tr>
 <td class="define_keyword">#define</td>
 <td class="function_name">
+<a class="link" href="hkl-darray.html#darray-insert" title="darray_insert()">darray_insert</a><span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name">
 <a class="link" href="hkl-darray.html#darray-push" title="darray_push()">darray_push</a><span class="c_punctuation">()</span>
 </td>
 </tr>
@@ -375,6 +381,11 @@ darray_item ();</pre>
 </div>
 <hr>
 <div class="refsect2">
+<a name="darray-insert"></a><h3>darray_insert()</h3>
+<pre class="programlisting">#define             darray_insert(arr, i, ...)</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="darray-push"></a><h3>darray_push()</h3>
 <pre class="programlisting">#define darray_push(arr, ...) darray_append(arr, __VA_ARGS__)
 </pre>
@@ -436,12 +447,12 @@ darray_item ();</pre>
 <hr>
 <div class="refsect2">
 <a name="darray-remove"></a><h3>darray_remove()</h3>
-<pre class="programlisting">#define             darray_remove(arr, index)</pre>
+<pre class="programlisting">#define             darray_remove(arr, i)</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-from-items"></a><h3>darray_from_items()</h3>
-<pre class="programlisting">#define darray_from_items(arr, items, count) do {size_t __count = (count); darray_resize(arr, __count); memcpy((arr).item, items, __count*sizeof(*(arr).item));} while(0)
+<pre class="programlisting">#define darray_from_items(arr, items, count) do {size_t count_ = (count); darray_resize(arr, count_); memcpy((arr).item, items, count_*sizeof(*(arr).item));} while(0)
 </pre>
 </div>
 <hr>
@@ -453,7 +464,7 @@ darray_item ();</pre>
 <hr>
 <div class="refsect2">
 <a name="darray-append-string"></a><h3>darray_append_string()</h3>
-<pre class="programlisting">#define darray_append_string(arr, str) do {const char *__str = (str); darray_append_items(arr, __str, strlen(__str)+1); (arr).size--;} while(0)
+<pre class="programlisting">#define darray_append_string(arr, str) do {const char *str_ = (str); darray_append_items(arr, str_, strlen(str_)+1); (arr).size--;} while(0)
 </pre>
 </div>
 <hr>
@@ -475,7 +486,7 @@ darray_item ();</pre>
 <hr>
 <div class="refsect2">
 <a name="darray-from-string"></a><h3>darray_from_string()</h3>
-<pre class="programlisting">#define darray_from_string(arr, str) do {const char *__str = (str); darray_from_items(arr, __str, strlen(__str)+1); (arr).size--;} while(0)
+<pre class="programlisting">#define darray_from_string(arr, str) do {const char *str_ = (str); darray_from_items(arr, str_, strlen(str_)+1); (arr).size--;} while(0)
 </pre>
 </div>
 <hr>
@@ -526,60 +537,42 @@ darray_item ();</pre>
 <a name="hkl-darray.other_details"></a><h2>Types and Values</h2>
 <div class="refsect2">
 <a name="darray-char"></a><h3>darray_char</h3>
-<pre class="programlisting">typedef darray(char)           darray_char;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-schar"></a><h3>darray_schar</h3>
-<pre class="programlisting">typedef darray(signed char)    darray_schar;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-uchar"></a><h3>darray_uchar</h3>
-<pre class="programlisting">typedef darray(unsigned char)  darray_uchar;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-short"></a><h3>darray_short</h3>
-<pre class="programlisting">typedef darray(short)          darray_short;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-int"></a><h3>darray_int</h3>
-<pre class="programlisting">typedef darray(int)            darray_int;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-long"></a><h3>darray_long</h3>
-<pre class="programlisting">typedef darray(long)           darray_long;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-ushort"></a><h3>darray_ushort</h3>
-<pre class="programlisting">typedef darray(unsigned short) darray_ushort;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-uint"></a><h3>darray_uint</h3>
-<pre class="programlisting">typedef darray(unsigned int)   darray_uint;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="darray-ulong"></a><h3>darray_ulong</h3>
-<pre class="programlisting">typedef darray(unsigned long)  darray_ulong;
-</pre>
 </div>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-axis-private.html b/Documentation/api/html/hkl-hkl-axis-private.html
index 1fef640..aea665b 100644
--- a/Documentation/api/html/hkl-hkl-axis-private.html
+++ b/Documentation/api/html/hkl-hkl-axis-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl.html" title="hkl">
 <link rel="next" href="hkl-hkl-detector-private.html" title="hkl-detector-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -38,14 +38,32 @@
 <col width="150px" class="functions_return">
 <col class="functions_name">
 </colgroup>
-<tbody><tr>
+<tbody>
+<tr>
 <td class="function_type">
 <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
 </td>
 <td class="function_name">
-<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-axis" title="hkl_parameter_new_axis ()">hkl_parameter_new_axis</a> <span class="c_punctuation">()</span>
+<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-rotation" title="hkl_parameter_new_rotation ()">hkl_parameter_new_rotation</a> <span class="c_punctuation">()</span>
 </td>
-</tr></tbody>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-rotation-with-origin" title="hkl_parameter_new_rotation_with_origin ()">hkl_parameter_new_rotation_with_origin</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-axis-private.html#hkl-parameter-new-translation" title="hkl_parameter_new_translation ()">hkl_parameter_new_translation</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+</tbody>
 </table></div>
 </div>
 <div class="refsect1">
@@ -55,10 +73,20 @@
 <col width="150px" class="name">
 <col class="description">
 </colgroup>
-<tbody><tr>
+<tbody>
+<tr>
 <td class="datatype_keyword">struct</td>
 <td class="function_name"><a class="link" href="hkl-hkl-axis-private.html#HklAxis" title="struct HklAxis">HklAxis</a></td>
-</tr></tbody>
+</tr>
+<tr>
+<td class="datatype_keyword">struct</td>
+<td class="function_name"><a class="link" href="hkl-hkl-axis-private.html#HklRotationWithOrigin" title="struct HklRotationWithOrigin">HklRotationWithOrigin</a></td>
+</tr>
+<tr>
+<td class="datatype_keyword">struct</td>
+<td class="function_name"><a class="link" href="hkl-hkl-axis-private.html#HklTranslation" title="struct HklTranslation">HklTranslation</a></td>
+</tr>
+</tbody>
 </table></div>
 </div>
 <div class="refsect1">
@@ -67,11 +95,29 @@
 <div class="refsect1">
 <a name="hkl-hkl-axis-private.functions_details"></a><h2>Functions</h2>
 <div class="refsect2">
-<a name="hkl-parameter-new-axis"></a><h3>hkl_parameter_new_axis ()</h3>
+<a name="hkl-parameter-new-rotation"></a><h3>hkl_parameter_new_rotation ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
+hkl_parameter_new_rotation (<em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
+                            <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> const *axis_v</code></em>,
+                            <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-parameter-new-rotation-with-origin"></a><h3>hkl_parameter_new_rotation_with_origin ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
+hkl_parameter_new_rotation_with_origin
+                               (<em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
+                                <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> *axis_v</code></em>,
+                                <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> *origin</code></em>,
+                                <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-parameter-new-translation"></a><h3>hkl_parameter_new_translation ()</h3>
 <pre class="programlisting"><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
-hkl_parameter_new_axis (<em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
-                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> const *axis_v</code></em>,
-                        <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
+hkl_parameter_new_translation (<em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
+                               <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> *axis_v</code></em>,
+                               <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
 </div>
 </div>
 <div class="refsect1">
@@ -85,9 +131,27 @@ hkl_parameter_new_axis (<em class="parameter"><code>const <span class="type">cha
 };
 </pre>
 </div>
+<hr>
+<div class="refsect2">
+<a name="HklRotationWithOrigin"></a><h3>struct HklRotationWithOrigin</h3>
+<pre class="programlisting">struct HklRotationWithOrigin {
+	HklAxis axis;
+	HklVector origin;
+};
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="HklTranslation"></a><h3>struct HklTranslation</h3>
+<pre class="programlisting">struct HklTranslation {
+	HklParameter parameter;
+	HklVector axis_v;
+};
+</pre>
+</div>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-detector-private.html b/Documentation/api/html/hkl-hkl-detector-private.html
index 3aaffbb..3f37b55 100644
--- a/Documentation/api/html/hkl-hkl-detector-private.html
+++ b/Documentation/api/html/hkl-hkl-detector-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-axis-private.html" title="hkl-axis-private">
 <link rel="next" href="hkl-hkl-factory-private.html" title="hkl-factory-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -118,12 +118,12 @@ hkl_detector_compute_kf (<em class="parameter"><code><a class="link" href="hkl-h
 <tbody>
 <tr>
 <td class="parameter_name"><p>g</p></td>
-<td class="parameter_description"><p> the diffractometer <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> use to compute kf. </p></td>
+<td class="parameter_description"><p>the diffractometer <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> use to compute kf. </p></td>
 <td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input. Default is transfer none."><span class="acronym">in</span></acronym>]</span></td>
 </tr>
 <tr>
 <td class="parameter_name"><p>kf</p></td>
-<td class="parameter_description"><p> the <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> fill with the kf coordinates. </p></td>
+<td class="parameter_description"><p>the <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> fill with the kf coordinates. </p></td>
 <td class="parameter_annotations"><span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span></td>
 </tr>
 </tbody>
@@ -148,6 +148,6 @@ hkl_detector_compute_kf (<em class="parameter"><code><a class="link" href="hkl-h
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-factory-private.html b/Documentation/api/html/hkl-hkl-factory-private.html
index eb134ab..7b3b461 100644
--- a/Documentation/api/html/hkl-hkl-factory-private.html
+++ b/Documentation/api/html/hkl-hkl-factory-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-detector-private.html" title="hkl-detector-private">
 <link rel="next" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -115,6 +115,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-geometry-private.html b/Documentation/api/html/hkl-hkl-geometry-private.html
index 5c05d24..e6a0dd5 100644
--- a/Documentation/api/html/hkl-hkl-geometry-private.html
+++ b/Documentation/api/html/hkl-hkl-geometry-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-factory-private.html" title="hkl-factory-private">
 <link rel="next" href="hkl-hkl-interval-private.html" title="hkl-interval-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -52,6 +52,14 @@
 <span class="returnvalue">return</span>
 </td>
 <td class="function_name">
+<a class="link" href="hkl-darray.html#darray-item" title="darray_item ()">darray_item</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<span class="returnvalue">return</span>
+</td>
+<td class="function_name">
 <a class="link" href="hkl-hkl-geometry-private.html#g-quark-from-static-string" title="g_quark_from_static_string ()">g_quark_from_static_string</a> <span class="c_punctuation">()</span>
 </td>
 </tr>
@@ -60,7 +68,7 @@
 <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
 </td>
 <td class="function_name">
-<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-axis" title="hkl_holder_add_rotation_axis ()">hkl_holder_add_rotation_axis</a> <span class="c_punctuation">()</span>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation" title="hkl_holder_add_rotation ()">hkl_holder_add_rotation</a> <span class="c_punctuation">()</span>
 </td>
 </tr>
 <tr>
@@ -68,7 +76,23 @@
 <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
 </td>
 <td class="function_name">
-<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-axis-with-punit" title="hkl_holder_add_rotation_axis_with_punit ()">hkl_holder_add_rotation_axis_with_punit</a> <span class="c_punctuation">()</span>
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-with-origin" title="hkl_holder_add_rotation_with_origin ()">hkl_holder_add_rotation_with_origin</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-add-translation" title="hkl_holder_add_translation ()">hkl_holder_add_translation</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-holder-transformation-apply" title="hkl_holder_transformation_apply ()">hkl_holder_transformation_apply</a> <span class="c_punctuation">()</span>
 </td>
 </tr>
 <tr>
@@ -161,6 +185,38 @@
 </tr>
 <tr>
 <td class="function_type">
+<a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="returnvalue">HklHolder</span></a> *
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-sample-holder-get" title="hkl_geometry_sample_holder_get ()">hkl_geometry_sample_holder_get</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="returnvalue">HklHolder</span></a> *
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-detector-holder-get" title="hkl_geometry_detector_holder_get ()">hkl_geometry_detector_holder_get</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-ki-get" title="hkl_geometry_ki_get ()">hkl_geometry_ki_get</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-kf-get" title="hkl_geometry_kf_get ()">hkl_geometry_kf_get</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
 <a class="link" href="hkl-hkl.html#HklGeometryList" title="HklGeometryList"><span class="returnvalue">HklGeometryList</span></a> *
 </td>
 <td class="function_name">
@@ -267,6 +323,14 @@
 </colgroup>
 <tbody>
 <tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#HKL-HOLDER-SAMPLE-IDX:CAPS" title="HKL_HOLDER_SAMPLE_IDX">HKL_HOLDER_SAMPLE_IDX</a></td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#HKL-HOLDER-DETECTOR-IDX:CAPS" title="HKL_HOLDER_DETECTOR_IDX">HKL_HOLDER_DETECTOR_IDX</a></td>
+</tr>
+<tr>
 <td class="typedef_keyword">typedef</td>
 <td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#darray-holder" title="darray_holder">darray_holder</a></td>
 </tr>
@@ -279,10 +343,30 @@
 <td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder">HklHolder</a></td>
 </tr>
 <tr>
+<td class="datatype_keyword">struct</td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#HklGeometryOperations" title="struct HklGeometryOperations">HklGeometryOperations</a></td>
+</tr>
+<tr>
 <td class="datatype_keyword"> </td>
 <td class="function_name"><a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry">HklGeometry</a></td>
 </tr>
 <tr>
+<td class="variable_type">HklVector </td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#kf" title="kf">kf</a></td>
+</tr>
+<tr>
+<td class="variable_type">HklHolder *</td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#detector-holder" title="detector_holder">detector_holder</a></td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#HKL-GEOMETRY-OPERATIONS-DEFAULTS:CAPS" title="HKL_GEOMETRY_OPERATIONS_DEFAULTS">HKL_GEOMETRY_OPERATIONS_DEFAULTS</a></td>
+</tr>
+<tr>
+<td class="variable_type">extern const HklGeometryOperations </td>
+<td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#hkl-geometry-operations-defaults" title="hkl_geometry_operations_defaults">hkl_geometry_operations_defaults</a></td>
+</tr>
+<tr>
 <td class="define_keyword">#define</td>
 <td class="function_name"><a class="link" href="hkl-hkl-geometry-private.html#HKL-GEOMETRY-ERROR:CAPS" title="HKL_GEOMETRY_ERROR">HKL_GEOMETRY_ERROR</a></td>
 </tr>
@@ -314,37 +398,65 @@
 </div>
 <hr>
 <div class="refsect2">
+<a name="darray-item"></a><h3>darray_item ()</h3>
+<pre class="programlisting"><span class="returnvalue">return</span>
+darray_item ();</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="g-quark-from-static-string"></a><h3>g_quark_from_static_string ()</h3>
 <pre class="programlisting"><span class="returnvalue">return</span>
 g_quark_from_static_string ();</pre>
 </div>
 <hr>
 <div class="refsect2">
-<a name="hkl-holder-add-rotation-axis"></a><h3>hkl_holder_add_rotation_axis ()</h3>
+<a name="hkl-holder-add-rotation"></a><h3>hkl_holder_add_rotation ()</h3>
 <pre class="programlisting"><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
-hkl_holder_add_rotation_axis (<em class="parameter"><code><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="type">HklHolder</span></a> *self</code></em>,
-                              <em class="parameter"><code><span class="type">char</span> const *name</code></em>,
-                              <em class="parameter"><code><span class="type">double</span> x</code></em>,
-                              <em class="parameter"><code><span class="type">double</span> y</code></em>,
-                              <em class="parameter"><code><span class="type">double</span> z</code></em>);</pre>
+hkl_holder_add_rotation (<em class="parameter"><code><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="type">HklHolder</span></a> *self</code></em>,
+                         <em class="parameter"><code><span class="type">char</span> const *name</code></em>,
+                         <em class="parameter"><code><span class="type">double</span> x</code></em>,
+                         <em class="parameter"><code><span class="type">double</span> y</code></em>,
+                         <em class="parameter"><code><span class="type">double</span> z</code></em>,
+                         <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
 </div>
 <hr>
 <div class="refsect2">
-<a name="hkl-holder-add-rotation-axis-with-punit"></a><h3>hkl_holder_add_rotation_axis_with_punit ()</h3>
+<a name="hkl-holder-add-rotation-with-origin"></a><h3>hkl_holder_add_rotation_with_origin ()</h3>
 <pre class="programlisting"><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
-hkl_holder_add_rotation_axis_with_punit
-                               (<em class="parameter"><code><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="type">HklHolder</span></a> *self</code></em>,
-                                <em class="parameter"><code><span class="type">char</span> const *name</code></em>,
-                                <em class="parameter"><code><span class="type">double</span> x</code></em>,
-                                <em class="parameter"><code><span class="type">double</span> y</code></em>,
-                                <em class="parameter"><code><span class="type">double</span> z</code></em>,
-                                <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
+hkl_holder_add_rotation_with_origin (<em class="parameter"><code><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="type">HklHolder</span></a> *self</code></em>,
+                                     <em class="parameter"><code>const <span class="type">char</span> *name</code></em>,
+                                     <em class="parameter"><code><span class="type">double</span> x</code></em>,
+                                     <em class="parameter"><code><span class="type">double</span> y</code></em>,
+                                     <em class="parameter"><code><span class="type">double</span> z</code></em>,
+                                     <em class="parameter"><code><span class="type">double</span> ox</code></em>,
+                                     <em class="parameter"><code><span class="type">double</span> oy</code></em>,
+                                     <em class="parameter"><code><span class="type">double</span> oz</code></em>,
+                                     <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-holder-add-translation"></a><h3>hkl_holder_add_translation ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="returnvalue">HklParameter</span></a> *
+hkl_holder_add_translation (<em class="parameter"><code><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="type">HklHolder</span></a> *self</code></em>,
+                            <em class="parameter"><code><span class="type">char</span> const *name</code></em>,
+                            <em class="parameter"><code><span class="type">double</span> x</code></em>,
+                            <em class="parameter"><code><span class="type">double</span> y</code></em>,
+                            <em class="parameter"><code><span class="type">double</span> z</code></em>,
+                            <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *punit</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-holder-transformation-apply"></a><h3>hkl_holder_transformation_apply ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+hkl_holder_transformation_apply (<em class="parameter"><code>const <a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="type">HklHolder</span></a> *self</code></em>,
+                                 <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> *v</code></em>);</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="hkl-geometry-new"></a><h3>hkl_geometry_new ()</h3>
 <pre class="programlisting"><a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="returnvalue">HklGeometry</span></a> *
-hkl_geometry_new (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklFactory" title="HklFactory"><span class="type">HklFactory</span></a> *factory</code></em>);</pre>
+hkl_geometry_new (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklFactory" title="HklFactory"><span class="type">HklFactory</span></a> *factory</code></em>,
+                  <em class="parameter"><code>const <a class="link" href="hkl-hkl-geometry-private.html#HklGeometryOperations" title="struct HklGeometryOperations"><span class="type">HklGeometryOperations</span></a> *ops</code></em>);</pre>
 <p>constructor</p>
 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
 </div>
@@ -524,6 +636,33 @@ hkl_geometry_is_valid_range (<em class="parameter"><code>const <a class="link" h
 </div>
 <hr>
 <div class="refsect2">
+<a name="hkl-geometry-sample-holder-get"></a><h3>hkl_geometry_sample_holder_get ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="returnvalue">HklHolder</span></a> *
+hkl_geometry_sample_holder_get (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *self</code></em>,
+                                <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklSample" title="HklSample"><span class="type">HklSample</span></a> *sample</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-geometry-detector-holder-get"></a><h3>hkl_geometry_detector_holder_get ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl-geometry-private.html#HklHolder" title="struct HklHolder"><span class="returnvalue">HklHolder</span></a> *
+hkl_geometry_detector_holder_get (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *self</code></em>,
+                                  <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector"><span class="type">HklDetector</span></a> *detector</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-geometry-ki-get"></a><h3>hkl_geometry_ki_get ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+hkl_geometry_ki_get (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *self</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-geometry-kf-get"></a><h3>hkl_geometry_kf_get ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+hkl_geometry_kf_get (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *self</code></em>,
+                     <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector"><span class="type">HklDetector</span></a> *detector</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="hkl-geometry-list-new"></a><h3>hkl_geometry_list_new ()</h3>
 <pre class="programlisting"><a class="link" href="hkl-hkl.html#HklGeometryList" title="HklGeometryList"><span class="returnvalue">HklGeometryList</span></a> *
 hkl_geometry_list_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
@@ -543,7 +682,7 @@ hkl_geometry_list_new_copy (<em class="parameter"><code>const <a class="link" hr
 <a name="hkl-geometry-list-add"></a><h3>hkl_geometry_list_add ()</h3>
 <pre class="programlisting"><span class="returnvalue">void</span>
 hkl_geometry_list_add (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklGeometryList" title="HklGeometryList"><span class="type">HklGeometryList</span></a> *self</code></em>,
-                       <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *geometry</code></em>);</pre>
+                       <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *geometry</code></em>);</pre>
 <p>this method Add a geometry to the geometries</p>
 <p>This method try to be clever by allocating memory only if the
 current length of the geometries is not large enought. Then it just
@@ -666,12 +805,22 @@ hkl_geometry_list_item_free (<em class="parameter"><code><a class="link" href="h
 <div class="refsect1">
 <a name="hkl-hkl-geometry-private.other_details"></a><h2>Types and Values</h2>
 <div class="refsect2">
-<a name="darray-holder"></a><h3>darray_holder</h3>
-<pre class="programlisting">typedef darray(HklHolder *) darray_holder;
+<a name="HKL-HOLDER-SAMPLE-IDX:CAPS"></a><h3>HKL_HOLDER_SAMPLE_IDX</h3>
+<pre class="programlisting">#define HKL_HOLDER_SAMPLE_IDX 0
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="HKL-HOLDER-DETECTOR-IDX:CAPS"></a><h3>HKL_HOLDER_DETECTOR_IDX</h3>
+<pre class="programlisting">#define HKL_HOLDER_DETECTOR_IDX 1
 </pre>
 </div>
 <hr>
 <div class="refsect2">
+<a name="darray-holder"></a><h3>darray_holder</h3>
+</div>
+<hr>
+<div class="refsect2">
 <a name="HklHolderConfig"></a><h3>struct HklHolderConfig</h3>
 <pre class="programlisting">struct HklHolderConfig {
 	int gc;
@@ -692,17 +841,55 @@ hkl_geometry_list_item_free (<em class="parameter"><code><a class="link" href="h
 </div>
 <hr>
 <div class="refsect2">
+<a name="HklGeometryOperations"></a><h3>struct HklGeometryOperations</h3>
+<pre class="programlisting">struct HklGeometryOperations {
+	HklHolder* (*sample_holder_get) (const HklGeometry *self, const HklSample *sample);
+
+	HklHolder* (*detector_holder_get) (const HklGeometry *self, const HklDetector *detector);
+
+	HklVector (*ki_get) (const HklGeometry *geometry);
+
+	HklVector (*kf_get) (const HklGeometry *self, const HklDetector *detector);
+};
+</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="HklGeometry"></a><h3>HklGeometry</h3>
 <pre class="programlisting">typedef struct {
 	const HklFactory *factory;
 	HklSource source;
 	darray_parameter axes;
 	darray_holder holders;
+	const HklGeometryOperations *ops;
 } HklGeometry;
 </pre>
 </div>
 <hr>
 <div class="refsect2">
+<a name="kf"></a><h3>kf</h3>
+<pre class="programlisting">	HklVector kf = {{HKL_TAU / self->source.wave_length, 0, 0}};
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="detector-holder"></a><h3>detector_holder</h3>
+<pre class="programlisting">	HklHolder *detector_holder = darray_item(self->holders, HKL_HOLDER_DETECTOR_IDX);
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="HKL-GEOMETRY-OPERATIONS-DEFAULTS:CAPS"></a><h3>HKL_GEOMETRY_OPERATIONS_DEFAULTS</h3>
+<pre class="programlisting">#define             HKL_GEOMETRY_OPERATIONS_DEFAULTS</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-geometry-operations-defaults"></a><h3>hkl_geometry_operations_defaults</h3>
+<pre class="programlisting">extern const HklGeometryOperations hkl_geometry_operations_defaults;
+</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="HKL-GEOMETRY-ERROR:CAPS"></a><h3>HKL_GEOMETRY_ERROR</h3>
 <pre class="programlisting">#define HKL_GEOMETRY_ERROR hkl_geometry_error_quark ()
 </pre>
@@ -755,6 +942,6 @@ hkl_geometry_list_item_free (<em class="parameter"><code><a class="link" href="h
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-interval-private.html b/Documentation/api/html/hkl-hkl-interval-private.html
index 290b785..a0b29f9 100644
--- a/Documentation/api/html/hkl-hkl-interval-private.html
+++ b/Documentation/api/html/hkl-hkl-interval-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-geometry-private.html" title="hkl-geometry-private">
 <link rel="next" href="hkl-hkl-lattice-private.html" title="hkl-lattice-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -385,6 +385,6 @@ hkl_interval_angle_restrict_symm (<em class="parameter"><code><a class="link" hr
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-lattice-private.html b/Documentation/api/html/hkl-hkl-lattice-private.html
index 6e3a748..b90a9b6 100644
--- a/Documentation/api/html/hkl-hkl-lattice-private.html
+++ b/Documentation/api/html/hkl-hkl-lattice-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-interval-private.html" title="hkl-interval-private">
 <link rel="next" href="hkl-hkl-macros-private.html" title="hkl-macros-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -198,6 +198,6 @@ hkl_lattice_fprintf (<em class="parameter"><code><span class="type">FILE</span>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-macros-private.html b/Documentation/api/html/hkl-hkl-macros-private.html
index 8cef5cf..a3bbea9 100644
--- a/Documentation/api/html/hkl-hkl-macros-private.html
+++ b/Documentation/api/html/hkl-hkl-macros-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-lattice-private.html" title="hkl-lattice-private">
 <link rel="next" href="hkl-hkl-matrix-private.html" title="hkl-matrix-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -176,6 +176,6 @@ hkl_printbt (<em class="parameter"><code><span class="type">void</span></code></
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-matrix-private.html b/Documentation/api/html/hkl-hkl-matrix-private.html
index e996711..5c6252e 100644
--- a/Documentation/api/html/hkl-hkl-matrix-private.html
+++ b/Documentation/api/html/hkl-hkl-matrix-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-macros-private.html" title="hkl-macros-private">
 <link rel="next" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -496,6 +496,6 @@ Todo: test</p>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-parameter-private.html b/Documentation/api/html/hkl-hkl-parameter-private.html
index c997d86..073077a 100644
--- a/Documentation/api/html/hkl-hkl-parameter-private.html
+++ b/Documentation/api/html/hkl-hkl-parameter-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-matrix-private.html" title="hkl-matrix-private">
 <link rel="next" href="hkl-hkl-pseudoaxis-auto-private.html" title="hkl-pseudoaxis-auto-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -111,6 +111,22 @@
 <a class="link" href="hkl-hkl-parameter-private.html#hkl-parameter-fprintf" title="hkl_parameter_fprintf ()">hkl_parameter_fprintf</a> <span class="c_punctuation">()</span>
 </td>
 </tr>
+<tr>
+<td class="function_type">
+<span class="returnvalue">int</span>
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-parameter-private.html#hkl-parameter-transformation-cmp" title="hkl_parameter_transformation_cmp ()">hkl_parameter_transformation_cmp</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+</td>
+<td class="function_name">
+<a class="link" href="hkl-hkl-parameter-private.html#hkl-parameter-transformation-apply" title="hkl_parameter_transformation_apply ()">hkl_parameter_transformation_apply</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
 </tbody>
 </table></div>
 </div>
@@ -207,7 +223,7 @@ hkl_parameter_new (<em class="parameter"><code>const <span class="type">char</sp
 <pre class="programlisting"><span class="returnvalue">int</span>
 hkl_parameter_init_copy (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *self</code></em>,
                          <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *src</code></em>,
-                         <em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
+                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
 <div class="refsect3">
 <a name="hkl-parameter-init-copy.parameters"></a><h4>Parameters</h4>
@@ -320,10 +336,79 @@ strictly (min < value < max).</p>
 <a name="hkl-parameter-fprintf"></a><h3>hkl_parameter_fprintf ()</h3>
 <pre class="programlisting"><span class="returnvalue">void</span>
 hkl_parameter_fprintf (<em class="parameter"><code><span class="type">FILE</span> *f</code></em>,
-                       <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *self</code></em>);</pre>
+                       <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *self</code></em>);</pre>
 <p>print into the <span class="type">FILE</span> f an <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a></p>
 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
 </div>
+<hr>
+<div class="refsect2">
+<a name="hkl-parameter-transformation-cmp"></a><h3>hkl_parameter_transformation_cmp ()</h3>
+<pre class="programlisting"><span class="returnvalue">int</span>
+hkl_parameter_transformation_cmp (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *self</code></em>,
+                                  <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *p2</code></em>);</pre>
+<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
+<div class="refsect3">
+<a name="hkl-parameter-transformation-cmp.parameters"></a><h4>Parameters</h4>
+<div class="informaltable"><table class="informaltable" width="100%" border="0">
+<colgroup>
+<col width="150px" class="parameters_name">
+<col class="parameters_description">
+<col width="200px" class="parameters_annotations">
+</colgroup>
+<tbody>
+<tr>
+<td class="parameter_name"><p>self</p></td>
+<td class="parameter_description"><p>the this ptr</p></td>
+<td class="parameter_annotations"> </td>
+</tr>
+<tr>
+<td class="parameter_name"><p>p2</p></td>
+<td class="parameter_description"><p>the second parameter to test with</p></td>
+<td class="parameter_annotations"> </td>
+</tr>
+</tbody>
+</table></div>
+</div>
+<div class="refsect3">
+<a name="hkl-parameter-transformation-cmp.returns"></a><h4>Returns</h4>
+<p> if two parameter transformations are compatibles.
+(0) compatible, (!= 0) not-compatible</p>
+</div>
+</div>
+<hr>
+<div class="refsect2">
+<a name="hkl-parameter-transformation-apply"></a><h3>hkl_parameter_transformation_apply ()</h3>
+<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="returnvalue">HklVector</span></a>
+hkl_parameter_transformation_apply (<em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklParameter" title="HklParameter"><span class="type">HklParameter</span></a> *self</code></em>,
+                                    <em class="parameter"><code>const <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> *v</code></em>);</pre>
+<p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
+<div class="refsect3">
+<a name="hkl-parameter-transformation-apply.parameters"></a><h4>Parameters</h4>
+<div class="informaltable"><table class="informaltable" width="100%" border="0">
+<colgroup>
+<col width="150px" class="parameters_name">
+<col class="parameters_description">
+<col width="200px" class="parameters_annotations">
+</colgroup>
+<tbody>
+<tr>
+<td class="parameter_name"><p>self</p></td>
+<td class="parameter_description"><p>the this ptr</p></td>
+<td class="parameter_annotations"> </td>
+</tr>
+<tr>
+<td class="parameter_name"><p>v</p></td>
+<td class="parameter_description"><p>the <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a> to transform</p></td>
+<td class="parameter_annotations"> </td>
+</tr>
+</tbody>
+</table></div>
+</div>
+<div class="refsect3">
+<a name="hkl-parameter-transformation-apply.returns"></a><h4>Returns</h4>
+<p> the transformed <a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector"><span class="type">HklVector</span></a></p>
+</div>
+</div>
 </div>
 <div class="refsect1">
 <a name="hkl-hkl-parameter-private.other_details"></a><h2>Types and Values</h2>
@@ -345,7 +430,7 @@ hkl_parameter_fprintf (<em class="parameter"><code><span class="type">FILE</span
 <hr>
 <div class="refsect2">
 <a name="HKL-PARAMETER-DEFAULTS:CAPS"></a><h3>HKL_PARAMETER_DEFAULTS</h3>
-<pre class="programlisting">#define HKL_PARAMETER_DEFAULTS .name="dummy", .description="no description", .range={.min=0, .max=0}, ._value=0, .unit=NULL, .punit=NULL, .fit=TRUE, .changed=TRUE, .ops = &hkl_parameter_operations_defaults
+<pre class="programlisting">#define HKL_PARAMETER_DEFAULTS .name="dummy", .description="no description", .range={.min=-DBL_MAX, .max=DBL_MAX}, ._value=0, .unit=NULL, .punit=NULL, .fit=TRUE, .changed=TRUE, .ops = &hkl_parameter_operations_defaults
 </pre>
 </div>
 <hr>
@@ -398,6 +483,8 @@ hkl_parameter_fprintf (<em class="parameter"><code><span class="type">FILE</span
 	void                  (*fprintf)(FILE *f, const HklParameter *self);
 	const HklVector *     (*axis_v_get)(const HklParameter *self);
 	const HklQuaternion * (*quaternion_get)(const HklParameter *self);
+	int                   (*transformation_cmp)(const HklParameter *self, const HklParameter *p2);
+	HklVector             (*transformation_apply)(const HklParameter *self, const HklVector *v);
 };
 </pre>
 </div>
@@ -427,12 +514,10 @@ hkl_parameter_fprintf (<em class="parameter"><code><span class="type">FILE</span
 <hr>
 <div class="refsect2">
 <a name="darray-parameter"></a><h3>darray_parameter</h3>
-<pre class="programlisting">typedef darray(HklParameter *) darray_parameter;
-</pre>
 </div>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-pseudoaxis-auto-private.html b/Documentation/api/html/hkl-hkl-pseudoaxis-auto-private.html
index a006b01..db9cfcd 100644
--- a/Documentation/api/html/hkl-hkl-pseudoaxis-auto-private.html
+++ b/Documentation/api/html/hkl-hkl-pseudoaxis-auto-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-parameter-private.html" title="hkl-parameter-private">
 <link rel="next" href="hkl-hkl-pseudoaxis-common-eulerians-private.html" title="hkl-pseudoaxis-common-eulerians-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -141,7 +141,7 @@
 <td class="function_name"><a class="link" href="hkl-hkl-pseudoaxis-auto-private.html#HKL-MODE-OPERATIONS-AUTO-WITH-INIT-DEFAULTS:CAPS" title="HKL_MODE_OPERATIONS_AUTO_WITH_INIT_DEFAULTS">HKL_MODE_OPERATIONS_AUTO_WITH_INIT_DEFAULTS</a></td>
 </tr>
 <tr>
-<td class="variable_type">HklMode *</td>
+<td class="variable_type">HklModeAutoWithInit *</td>
 <td class="function_name"><a class="link" href="hkl-hkl-pseudoaxis-auto-private.html#self" title="self">self</a></td>
 </tr>
 </tbody>
@@ -194,7 +194,7 @@ hkl_mode_auto_set_real (<em class="parameter"><code><a class="link" href="hkl-hk
                         <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *geometry</code></em>,
                         <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector"><span class="type">HklDetector</span></a> *detector</code></em>,
                         <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklSample" title="HklSample"><span class="type">HklSample</span></a> *sample</code></em>,
-                        <em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
+                        <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -224,8 +224,6 @@ hkl_mode_auto_with_init_new (<em class="parameter"><code>const <a class="link" h
 <hr>
 <div class="refsect2">
 <a name="darray-function"></a><h3>darray_function</h3>
-<pre class="programlisting">typedef darray(const HklFunction*) darray_function;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -285,12 +283,12 @@ hkl_mode_auto_with_init_new (<em class="parameter"><code>const <a class="link" h
 <hr>
 <div class="refsect2">
 <a name="self"></a><h3>self</h3>
-<pre class="programlisting">	HklMode *self = NULL;
+<pre class="programlisting">	HklModeAutoWithInit *self = container_of(mode, HklModeAutoWithInit, mode);
 </pre>
 </div>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-pseudoaxis-common-eulerians-private.html b/Documentation/api/html/hkl-hkl-pseudoaxis-common-eulerians-private.html
index 3adf472..f0a4a3e 100644
--- a/Documentation/api/html/hkl-hkl-pseudoaxis-common-eulerians-private.html
+++ b/Documentation/api/html/hkl-hkl-pseudoaxis-common-eulerians-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-pseudoaxis-auto-private.html" title="hkl-pseudoaxis-auto-private">
 <link rel="next" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -86,6 +86,6 @@ kappa_2_kappap (<em class="parameter"><code><span class="type">double</span> kom
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-pseudoaxis-common-hkl-private.html b/Documentation/api/html/hkl-hkl-pseudoaxis-common-hkl-private.html
index c191cab..695a56c 100644
--- a/Documentation/api/html/hkl-hkl-pseudoaxis-common-hkl-private.html
+++ b/Documentation/api/html/hkl-hkl-pseudoaxis-common-hkl-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-pseudoaxis-common-eulerians-private.html" title="hkl-pseudoaxis-common-eulerians-private">
 <link rel="next" href="hkl-hkl-pseudoaxis-common-psi-private.html" title="hkl-pseudoaxis-common-psi-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -52,6 +52,14 @@
 <span class="returnvalue">int</span>
 </td>
 <td class="function_name">
+<a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-is-reachable" title="hkl_is_reachable ()">hkl_is_reachable</a> <span class="c_punctuation">()</span>
+</td>
+</tr>
+<tr>
+<td class="function_type">
+<span class="returnvalue">int</span>
+</td>
+<td class="function_name">
 <a class="link" href="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-mode-get-hkl-real" title="hkl_mode_get_hkl_real ()">hkl_mode_get_hkl_real</a> <span class="c_punctuation">()</span>
 </td>
 </tr>
@@ -140,6 +148,14 @@ RUBh_minus_Q (<em class="parameter"><code><span class="type">double</span> const
 </div>
 <hr>
 <div class="refsect2">
+<a name="hkl-is-reachable"></a><h3>hkl_is_reachable ()</h3>
+<pre class="programlisting"><span class="returnvalue">int</span>
+hkl_is_reachable (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="type">HklEngine</span></a> *engine</code></em>,
+                  <em class="parameter"><code><span class="type">double</span> wavelength</code></em>,
+                  <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="hkl-mode-get-hkl-real"></a><h3>hkl_mode_get_hkl_real ()</h3>
 <pre class="programlisting"><span class="returnvalue">int</span>
 hkl_mode_get_hkl_real (<em class="parameter"><code><a class="link" href="hkl-hkl-pseudoaxis-private.html#HklMode" title="struct HklMode"><span class="type">HklMode</span></a> *self</code></em>,
@@ -147,7 +163,7 @@ hkl_mode_get_hkl_real (<em class="parameter"><code><a class="link" href="hkl-hkl
                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *geometry</code></em>,
                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector"><span class="type">HklDetector</span></a> *detector</code></em>,
                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklSample" title="HklSample"><span class="type">HklSample</span></a> *sample</code></em>,
-                       <em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
+                       <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -158,7 +174,7 @@ hkl_mode_set_hkl_real (<em class="parameter"><code><a class="link" href="hkl-hkl
                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklGeometry" title="HklGeometry"><span class="type">HklGeometry</span></a> *geometry</code></em>,
                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector"><span class="type">HklDetector</span></a> *detector</code></em>,
                        <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklSample" title="HklSample"><span class="type">HklSample</span></a> *sample</code></em>,
-                       <em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
+                       <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -171,7 +187,7 @@ hkl_mode_initialized_set_psi_constant_vertical_real
                                 <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklDetector" title="HklDetector"><span class="type">HklDetector</span></a> *detector</code></em>,
                                 <em class="parameter"><code><a class="link" href="hkl-hkl.html#HklSample" title="HklSample"><span class="type">HklSample</span></a> *sample</code></em>,
                                 <em class="parameter"><code><span class="type">int</span> initialized</code></em>,
-                                <em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
+                                <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -225,6 +241,6 @@ hkl_engine_hkl_new (<em class="parameter"><code><a class="link" href="hkl-hkl.ht
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-pseudoaxis-common-psi-private.html b/Documentation/api/html/hkl-hkl-pseudoaxis-common-psi-private.html
index 84fbd7b..16519b1 100644
--- a/Documentation/api/html/hkl-hkl-pseudoaxis-common-psi-private.html
+++ b/Documentation/api/html/hkl-hkl-pseudoaxis-common-psi-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-pseudoaxis-common-hkl-private.html" title="hkl-pseudoaxis-common-hkl-private">
 <link rel="next" href="hkl-hkl-pseudoaxis-common-q-private.html" title="hkl-pseudoaxis-common-q-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -32,91 +32,17 @@
 <td class="gallery_image" valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="hkl-hkl-pseudoaxis-common-psi-private.functions"></a><h2>Functions</h2>
-<div class="informaltable"><table class="informaltable" width="100%" border="0">
-<colgroup>
-<col width="150px" class="functions_return">
-<col class="functions_name">
-</colgroup>
-<tbody>
-<tr>
-<td class="function_type">
-<a class="link" href="hkl-hkl-pseudoaxis-private.html#HklMode" title="struct HklMode"><span class="returnvalue">HklMode</span></a> *
-</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#hkl-mode-psi-new" title="hkl_mode_psi_new ()">hkl_mode_psi_new</a> <span class="c_punctuation">()</span>
-</td>
-</tr>
-<tr>
-<td class="function_type">
-<a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#hkl-engine-psi-new" title="hkl_engine_psi_new ()">hkl_engine_psi_new</a> <span class="c_punctuation">()</span>
-</td>
-</tr>
-</tbody>
-</table></div>
-</div>
-<div class="refsect1">
-<a name="hkl-hkl-pseudoaxis-common-psi-private.other"></a><h2>Types and Values</h2>
-<div class="informaltable"><table class="informaltable" width="100%" border="0">
-<colgroup>
-<col width="150px" class="name">
-<col class="description">
-</colgroup>
-<tbody>
-<tr>
-<td class="datatype_keyword">struct</td>
-<td class="function_name"><a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#HklModePsi" title="struct HklModePsi">HklModePsi</a></td>
-</tr>
-<tr>
-<td class="datatype_keyword">struct</td>
-<td class="function_name"><a class="link" href="hkl-hkl-pseudoaxis-common-psi-private.html#HklEnginePsi" title="struct HklEnginePsi">HklEnginePsi</a></td>
-</tr>
-</tbody>
-</table></div>
-</div>
-<div class="refsect1">
 <a name="hkl-hkl-pseudoaxis-common-psi-private.description"></a><h2>Description</h2>
 </div>
 <div class="refsect1">
 <a name="hkl-hkl-pseudoaxis-common-psi-private.functions_details"></a><h2>Functions</h2>
-<div class="refsect2">
-<a name="hkl-mode-psi-new"></a><h3>hkl_mode_psi_new ()</h3>
-<pre class="programlisting"><a class="link" href="hkl-hkl-pseudoaxis-private.html#HklMode" title="struct HklMode"><span class="returnvalue">HklMode</span></a> *
-hkl_mode_psi_new (<em class="parameter"><code>const <a class="link" href="hkl-hkl-pseudoaxis-auto-private.html#HklModeAutoInfo" title="struct HklModeAutoInfo"><span class="type">HklModeAutoInfo</span></a> *info</code></em>);</pre>
-</div>
-<hr>
-<div class="refsect2">
-<a name="hkl-engine-psi-new"></a><h3>hkl_engine_psi_new ()</h3>
-<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-hkl_engine_psi_new (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklEngineList" title="HklEngineList"><span class="type">HklEngineList</span></a> *engines</code></em>);</pre>
-</div>
+<p></p>
 </div>
 <div class="refsect1">
 <a name="hkl-hkl-pseudoaxis-common-psi-private.other_details"></a><h2>Types and Values</h2>
-<div class="refsect2">
-<a name="HklModePsi"></a><h3>struct HklModePsi</h3>
-<pre class="programlisting">struct HklModePsi {
-	HklMode parent;
-	HklVector Q0;
-	HklVector hkl0;
-};
-</pre>
-</div>
-<hr>
-<div class="refsect2">
-<a name="HklEnginePsi"></a><h3>struct HklEnginePsi</h3>
-<pre class="programlisting">struct HklEnginePsi {
-	HklEngine engine;
-	HklParameter *psi;
-};
-</pre>
-</div>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-pseudoaxis-common-q-private.html b/Documentation/api/html/hkl-hkl-pseudoaxis-common-q-private.html
index 5441c48..b6a717b 100644
--- a/Documentation/api/html/hkl-hkl-pseudoaxis-common-q-private.html
+++ b/Documentation/api/html/hkl-hkl-pseudoaxis-common-q-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-pseudoaxis-common-psi-private.html" title="hkl-pseudoaxis-common-psi-private">
 <link rel="next" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -32,82 +32,17 @@
 <td class="gallery_image" valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="hkl-hkl-pseudoaxis-common-q-private.functions"></a><h2>Functions</h2>
-<div class="informaltable"><table class="informaltable" width="100%" border="0">
-<colgroup>
-<col width="150px" class="functions_return">
-<col class="functions_name">
-</colgroup>
-<tbody>
-<tr>
-<td class="function_type">
-<span class="returnvalue">double</span>
-</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#qmax" title="qmax ()">qmax</a> <span class="c_punctuation">()</span>
-</td>
-</tr>
-<tr>
-<td class="function_type">
-<a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-q-new" title="hkl_engine_q_new ()">hkl_engine_q_new</a> <span class="c_punctuation">()</span>
-</td>
-</tr>
-<tr>
-<td class="function_type">
-<a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-q2-new" title="hkl_engine_q2_new ()">hkl_engine_q2_new</a> <span class="c_punctuation">()</span>
-</td>
-</tr>
-<tr>
-<td class="function_type">
-<a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-qper-qpar-new" title="hkl_engine_qper_qpar_new ()">hkl_engine_qper_qpar_new</a> <span class="c_punctuation">()</span>
-</td>
-</tr>
-</tbody>
-</table></div>
-</div>
-<div class="refsect1">
 <a name="hkl-hkl-pseudoaxis-common-q-private.description"></a><h2>Description</h2>
 </div>
 <div class="refsect1">
 <a name="hkl-hkl-pseudoaxis-common-q-private.functions_details"></a><h2>Functions</h2>
-<div class="refsect2">
-<a name="qmax"></a><h3>qmax ()</h3>
-<pre class="programlisting"><span class="returnvalue">double</span>
-qmax (<em class="parameter"><code><span class="type">double</span> wavelength</code></em>);</pre>
-</div>
-<hr>
-<div class="refsect2">
-<a name="hkl-engine-q-new"></a><h3>hkl_engine_q_new ()</h3>
-<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-hkl_engine_q_new (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklEngineList" title="HklEngineList"><span class="type">HklEngineList</span></a> *engines</code></em>);</pre>
-</div>
-<hr>
-<div class="refsect2">
-<a name="hkl-engine-q2-new"></a><h3>hkl_engine_q2_new ()</h3>
-<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-hkl_engine_q2_new (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklEngineList" title="HklEngineList"><span class="type">HklEngineList</span></a> *engines</code></em>);</pre>
-</div>
-<hr>
-<div class="refsect2">
-<a name="hkl-engine-qper-qpar-new"></a><h3>hkl_engine_qper_qpar_new ()</h3>
-<pre class="programlisting"><a class="link" href="hkl-hkl.html#HklEngine" title="HklEngine"><span class="returnvalue">HklEngine</span></a> *
-hkl_engine_qper_qpar_new (<em class="parameter"><code><a class="link" href="hkl-hkl.html#HklEngineList" title="HklEngineList"><span class="type">HklEngineList</span></a> *engines</code></em>);</pre>
-</div>
+<p></p>
 </div>
 <div class="refsect1">
 <a name="hkl-hkl-pseudoaxis-common-q-private.other_details"></a><h2>Types and Values</h2>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-pseudoaxis-private.html b/Documentation/api/html/hkl-hkl-pseudoaxis-private.html
index 904d860..8f1aa4c 100644
--- a/Documentation/api/html/hkl-hkl-pseudoaxis-private.html
+++ b/Documentation/api/html/hkl-hkl-pseudoaxis-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-pseudoaxis-common-q-private.html" title="hkl-pseudoaxis-common-q-private">
 <link rel="next" href="hkl-hkl-quaternion-private.html" title="hkl-quaternion-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -117,7 +117,7 @@
 <td class="function_name"><a class="link" href="hkl-hkl-pseudoaxis-private.html#HklMode" title="struct HklMode">HklMode</a></td>
 </tr>
 <tr>
-<td class="variable_type">HklMode *</td>
+<td class="variable_type">HklModeAutoWithInit *</td>
 <td class="function_name"><a class="link" href="hkl-hkl-pseudoaxis-auto-private.html#self" title="self">self</a></td>
 </tr>
 <tr>
@@ -216,8 +216,6 @@ darray_item ();</pre>
 <a name="hkl-hkl-pseudoaxis-private.other_details"></a><h2>Types and Values</h2>
 <div class="refsect2">
 <a name="darray-mode"></a><h3>darray_mode</h3>
-<pre class="programlisting">typedef darray(HklMode *) darray_mode;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -280,7 +278,7 @@ darray_item ();</pre>
 <hr>
 <div class="refsect2">
 <a name="self"></a><h3>self</h3>
-<pre class="programlisting">	HklMode *self = NULL;
+<pre class="programlisting">	HklModeAutoWithInit *self = container_of(mode, HklModeAutoWithInit, mode);
 </pre>
 </div>
 <hr>
@@ -453,6 +451,6 @@ darray_item ();</pre>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-quaternion-private.html b/Documentation/api/html/hkl-hkl-quaternion-private.html
index fca1d3c..11a6e3a 100644
--- a/Documentation/api/html/hkl-hkl-quaternion-private.html
+++ b/Documentation/api/html/hkl-hkl-quaternion-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-pseudoaxis-private.html" title="hkl-pseudoaxis-private">
 <link rel="next" href="hkl-hkl-sample-private.html" title="hkl-sample-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -340,7 +340,7 @@ hkl_quaternion_cmp (<em class="parameter"><code>const <a class="link" href="hkl-
 </div>
 <div class="refsect3">
 <a name="hkl-quaternion-cmp.returns"></a><h4>Returns</h4>
-<p> <span class="type">TRUE</span> if both are equal, <span class="type">FALSE</span> otherwise.</p>
+<p> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><span class="type">TRUE</span></a> if both are equal, <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#FALSE:CAPS"><span class="type">FALSE</span></a> otherwise.</p>
 </div>
 </div>
 <hr>
@@ -487,7 +487,7 @@ Todo: optimize</p>
 </tr>
 <tr>
 <td class="parameter_name"><p>m</p></td>
-<td class="parameter_description"><p> the <a class="link" href="hkl-hkl.html#HklMatrix" title="HklMatrix"><span class="type">HklMatrix</span></a> return. </p></td>
+<td class="parameter_description"><p>the <a class="link" href="hkl-hkl.html#HklMatrix" title="HklMatrix"><span class="type">HklMatrix</span></a> return. </p></td>
 <td class="parameter_annotations"><span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span></td>
 </tr>
 </tbody>
@@ -537,6 +537,6 @@ if q is the (1, 0, 0, 0) quaternion return the (0,0,0) axe and a 0 angle</p>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-sample-private.html b/Documentation/api/html/hkl-hkl-sample-private.html
index 6964531..2a2fe2d 100644
--- a/Documentation/api/html/hkl-hkl-sample-private.html
+++ b/Documentation/api/html/hkl-hkl-sample-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-quaternion-private.html" title="hkl-quaternion-private">
 <link rel="next" href="hkl-hkl-source-private.html" title="hkl-source-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -200,6 +200,7 @@ hkl_sample_reflection_free (<em class="parameter"><code><a class="link" href="hk
 <pre class="programlisting">typedef struct {
 	HklGeometry *geometry;
 	HklDetector *detector;
+	HklSample *sample;
 	HklVector hkl;
 	HklVector _hkl;
 	int flag;
@@ -235,6 +236,6 @@ hkl_sample_reflection_free (<em class="parameter"><code><a class="link" href="hk
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-source-private.html b/Documentation/api/html/hkl-hkl-source-private.html
index b6960b1..92bfc67 100644
--- a/Documentation/api/html/hkl-hkl-source-private.html
+++ b/Documentation/api/html/hkl-hkl-source-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-sample-private.html" title="hkl-sample-private">
 <link rel="next" href="hkl-hkl-type-builtins.html" title="hkl-type-builtins">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -315,6 +315,6 @@ hkl_source_fprintf (<em class="parameter"><code><span class="type">FILE</span> *
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-type-builtins.html b/Documentation/api/html/hkl-hkl-type-builtins.html
index 3affad5..f6f00a1 100644
--- a/Documentation/api/html/hkl-hkl-type-builtins.html
+++ b/Documentation/api/html/hkl-hkl-type-builtins.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-source-private.html" title="hkl-source-private">
 <link rel="next" href="hkl-hkl-types.html" title="hkl-types">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -41,9 +41,7 @@
 <tbody>
 <tr>
 <td class="define_keyword">#define</td>
-<td class="function_name">
-<a class="link" href="hkl-hkl-type-builtins.html#HKL-TYPE-UNIT-ENUM:CAPS" title="HKL_TYPE_UNIT_ENUM()">HKL_TYPE_UNIT_ENUM</a><span class="c_punctuation">()</span>
-</td>
+<td class="function_name"><a class="link" href="hkl-hkl-type-builtins.html#HKL-TYPE-UNIT-ENUM:CAPS" title="HKL_TYPE_UNIT_ENUM">HKL_TYPE_UNIT_ENUM</a></td>
 </tr>
 <tr>
 <td class="define_keyword">#define</td>
@@ -74,8 +72,9 @@
 <div class="refsect1">
 <a name="hkl-hkl-type-builtins.other_details"></a><h2>Types and Values</h2>
 <div class="refsect2">
-<a name="HKL-TYPE-UNIT-ENUM:CAPS"></a><h3>HKL_TYPE_UNIT_ENUM()</h3>
-<pre class="programlisting">#define             HKL_TYPE_UNIT_ENUM(_x, _y, _z, _emergence)</pre>
+<a name="HKL-TYPE-UNIT-ENUM:CAPS"></a><h3>HKL_TYPE_UNIT_ENUM</h3>
+<pre class="programlisting">#define HKL_TYPE_UNIT_ENUM (hkl_unit_enum_get_type ())
+</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -104,6 +103,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-types.html b/Documentation/api/html/hkl-hkl-types.html
index 3967247..340bf5b 100644
--- a/Documentation/api/html/hkl-hkl-types.html
+++ b/Documentation/api/html/hkl-hkl-types.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-type-builtins.html" title="hkl-type-builtins">
 <link rel="next" href="hkl-hkl-unit-private.html" title="hkl-unit-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -203,6 +203,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-unit-private.html b/Documentation/api/html/hkl-hkl-unit-private.html
index dc85850..759d0bf 100644
--- a/Documentation/api/html/hkl-hkl-unit-private.html
+++ b/Documentation/api/html/hkl-hkl-unit-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-types.html" title="hkl-types">
 <link rel="next" href="hkl-hkl-vector-private.html" title="hkl-vector-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -83,8 +83,16 @@
 </colgroup>
 <tbody>
 <tr>
-<td class="datatype_keyword">enum</td>
-<td class="function_name"><a class="link" href="hkl-hkl-unit-private.html#HklUnitType" title="enum HklUnitType">HklUnitType</a></td>
+<td class="datatype_keyword">struct</td>
+<td class="function_name"><a class="link" href="hkl-hkl-unit-private.html#HklUnitDimension" title="struct HklUnitDimension">HklUnitDimension</a></td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl-unit-private.html#HklDPlaneAngle" title="HklDPlaneAngle">HklDPlaneAngle</a></td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl-unit-private.html#HklDLength" title="HklDLength">HklDLength</a></td>
 </tr>
 <tr>
 <td class="datatype_keyword">struct</td>
@@ -122,8 +130,8 @@ hkl_unit_free (<em class="parameter"><code><a class="link" href="hkl-hkl-unit-pr
 <div class="refsect2">
 <a name="hkl-unit-compatible"></a><h3>hkl_unit_compatible ()</h3>
 <pre class="programlisting"><span class="returnvalue">int</span>
-hkl_unit_compatible (<em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *self</code></em>,
-                     <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *unit</code></em>);</pre>
+hkl_unit_compatible (<em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *unit1</code></em>,
+                     <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *unit2</code></em>);</pre>
 <p>check if two units are compatible.</p>
 <p><span class="annotation">[<acronym title="Exposed in C code, not necessarily available in other languages."><span class="acronym">skip</span></acronym>]</span></p>
 <div class="refsect3">
@@ -159,8 +167,8 @@ to check</p></td>
 <div class="refsect2">
 <a name="hkl-unit-factor"></a><h3>hkl_unit_factor ()</h3>
 <pre class="programlisting"><span class="returnvalue">double</span>
-hkl_unit_factor (<em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *self</code></em>,
-                 <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *unit</code></em>);</pre>
+hkl_unit_factor (<em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *from</code></em>,
+                 <em class="parameter"><code>const <a class="link" href="hkl-hkl-unit-private.html#HklUnit" title="struct HklUnit"><span class="type">HklUnit</span></a> *to</code></em>);</pre>
 <p>compute the factor to convert from one <em class="parameter"><code>Hklunit</code></em>
  to another one.
 <em class="parameter"><code>self</code></em>
@@ -175,45 +183,36 @@ hkl_unit_factor (<em class="parameter"><code>const <a class="link" href="hkl-hkl
 <div class="refsect1">
 <a name="hkl-hkl-unit-private.other_details"></a><h2>Types and Values</h2>
 <div class="refsect2">
-<a name="HklUnitType"></a><h3>enum HklUnitType</h3>
-<div class="refsect3">
-<a name="HklUnitType.members"></a><h4>Members</h4>
-<div class="informaltable"><table class="informaltable" width="100%" border="0">
-<colgroup>
-<col width="300px" class="enum_members_name">
-<col class="enum_members_description">
-<col width="200px" class="enum_members_annotations">
-</colgroup>
-<tbody>
-<tr>
-<td class="enum_member_name"><p><a name="HKL-UNIT-ANGLE-DEG:CAPS"></a>HKL_UNIT_ANGLE_DEG</p></td>
-<td> </td>
-<td> </td>
-</tr>
-<tr>
-<td class="enum_member_name"><p><a name="HKL-UNIT-ANGLE-RAD:CAPS"></a>HKL_UNIT_ANGLE_RAD</p></td>
-<td> </td>
-<td> </td>
-</tr>
-<tr>
-<td class="enum_member_name"><p><a name="HKL-UNIT-LENGTH-NM:CAPS"></a>HKL_UNIT_LENGTH_NM</p></td>
-<td> </td>
-<td> </td>
-</tr>
-<tr>
-<td class="enum_member_name"><p><a name="HKL-UNIT-ANGLE-MRAD:CAPS"></a>HKL_UNIT_ANGLE_MRAD</p></td>
-<td> </td>
-<td> </td>
-</tr>
-</tbody>
-</table></div>
+<a name="HklUnitDimension"></a><h3>struct HklUnitDimension</h3>
+<pre class="programlisting">struct HklUnitDimension {
+	int l; /* Length */
+	int m; /* Mass */
+	int t; /* Time */
+	int i; /* Electric current */
+	int th; /* Thermodynamic temperature */
+	int n; /* Amount of substance */
+	int j; /* Luminous intensity */
+};
+</pre>
 </div>
+<hr>
+<div class="refsect2">
+<a name="HklDPlaneAngle"></a><h3>HklDPlaneAngle</h3>
+<pre class="programlisting">#define HklDPlaneAngle {0, 0, 0, 0, 0, 0, 0}
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="HklDLength"></a><h3>HklDLength</h3>
+<pre class="programlisting">#define HklDLength {1, 0, 0, 0, 0, 0, 0}
+</pre>
 </div>
 <hr>
 <div class="refsect2">
 <a name="HklUnit"></a><h3>struct HklUnit</h3>
 <pre class="programlisting">struct HklUnit {
-	HklUnitType type;
+	HklUnitDimension dimension;
+	double factor;
 	char const *name;
 	char const *repr;
 };
@@ -222,6 +221,6 @@ hkl_unit_factor (<em class="parameter"><code>const <a class="link" href="hkl-hkl
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl-vector-private.html b/Documentation/api/html/hkl-hkl-vector-private.html
index ee2b94f..c2d32ba 100644
--- a/Documentation/api/html/hkl-hkl-vector-private.html
+++ b/Documentation/api/html/hkl-hkl-vector-private.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-unit-private.html" title="hkl-unit-private">
 <link rel="next" href="hkl-list.html" title="list">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -1202,6 +1202,6 @@ hkl_vector_project_on_plan_with_point (<em class="parameter"><code><a class="lin
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-hkl.html b/Documentation/api/html/hkl-hkl.html
index 5316576..f5a6cbf 100644
--- a/Documentation/api/html/hkl-hkl.html
+++ b/Documentation/api/html/hkl-hkl.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-darray.html" title="darray">
 <link rel="next" href="hkl-hkl-axis-private.html" title="hkl-axis-private">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -111,6 +111,18 @@
 <td class="function_name"><a class="link" href="hkl-hkl.html#HklVector" title="struct HklVector">HklVector</a></td>
 </tr>
 <tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl.html#HKL-VECTOR-X:CAPS" title="HKL_VECTOR_X">HKL_VECTOR_X</a></td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl.html#HKL-VECTOR-Y:CAPS" title="HKL_VECTOR_Y">HKL_VECTOR_Y</a></td>
+</tr>
+<tr>
+<td class="define_keyword">#define</td>
+<td class="function_name"><a class="link" href="hkl-hkl.html#HKL-VECTOR-Z:CAPS" title="HKL_VECTOR_Z">HKL_VECTOR_Z</a></td>
+</tr>
+<tr>
 <td class="datatype_keyword">struct</td>
 <td class="function_name"><a class="link" href="hkl-hkl.html#HklQuaternion" title="struct HklQuaternion">HklQuaternion</a></td>
 </tr>
@@ -279,6 +291,24 @@
 </div>
 <hr>
 <div class="refsect2">
+<a name="HKL-VECTOR-X:CAPS"></a><h3>HKL_VECTOR_X</h3>
+<pre class="programlisting">#define HKL_VECTOR_X {{1, 0, 0}}
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="HKL-VECTOR-Y:CAPS"></a><h3>HKL_VECTOR_Y</h3>
+<pre class="programlisting">#define HKL_VECTOR_Y {{0, 1, 0}}
+</pre>
+</div>
+<hr>
+<div class="refsect2">
+<a name="HKL-VECTOR-Z:CAPS"></a><h3>HKL_VECTOR_Z</h3>
+<pre class="programlisting">#define HKL_VECTOR_Z {{0, 0, 1}}
+</pre>
+</div>
+<hr>
+<div class="refsect2">
 <a name="HklQuaternion"></a><h3>struct HklQuaternion</h3>
 <pre class="programlisting">struct HklQuaternion {
 	double data[4];
@@ -288,8 +318,6 @@
 <hr>
 <div class="refsect2">
 <a name="darray-string"></a><h3>darray_string</h3>
-<pre class="programlisting">typedef darray(const char *) darray_string;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -339,8 +367,6 @@
 <hr>
 <div class="refsect2">
 <a name="darray-engine"></a><h3>darray_engine</h3>
-<pre class="programlisting">typedef darray(HklEngine *) darray_engine;
-</pre>
 </div>
 <hr>
 <div class="refsect2">
@@ -491,6 +517,7 @@
 	HklSource source;
 	darray_parameter axes;
 	darray_holder holders;
+	const HklGeometryOperations *ops;
 } HklGeometry;
 </pre>
 </div>
@@ -573,6 +600,7 @@
 <pre class="programlisting">typedef struct {
 	HklGeometry *geometry;
 	HklDetector *detector;
+	HklSample *sample;
 	HklVector hkl;
 	HklVector _hkl;
 	int flag;
@@ -583,6 +611,6 @@
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-list.html b/Documentation/api/html/hkl-list.html
index e5eacdb..b98eca5 100644
--- a/Documentation/api/html/hkl-list.html
+++ b/Documentation/api/html/hkl-list.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-hkl-vector-private.html" title="hkl-vector-private">
 <link rel="next" href="hkl-noerr.html" title="noerr">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -579,6 +579,6 @@ list_check_node (<em class="parameter"><code>const <span class="type">struct lis
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-noerr.html b/Documentation/api/html/hkl-noerr.html
index 54c525d..a30bb9a 100644
--- a/Documentation/api/html/hkl-noerr.html
+++ b/Documentation/api/html/hkl-noerr.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-list.html" title="list">
 <link rel="next" href="hkl-ptr-valid.html" title="ptr_valid">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -108,6 +108,6 @@ free_noerr (<em class="parameter"><code><span class="type">void</span> *p</code>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-ptr-valid.html b/Documentation/api/html/hkl-ptr-valid.html
index e9e359a..a7d4ff6 100644
--- a/Documentation/api/html/hkl-ptr-valid.html
+++ b/Documentation/api/html/hkl-ptr-valid.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-noerr.html" title="noerr">
 <link rel="next" href="hkl-str.html" title="str">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -222,6 +222,6 @@ ptr_valid_batch_end (<em class="parameter"><code><span class="type">struct ptr_v
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-str-debug.html b/Documentation/api/html/hkl-str-debug.html
index d434b02..208f223 100644
--- a/Documentation/api/html/hkl-str-debug.html
+++ b/Documentation/api/html/hkl-str-debug.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-str.html" title="str">
 <link rel="next" href="object-tree.html" title="Object Hierarchy">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -279,6 +279,6 @@ str_strrchr (<em class="parameter"><code>const <span class="type">char</span> *s
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl-str.html b/Documentation/api/html/hkl-str.html
index 4b8cb1c..126df58 100644
--- a/Documentation/api/html/hkl-str.html
+++ b/Documentation/api/html/hkl-str.html
@@ -8,7 +8,7 @@
 <link rel="up" href="ch01.html" title="[Insert title here]">
 <link rel="prev" href="hkl-ptr-valid.html" title="ptr_valid">
 <link rel="next" href="hkl-str-debug.html" title="str_debug">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -363,6 +363,6 @@ isxdigit ();</pre>
 </div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/hkl.devhelp2 b/Documentation/api/html/hkl.devhelp2
index 87132ad..7a6eead 100644
--- a/Documentation/api/html/hkl.devhelp2
+++ b/Documentation/api/html/hkl.devhelp2
@@ -83,6 +83,7 @@
     <keyword type="macro" name="darray_empty()" link="hkl-darray.html#darray-empty"/>
     <keyword type="macro" name="darray_append()" link="hkl-darray.html#darray-append"/>
     <keyword type="macro" name="darray_prepend()" link="hkl-darray.html#darray-prepend"/>
+    <keyword type="macro" name="darray_insert()" link="hkl-darray.html#darray-insert"/>
     <keyword type="macro" name="darray_push()" link="hkl-darray.html#darray-push"/>
     <keyword type="macro" name="darray_append_items()" link="hkl-darray.html#darray-append-items"/>
     <keyword type="macro" name="darray_prepend_items()" link="hkl-darray.html#darray-prepend-items"/>
@@ -132,6 +133,9 @@
     <keyword type="macro" name="HKLAPI" link="hkl-hkl.html#HKLAPI:CAPS"/>
     <keyword type="macro" name="HKL_WARN_UNUSED_RESULT" link="hkl-hkl.html#HKL-WARN-UNUSED-RESULT:CAPS"/>
     <keyword type="struct" name="struct HklVector" link="hkl-hkl.html#HklVector"/>
+    <keyword type="macro" name="HKL_VECTOR_X" link="hkl-hkl.html#HKL-VECTOR-X:CAPS"/>
+    <keyword type="macro" name="HKL_VECTOR_Y" link="hkl-hkl.html#HKL-VECTOR-Y:CAPS"/>
+    <keyword type="macro" name="HKL_VECTOR_Z" link="hkl-hkl.html#HKL-VECTOR-Z:CAPS"/>
     <keyword type="struct" name="struct HklQuaternion" link="hkl-hkl.html#HklQuaternion"/>
     <keyword type="typedef" name="darray_string" link="hkl-hkl.html#darray-string"/>
     <keyword type="enum" name="enum HklUnitEnum" link="hkl-hkl.html#HklUnitEnum"/>
@@ -152,8 +156,12 @@
     <keyword type="struct" name="HklParameter" link="hkl-hkl.html#HklParameter"/>
     <keyword type="struct" name="HklSample" link="hkl-hkl.html#HklSample"/>
     <keyword type="struct" name="HklSampleReflection" link="hkl-hkl.html#HklSampleReflection"/>
-    <keyword type="function" name="hkl_parameter_new_axis ()" link="hkl-hkl-axis-private.html#hkl-parameter-new-axis"/>
+    <keyword type="function" name="hkl_parameter_new_rotation ()" link="hkl-hkl-axis-private.html#hkl-parameter-new-rotation"/>
+    <keyword type="function" name="hkl_parameter_new_rotation_with_origin ()" link="hkl-hkl-axis-private.html#hkl-parameter-new-rotation-with-origin"/>
+    <keyword type="function" name="hkl_parameter_new_translation ()" link="hkl-hkl-axis-private.html#hkl-parameter-new-translation"/>
     <keyword type="struct" name="struct HklAxis" link="hkl-hkl-axis-private.html#HklAxis"/>
+    <keyword type="struct" name="struct HklRotationWithOrigin" link="hkl-hkl-axis-private.html#HklRotationWithOrigin"/>
+    <keyword type="struct" name="struct HklTranslation" link="hkl-hkl-axis-private.html#HklTranslation"/>
     <keyword type="function" name="hkl_detector_new ()" link="hkl-hkl-detector-private.html#hkl-detector-new"/>
     <keyword type="function" name="hkl_detector_attach_to_holder ()" link="hkl-hkl-detector-private.html#hkl-detector-attach-to-holder"/>
     <keyword type="function" name="hkl_detector_compute_kf ()" link="hkl-hkl-detector-private.html#hkl-detector-compute-kf"/>
@@ -163,9 +171,12 @@
     <keyword type="macro" name="REGISTER_DIFFRACTOMETER()" link="hkl-hkl-factory-private.html#REGISTER-DIFFRACTOMETER:CAPS"/>
     <keyword type="struct" name="HklFactory" link="hkl-hkl-factory-private.html#HklFactory"/>
     <keyword type="function" name="HklGeometryListMultiplyFunction ()" link="hkl-hkl-geometry-private.html#HklGeometryListMultiplyFunction"/>
+    <keyword type="function" name="darray_item ()" link="hkl-hkl-geometry-private.html#darray-item"/>
     <keyword type="function" name="g_quark_from_static_string ()" link="hkl-hkl-geometry-private.html#g-quark-from-static-string"/>
-    <keyword type="function" name="hkl_holder_add_rotation_axis ()" link="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-axis"/>
-    <keyword type="function" name="hkl_holder_add_rotation_axis_with_punit ()" link="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-axis-with-punit"/>
+    <keyword type="function" name="hkl_holder_add_rotation ()" link="hkl-hkl-geometry-private.html#hkl-holder-add-rotation"/>
+    <keyword type="function" name="hkl_holder_add_rotation_with_origin ()" link="hkl-hkl-geometry-private.html#hkl-holder-add-rotation-with-origin"/>
+    <keyword type="function" name="hkl_holder_add_translation ()" link="hkl-hkl-geometry-private.html#hkl-holder-add-translation"/>
+    <keyword type="function" name="hkl_holder_transformation_apply ()" link="hkl-hkl-geometry-private.html#hkl-holder-transformation-apply"/>
     <keyword type="function" name="hkl_geometry_new ()" link="hkl-hkl-geometry-private.html#hkl-geometry-new"/>
     <keyword type="function" name="hkl_geometry_init_geometry ()" link="hkl-hkl-geometry-private.html#hkl-geometry-init-geometry"/>
     <keyword type="function" name="hkl_geometry_add_holder ()" link="hkl-hkl-geometry-private.html#hkl-geometry-add-holder"/>
@@ -177,6 +188,10 @@
     <keyword type="function" name="hkl_geometry_closest_from_geometry_with_range ()" link="hkl-hkl-geometry-private.html#hkl-geometry-closest-from-geometry-with-range"/>
     <keyword type="function" name="hkl_geometry_is_valid ()" link="hkl-hkl-geometry-private.html#hkl-geometry-is-valid"/>
     <keyword type="function" name="hkl_geometry_is_valid_range ()" link="hkl-hkl-geometry-private.html#hkl-geometry-is-valid-range"/>
+    <keyword type="function" name="hkl_geometry_sample_holder_get ()" link="hkl-hkl-geometry-private.html#hkl-geometry-sample-holder-get"/>
+    <keyword type="function" name="hkl_geometry_detector_holder_get ()" link="hkl-hkl-geometry-private.html#hkl-geometry-detector-holder-get"/>
+    <keyword type="function" name="hkl_geometry_ki_get ()" link="hkl-hkl-geometry-private.html#hkl-geometry-ki-get"/>
+    <keyword type="function" name="hkl_geometry_kf_get ()" link="hkl-hkl-geometry-private.html#hkl-geometry-kf-get"/>
     <keyword type="function" name="hkl_geometry_list_new ()" link="hkl-hkl-geometry-private.html#hkl-geometry-list-new"/>
     <keyword type="function" name="hkl_geometry_list_new_copy ()" link="hkl-hkl-geometry-private.html#hkl-geometry-list-new-copy"/>
     <keyword type="function" name="hkl_geometry_list_add ()" link="hkl-hkl-geometry-private.html#hkl-geometry-list-add"/>
@@ -189,10 +204,17 @@
     <keyword type="function" name="hkl_geometry_list_item_new ()" link="hkl-hkl-geometry-private.html#hkl-geometry-list-item-new"/>
     <keyword type="function" name="hkl_geometry_list_item_new_copy ()" link="hkl-hkl-geometry-private.html#hkl-geometry-list-item-new-copy"/>
     <keyword type="function" name="hkl_geometry_list_item_free ()" link="hkl-hkl-geometry-private.html#hkl-geometry-list-item-free"/>
+    <keyword type="macro" name="HKL_HOLDER_SAMPLE_IDX" link="hkl-hkl-geometry-private.html#HKL-HOLDER-SAMPLE-IDX:CAPS"/>
+    <keyword type="macro" name="HKL_HOLDER_DETECTOR_IDX" link="hkl-hkl-geometry-private.html#HKL-HOLDER-DETECTOR-IDX:CAPS"/>
     <keyword type="typedef" name="darray_holder" link="hkl-hkl-geometry-private.html#darray-holder"/>
     <keyword type="struct" name="struct HklHolderConfig" link="hkl-hkl-geometry-private.html#HklHolderConfig"/>
     <keyword type="struct" name="struct HklHolder" link="hkl-hkl-geometry-private.html#HklHolder"/>
+    <keyword type="struct" name="struct HklGeometryOperations" link="hkl-hkl-geometry-private.html#HklGeometryOperations"/>
     <keyword type="struct" name="HklGeometry" link="hkl-hkl-geometry-private.html#HklGeometry"/>
+    <keyword type="variable" name="kf" link="hkl-hkl-geometry-private.html#kf"/>
+    <keyword type="variable" name="detector_holder" link="hkl-hkl-geometry-private.html#detector-holder"/>
+    <keyword type="macro" name="HKL_GEOMETRY_OPERATIONS_DEFAULTS" link="hkl-hkl-geometry-private.html#HKL-GEOMETRY-OPERATIONS-DEFAULTS:CAPS"/>
+    <keyword type="variable" name="hkl_geometry_operations_defaults" link="hkl-hkl-geometry-private.html#hkl-geometry-operations-defaults"/>
     <keyword type="macro" name="HKL_GEOMETRY_ERROR" link="hkl-hkl-geometry-private.html#HKL-GEOMETRY-ERROR:CAPS"/>
     <keyword type="enum" name="enum HklGeometryError" link="hkl-hkl-geometry-private.html#HklGeometryError"/>
     <keyword type="struct" name="HklGeometryList" link="hkl-hkl-geometry-private.html#HklGeometryList"/>
@@ -255,6 +277,8 @@
     <keyword type="function" name="hkl_parameter_is_valid ()" link="hkl-hkl-parameter-private.html#hkl-parameter-is-valid"/>
     <keyword type="function" name="hkl_parameter_is_valid_range ()" link="hkl-hkl-parameter-private.html#hkl-parameter-is-valid-range"/>
     <keyword type="function" name="hkl_parameter_fprintf ()" link="hkl-hkl-parameter-private.html#hkl-parameter-fprintf"/>
+    <keyword type="function" name="hkl_parameter_transformation_cmp ()" link="hkl-hkl-parameter-private.html#hkl-parameter-transformation-cmp"/>
+    <keyword type="function" name="hkl_parameter_transformation_apply ()" link="hkl-hkl-parameter-private.html#hkl-parameter-transformation-apply"/>
     <keyword type="struct" name="HklParameter" link="hkl-hkl-parameter-private.html#HklParameter"/>
     <keyword type="macro" name="HKL_PARAMETER_DEFAULTS" link="hkl-hkl-parameter-private.html#HKL-PARAMETER-DEFAULTS:CAPS"/>
     <keyword type="macro" name="HKL_PARAMETER_DEFAULTS_ANGLE" link="hkl-hkl-parameter-private.html#HKL-PARAMETER-DEFAULTS-ANGLE:CAPS"/>
@@ -286,6 +310,7 @@
     <keyword type="function" name="hkl_engine_eulerians_new ()" link="hkl-hkl-pseudoaxis-common-eulerians-private.html#hkl-engine-eulerians-new"/>
     <keyword type="function" name="kappa_2_kappap ()" link="hkl-hkl-pseudoaxis-common-eulerians-private.html#kappa-2-kappap"/>
     <keyword type="function" name="RUBh_minus_Q ()" link="hkl-hkl-pseudoaxis-common-hkl-private.html#RUBh-minus-Q"/>
+    <keyword type="function" name="hkl_is_reachable ()" link="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-is-reachable"/>
     <keyword type="function" name="hkl_mode_get_hkl_real ()" link="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-mode-get-hkl-real"/>
     <keyword type="function" name="hkl_mode_set_hkl_real ()" link="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-mode-set-hkl-real"/>
     <keyword type="function" name="hkl_mode_initialized_set_psi_constant_vertical_real ()" link="hkl-hkl-pseudoaxis-common-hkl-private.html#hkl-mode-initialized-set-psi-constant-vertical-real"/>
@@ -297,14 +322,6 @@
     <keyword type="macro" name="HKL_MODE_OPERATIONS_HKL_FULL_DEFAULTS" link="hkl-hkl-pseudoaxis-common-hkl-private.html#HKL-MODE-OPERATIONS-HKL-FULL-DEFAULTS:CAPS"/>
     <keyword type="macro" name="HKL_PARAMETER_EMERGENCE_DEFAULTS" link="hkl-hkl-pseudoaxis-common-hkl-private.html#HKL-PARAMETER-EMERGENCE-DEFAULTS:CAPS"/>
     <keyword type="macro" name="HKL_PARAMETER_EMERGENCE_AZIMUTH_DEFAULTS" link="hkl-hkl-pseudoaxis-common-hkl-private.html#HKL-PARAMETER-EMERGENCE-AZIMUTH-DEFAULTS:CAPS"/>
-    <keyword type="function" name="hkl_mode_psi_new ()" link="hkl-hkl-pseudoaxis-common-psi-private.html#hkl-mode-psi-new"/>
-    <keyword type="function" name="hkl_engine_psi_new ()" link="hkl-hkl-pseudoaxis-common-psi-private.html#hkl-engine-psi-new"/>
-    <keyword type="struct" name="struct HklModePsi" link="hkl-hkl-pseudoaxis-common-psi-private.html#HklModePsi"/>
-    <keyword type="struct" name="struct HklEnginePsi" link="hkl-hkl-pseudoaxis-common-psi-private.html#HklEnginePsi"/>
-    <keyword type="function" name="qmax ()" link="hkl-hkl-pseudoaxis-common-q-private.html#qmax"/>
-    <keyword type="function" name="hkl_engine_q_new ()" link="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-q-new"/>
-    <keyword type="function" name="hkl_engine_q2_new ()" link="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-q2-new"/>
-    <keyword type="function" name="hkl_engine_qper_qpar_new ()" link="hkl-hkl-pseudoaxis-common-q-private.html#hkl-engine-qper-qpar-new"/>
     <keyword type="macro" name="HKL_MODE_INFO_RO()" link="hkl-hkl-pseudoaxis-private.html#HKL-MODE-INFO-RO:CAPS"/>
     <keyword type="macro" name="HKL_MODE_INFO()" link="hkl-hkl-pseudoaxis-private.html#HKL-MODE-INFO:CAPS"/>
     <keyword type="macro" name="HKL_MODE_INFO_RO_WITH_PARAMS()" link="hkl-hkl-pseudoaxis-private.html#HKL-MODE-INFO-RO-WITH-PARAMS:CAPS"/>
@@ -361,7 +378,7 @@
     <keyword type="function" name="hkl_source_fprintf ()" link="hkl-hkl-source-private.html#hkl-source-fprintf"/>
     <keyword type="macro" name="HKL_SOURCE_DEFAULT_WAVE_LENGTH" link="hkl-hkl-source-private.html#HKL-SOURCE-DEFAULT-WAVE-LENGTH:CAPS"/>
     <keyword type="struct" name="struct HklSource" link="hkl-hkl-source-private.html#HklSource"/>
-    <keyword type="macro" name="HKL_TYPE_UNIT_ENUM()" link="hkl-hkl-type-builtins.html#HKL-TYPE-UNIT-ENUM:CAPS"/>
+    <keyword type="macro" name="HKL_TYPE_UNIT_ENUM" link="hkl-hkl-type-builtins.html#HKL-TYPE-UNIT-ENUM:CAPS"/>
     <keyword type="macro" name="HKL_TYPE_DETECTOR_TYPE" link="hkl-hkl-type-builtins.html#HKL-TYPE-DETECTOR-TYPE:CAPS"/>
     <keyword type="macro" name="HKL_TYPE_ENGINE_CAPABILITIES" link="hkl-hkl-type-builtins.html#HKL-TYPE-ENGINE-CAPABILITIES:CAPS"/>
     <keyword type="macro" name="HKL_TYPE_ENGINE_AXIS_NAMES_GET" link="hkl-hkl-type-builtins.html#HKL-TYPE-ENGINE-AXIS-NAMES-GET:CAPS"/>
@@ -385,7 +402,9 @@
     <keyword type="function" name="hkl_unit_free ()" link="hkl-hkl-unit-private.html#hkl-unit-free"/>
     <keyword type="function" name="hkl_unit_compatible ()" link="hkl-hkl-unit-private.html#hkl-unit-compatible"/>
     <keyword type="function" name="hkl_unit_factor ()" link="hkl-hkl-unit-private.html#hkl-unit-factor"/>
-    <keyword type="enum" name="enum HklUnitType" link="hkl-hkl-unit-private.html#HklUnitType"/>
+    <keyword type="struct" name="struct HklUnitDimension" link="hkl-hkl-unit-private.html#HklUnitDimension"/>
+    <keyword type="macro" name="HklDPlaneAngle" link="hkl-hkl-unit-private.html#HklDPlaneAngle"/>
+    <keyword type="macro" name="HklDLength" link="hkl-hkl-unit-private.html#HklDLength"/>
     <keyword type="struct" name="struct HklUnit" link="hkl-hkl-unit-private.html#HklUnit"/>
     <keyword type="function" name="hkl_vector_dup ()" link="hkl-hkl-vector-private.html#hkl-vector-dup"/>
     <keyword type="function" name="hkl_vector_free ()" link="hkl-hkl-vector-private.html#hkl-vector-free"/>
@@ -547,9 +566,5 @@
     <keyword type="constant" name="HKL_SAMPLE_ERROR_MINIMIZED" link="hkl-hkl-sample-private.html#HKL-SAMPLE-ERROR-MINIMIZED:CAPS"/>
     <keyword type="constant" name="HKL_SAMPLE_ERROR_COMPUTE_UB_BUSING_LEVY" link="hkl-hkl-sample-private.html#HKL-SAMPLE-ERROR-COMPUTE-UB-BUSING-LEVY:CAPS"/>
     <keyword type="constant" name="HKL_SAMPLE_REFLECTION_ERROR_HKL_SET" link="hkl-hkl-sample-private.html#HKL-SAMPLE-REFLECTION-ERROR-HKL-SET:CAPS"/>
-    <keyword type="constant" name="HKL_UNIT_ANGLE_DEG" link="hkl-hkl-unit-private.html#HKL-UNIT-ANGLE-DEG:CAPS"/>
-    <keyword type="constant" name="HKL_UNIT_ANGLE_RAD" link="hkl-hkl-unit-private.html#HKL-UNIT-ANGLE-RAD:CAPS"/>
-    <keyword type="constant" name="HKL_UNIT_LENGTH_NM" link="hkl-hkl-unit-private.html#HKL-UNIT-LENGTH-NM:CAPS"/>
-    <keyword type="constant" name="HKL_UNIT_ANGLE_MRAD" link="hkl-hkl-unit-private.html#HKL-UNIT-ANGLE-MRAD:CAPS"/>
   </functions>
 </book>
diff --git a/Documentation/api/html/home.png b/Documentation/api/html/home.png
index 4bf6d92..431ab24 100644
Binary files a/Documentation/api/html/home.png and b/Documentation/api/html/home.png differ
diff --git a/Documentation/api/html/index.html b/Documentation/api/html/index.html
index ac3c8e1..1d57f17 100644
--- a/Documentation/api/html/index.html
+++ b/Documentation/api/html/index.html
@@ -6,7 +6,7 @@
 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
 <link rel="home" href="index.html" title="hkl Reference Manual">
 <link rel="next" href="ch01.html" title="[Insert title here]">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -138,6 +138,6 @@
 </dl></div>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/left-insensitive.png b/Documentation/api/html/left-insensitive.png
index 82cba0a..a52885c 100644
Binary files a/Documentation/api/html/left-insensitive.png and b/Documentation/api/html/left-insensitive.png differ
diff --git a/Documentation/api/html/left.png b/Documentation/api/html/left.png
index 8444ec0..0216ce0 100644
Binary files a/Documentation/api/html/left.png and b/Documentation/api/html/left.png differ
diff --git a/Documentation/api/html/object-tree.html b/Documentation/api/html/object-tree.html
index a0cb7af..1a6d661 100644
--- a/Documentation/api/html/object-tree.html
+++ b/Documentation/api/html/object-tree.html
@@ -8,7 +8,7 @@
 <link rel="up" href="index.html" title="hkl Reference Manual">
 <link rel="prev" href="hkl-str-debug.html" title="str_debug">
 <link rel="next" href="api-index-full.html" title="API Index">
-<meta name="generator" content="GTK-Doc V1.25 (XML mode)">
+<meta name="generator" content="GTK-Doc V1.26 (XML mode)">
 <link rel="stylesheet" href="style.css" type="text/css">
 </head>
 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -27,6 +27,6 @@
 </pre>
 </div>
 <div class="footer">
-<hr>Generated by GTK-Doc V1.25</div>
+<hr>Generated by GTK-Doc V1.26</div>
 </body>
 </html>
\ No newline at end of file
diff --git a/Documentation/api/html/right-insensitive.png b/Documentation/api/html/right-insensitive.png
index 7a90b99..857714a 100644
Binary files a/Documentation/api/html/right-insensitive.png and b/Documentation/api/html/right-insensitive.png differ
diff --git a/Documentation/api/html/right.png b/Documentation/api/html/right.png
index 55f3359..2ca36a5 100644
Binary files a/Documentation/api/html/right.png and b/Documentation/api/html/right.png differ
diff --git a/Documentation/api/html/up-insensitive.png b/Documentation/api/html/up-insensitive.png
index fdb8cc7..8b70778 100644
Binary files a/Documentation/api/html/up-insensitive.png and b/Documentation/api/html/up-insensitive.png differ
diff --git a/Documentation/api/html/up.png b/Documentation/api/html/up.png
index c1aad52..b2a80fb 100644
Binary files a/Documentation/api/html/up.png and b/Documentation/api/html/up.png differ
diff --git a/Documentation/css/style.css b/Documentation/css/style.css
new file mode 100644
index 0000000..fdce2cf
--- /dev/null
+++ b/Documentation/css/style.css
@@ -0,0 +1,445 @@
+body {
+    font-family: Helvetica, Arial, sans-serif;
+    font-size: 16px;
+    line-height: 1.4;
+    color: #33333f;
+}
+
+code {
+    font-family: "Inconsolata", monospace;
+    font-size: 16px;
+}
+
+p>code, li>code {
+    background-color: #eee;
+    padding: 0.25em;
+}
+
+h1, h2, h3 {
+    font-family: "Roboto Slab", Helvetica, Arial, sans-serif;
+}
+
+h2 {
+    border-bottom: 1px solid #f0c;
+    padding-bottom: 0.5em;
+    font-size: 1.75em;
+}
+
+h3 {
+    margin-top: 2em;
+    font-size: 1.5em;
+}
+
+h4 {
+    font-size: 1.25em;
+}
+
+h5 {
+    font-size: 1em;
+}
+
+h2 code, h3 code, h4 code, h5 code, td code {
+    font-family: inherit !important;
+    font-size: inherit !important;
+}
+
+td code {
+    font-weight: bold;
+}
+
+a:link, a:hover, a:visited {
+                     text-decoration: none;
+                     color: black;
+                 }
+
+a:link {
+    background: #ff8;
+}
+
+a:visited {
+    color: #666;
+    background: #ffc;
+}
+
+a:link:hover,
+a:visited:hover {
+    background: #ff0;
+}
+
+a[href^="http"] {
+    background: #bff;
+}
+
+a[href^="http"]:visited {
+    background: #dff;
+}
+
+a[href^="http"]:link:hover,
+a[href^="http"]:visited:hover {
+    background: #0ff;
+}
+
+a[href^="http"]:after {
+    content: "\21B3";
+    background: white;
+    padding-left: 0.2em;
+}
+
+#meta {
+    margin-top: 2em;
+}
+
+#table-of-contents a:link,
+#table-of-contents a:visited {
+    color: black;
+    background: transparent;
+}
+
+#table-of-contents {
+    line-height: 1.2;
+}
+#table-of-contents h2 {
+    border-bottom: 0;
+}
+
+#table-of-contents ul {
+    list-style: none;
+    padding-left:0;
+    font-weight: normal;
+}
+
+#table-of-contents div>ul>li {
+    margin-top: 1em;
+    font-weight: bold;
+}
+
+#table-of-contents .tag {
+    display: none;
+}
+
+#table-of-contents .todo,
+#table-of-contents .done {
+    font-size: 80%;
+}
+
+#table-of-contents ol>li {
+    margin-top: 1em;
+}
+
+table {
+    width: 100%;
+}
+
+table, th, td {
+    border: 1px solid #666;
+}
+
+th, td {
+    padding: 0.5em;
+    text-align: left;
+}
+
+tbody tr:nth-child(odd) {
+    background-color: #eee;
+}
+
+img {
+    max-width: 90%;
+}
+
+div.notice {
+    position: relative;
+    margin: 0 1.2em;
+    padding: 0.25em 1em;
+    border-left: 4px solid;
+}
+
+table + div.notice {
+    margin-top: 2em;
+}
+
+div.notice a {
+    background: transparent !important;
+    border-bottom: 1px dotted;
+}
+
+div.notice a[href^="http"]:after {
+    background: transparent !important;
+}
+
+div.notice:before {
+    position: absolute;
+    top: 0;
+    right: 0;
+    padding: 0.25em 0.5em 0;
+    font-size: 60%;
+    border-bottom-left-radius: 0.5em;
+}
+
+.notice-warning {
+    background: #fcc;
+    color: #600;
+}
+
+.notice-example {
+    background: #def;
+    color: #069;
+}
+
+.notice-info {
+    background: #efe;
+    color: #060;
+}
+
+.notice-warning a {
+    color: #600;
+}
+
+.notice-example a {
+    color: #069;
+}
+
+.notice-info a {
+    color: #060;
+}
+
+div.notice-warning:before {
+    content: "WARNING";
+    background: #c99;
+    color: #fcc;
+}
+
+div.notice-example:before {
+    content: "EXAMPLE";
+    background: #abc;
+    color: #def;
+}
+
+div.notice-info:before {
+    content: "INFO";
+    background: #9c9;
+    color: #efe;
+}
+
+pre {
+    font-family: Inconsolata;
+    border: 0;
+    box-shadow: none;
+}
+
+pre.example:before {
+    content: "Properties";
+    display: block;
+    border-bottom: 1px dotted;
+    margin-bottom: 1em;
+}
+
+pre.example {
+    background: #fec;
+    color: #666;
+    font-size: 0.85em;
+}
+
+pre {
+    background-color: #f8f8f8;
+    background-size: 8px 8px;
+    background-image: linear-gradient(135deg, transparent 25%, rgba(0, 0, 0, 0.02) 25%, rgba(0, 0, 0, 0.02) 50%, transparent 50%, transparent 75%, rgba(0, 0, 0, 0.02) 75%, rgba(0, 0, 0, 0.02));
+}
+
+pre.src {
+    padding: 0.5em;
+}
+
+pre.src:before {
+    display: block;
+    position: absolute;
+    background-color: #ccccd0;
+    top: 0;
+    right: 0;
+    padding: 0.25em 0.5em;
+    border-bottom-left-radius: 8px;
+    border: 0;
+    color: white;
+    font-size: 80%;
+}
+
+pre.src-plantuml:before {
+    content: "UML";
+}
+
+pre.src-javascript:before {
+    content: "JS";
+}
+
+pre.src-clojure:before {
+    content: "CLJ";
+}
+
+pre.src-c:before {
+    content: "C";
+}
+
+span.org-string {
+    color: #f94;
+}
+
+span.org-keyword {
+    color: #c07;
+}
+
+span.org-variable-name {
+    color: #f04;
+}
+
+span.org-clojure-keyword {
+    color: #09f;
+}
+
+span.org-comment, span.org-comment-delimiter {
+    color: #999;
+}
+
+span.org-rainbow-delimiters-depth-1, span.org-rainbow-delimiters-depth-5 {
+    color: #666;
+}
+
+span.org-rainbow-delimiters-depth-2, span.org-rainbow-delimiters-depth-6 {
+    color: #888;
+}
+
+span.org-rainbow-delimiters-depth-3, span.org-rainbow-delimiters-depth-7 {
+    color: #aaa;
+}
+
+span.org-rainbow-delimiters-depth-4, span.org-rainbow-delimiters-depth-8 {
+    color: #ccc;
+}
+
+div.figure {
+    font-size: 0.85em;
+}
+
+.tag {
+    font-family: "Roboto Slab", Helvetica, Arial, sans-serif;
+    font-size: 11px;
+    font-weight: normal;
+    float: right;
+    margin-top: 1em;
+    background: transparent;
+}
+
+.tag span {
+    background: #ccc;
+    padding: 0 0.5em;
+    border-radius: 0.2em;
+    color: white;
+}
+
+.todo, .done {
+    font-family: "Roboto Slab", Helvetica, Arial, sans-serif;
+    font-weight: normal;
+    padding: 0 0.25em;
+    border-radius: 0.2em;
+}
+
+.todo {
+    background: #f04;
+    color: white;
+}
+
+.done {
+    background: #5f7;
+    color: white;
+}
+
+ at media screen {
+    h1.title {
+        text-align: left;
+        margin: 1em 0 0 280px;
+    }
+
+    h2 {
+        margin-top: 3em;
+    }
+
+    #table-of-contents {
+        position: fixed;
+        top: 0;
+        left: 0;
+        padding: 2em 0 2em 2em;
+        width: 240px;
+        height: 100vh;
+        font-size: 11px;
+        background: #eee;
+        overflow: auto;
+    }
+
+    #table-of-contents ul>li>ul>li>ul>li {
+        display: none;
+    }
+
+    #table-of-contents h2 {
+        margin-top: 0;
+    }
+
+    #table-of-contents code {
+        font-size: 12px;
+    }
+
+    div.outline-2, #footnotes {
+        margin-left: 280px;
+        max-width: 960px;
+    }
+}
+
+ at media screen and (max-width: 1024px) {
+    html, body {
+        font-size: 14px;
+    }
+
+    #table-of-contents {
+        display: none;
+    }
+
+    h1.title {
+        margin-left: 5%;
+    }
+
+    div.outline-2, #footnotes {
+        margin-left: 5%;
+        max-width: 90%;
+    }
+}
+
+ at media print {
+
+    body {
+        color: black;
+    }
+
+    @page {
+        margin: 25mm;
+    }
+
+    h2, h3 {
+        page-break-before: always;
+        margin-top: 0;
+    }
+
+    table {
+        page-break-inside: avoid;
+    }
+
+    a:visited {
+        color: black;
+        background: #ff8;
+    }
+
+    a[href^="http"]:visited {
+        background: #bff;
+    }
+
+    div.notice:before {
+        display: none;
+    }
+}
\ No newline at end of file
diff --git a/Documentation/figures/3S+1D.png b/Documentation/figures/3S+1D.png
index a78e015..760662d 100644
Binary files a/Documentation/figures/3S+1D.png and b/Documentation/figures/3S+1D.png differ
diff --git a/Documentation/figures/4S+2D.png b/Documentation/figures/4S+2D.png
index 0cf3e4e..3a934fb 100644
Binary files a/Documentation/figures/4S+2D.png and b/Documentation/figures/4S+2D.png differ
diff --git a/Documentation/figures/4S+2D_reciprocal.png b/Documentation/figures/4S+2D_reciprocal.png
index dbccc3f..b1cfc4f 100644
Binary files a/Documentation/figures/4S+2D_reciprocal.png and b/Documentation/figures/4S+2D_reciprocal.png differ
diff --git a/Documentation/figures/4S+2D_reciprocal2.png b/Documentation/figures/4S+2D_reciprocal2.png
index 3b726a7..6ed0afc 100644
Binary files a/Documentation/figures/4S+2D_reciprocal2.png and b/Documentation/figures/4S+2D_reciprocal2.png differ
diff --git a/Documentation/figures/4S+2D_reciprocal3.png b/Documentation/figures/4S+2D_reciprocal3.png
index d9068ff..c3b000d 100644
Binary files a/Documentation/figures/4S+2D_reciprocal3.png and b/Documentation/figures/4S+2D_reciprocal3.png differ
diff --git a/Documentation/figures/4S+2D_reciprocal4.png b/Documentation/figures/4S+2D_reciprocal4.png
index 2c40dc1..0533b37 100644
Binary files a/Documentation/figures/4S+2D_reciprocal4.png and b/Documentation/figures/4S+2D_reciprocal4.png differ
diff --git a/Documentation/figures/B_a.asy b/Documentation/figures/B_a.asy
index 6b0f55e..8ec4efe 100644
--- a/Documentation/figures/B_a.asy
+++ b/Documentation/figures/B_a.asy
@@ -1,6 +1,8 @@
 import three;
 
 size(6cm);
+currentprojection=orthographic(1,0,0);
+currentlight=White;
 
 triple b1 = (1, 0, 0);
 triple b2 = (.31, .95, 0);
diff --git a/Documentation/figures/B_a.png b/Documentation/figures/B_a.png
index d3dfd9e..ed8096f 100644
Binary files a/Documentation/figures/B_a.png and b/Documentation/figures/B_a.png differ
diff --git a/Documentation/figures/B_b.asy b/Documentation/figures/B_b.asy
index 1be2509..c40cefd 100644
--- a/Documentation/figures/B_b.asy
+++ b/Documentation/figures/B_b.asy
@@ -1,5 +1,8 @@
 import three;
 
+currentprojection=orthographic(1,0,0);
+currentlight=White;
+
 size(6cm);
 
 triple b1 = (1, 0, 0);
diff --git a/Documentation/figures/B_b.png b/Documentation/figures/B_b.png
index da87401..e48ad40 100644
Binary files a/Documentation/figures/B_b.png and b/Documentation/figures/B_b.png differ
diff --git a/Documentation/figures/B_b3_y.png b/Documentation/figures/B_b3_y.png
index ded2c08..33f2614 100644
Binary files a/Documentation/figures/B_b3_y.png and b/Documentation/figures/B_b3_y.png differ
diff --git a/Documentation/figures/Makefile.am b/Documentation/figures/Makefile.am
index 4b706e3..b01444e 100644
--- a/Documentation/figures/Makefile.am
+++ b/Documentation/figures/Makefile.am
@@ -4,6 +4,43 @@
 .asy.pdf:
 	- at ASY@ -config "" -render=0 -f pdf -noprc -o $@ $<
 
+
+AM_CPPFLAGS = -Wextra -D_DEFAULT_SOURCE \
+	-I$(top_srcdir) \
+	-I$(top_srcdir)/hkl \
+	$(GLIB_CFLAGS) \
+	$(GSL_CFLAGS)
+
+LDADD = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
+	$(GLIB_LIBS) \
+	$(GSL_LIBS)
+
+noinst_PROGRAMS = sirius
+
+SIRIUSFILES=s1-11.dat s2-11.dat s1-101.dat s2-101.dat m1-11.dat m2-11.dat m1-101.dat m2-101.dat traj_n.dat
+
+sirius.stamp: sirius
+	cd $(builddir) && ./sirius
+
+$(SIRIUSFILES): sirius.stamp
+	## Recover from the removal of $@
+	@if test -f $@; then :; else \
+		trap 'rm -rf sirius.lock sirius.stamp' 1 2 13 15; \
+		## mkdir is a portable test-and-set
+		if mkdir sirius.lock 2>/dev/null; then \
+		## This code is being executed by the first process.
+			rm -f sirius.stamp; \
+			$(MAKE) $(AM_MAKEFLAGS) sirius.stamp; \
+		else \
+		## This code is being executed by the follower processes.
+		## Wait until the first process is done.
+			while test -d sirius.lock; do sleep 1; done; \
+		## Succeed if and only if the first process succeeded.
+			test -f sirius.stamp; exit $$?; \
+		fi; \
+	fi
+
 dist_noinst_DATA = \
 	3S+1D.png \
 	B_b3_y.png \
@@ -23,7 +60,10 @@ dist_noinst_DATA = \
 	e2k_2.png \
 	e2k_3.png \
 	e2k_4.png \
-	qper_qpar.png
+	qper_qpar.png \
+	$(SIRIUSFILES)
+
+CLEANFILES = $(SIRIUSFILES) sirius-s.svg sirius-m.svg sirius-m-zoom.svg traj_n.svg
 
 MAINTAINERCLEANFILES = $(dist_noinst_DATA)
 
@@ -49,3 +89,9 @@ EXTRA_DIST = \
 	e2k_3.asy \
 	e2k_4.asy \
 	qper_qpar.asy
+
+# Support for GNU Flymake, in Emacs.
+
+check-syntax: AM_CFLAGS += -fsyntax-only -pipe
+check-syntax:
+	test -z "$(CHK_SOURCES)" || $(COMPILE) $(CHK_SOURCES)
diff --git a/Documentation/figures/Makefile.in b/Documentation/figures/Makefile.in
index 89bbfdd..262f5f1 100644
--- a/Documentation/figures/Makefile.in
+++ b/Documentation/figures/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -14,6 +14,7 @@
 
 @SET_MAKE@
 
+
 VPATH = @srcdir@
 am__is_gnu_make = { \
   if test -z '$(MAKELEVEL)'; then \
@@ -88,6 +89,7 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+noinst_PROGRAMS = sirius$(EXEEXT)
 subdir = Documentation/figures
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/m4/gtk-doc.m4 \
@@ -102,6 +104,18 @@ mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+PROGRAMS = $(noinst_PROGRAMS)
+sirius_SOURCES = sirius.c
+sirius_OBJECTS = sirius.$(OBJEXT)
+sirius_LDADD = $(LDADD)
+am__DEPENDENCIES_1 =
+sirius_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la $(am__DEPENDENCIES_1) \
+	$(am__DEPENDENCIES_1)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 AM_V_P = $(am__v_P_ at AM_V@)
 am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
 am__v_P_0 = false
@@ -114,8 +128,30 @@ AM_V_at = $(am__v_at_ at AM_V@)
 am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
 am__v_at_0 = @
 am__v_at_1 = 
-SOURCES =
-DIST_SOURCES =
+DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
+depcomp = $(SHELL) $(top_srcdir)/config/depcomp
+am__depfiles_maybe = depfiles
+am__mv = mv -f
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
+CCLD = $(CC)
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
+SOURCES = sirius.c
+DIST_SOURCES = sirius.c
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -123,7 +159,25 @@ am__can_run_installinfo = \
   esac
 DATA = $(dist_noinst_DATA)
 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
-am__DIST_COMMON = $(srcdir)/Makefile.in
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
+ETAGS = etags
+CTAGS = ctags
+am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/config/depcomp
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 ALLOCA = @ALLOCA@
@@ -168,6 +222,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -295,6 +350,18 @@ top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 version_info = @version_info@
+AM_CPPFLAGS = -Wextra -D_DEFAULT_SOURCE \
+	-I$(top_srcdir) \
+	-I$(top_srcdir)/hkl \
+	$(GLIB_CFLAGS) \
+	$(GSL_CFLAGS)
+
+LDADD = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
+	$(GLIB_LIBS) \
+	$(GSL_LIBS)
+
+SIRIUSFILES = s1-11.dat s2-11.dat s1-101.dat s2-101.dat m1-11.dat m2-11.dat m1-101.dat m2-101.dat traj_n.dat
 dist_noinst_DATA = \
 	3S+1D.png \
 	B_b3_y.png \
@@ -314,8 +381,10 @@ dist_noinst_DATA = \
 	e2k_2.png \
 	e2k_3.png \
 	e2k_4.png \
-	qper_qpar.png
+	qper_qpar.png \
+	$(SIRIUSFILES)
 
+CLEANFILES = $(SIRIUSFILES) sirius-s.svg sirius-m.svg sirius-m-zoom.svg traj_n.svg
 MAINTAINERCLEANFILES = $(dist_noinst_DATA)
 EXTRA_DIST = \
 	3S+1D.asy \
@@ -343,7 +412,7 @@ EXTRA_DIST = \
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .asy .pdf .png
+.SUFFIXES: .asy .c .lo .o .obj .pdf .png
 $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -374,17 +443,108 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(am__aclocal_m4_deps):
 
+clean-noinstPROGRAMS:
+	@list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
+	echo " rm -f" $$list; \
+	rm -f $$list || exit $$?; \
+	test -n "$(EXEEXT)" || exit 0; \
+	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
+	echo " rm -f" $$list; \
+	rm -f $$list
+
+sirius$(EXEEXT): $(sirius_OBJECTS) $(sirius_DEPENDENCIES) $(EXTRA_sirius_DEPENDENCIES) 
+	@rm -f sirius$(EXEEXT)
+	$(AM_V_CCLD)$(LINK) $(sirius_OBJECTS) $(sirius_LDADD) $(LIBS)
+
+mostlyclean-compile:
+	-rm -f *.$(OBJEXT)
+
+distclean-compile:
+	-rm -f *.tab.c
+
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/sirius.Po at am__quote@
+
+.c.o:
+ at am__fastdepCC_TRUE@	$(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\
+ at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\
+ at am__fastdepCC_TRUE@	$(am__mv) $$depbase.Tpo $$depbase.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
+
+.c.obj:
+ at am__fastdepCC_TRUE@	$(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.obj$$||'`;\
+ at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ `$(CYGPATH_W) '$<'` &&\
+ at am__fastdepCC_TRUE@	$(am__mv) $$depbase.Tpo $$depbase.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+
+.c.lo:
+ at am__fastdepCC_TRUE@	$(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.lo$$||'`;\
+ at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\
+ at am__fastdepCC_TRUE@	$(am__mv) $$depbase.Tpo $$depbase.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
+
 mostlyclean-libtool:
 	-rm -f *.lo
 
 clean-libtool:
 	-rm -rf .libs _libs
-tags TAGS:
 
-ctags CTAGS:
-
-cscope cscopelist:
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	set x; \
+	here=`pwd`; \
+	$(am__define_uniq_tagged_files); \
+	shift; \
+	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+	  test -n "$$unique" || unique=$$empty_fix; \
+	  if test $$# -gt 0; then \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      "$$@" $$unique; \
+	  else \
+	    $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+	      $$unique; \
+	  fi; \
+	fi
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
+	test -z "$(CTAGS_ARGS)$$unique" \
+	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+	     $$unique
+
+GTAGS:
+	here=`$(am__cd) $(top_builddir) && pwd` \
+	  && $(am__cd) $(top_srcdir) \
+	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
+
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
+	case "$(srcdir)" in \
+	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+	  *) sdir=$(subdir)/$(srcdir) ;; \
+	esac; \
+	for i in $$list; do \
+	  if test -f "$$i"; then \
+	    echo "$(subdir)/$$i"; \
+	  else \
+	    echo "$$sdir/$$i"; \
+	  fi; \
+	done >> $(top_builddir)/cscope.files
 
+distclean-tags:
+	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -418,7 +578,7 @@ distdir: $(DISTFILES)
 	done
 check-am: all-am
 check: check-am
-all-am: Makefile $(DATA)
+all-am: Makefile $(PROGRAMS) $(DATA)
 installdirs:
 install: install-am
 install-exec: install-exec-am
@@ -442,6 +602,7 @@ install-strip:
 mostlyclean-generic:
 
 clean-generic:
+	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
 
 distclean-generic:
 	-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
@@ -453,11 +614,14 @@ maintainer-clean-generic:
 	-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
 clean: clean-am
 
-clean-am: clean-generic clean-libtool mostlyclean-am
+clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \
+	mostlyclean-am
 
 distclean: distclean-am
+	-rm -rf ./$(DEPDIR)
 	-rm -f Makefile
-distclean-am: clean-am distclean-generic
+distclean-am: clean-am distclean-compile distclean-generic \
+	distclean-tags
 
 dvi: dvi-am
 
@@ -500,12 +664,14 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
+	-rm -rf ./$(DEPDIR)
 	-rm -f Makefile
 maintainer-clean-am: distclean-am maintainer-clean-generic
 
 mostlyclean: mostlyclean-am
 
-mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+	mostlyclean-libtool
 
 pdf: pdf-am
 
@@ -519,17 +685,19 @@ uninstall-am:
 
 .MAKE: install-am install-strip
 
-.PHONY: all all-am check check-am clean clean-generic clean-libtool \
-	cscopelist-am ctags-am distclean distclean-generic \
-	distclean-libtool distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-html \
-	install-html-am install-info install-info-am install-man \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	maintainer-clean maintainer-clean-generic mostlyclean \
+.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
+	clean-libtool clean-noinstPROGRAMS cscopelist-am ctags \
+	ctags-am distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am install-info \
+	install-info-am install-man install-pdf install-pdf-am \
+	install-ps install-ps-am install-strip installcheck \
+	installcheck-am installdirs maintainer-clean \
+	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
-	tags-am uninstall uninstall-am
+	tags tags-am uninstall uninstall-am
 
 .PRECIOUS: Makefile
 
@@ -539,6 +707,27 @@ uninstall-am:
 .asy.pdf:
 	- at ASY@ -config "" -render=0 -f pdf -noprc -o $@ $<
 
+sirius.stamp: sirius
+	cd $(builddir) && ./sirius
+
+$(SIRIUSFILES): sirius.stamp
+	@if test -f $@; then :; else \
+		trap 'rm -rf sirius.lock sirius.stamp' 1 2 13 15; \
+		if mkdir sirius.lock 2>/dev/null; then \
+			rm -f sirius.stamp; \
+			$(MAKE) $(AM_MAKEFLAGS) sirius.stamp; \
+		else \
+			while test -d sirius.lock; do sleep 1; done; \
+			test -f sirius.stamp; exit $$?; \
+		fi; \
+	fi
+
+# Support for GNU Flymake, in Emacs.
+
+check-syntax: AM_CFLAGS += -fsyntax-only -pipe
+check-syntax:
+	test -z "$(CHK_SOURCES)" || $(COMPILE) $(CHK_SOURCES)
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
diff --git a/Documentation/figures/crystal.png b/Documentation/figures/crystal.png
index 59d0faa..c720a20 100644
Binary files a/Documentation/figures/crystal.png and b/Documentation/figures/crystal.png differ
diff --git a/Documentation/figures/e2k_1.png b/Documentation/figures/e2k_1.png
index 819d94d..3f561b2 100644
Binary files a/Documentation/figures/e2k_1.png and b/Documentation/figures/e2k_1.png differ
diff --git a/Documentation/figures/e2k_2.png b/Documentation/figures/e2k_2.png
index 519bfd7..7251c3c 100644
Binary files a/Documentation/figures/e2k_2.png and b/Documentation/figures/e2k_2.png differ
diff --git a/Documentation/figures/e2k_3.png b/Documentation/figures/e2k_3.png
index 8bcaaa4..c573c99 100644
Binary files a/Documentation/figures/e2k_3.png and b/Documentation/figures/e2k_3.png differ
diff --git a/Documentation/figures/e2k_4.png b/Documentation/figures/e2k_4.png
index 9d48ebb..ba88892 100644
Binary files a/Documentation/figures/e2k_4.png and b/Documentation/figures/e2k_4.png differ
diff --git a/Documentation/figures/k4cv.png b/Documentation/figures/k4cv.png
index 46f6746..7704f16 100644
Binary files a/Documentation/figures/k4cv.png and b/Documentation/figures/k4cv.png differ
diff --git a/Documentation/figures/k6c.png b/Documentation/figures/k6c.png
index e074223..1029b43 100644
Binary files a/Documentation/figures/k6c.png and b/Documentation/figures/k6c.png differ
diff --git a/Documentation/figures/m1-101.dat b/Documentation/figures/m1-101.dat
new file mode 100644
index 0000000..b9761a1
--- /dev/null
+++ b/Documentation/figures/m1-101.dat
@@ -0,0 +1,103 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.795148837723552  134.088340521547394 -55.578087980042497 -0.022336900000000  14.824478552849410
+0.000000 0.000000 1.049505 -0.519320200000000  41.162927817486029  134.090501606362437 -55.567541326156281 -0.022336900000000  15.562801325953199
+0.000000 0.000000 1.099010 -0.519320200000000  41.531593227586733  134.091785622984872 -55.559521606340653 -0.022336900000000  16.301774869400464
+0.000000 0.000000 1.148515 -0.519320200000000  41.901086207380260  134.092309868773839 -55.552260600258755 -0.022336900000000  17.041431537715610
+0.000000 0.000000 1.198020 -0.519320200000000  42.271362938674514  134.092168497861906 -55.545661168587955 -0.022336900000000  17.781804141490330
+0.000000 0.000000 1.247525 -0.519320200000000  42.642389280064464  134.091440743675946 -55.539641520213969 -0.022336900000000  18.522925768941228
+0.000000 0.000000 1.297030 -0.519320200000000  43.014138958241922  134.090193761488251 -55.534132283904107 -0.022336900000000  19.264829800524737
+0.000000 0.000000 1.346535 -0.519320200000000  43.386592159215553  134.088484844662162 -55.529074171727899 -0.022336900000000  20.007549923894963
+0.000000 0.000000 1.396040 -0.519320200000000  43.759734419630838  134.086363171611765 -55.524416226134598 -0.022336900000000  20.751120149081245
+0.000000 0.000000 1.445545 -0.519320200000000  44.133555748006358  134.083871192735302 -55.520114366056013 -0.022336900000000  21.495574824107685
+0.000000 0.000000 1.495050 -0.519320200000000  44.508049921657388  134.081045742829218 -55.516130225791542 -0.022336900000000  22.240948650904578
+0.000000 0.000000 1.544554 -0.519320200000000  44.883213919814573  134.077918940516668 -55.512430283500727 -0.022336900000000  22.987276701641672
+0.000000 0.000000 1.594059 -0.519320200000000  45.259047464982231  134.074518918773151 -55.508985074745716 -0.022336900000000  23.734594435498039
+0.000000 0.000000 1.643564 -0.519320200000000  45.635552647485198  134.070870425413005 -55.505768578752495 -0.022336900000000  24.482937715816131
+0.000000 0.000000 1.693069 -0.519320200000000  46.012733618898558  134.066995316397566 -55.502757712153631 -0.022336900000000  25.232342827832756
+0.000000 0.000000 1.742574 -0.519320200000000  46.390596338127537  134.062912967023010 -55.499931935472070 -0.022336900000000  25.982846496792639
+0.000000 0.000000 1.792079 -0.519320200000000  46.769148362015414  134.058640613898518 -55.497272858599587 -0.022336900000000  26.734485906689144
+0.000000 0.000000 1.841584 -0.519320200000000  47.148398671510577  134.054193641840385 -55.494763993668229 -0.022336900000000  27.487298719516325
+0.000000 0.000000 1.891089 -0.519320200000000  47.528357526422461  134.049585826324915 -55.492390468376996 -0.022336900000000  28.241323095109347
+0.000000 0.000000 1.940594 -0.519320200000000  47.909036344527522  134.044829538552591 -55.490138837299305 -0.022336900000000  28.996597711642369
+0.000000 0.000000 1.990099 -0.519320200000000  48.290447600706351  134.039935919625378 -55.487996907245517 -0.022336900000000  29.753161786780758
+0.000000 0.000000 2.039604 -0.519320200000000  48.672604742041301  134.034915030190888 -55.485953565546929 -0.022336900000000  30.511055099432234
+0.000000 0.000000 2.089109 -0.519320200000000  49.055522117603658  134.029775977911669 -55.483998667698970 -0.022336900000000  31.270318012395446
+0.000000 0.000000 2.138614 -0.519320200000000  49.439214919459729  134.024527027833244 -55.482122910217470 -0.022336900000000  32.030991495623155
+0.000000 0.000000 2.188119 -0.519320200000000  49.823699133750644  134.019175697673234 -55.480317752925927 -0.022336900000000  32.793117150386770
+0.000000 0.000000 2.237624 -0.519320200000000  50.208991500438380  134.013728840293169 -55.478575312145480 -0.022336900000000  33.556737234267530
+0.000000 0.000000 2.287129 -0.519320200000000  50.595109480165107  134.008192715653536 -55.476888297007598 -0.022336900000000  34.321894687026543
+0.000000 0.000000 2.336634 -0.519320200000000  50.982071227428435  134.002573053730487 -55.475249956196912 -0.022336900000000  35.088633157458155
+0.000000 0.000000 2.386139 -0.519320200000000  51.369895569556540  133.996875109073983 -55.473654000473623 -0.022336900000000  35.856997031217659
+0.000000 0.000000 2.435644 -0.519320200000000  51.758601990011940  133.991103709501914 -55.472094568507671 -0.022336900000000  36.627031459726865
+0.000000 0.000000 2.485149 -0.519320200000000  52.148210616349971  133.985263298303948 -55.470566176261826 -0.022336900000000  37.398782390155368
+0.000000 0.000000 2.534653 -0.519320200000000  52.538742211774377  133.979357971809293 -55.469063683919728 -0.022336900000000  38.172296596601484
+0.000000 0.000000 2.584158 -0.519320200000000  52.930218170017966  133.973391512684515 -55.467582254706976 -0.022336900000000  38.947621712509353
+0.000000 0.000000 2.633663 -0.519320200000000  53.322660513376313  133.967367419325853 -55.466117332383661 -0.022336900000000  39.724806264361888
+0.000000 0.000000 2.683168 -0.519320200000000  53.716091893514822  133.961288932030641 -55.464664607676028 -0.022336900000000  40.503899706790314
+0.000000 0.000000 2.732673 -0.519320200000000  54.110535594683853  133.955159056483410 -55.463219997047453 -0.022336900000000  41.284952459102307
+0.000000 0.000000 2.782178 -0.519320200000000  54.506015539492175  133.948980584485525 -55.461779622065215 -0.022336900000000  42.068015943358155
+0.000000 0.000000 2.831683 -0.519320200000000  54.902556296752358  133.942756112712601 -55.460339786547728 -0.022336900000000  42.853142624086011
+0.000000 0.000000 2.881188 -0.519320200000000  55.300183091494446  133.936488059417371 -55.458896962135384 -0.022336900000000  43.640386049691976
+0.000000 0.000000 2.930693 -0.519320200000000  55.698921816872243  133.930178679578603 -55.457447770302132 -0.022336900000000  44.429800895691123
+0.000000 0.000000 2.980198 -0.519320200000000  56.098799048124938  133.923830078373612 -55.455988969536911 -0.022336900000000  45.221443009853076
+0.000000 0.000000 3.029703 -0.519320200000000  56.499842058405896  133.917444223293131 -55.454517443236924 -0.022336900000000  46.015369459409023
+0.000000 0.000000 3.079208 -0.519320200000000  56.902078836106220  133.911022955600686 -55.453030184694590 -0.022336900000000  46.811638580352856
+0.000000 0.000000 3.128713 -0.519320200000000  57.305538104620005  133.904567999796257 -55.451524288678854 -0.022336900000000  47.610310029099942
+0.000000 0.000000 3.178218 -0.519320200000000  57.710249343247675  133.898080973130448 -55.449996941901581 -0.022336900000000  48.411444836486240
+0.000000 0.000000 3.227723 -0.519320200000000  58.116242810440355  133.891563393543834 -55.448445411845512 -0.022336900000000  49.215105464407678
+0.000000 0.000000 3.277228 -0.519320200000000  58.523549568502432  133.885016687379533 -55.446867040834057 -0.022336900000000  50.021355865117251
+0.000000 0.000000 3.326733 -0.519320200000000  58.932201510472318  133.878442195992733 -55.445259236574714 -0.022336900000000  50.830261543459585
+0.000000 0.000000 3.376238 -0.519320200000000  59.342231388714943  133.871841182091174 -55.443619466001607 -0.022336900000000  51.641889622155162
+0.000000 0.000000 3.425743 -0.519320200000000  59.753672845530872  133.865214835447148 -55.441945248925570 -0.022336900000000  52.456308910354046
+0.000000 0.000000 3.475248 -0.519320200000000  60.166560445936902  133.858564277967531 -55.440234152520596 -0.022336900000000  53.273589975689546
+0.000000 0.000000 3.524752 -0.519320200000000  60.580929712363456  133.851890568622906 -55.438483780717746 -0.022336900000000  54.093805219975359
+0.000000 0.000000 3.574257 -0.519320200000000  60.996817161840177  133.845194707614041 -55.436691777686931 -0.022336900000000  54.917028958926274
+0.000000 0.000000 3.623762 -0.519320200000000  61.414260345253389  133.838477640527003 -55.434855815151423 -0.022336900000000  55.743337505994234
+0.000000 0.000000 3.673267 -0.519320200000000  61.833297889245117  133.831740261926598 -55.432973589839847 -0.022336900000000  56.572809260763030
+0.000000 0.000000 3.722772 -0.519320200000000  62.253969540519279  133.824983418872279 -55.431042821814877 -0.022336900000000  57.405524802073337
+0.000000 0.000000 3.772277 -0.519320200000000  62.676316213095888  133.818207913861414 -55.429061245418225 -0.022336900000000  58.241566986290792
+0.000000 0.000000 3.821782 -0.519320200000000  63.100380038255935  133.811414507819961 -55.427026608310179 -0.022336900000000  59.081021051035883
+0.000000 0.000000 3.871287 -0.519320200000000  63.526204417644166  133.804603922722009 -55.424936668953073 -0.022336900000000  59.923974724749229
+0.000000 0.000000 3.920792 -0.519320200000000  63.953834079594266  133.797776844092937 -55.422789186902328 -0.022336900000000  60.770518342539312
+0.000000 0.000000 3.970297 -0.519320200000000  64.383315138954771  133.790933923267914 -55.420581925850811 -0.022336900000000  61.620744968726946
+0.000000 0.000000 4.019802 -0.519320200000000  64.814695160662765  133.784075779413769 -55.418312645439237 -0.022336900000000  62.474750526599514
+0.000000 0.000000 4.069307 -0.519320200000000  65.248023227158782  133.777203001620450 -55.415979101338955 -0.022336900000000  63.332633935895196
+0.000000 0.000000 4.118812 -0.519320200000000  65.683350010207008  133.770316150563076 -55.413579036291345 -0.022336900000000  64.194497258594339
+0.000000 0.000000 4.168317 -0.519320200000000  66.120727847069631  133.763415760357447 -55.411110182004421 -0.022336900000000  65.060445853638711
+0.000000 0.000000 4.217822 -0.519320200000000  66.560210821826402  133.756502339906149 -55.408570257894020 -0.022336900000000  65.930588541285800
+0.000000 0.000000 4.267327 -0.519320200000000  67.001854851629886  133.749576374594625 -55.405956955690144 -0.022336900000000  66.805037777815429
+0.000000 0.000000 4.316832 -0.519320200000000  67.445717778929918  133.742638327441995 -55.403267949425036 -0.022336900000000  67.683909841420473
+0.000000 0.000000 4.366337 -0.519320200000000  67.891859469564565  133.735688640484057 -55.400500885946435 -0.022336900000000  68.567325030192606
+0.000000 0.000000 4.415842 -0.519320200000000  68.340341917557751  133.728727735893898 -55.397653380916815 -0.022336900000000  69.455407873138327
+0.000000 0.000000 4.465347 -0.519320200000000  68.791229356975236  133.721756017113307 -55.394723016185004 -0.022336900000000  70.348287355335287
+0.000000 0.000000 4.514851 -0.519320200000000  69.244588381493585  133.714773869883714 -55.391707336670343 -0.022336900000000  71.246097158405107
+0.000000 0.000000 4.564356 -0.519320200000000  69.700488072370348  133.707781663130021 -55.388603847354361 -0.022336900000000  72.148975917576109
+0.000000 0.000000 4.613861 -0.519320200000000  70.159000135320696  133.700779750007683 -55.385410006131572 -0.022336900000000  73.057067496781798
+0.000000 0.000000 4.663366 -0.519320200000000  70.620199047447485  133.693768468576792 -55.382123221435016 -0.022336900000000  73.970521283387086
+0.000000 0.000000 4.712871 -0.519320200000000  71.084162214684355  133.686748142719750 -55.378740851769841 -0.022336900000000  74.889492504242583
+0.000000 0.000000 4.762376 -0.519320200000000  71.550970141039173  133.679719082796510 -55.375260194897777 -0.022336900000000  75.814142565021328
+0.000000 0.000000 4.811881 -0.519320200000000  72.020706610498053  133.672681586392173 -55.371678485976112 -0.022336900000000  76.744639414980895
+0.000000 0.000000 4.861386 -0.519320200000000  72.493458882893847  133.665635938946110 -55.367992895743363 -0.022336900000000  77.681157939496927
+0.000000 0.000000 4.910891 -0.519320200000000  72.969317904978411  133.658582414361604 -55.364200519476704 -0.022336900000000  78.623880383008341
+0.000000 0.000000 4.960396 -0.519320200000000  73.448378538206811  133.651521275600032 -55.360298377549675 -0.022336900000000  79.572996805332579
+0.000000 0.000000 5.009901 -0.519320200000000  73.930739804886301  133.644452775175523 -55.356283404396187 -0.022336900000000  80.528705574597637
+0.000000 0.000000 5.059406 -0.519320200000000  74.416505154432684  133.637377155709515 -55.352152447182974 -0.022336900000000  81.491213900471976
+0.000000 0.000000 5.108911 -0.519320200000000  74.905782751882413  133.630294650403528 -55.347902254712139 -0.022336900000000  82.460738411794864
+0.000000 0.000000 5.158416 -0.519320200000000  75.398685790923295  133.623205483481343 -55.343529473830586 -0.022336900000000  83.437505783194936
+0.000000 0.000000 5.207921 -0.519320200000000  75.895332834020152  133.616109870627980 -55.339030640498635 -0.022336900000000  84.421753415915830
+0.000000 0.000000 5.257426 -0.519320200000000  76.395848182607210  133.609008019338660 -55.334402171345303 -0.022336900000000  85.413730178641970
+0.000000 0.000000 5.306931 -0.519320200000000  76.900362280513875  133.601900129412456 -55.329640355507031 -0.022336900000000  86.413697214981127
+0.000000 0.000000 5.356436 -0.519320200000000  77.409012154585341  133.594786393183426 -55.324741345422396 -0.022336900000000  87.421928825006646
+0.000000 0.000000 5.405941 -0.519320200000000  77.921941896491376  133.587666995955914 -55.319701145744666 -0.022336900000000  88.438713429429541
+0.000000 0.000000 5.455446 -0.519320200000000  78.439303190769024  133.580542116229481 -55.314515602769511 -0.022336900000000  89.464354625975361
+0.000000 0.000000 5.504950 -0.519320200000000  78.961255894370694  133.573411926149021 -55.309180391158485 -0.022336900000000  90.499172349051193
+0.000000 0.000000 5.554455 -0.519320200000000  79.487968674354306  133.566276591608727 -55.303691003464984 -0.022336900000000  91.543504145267093
+0.000000 0.000000 5.603960 -0.519320200000000  80.019619710555119  133.559136272663039 -55.298042731511970 -0.022336900000000  92.597706579301899
+0.000000 0.000000 5.653465 -0.519320200000000  80.556397471879052  133.551991123756125 -55.292230653645802 -0.022336900000000  93.662156786780116
+0.000000 0.000000 5.702970 -0.519320200000000  81.098501575717762  133.544841293904767 -55.286249615405161 -0.022336900000000  94.737254193349145
+0.000000 0.000000 5.752475 -0.519320200000000  81.646143741556315  133.537686927000379 -55.280094211081014 -0.022336900000000  95.823422422265040
+0.000000 0.000000 5.801980 -0.519320200000000  82.199548851811130  133.530528162016566 -55.273758761097163 -0.022336900000000  96.921111416349760
+0.000000 0.000000 5.851485 -0.519320200000000  82.758956135014273  133.523365133130596 -55.267237289777633 -0.022336900000000  98.030799804502919
+0.000000 0.000000 5.900990 -0.519320200000000  83.324620488796327  133.516197970083510 -55.260523496923803 -0.022336900000000  99.152997548139794
+0.000000 0.000000 5.950495 -0.519320200000000  83.896813963785448  133.509026798239631 -55.253610728358929 -0.022336900000000  100.288248909058183
+0.000000 0.000000 6.000000 -0.519320200000000  84.475827432648728  133.501851738786627 -55.246491944180782 -0.022336900000000  101.437135787779098
\ No newline at end of file
diff --git a/Documentation/figures/m1-11.dat b/Documentation/figures/m1-11.dat
new file mode 100644
index 0000000..aa10743
--- /dev/null
+++ b/Documentation/figures/m1-11.dat
@@ -0,0 +1,13 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.795148837723552  134.088340521547394 -55.578087980042497 -0.022336900000000  14.824478552849410
+0.000000 0.000000 1.454545 -0.519320200000000  43.806822757215407  134.699173262003058  124.898718475162639 -0.022336900000000  21.631027888318709
+0.000000 0.000000 1.909091 -0.519320200000000  47.272270521383987  134.663292943082951  124.916656492736763 -0.022336900000000  28.515821774043257
+0.000000 0.000000 2.363636 -0.519320200000000  50.799541156706113  134.614380653440122  124.961695704616673 -0.022336900000000  35.507536366647059
+0.000000 0.000000 2.818182 -0.519320200000000  54.400871058610306  134.558783263226246  125.018919292316852 -0.022336900000000  42.638809595919270
+0.000000 0.000000 3.272727 -0.519320200000000  58.486466730581547  133.885612866783788 -55.446989013663412 -0.022336900000000  49.947951730547082
+0.000000 0.000000 3.727273 -0.519320200000000  61.900019187608201  134.437430128115551  125.143770189795163 -0.022336900000000  57.481389921508409
+0.000000 0.000000 4.181818 -0.519320200000000  66.240375731726161  133.761531531134239 -55.410317546243355 -0.022336900000000  65.297336845715279
+0.000000 0.000000 4.636364 -0.519320200000000  69.977235278457528  134.309331314804496  125.259816130711542 -0.022336900000000  73.471599845445795
+0.000000 0.000000 5.090909 -0.519320200000000  74.727450269522620  133.632870840991842 -55.349454108023657 -0.022336900000000  82.107358205505179
+0.000000 0.000000 5.545455 -0.519320200000000  79.002012485552598  134.177964670421204  125.347572178779672 -0.022336900000000  91.352902210421746
+0.000000 0.000000 6.000000 -0.519320200000000  84.475827513796219  133.501851715647120 -55.246517777093253 -0.022336900000000  101.437135910962581
\ No newline at end of file
diff --git a/Documentation/figures/m2-101.dat b/Documentation/figures/m2-101.dat
new file mode 100644
index 0000000..38bbef3
--- /dev/null
+++ b/Documentation/figures/m2-101.dat
@@ -0,0 +1,103 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.400329236644197  134.704182457760055  124.948883370711130 -0.022336900000000  14.824478351069212
+0.000000 0.000000 1.049505 -0.519320200000000  40.768091717727891  134.706359702627083  124.937616263670648 -0.022336900000000  15.562801324231163
+0.000000 0.000000 1.099010 -0.519320200000000  41.136743458042275  134.707659256470151  124.927942900053353 -0.022336900000000  16.301774870111238
+0.000000 0.000000 1.148515 -0.519320200000000  41.506230350975692  134.708190640309368  124.920007658730114 -0.022336900000000  17.041431540414870
+0.000000 0.000000 1.198020 -0.519320200000000  41.876507620818174  134.708049077776906  124.913592033865314 -0.022336900000000  17.781804145828875
+0.000000 0.000000 1.247525 -0.519320200000000  42.247540324497315  134.707314695536411  124.908512076211267 -0.022336900000000  18.522925774655075
+0.000000 0.000000 1.297030 -0.519320200000000  42.619301511185569  134.706055402623008  124.904611808914268 -0.022336900000000  19.264829807409075
+0.000000 0.000000 1.346535 -0.519320200000000  42.991770790385168  134.704329132977165  124.901758070916415 -0.022336900000000  20.007549931760948
+0.000000 0.000000 1.396040 -0.519320200000000  43.364933205530861  134.702185612108707  124.899836473097054 -0.022336900000000  20.751120157785124
+0.000000 0.000000 1.445545 -0.519320200000000  43.738778340013162  134.699667761625221  124.898748185916730 -0.022336900000000  21.495574833533713
+0.000000 0.000000 1.495050 -0.519320200000000  44.113299602958364  134.696812824030332  124.898407355249788 -0.022336900000000  22.240948660971945
+0.000000 0.000000 1.544554 -0.519320200000000  44.488493653216139  134.693653272317391  124.898739019200974 -0.022336900000000  22.987276712271413
+0.000000 0.000000 1.594059 -0.519320200000000  44.864359932709455  134.690217549724792  124.899677416769407 -0.022336900000000  23.734594446613137
+0.000000 0.000000 1.643564 -0.519320200000000  45.240900285720855  134.686530675797172  124.901164611627721 -0.022336900000000  24.482937727380651
+0.000000 0.000000 1.693069 -0.519320200000000  45.618118646338118  134.682614746704388  124.903149335335854 -0.022336900000000  25.232342839798360
+0.000000 0.000000 1.742574 -0.519320200000000  45.996020780950623  134.678489350195491  124.905586040600070 -0.022336900000000  25.982846509122627
+0.000000 0.000000 1.792079 -0.519320200000000  46.374614075400778  134.674171911482148  124.908434108375289 -0.022336900000000  26.734485919345456
+0.000000 0.000000 1.841584 -0.519320200000000  46.753907357989661  134.669677983697881  124.911657196384397 -0.022336900000000  27.487298732482031
+0.000000 0.000000 1.891089 -0.519320200000000  47.133910751946807  134.665021492887917  124.915222663442279 -0.022336900000000  28.241323108361122
+0.000000 0.000000 1.940594 -0.519320200000000  47.514635552491612  134.660214945294399  124.919101105138367 -0.022336900000000  28.996597725175405
+0.000000 0.000000 1.990099 -0.519320200000000  47.896094124108608  134.655269603620241  124.923265941552984 -0.022336900000000  29.753161800564556
+0.000000 0.000000 2.039604 -0.519320200000000  48.278299814337906  134.650195638155026  124.927693092295115 -0.022336900000000  30.511055113470164
+0.000000 0.000000 2.089109 -0.519320200000000  48.661266882081478  134.645002255831400  124.932360652284999 -0.022336900000000  31.270318026669447
+0.000000 0.000000 2.138614 -0.519320200000000  49.045010437627603  134.639697811740831  124.937248660169644 -0.022336900000000  32.030991510130185
+0.000000 0.000000 2.188119 -0.519320200000000  49.429546392776608  134.634289905410014  124.942338868764864 -0.022336900000000  32.793117165125388
+0.000000 0.000000 2.237624 -0.519320200000000  49.814891419689715  134.628785464326427  124.947614551333146 -0.022336900000000  33.556737249230693
+0.000000 0.000000 2.287129 -0.519320200000000  50.201062917075383  134.623190816613857  124.953060344637933 -0.022336900000000  34.321894702208262
+0.000000 0.000000 2.336634 -0.519320200000000  50.588078982843392  134.617511754489072  124.958662095239717 -0.022336900000000  35.088633172860433
+0.000000 0.000000 2.386139 -0.519320200000000  50.975958392326170  134.611753589727329  124.964406735943612 -0.022336900000000  35.856997046840185
+0.000000 0.000000 2.435644 -0.519320200000000  51.364720581250936  134.605921202658976  124.970282175513674 -0.022336900000000  36.627031475565893
+0.000000 0.000000 2.485149 -0.519320200000000  51.754385633292159  134.600019084826585  124.976277195687317 -0.022336900000000  37.398782406213599
+0.000000 0.000000 2.534653 -0.519320200000000  52.144974271102576  134.594051377198326  124.982381366997416 -0.022336900000000  38.172296612886718
+0.000000 0.000000 2.584158 -0.519320200000000  52.536507851023998  134.588021903553624  124.988584975441597 -0.022336900000000  38.947621729017449
+0.000000 0.000000 2.633663 -0.519320200000000  52.929008360789645  134.581934200309149  124.994878945693003 -0.022336900000000  39.724806281103341
+0.000000 0.000000 2.683168 -0.519320200000000  53.322498419939578  134.575791543123785  125.001254784265299 -0.022336900000000  40.503899723760711
+0.000000 0.000000 2.732673 -0.519320200000000  53.717001283076641  134.569596970264371  125.007704534681054 -0.022336900000000  41.284952476307105
+0.000000 0.000000 2.782178 -0.519320200000000  54.112540845136699  134.563353304008700  125.014220709473861 -0.022336900000000  42.068015960799301
+0.000000 0.000000 2.831683 -0.519320200000000  54.509141649258005  134.557063169266826  125.020796262600740 -0.022336900000000  42.853142641774710
+0.000000 0.000000 2.881188 -0.519320200000000  54.906828896510568  134.550729010661769  125.027424543585781 -0.022336900000000  43.640386067629656
+0.000000 0.000000 2.930693 -0.519320200000000  55.305628457738507  134.544353107726437  125.034099265393550 -0.022336900000000  44.429800913882815
+0.000000 0.000000 2.980198 -0.519320200000000  55.705566887360398  134.537937588534021  125.040814468799155 -0.022336900000000  45.221443028309608
+0.000000 0.000000 3.029703 -0.519320200000000  56.106671438931656  134.531484442189537  125.047564494312866 -0.022336900000000  46.015369478132492
+0.000000 0.000000 3.079208 -0.519320200000000  56.508970082681003  134.524995529916083  125.054343961832174 -0.022336900000000  46.811638599349422
+0.000000 0.000000 3.128713 -0.519320200000000  56.912491524853017  134.518472595116833  125.061147737329350 -0.022336900000000  47.610310048378302
+0.000000 0.000000 3.178218 -0.519320200000000  57.317265228730385  134.511917272681757  125.067970922445227 -0.022336900000000  48.411444856056960
+0.000000 0.000000 3.227723 -0.519320200000000  57.723321437637125  134.505331097227014  125.074808823615555 -0.022336900000000  49.215105484271355
+0.000000 0.000000 3.277228 -0.519320200000000  58.130691199785836  134.498715510600988  125.081656940648784 -0.022336900000000  50.021355885289424
+0.000000 0.000000 3.326733 -0.519320200000000  58.539406394826031  134.492071868935341  125.088510951492594 -0.022336900000000  50.830261563947488
+0.000000 0.000000 3.376238 -0.519320200000000  58.949499762557039  134.485401448792459  125.095366692982793 -0.022336900000000  51.641889642964180
+0.000000 0.000000 3.425743 -0.519320200000000  59.361004933454886  134.478705452984286  125.102220149282900 -0.022336900000000  52.456308931498988
+0.000000 0.000000 3.475248 -0.519320200000000  59.773956461337967  134.471985015770144  125.109067436398519 -0.022336900000000  53.273589997174597
+0.000000 0.000000 3.524752 -0.519320200000000  60.188389858113261  134.465241207733385  125.115904795609836 -0.022336900000000  54.093805241816447
+0.000000 0.000000 3.574257 -0.519320200000000  60.604341630785257  134.458475040145146  125.122728575243315 -0.022336900000000  54.917028981128134
+0.000000 0.000000 3.623762 -0.519320200000000  61.021849320817054  134.451687469007084  125.129535228519089 -0.022336900000000  55.743337528572653
+0.000000 0.000000 3.673267 -0.519320200000000  61.440951545880459  134.444879398799571  125.136321298402294 -0.022336900000000  56.572809283728169
+0.000000 0.000000 3.722772 -0.519320200000000  61.861688044242420  134.438051685895289  125.143083408123772 -0.022336900000000  57.405524825440004
+0.000000 0.000000 3.772277 -0.519320200000000  62.284099721848655  134.431205141728071  125.149818258667864 -0.022336900000000  58.241567010071662
+0.000000 0.000000 3.821782 -0.519320200000000  62.708228702348549  134.424340535673139  125.156522614546148 -0.022336900000000  59.081021075245133
+0.000000 0.000000 3.871287 -0.519320200000000  63.134118380114124  134.417458597767791  125.163193301002508 -0.022336900000000  59.923974749401047
+0.000000 0.000000 3.920792 -0.519320200000000  63.561813476600634  134.410560021148854  125.169827194391459 -0.022336900000000  60.770518367648393
+0.000000 0.000000 3.970297 -0.519320200000000  63.991360100098717  134.403645464415405  125.176421214976003 -0.022336900000000  61.620744994306833
+0.000000 0.000000 4.019802 -0.519320200000000  64.422805809287908  134.396715553691791  125.182972325289114 -0.022336900000000  62.474750552671054
+0.000000 0.000000 4.069307 -0.519320200000000  64.856199680663295  134.389770884655405  125.189477518710163 -0.022336900000000  63.332633962475903
+0.000000 0.000000 4.118812 -0.519320200000000  65.291592380285351  134.382812024332452  125.195933813848526 -0.022336900000000  64.194497285699924
+0.000000 0.000000 4.168317 -0.519320200000000  65.729036240041594  134.375839512798706  125.202338256513727 -0.022336900000000  65.060445881289610
+0.000000 0.000000 4.217822 -0.519320200000000  66.168585338793477  134.368853864779396  125.208687902058713 -0.022336900000000  65.930588569503172
+0.000000 0.000000 4.267327 -0.519320200000000  66.610295588792638  134.361855571107753  125.214979822132563 -0.022336900000000  66.805037806620263
+0.000000 0.000000 4.316832 -0.519320200000000  67.054224827744235  134.354845100094394  125.221211088702233 -0.022336900000000  67.683909870834540
+0.000000 0.000000 4.366337 -0.519320200000000  67.500432916982618  134.347822898798029  125.227378779523789 -0.022336900000000  68.567325060242425
+0.000000 0.000000 4.415842 -0.519320200000000  67.948981846199047  134.340789394232360  125.233479964692577 -0.022336900000000  69.455407903848354
+0.000000 0.000000 4.465347 -0.519320200000000  68.399935845304725  134.333744994487404  125.239511705458554 -0.022336900000000  70.348287386732281
+0.000000 0.000000 4.514851 -0.519320200000000  68.853361504032620  134.326690089707313  125.245471047832950 -0.022336900000000  71.246097190516195
+0.000000 0.000000 4.564356 -0.519320200000000  69.309327899808466  134.319625053121200  125.251355020696565 -0.022336900000000  72.148975950431137
+0.000000 0.000000 4.613861 -0.519320200000000  69.767906734707267  134.312550241958917  125.257160624785087 -0.022336900000000  73.057067530412041
+0.000000 0.000000 4.663366 -0.519320200000000  70.229172482336409  134.305465998208575  125.262884834921024 -0.022336900000000  73.970521317830290
+0.000000 0.000000 4.712871 -0.519320200000000  70.693202545239458  134.298372649562538  125.268524588080680 -0.022336900000000  74.889492539530181
+0.000000 0.000000 4.762376 -0.519320200000000  71.160077424190504  134.291270510025015  125.274076781301915 -0.022336900000000  75.814142601193396
+0.000000 0.000000 4.811881 -0.519320200000000  71.629880900070660  134.284159880680591  125.279538267443144 -0.022336900000000  76.744639452079952
+0.000000 0.000000 4.861386 -0.519320200000000  72.102700229711232  134.277041050350022  125.284905846364381 -0.022336900000000  77.681157977564155
+0.000000 0.000000 4.910891 -0.519320200000000  72.578626356975121  134.269914296212193  125.290176261800312 -0.022336900000000  78.623880422090863
+0.000000 0.000000 4.960396 -0.519320200000000  73.057754140558231  134.262779884336908  125.295346192191204 -0.022336900000000  79.572996845476098
+0.000000 0.000000 5.009901 -0.519320200000000  73.540182600072669  134.255638070306276  125.300412247269165 -0.022336900000000  80.528705615856055
+0.000000 0.000000 5.059406 -0.519320200000000  74.026015182351188  134.248489099675709  125.305370959126975 -0.022336900000000  81.491213942904594
+0.000000 0.000000 5.108911 -0.519320200000000  74.515360049950644  134.241333208459281  125.310218776288252 -0.022336900000000  82.460738455458937
+0.000000 0.000000 5.158416 -0.519320200000000  75.008330394136991  134.234170623650442  125.314952056149465 -0.022336900000000  83.437505828155622
+0.000000 0.000000 5.207921 -0.519320200000000  75.505044775070090  134.227001563553358  125.319567054443795 -0.022336900000000  84.421753462239849
+0.000000 0.000000 5.257426 -0.519320200000000  76.005627491928294  134.219826238257326  125.324059920812928 -0.022336900000000  85.413730226409541
+0.000000 0.000000 5.306931 -0.519320200000000  76.510208986381940  134.212644850019956  125.328426685539711 -0.022336900000000  86.413697264267981
+0.000000 0.000000 5.356436 -0.519320200000000  77.018926283173982  134.205457593601011  125.332663253060844 -0.022336900000000  87.421928875901912
+0.000000 0.000000 5.405941 -0.519320200000000  77.531923471947977  134.198264656627572  125.336765387856701 -0.022336900000000  88.438713482026202
+0.000000 0.000000 5.455446 -0.519320200000000  78.049352235261324  134.191066219891638  125.340728704701974 -0.022336900000000  89.464354680376118
+0.000000 0.000000 5.504950 -0.519320200000000  78.571372428188482  134.183862457695142  125.344548657350714 -0.022336900000000  90.499172405364519
+0.000000 0.000000 5.554455 -0.519320200000000  79.098152715924414  134.176653538097241  125.348220521545187 -0.022336900000000  91.543504203612144
+0.000000 0.000000 5.603960 -0.519320200000000  79.629871276525222  134.169439623221479  125.351739383491790 -0.022336900000000  92.597706639812756
+0.000000 0.000000 5.653465 -0.519320200000000  80.166716577161068  134.162220869522173  125.355100121039882 -0.022336900000000  93.662156849594240
+0.000000 0.000000 5.702970 -0.519320200000000  80.708888233547142  134.154997427980589  125.358297386337753 -0.022336900000000  94.737254258622528
+0.000000 0.000000 5.752475 -0.519320200000000  81.256597963536706  134.147769444394157  125.361325588345906 -0.022336900000000  95.823422490170103
+0.000000 0.000000 5.801980 -0.519320200000000  81.810070647971926  134.140537059580311  125.364178866173219 -0.022336900000000  96.921111487069084
+0.000000 0.000000 5.851485 -0.519320200000000  82.369545513832634  134.133300409553357  125.366851070987494 -0.022336900000000  98.030799878246512
+0.000000 0.000000 5.900990 -0.519320200000000  82.935277457254429  134.126059625814378  125.369335733008697 -0.022336900000000  99.152997625129558
+0.000000 0.000000 5.950495 -0.519320200000000  83.507538527436054  134.118814835420579  125.371626036927438 -0.022336900000000  100.288248989548421
+0.000000 0.000000 6.000000 -0.519320200000000  84.086619595623702  134.111566161254785  125.373714785174769 -0.022336900000000  101.437135872050320
\ No newline at end of file
diff --git a/Documentation/figures/m2-11.dat b/Documentation/figures/m2-11.dat
new file mode 100644
index 0000000..fc46f41
--- /dev/null
+++ b/Documentation/figures/m2-11.dat
@@ -0,0 +1,13 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.400329236644197  134.704182457760055  124.948883370711130 -0.022336900000000  14.824478351069212
+0.000000 0.000000 1.454545 -0.519320200000000  43.806823181195078  134.699172673379707  124.898698419486905 -0.022336900000000  21.631027940224062
+0.000000 0.000000 1.909091 -0.519320200000000  47.272270521411770  134.663292943025397  124.916656495771178 -0.022336900000000  28.515821774033888
+0.000000 0.000000 2.363636 -0.519320200000000  50.799541156706340  134.614380653440065  124.961695709155549 -0.022336900000000  35.507536366647649
+0.000000 0.000000 2.818182 -0.519320200000000  54.400871058606626  134.558783263228946  125.018919290059415 -0.022336900000000  42.638809595916634
+0.000000 0.000000 3.272727 -0.519320200000000  58.486466730589271  133.885612866780122 -55.446989014044156 -0.022336900000000  49.947951730555722
+0.000000 0.000000 3.727273 -0.519320200000000  61.900019187608748  134.437430128114784  125.143770187333516 -0.022336900000000  57.481389921508047
+0.000000 0.000000 4.181818 -0.519320200000000  66.240375731739093  133.761531531130856 -55.410317580254272 -0.022336900000000  65.297336845733511
+0.000000 0.000000 4.636364 -0.519320200000000  69.977235278479284  134.309331314767377  125.259816155740268 -0.022336900000000  73.471599845423640
+0.000000 0.000000 5.090909 -0.519320200000000  74.727450269523302  133.632870840991785 -55.349454108434074 -0.022336900000000  82.107358205506344
+0.000000 0.000000 5.545455 -0.519320200000000  79.002012485552456  134.177964670420948  125.347572178555652 -0.022336900000000  91.352902210420979
+0.000000 0.000000 6.000000 -0.519320200000000  84.475827513800724  133.501851715633137 -55.246517777290137 -0.022336900000000  101.437135910950062
\ No newline at end of file
diff --git a/Documentation/figures/med2_3_slits.png b/Documentation/figures/med2_3_slits.png
index d415f89..9725231 100644
Binary files a/Documentation/figures/med2_3_slits.png and b/Documentation/figures/med2_3_slits.png differ
diff --git a/Documentation/figures/qper_qpar.asy b/Documentation/figures/qper_qpar.asy
index ac504a7..4f79fcb 100644
--- a/Documentation/figures/qper_qpar.asy
+++ b/Documentation/figures/qper_qpar.asy
@@ -1,5 +1,8 @@
 import solids;
 
+currentprojection=orthographic(1,0,0);
+currentlight=White;
+
 size(300,0);
 
 real k = 2;
diff --git a/Documentation/figures/qper_qpar.png b/Documentation/figures/qper_qpar.png
index 893d5ca..62426e6 100644
Binary files a/Documentation/figures/qper_qpar.png and b/Documentation/figures/qper_qpar.png differ
diff --git a/Documentation/figures/s1-101.dat b/Documentation/figures/s1-101.dat
new file mode 100644
index 0000000..8554f5d
--- /dev/null
+++ b/Documentation/figures/s1-101.dat
@@ -0,0 +1,103 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.795148837723552  134.088340521547394 -55.578087980042497 -0.022336900000000  14.824478552849410
+0.000000 0.000000 1.049505 -0.519320200000000  41.162930235995610  134.090497816304008 -55.567338357726918 -0.022336900000000  15.562801336307878
+0.000000 0.000000 1.099010 -0.519320200000000  41.531595365406638  134.091782359245343 -55.558677847218348 -0.022336900000000  16.301774976660209
+0.000000 0.000000 1.148515 -0.519320200000000  41.506228636503572  134.708193307272097  124.919430433494568 -0.022336900000000  17.041431506604862
+0.000000 0.000000 1.198020 -0.519320200000000  41.876506235401941  134.708051255797898  124.913611853652085 -0.022336900000000  17.781804143572447
+0.000000 0.000000 1.247525 -0.519320200000000  42.642390631082485  134.091438769299089 -55.540641977741075 -0.022336900000000  18.522925913040577
+0.000000 0.000000 1.297030 -0.519320200000000  43.014139709206276  134.090193192651753 -55.534384935388822 -0.022336900000000  19.264830400984177
+0.000000 0.000000 1.346535 -0.519320200000000  43.386593304043338  134.088483261020315 -55.529046246398160 -0.022336900000000  20.007550148416467
+0.000000 0.000000 1.396040 -0.519320200000000  43.759735178321314  134.086361956176830 -55.525137445393355 -0.022336900000000  20.751120125948109
+0.000000 0.000000 1.445545 -0.519320200000000  44.133557575642094  134.083868662041397 -55.520128537913166 -0.022336900000000  21.495574822081419
+0.000000 0.000000 1.495050 -0.519320200000000  44.508050484586931  134.081045016141957 -55.515621840315191 -0.022336900000000  22.240948896338008
+0.000000 0.000000 1.544554 -0.519320200000000  44.883214401959464  134.077918831582565 -55.512076356158488 -0.022336900000000  22.987277620814297
+0.000000 0.000000 1.594059 -0.519320200000000  44.864359450881892  134.690218295458692  124.899701025551735 -0.022336900000000  23.734594441029198
+0.000000 0.000000 1.643564 -0.519320200000000  45.635553091791920  134.070869713471836 -55.505736643739446 -0.022336900000000  24.482937713279135
+0.000000 0.000000 1.693069 -0.519320200000000  46.012732868177707  134.066994920384190 -55.501746861696006 -0.022336900000000  25.232342879096553
+0.000000 0.000000 1.742574 -0.519320200000000  46.390596439900563  134.062912450633462 -55.499571281696589 -0.022336900000000  25.982846077756516
+0.000000 0.000000 1.792079 -0.519320200000000  46.769147618866540  134.058640206088967 -55.496803513742478 -0.022336900000000  26.734486098443337
+0.000000 0.000000 1.841584 -0.519320200000000  47.148399155214591  134.054193100248852 -55.494870797521152 -0.022336900000000  27.487298963477279
+0.000000 0.000000 1.891089 -0.519320200000000  47.528358716291493  134.049584626053871 -55.492610004798856 -0.022336900000000  28.241323612566362
+0.000000 0.000000 1.940594 -0.519320200000000  47.514635532971845  134.660215238199498  124.919178478115725 -0.022336900000000  28.996598013086256
+0.000000 0.000000 1.990099 -0.519320200000000  47.896093787386526  134.655270135930067  124.923296323063937 -0.022336900000000  29.753161896631969
+0.000000 0.000000 2.039604 -0.519320200000000  48.278299449327079  134.650196038547023  124.927702055012418 -0.022336900000000  30.511054927748233
+0.000000 0.000000 2.089109 -0.519320200000000  48.661266716160696  134.645002583555680  124.932370114911549 -0.022336900000000  31.270318126865533
+0.000000 0.000000 2.138614 -0.519320200000000  49.045010890956213  134.639697954524792  124.937134937352369 -0.022336900000000  32.030992542296673
+0.000000 0.000000 2.188119 -0.519320200000000  49.429546188071377  134.634290216604541  124.942333281899451 -0.022336900000000  32.793117180157687
+0.000000 0.000000 2.237624 -0.519320200000000  50.208991509296396  134.013728575099805 -55.478648564136506 -0.022336900000000  33.556736874607275
+0.000000 0.000000 2.287129 -0.519320200000000  50.595109568243728  134.008192481585155 -55.476885295668453 -0.022336900000000  34.321894555778279
+0.000000 0.000000 2.336634 -0.519320200000000  50.982071342612095  134.002572823097353 -55.475247708735019 -0.022336900000000  35.088633080541165
+0.000000 0.000000 2.386139 -0.519320200000000  51.369895648155321  133.996874907374377 -55.473657505564411 -0.022336900000000  35.856996923928648
+0.000000 0.000000 2.435644 -0.519320200000000  51.758602610218745  133.991103201387659 -55.471992861776826 -0.022336900000000  36.627031910037395
+0.000000 0.000000 2.485149 -0.519320200000000  52.148211567829804  133.985262583924367 -55.470715233849390 -0.022336900000000  37.398783129161352
+0.000000 0.000000 2.534653 -0.519320200000000  52.144974165348280  134.594051559031698  124.982374133813266 -0.022336900000000  38.172296645194052
+0.000000 0.000000 2.584158 -0.519320200000000  52.930218691289994  133.973390058411212 -55.467665400016720 -0.022336900000000  38.947621043374163
+0.000000 0.000000 2.633663 -0.519320200000000  53.322660652064378  133.967367399815259 -55.466289159353316 -0.022336900000000  39.724806109070755
+0.000000 0.000000 2.683168 -0.519320200000000  53.716091996864002  133.961288763510453 -55.464667362500634 -0.022336900000000  40.503899681209525
+0.000000 0.000000 2.732673 -0.519320200000000  54.110535521010917  133.955158946997955 -55.463364702671200 -0.022336900000000  41.284952173243404
+0.000000 0.000000 2.782178 -0.519320200000000  54.112541007277343  134.563353416572369  125.014002526100342 -0.022336900000000  42.068016421386055
+0.000000 0.000000 2.831683 -0.519320200000000  54.902556012481782  133.942756078632300 -55.460740971569628 -0.022336900000000  42.853142027486605
+0.000000 0.000000 2.881188 -0.519320200000000  55.300183195680290  133.936487879112349 -55.458952028653080 -0.022336900000000  43.640385992473057
+0.000000 0.000000 2.930693 -0.519320200000000  55.305628311501174  134.544353221876577  125.034279601274662 -0.022336900000000  44.429800772750291
+0.000000 0.000000 2.980198 -0.519320200000000  56.098799049187200  133.923829950065539 -55.456080051783523 -0.022336900000000  45.221442829408282
+0.000000 0.000000 3.029703 -0.519320200000000  56.499842139750463  133.917444077824427 -55.454523517610184 -0.022336900000000  46.015369412709063
+0.000000 0.000000 3.079208 -0.519320200000000  56.902078912621803  133.911022842067865 -55.453026229224164 -0.022336900000000  46.811638577485510
+0.000000 0.000000 3.128713 -0.519320200000000  56.912491412708732  134.518472813835217  125.060774461522797 -0.022336900000000  47.610310188125055
+0.000000 0.000000 3.178218 -0.519320200000000  57.710249257272707  133.898080882362137 -55.450338155497526 -0.022336900000000  48.411444549626765
+0.000000 0.000000 3.227723 -0.519320200000000  58.116242714745951  133.891563343720406 -55.448627653413340 -0.022336900000000  49.215105234536487
+0.000000 0.000000 3.277228 -0.519320200000000  58.130691130449073  134.498715605270689  125.081664667175843 -0.022336900000000  50.021355877843689
+0.000000 0.000000 3.326733 -0.519320200000000  58.932201493399688  133.878442304927489 -55.445120200728134 -0.022336900000000  50.830261677354322
+0.000000 0.000000 3.376238 -0.519320200000000  59.342231453509825  133.871841080262783 -55.443648345267071 -0.022336900000000  51.641889604080340
+0.000000 0.000000 3.425743 -0.519320200000000  59.361004902514857  134.478705521023016  125.102152470212104 -0.022336900000000  52.456308953161695
+0.000000 0.000000 3.475248 -0.519320200000000  60.166561168310515  133.858563583256910 -55.440117375277204 -0.022336900000000  53.273590297247331
+0.000000 0.000000 3.524752 -0.519320200000000  60.188388825450268  134.465241133419283  125.115270034451697 -0.022336900000000  54.093805349638124
+0.000000 0.000000 3.574257 -0.519320200000000  60.996817357961042  133.845194596624964 -55.436468451480273 -0.022336900000000  54.917029175214651
+0.000000 0.000000 3.623762 -0.519320200000000  61.021849322031471  134.451687525953133  125.129460246102596 -0.022336900000000  55.743337604034473
+0.000000 0.000000 3.673267 -0.519320200000000  61.440950970254782  134.444880977459746  125.136444422431865 -0.022336900000000  56.572809338526412
+0.000000 0.000000 3.722772 -0.519320200000000  62.253969686444414  133.824983279873607 -55.430972979481702 -0.022336900000000  57.405524891411368
+0.000000 0.000000 3.772277 -0.519320200000000  62.284099626528160  134.431205279721610  125.149826665073959 -0.022336900000000  58.241566976812464
+0.000000 0.000000 3.821782 -0.519320200000000  63.100380131853363  133.811414432121353 -55.426918005275240 -0.022336900000000  59.081021133834092
+0.000000 0.000000 3.871287 -0.519320200000000  63.526204508546655  133.804603876504018 -55.424934911812819 -0.022336900000000  59.923974748890579
+0.000000 0.000000 3.920792 -0.519320200000000  63.953834139811860  133.797776781662577 -55.422743361737098 -0.022336900000000  60.770518377880464
+0.000000 0.000000 3.970297 -0.519320200000000  64.383315138963511  133.790933904699500 -55.420586951641084 -0.022336900000000  61.620744958831729
+0.000000 0.000000 4.019802 -0.519320200000000  64.814695671546644  133.784075253085433 -55.418021655208449 -0.022336900000000  62.474750774740663
+0.000000 0.000000 4.069307 -0.519320200000000  65.248023312308803  133.777202912612893 -55.415930927798527 -0.022336900000000  63.332633975468063
+0.000000 0.000000 4.118812 -0.519320200000000  65.683350115858843  133.770316052702299 -55.413528515484138 -0.022336900000000  64.194497290329011
+0.000000 0.000000 4.168317 -0.519320200000000  66.120727921339068  133.763415655236969 -55.411252667963552 -0.022336900000000  65.060445841871370
+0.000000 0.000000 4.217822 -0.519320200000000  66.168585988640672  134.368853306688038  125.208877184229650 -0.022336900000000  65.930588492570905
+0.000000 0.000000 4.267327 -0.519320200000000  66.610295571188374  134.361855648603637  125.214908492219351 -0.022336900000000  66.805037859691851
+0.000000 0.000000 4.316832 -0.519320200000000  67.445717813944057  133.742638274526541 -55.403286804215234 -0.022336900000000  67.683909836896234
+0.000000 0.000000 4.366337 -0.519320200000000  67.891859493936082  133.735688654659015 -55.400303960071561 -0.022336900000000  68.567325100229255
+0.000000 0.000000 4.415842 -0.519320200000000  67.948981812268229  134.340789429694695  125.233490400739129 -0.022336900000000  69.455407886057799
+0.000000 0.000000 4.465347 -0.519320200000000  68.399934746631473  134.333746201043482  125.239505390394029 -0.022336900000000  70.348287177779497
+0.000000 0.000000 4.514851 -0.519320200000000  68.853361452627496  134.326690141282597  125.245503852503049 -0.022336900000000  71.246097161598257
+0.000000 0.000000 4.564356 -0.519320200000000  69.309327561211092  134.319625384011857  125.251313755162940 -0.022336900000000  72.148976002173299
+0.000000 0.000000 4.613861 -0.519320200000000  69.767906735205614  134.312550283078849  125.257064854310713 -0.022336900000000  73.057067585517188
+0.000000 0.000000 4.663366 -0.519320200000000  70.620199035198340  133.693768439961104 -55.382361645180964 -0.022336900000000  73.970521215861680
+0.000000 0.000000 4.712871 -0.519320200000000  71.084162312757897  133.686748047652372 -55.378728685042546 -0.022336900000000  74.889492557948117
+0.000000 0.000000 4.762376 -0.519320200000000  71.550970147647391  133.679719048365058 -55.375376779755648 -0.022336900000000  75.814142528503027
+0.000000 0.000000 4.811881 -0.519320200000000  71.629881621825021  134.284159791739995  125.279950343633530 -0.022336900000000  76.744639338183930
+0.000000 0.000000 4.861386 -0.519320200000000  72.102700329200914  134.277040881307897  125.284927127047141 -0.022336900000000  77.681157945014249
+0.000000 0.000000 4.910891 -0.519320200000000  72.969318371227970  133.658581860833863 -55.364204129624490 -0.022336900000000  78.623880472894129
+0.000000 0.000000 4.960396 -0.519320200000000  73.448378609214018  133.651521223886192 -55.360209641514622 -0.022336900000000  79.572996875413310
+0.000000 0.000000 5.009901 -0.519320200000000  73.930740036258456  133.644452780602819 -55.356114985401540 -0.022336900000000  80.528706053786109
+0.000000 0.000000 5.059406 -0.519320200000000  74.026015199158721  134.248489151062728  125.305185031445944 -0.022336900000000  81.491214051280181
+0.000000 0.000000 5.108911 -0.519320200000000  74.515360096454174  134.241333268007367  125.309934463707407 -0.022336900000000  82.460738637228403
+0.000000 0.000000 5.158416 -0.519320200000000  75.398685764461632  133.623205364754142 -55.343381232835924 -0.022336900000000  83.437505562286759
+0.000000 0.000000 5.207921 -0.519320200000000  75.895333004830121  133.616109809337843 -55.338726548787520 -0.022336900000000  84.421753674832786
+0.000000 0.000000 5.257426 -0.519320200000000  76.005627900482708  134.219825786355131  125.324079866406493 -0.022336900000000  85.413730274710915
+0.000000 0.000000 5.306931 -0.519320200000000  76.900362309529271  133.601900071487051 -55.329595253143701 -0.022336900000000  86.413697199895481
+0.000000 0.000000 5.356436 -0.519320200000000  77.409012199842039  133.594786349638184 -55.324726808853669 -0.022336900000000  87.421928854299551
+0.000000 0.000000 5.405941 -0.519320200000000  77.531923417415101  134.198264698425788  125.336817002046601 -0.022336900000000  88.438713432615558
+0.000000 0.000000 5.455446 -0.519320200000000  78.439303246488208  133.580542070589615 -55.314472544657448 -0.022336900000000  89.464354673613116
+0.000000 0.000000 5.504950 -0.519320200000000  78.961255935672980  133.573411882736792 -55.309192501231209 -0.022336900000000  90.499172370509669
+0.000000 0.000000 5.554455 -0.519320200000000  79.487968714802875  133.566276551077095 -55.303699783696807 -0.022336900000000  91.543504168839149
+0.000000 0.000000 5.603960 -0.519320200000000  80.019619746110038  133.559136126987113 -55.298136355430344 -0.022336900000000  92.597706459774429
+0.000000 0.000000 5.653465 -0.519320200000000  80.556397541229614  133.551991074448978 -55.292150137672351 -0.022336900000000  93.662156856661127
+0.000000 0.000000 5.702970 -0.519320200000000  80.708888469267862  134.154997383609128  125.358399886645429 -0.022336900000000  94.737254191554953
+0.000000 0.000000 5.752475 -0.519320200000000  81.256597938838979  134.147769489169178  125.361262107847537 -0.022336900000000  95.823422504510631
+0.000000 0.000000 5.801980 -0.519320200000000  81.810070608984134  134.140537107284928  125.364187146247104 -0.022336900000000  96.921111462925367
+0.000000 0.000000 5.851485 -0.519320200000000  82.758956020026332  133.523364924492824 -55.267060356764972 -0.022336900000000  98.030799879183121
+0.000000 0.000000 5.900990 -0.519320200000000  82.935277513756802  134.126059626281744  125.369350944640630 -0.022336900000000  99.152997644045172
+0.000000 0.000000 5.950495 -0.519320200000000  83.896814236585655  133.509026635688684 -55.253613490231942 -0.022336900000000  100.288249044364804
+0.000000 0.000000 6.000000 -0.519320200000000  84.086619565424471  134.111566204855734  125.373711397867524 -0.022336900000000  101.437135873662697
\ No newline at end of file
diff --git a/Documentation/figures/s1-11.dat b/Documentation/figures/s1-11.dat
new file mode 100644
index 0000000..055dbb5
--- /dev/null
+++ b/Documentation/figures/s1-11.dat
@@ -0,0 +1,13 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.795148837723552  134.088340521547394 -55.578087980042497 -0.022336900000000  14.824478552849410
+0.000000 0.000000 1.454545 -0.519320200000000  44.201599434245637  134.083376378454716 -55.519563773052468 -0.022336900000000  21.631027973353795
+0.000000 0.000000 1.909091 -0.519320200000000  47.666702676883226  134.047872377601266 -55.491623810964121 -0.022336900000000  28.515821952429473
+0.000000 0.000000 2.363636 -0.519320200000000  51.193503814689336  133.999474227299658 -55.474311463553704 -0.022336900000000  35.507536435635025
+0.000000 0.000000 2.818182 -0.519320200000000  54.794302405697458  133.944457950934918 -55.460498051704882 -0.022336900000000  42.638809731916680
+0.000000 0.000000 3.272727 -0.519320200000000  58.093602764046082  134.499318209431692  125.081129455412878 -0.022336900000000  49.947952253487962
+0.000000 0.000000 3.727273 -0.519320200000000  61.900019148789468  134.437430134023458  125.143771202766871 -0.022336900000000  57.481389853279474
+0.000000 0.000000 4.181818 -0.519320200000000  66.240375744790057  133.761531517821481 -55.410516764503754 -0.022336900000000  65.297336836290114
+0.000000 0.000000 4.636364 -0.519320200000000  69.977235341480124  134.309331274499868  125.259489975141051 -0.022336900000000  73.471599899498145
+0.000000 0.000000 5.090909 -0.519320200000000  74.727450326601485  133.632870811920895 -55.349173123619963 -0.022336900000000  82.107358281876429
+0.000000 0.000000 5.545455 -0.519320200000000  79.002012473641372  134.177964675433685  125.347569522109112 -0.022336900000000  91.352902201654246
+0.000000 0.000000 6.000000 -0.519320200000000  84.086619565424471  134.111566204855734  125.373711397867524 -0.022336900000000  101.437135873662697
\ No newline at end of file
diff --git a/Documentation/figures/s2-101.dat b/Documentation/figures/s2-101.dat
new file mode 100644
index 0000000..30b0843
--- /dev/null
+++ b/Documentation/figures/s2-101.dat
@@ -0,0 +1,103 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.400329236644197  134.704182457760055  124.948883370711130 -0.022336900000000  14.824478351069212
+0.000000 0.000000 1.049505 -0.519320200000000  40.768089313828689  134.706363470030624  124.937541549238986 -0.022336900000000  15.562801322318858
+0.000000 0.000000 1.099010 -0.519320200000000  41.136741488093215  134.707662396950383  124.927675562141488 -0.022336900000000  16.301774926017963
+0.000000 0.000000 1.148515 -0.519320200000000  41.506228657635631  134.708193308921466  124.918947112250379 -0.022336900000000  17.041431559417731
+0.000000 0.000000 1.198020 -0.519320200000000  41.876505994038979  134.708051459082213  124.913938238052111 -0.022336900000000  17.781803977467231
+0.000000 0.000000 1.247525 -0.519320200000000  42.247539047566683  134.707316699982414  124.908069222970838 -0.022336900000000  18.522925804457664
+0.000000 0.000000 1.297030 -0.519320200000000  42.619300621451451  134.706057005330820  124.904023840220972 -0.022336900000000  19.264830026097581
+0.000000 0.000000 1.346535 -0.519320200000000  42.991769806737750  134.704330650378608  124.901762472679493 -0.022336900000000  20.007549924876880
+0.000000 0.000000 1.396040 -0.519320200000000  43.364932259891482  134.702186952100817  124.898473429758241 -0.022336900000000  20.751120004007358
+0.000000 0.000000 1.445545 -0.519320200000000  43.738777532103441  134.699668951666581  124.898519173273243 -0.022336900000000  21.495574767045365
+0.000000 0.000000 1.495050 -0.519320200000000  44.508050636848481  134.081044751669509 -55.516877723394508 -0.022336900000000  22.240948799484581
+0.000000 0.000000 1.544554 -0.519320200000000  44.883214819177645  134.077917802435337 -55.512507387039477 -0.022336900000000  22.987277157465339
+0.000000 0.000000 1.594059 -0.519320200000000  44.864359375639857  134.690218398640468  124.899778101103905 -0.022336900000000  23.734594446755704
+0.000000 0.000000 1.643564 -0.519320200000000  45.635553197087624  134.070869619756735 -55.505654976704932 -0.022336900000000  24.482937746386941
+0.000000 0.000000 1.693069 -0.519320200000000  45.618117923284352  134.682615593970553  124.903284827625825 -0.022336900000000  25.232342586583208
+0.000000 0.000000 1.742574 -0.519320200000000  45.996020293935587  134.678490001125056  124.905540950751217 -0.022336900000000  25.982846405754906
+0.000000 0.000000 1.792079 -0.519320200000000  46.374613645599659  134.674172485174097  124.908371796987140 -0.022336900000000  26.734485819263842
+0.000000 0.000000 1.841584 -0.519320200000000  46.753906712998052  134.669678646041660  124.911741088615784 -0.022336900000000  27.487298390571937
+0.000000 0.000000 1.891089 -0.519320200000000  47.133910466146610  134.665021955472099  124.915256835642964 -0.022336900000000  28.241323144518638
+0.000000 0.000000 1.940594 -0.519320200000000  47.909036654283703  134.044829092365546 -55.490112462881854 -0.022336900000000  28.996597739053964
+0.000000 0.000000 1.990099 -0.519320200000000  48.290447848316944  134.039935511307704 -55.487963231057556 -0.022336900000000  29.753161739697020
+0.000000 0.000000 2.039604 -0.519320200000000  48.672604727495745  134.034914698942316 -55.485914324940218 -0.022336900000000  30.511054642329345
+0.000000 0.000000 2.089109 -0.519320200000000  49.055522205808003  134.029775962704235 -55.484204595551489 -0.022336900000000  31.270318341267796
+0.000000 0.000000 2.138614 -0.519320200000000  49.439215353637323  134.024526680744856 -55.482029121667544 -0.022336900000000  32.030991892300470
+0.000000 0.000000 2.188119 -0.519320200000000  49.823699277836035  134.019175011714339 -55.480480570552210 -0.022336900000000  32.793116354213893
+0.000000 0.000000 2.237624 -0.519320200000000  50.208991641636523  134.013728525351269 -55.478596775065419 -0.022336900000000  33.556737076159024
+0.000000 0.000000 2.287129 -0.519320200000000  50.201062752953419  134.623191070707946  124.953071693430076 -0.022336900000000  34.321894713543266
+0.000000 0.000000 2.336634 -0.519320200000000  50.588079163841591  134.617511877588214  124.958554653460141 -0.022336900000000  35.088633650004311
+0.000000 0.000000 2.386139 -0.519320200000000  50.975958249678584  134.611753816354991  124.964402662090706 -0.022336900000000  35.856997067420266
+0.000000 0.000000 2.435644 -0.519320200000000  51.364720471878293  134.605921415106508  124.970262772572568 -0.022336900000000  36.627031544314001
+0.000000 0.000000 2.485149 -0.519320200000000  51.754385339767353  134.600019287199729  124.976546177216306 -0.022336900000000  37.398782090335644
+0.000000 0.000000 2.534653 -0.519320200000000  52.144974173975129  134.594051555114135  124.982391428590333 -0.022336900000000  38.172296653760355
+0.000000 0.000000 2.584158 -0.519320200000000  52.930218286419795  133.973391331007832 -55.467565210513740 -0.022336900000000  38.947621699979344
+0.000000 0.000000 2.633663 -0.519320200000000  52.929008290404305  134.581934399184007  124.994741738655563 -0.022336900000000  39.724806426655654
+0.000000 0.000000 2.683168 -0.519320200000000  53.322498281859986  134.575791697344130  125.001279138017480 -0.022336900000000  40.503899653809206
+0.000000 0.000000 2.732673 -0.519320200000000  53.717001207955100  134.569597164399994  125.007609342236506 -0.022336900000000  41.284952621031444
+0.000000 0.000000 2.782178 -0.519320200000000  54.112540731265156  134.563353450624447  125.014250419519584 -0.022336900000000  42.068015933734948
+0.000000 0.000000 2.831683 -0.519320200000000  54.902556356724567  133.942755978121909 -55.460389907307459 -0.022336900000000  42.853142559471685
+0.000000 0.000000 2.881188 -0.519320200000000  54.906828967180594  134.550729098324638  125.027303872269314 -0.022336900000000  43.640386311953293
+0.000000 0.000000 2.930693 -0.519320200000000  55.305628417849121  134.544353225513476  125.034005066785838 -0.022336900000000  44.429800992701637
+0.000000 0.000000 2.980198 -0.519320200000000  56.098799154756477  133.923829949388050 -55.455952833261385 -0.022336900000000  45.221443045780667
+0.000000 0.000000 3.029703 -0.519320200000000  56.499842109179518  133.917444113187486 -55.454572202600190 -0.022336900000000  46.015369409543766
+0.000000 0.000000 3.079208 -0.519320200000000  56.508970233971468  134.524995541924682  125.054133222406662 -0.022336900000000  46.811638885907371
+0.000000 0.000000 3.128713 -0.519320200000000  56.912491732677502  134.518472971483845  125.061163794732011 -0.022336900000000  47.610310391405605
+0.000000 0.000000 3.178218 -0.519320200000000  57.710249417661984  133.898080867410670 -55.449987354707062 -0.022336900000000  48.411444839851924
+0.000000 0.000000 3.227723 -0.519320200000000  57.723321396337120  134.505331192152681  125.074760005580188 -0.022336900000000  49.215105531787046
+0.000000 0.000000 3.277228 -0.519320200000000  58.130690459987242  134.498716045526692  125.081913605951229 -0.022336900000000  50.021355340433438
+0.000000 0.000000 3.326733 -0.519320200000000  58.932201547766269  133.878442109073518 -55.445308344243912 -0.022336900000000  50.830261498171041
+0.000000 0.000000 3.376238 -0.519320200000000  58.949499700958640  134.485401533909169  125.095377807118695 -0.022336900000000  51.641889633553212
+0.000000 0.000000 3.425743 -0.519320200000000  59.361004681889817  134.478705646119124  125.102378162406723 -0.022336900000000  52.456308732982677
+0.000000 0.000000 3.475248 -0.519320200000000  59.773957851412533  134.471983608803669  125.109090186797019 -0.022336900000000  53.273590213039242
+0.000000 0.000000 3.524752 -0.519320200000000  60.188389895310415  134.465241280244840  125.115744125650451 -0.022336900000000  54.093805415127882
+0.000000 0.000000 3.574257 -0.519320200000000  60.604341592227307  134.458475092350426  125.122795565095956 -0.022336900000000  54.917028966382084
+0.000000 0.000000 3.623762 -0.519320200000000  61.414259764726772  133.838477035972318 -55.434504596911005 -0.022336900000000  55.743337131549374
+0.000000 0.000000 3.673267 -0.519320200000000  61.833298659223807  133.831739003094782 -55.433102910631966 -0.022336900000000  56.572809074805598
+0.000000 0.000000 3.722772 -0.519320200000000  62.253969767160058  133.824983286824306 -55.430772478709187 -0.022336900000000  57.405525057449005
+0.000000 0.000000 3.772277 -0.519320200000000  62.676316254749956  133.818207847554532 -55.429068484729527 -0.022336900000000  58.241566977407253
+0.000000 0.000000 3.821782 -0.519320200000000  62.708228806757639  134.424340518297697  125.156403255431385 -0.022336900000000  59.081021225676835
+0.000000 0.000000 3.871287 -0.519320200000000  63.526205385790860  133.804602916262780 -55.424933837581918 -0.022336900000000  59.923974896071968
+0.000000 0.000000 3.920792 -0.519320200000000  63.561813312125700  134.410560141708061  125.169971983776875 -0.022336900000000  60.770518232310508
+0.000000 0.000000 3.970297 -0.519320200000000  63.991360029858178  134.403645535186627  125.176460085933030 -0.022336900000000  61.620744957112535
+0.000000 0.000000 4.019802 -0.519320200000000  64.422805832604112  134.396715565564449  125.182921234631735 -0.022336900000000  62.474750593738769
+0.000000 0.000000 4.069307 -0.519320200000000  64.856199659277422  134.389770940282062  125.189411264486978 -0.022336900000000  63.332633998811538
+0.000000 0.000000 4.118812 -0.519320200000000  65.683350266156893  133.770315981111509 -55.413282617639624 -0.022336900000000  64.194497506714583
+0.000000 0.000000 4.168317 -0.519320200000000  65.729036183539748  134.375839573248157  125.202367923623711 -0.022336900000000  65.060445855490414
+0.000000 0.000000 4.217822 -0.519320200000000  66.560210941970496  133.756502257898632 -55.408394663624065 -0.022336900000000  65.930588664383237
+0.000000 0.000000 4.267327 -0.519320200000000  66.610295648857843  134.361855559375670  125.214909441511438 -0.022336900000000  66.805037880336911
+0.000000 0.000000 4.316832 -0.519320200000000  67.445717838121809  133.742638274249771 -55.403182850066308 -0.022336900000000  67.683909889203562
+0.000000 0.000000 4.366337 -0.519320200000000  67.500432877656792  134.347822949155557  125.227374744182356 -0.022336900000000  68.567325052221491
+0.000000 0.000000 4.415842 -0.519320200000000  67.948982030764896  134.340789167125763  125.233499083278431 -0.022336900000000  69.455407901924161
+0.000000 0.000000 4.465347 -0.519320200000000  68.399935810173062  134.333745047248868  125.239495835372239 -0.022336900000000  70.348287392501248
+0.000000 0.000000 4.514851 -0.519320200000000  68.853361496459186  134.326690111902735  125.245531750511319 -0.022336900000000  71.246097196980529
+0.000000 0.000000 4.564356 -0.519320200000000  69.309327892917381  134.319625105469157  125.251252555484982 -0.022336900000000  72.148976012029337
+0.000000 0.000000 4.613861 -0.519320200000000  69.767906715473458  134.312550271551828  125.257185436578567 -0.022336900000000  73.057067418408650
+0.000000 0.000000 4.663366 -0.519320200000000  70.620199164338700  133.693768283561695 -55.382119594297386 -0.022336900000000  73.970521277363957
+0.000000 0.000000 4.712871 -0.519320200000000  71.084162310146269  133.686748073249646 -55.378574891463451 -0.022336900000000  74.889492593661515
+0.000000 0.000000 4.762376 -0.519320200000000  71.160077380440399  134.291270562758228  125.274084456210431 -0.022336900000000  75.814142585648227
+0.000000 0.000000 4.811881 -0.519320200000000  71.629880754125352  134.284159935281451  125.279439785112075 -0.022336900000000  76.744639238620749
+0.000000 0.000000 4.861386 -0.519320200000000  72.102700203132557  134.277041099154218  125.284871583264916 -0.022336900000000  77.681157994928441
+0.000000 0.000000 4.910891 -0.519320200000000  72.578626286539901  134.269914364934664  125.290168385807078 -0.022336900000000  78.623880375727580
+0.000000 0.000000 4.960396 -0.519320200000000  73.057754099935750  134.262779928244925  125.295354474306563 -0.022336900000000  79.572996826537747
+0.000000 0.000000 5.009901 -0.519320200000000  73.930740053848638  133.644452240465910 -55.356313696774293 -0.022336900000000  80.528705404622642
+0.000000 0.000000 5.059406 -0.519320200000000  74.026015253976922  134.248489283551777  125.305336694867506 -0.022336900000000  81.491214409687913
+0.000000 0.000000 5.108911 -0.519320200000000  74.515360022209549  134.241333251611508  125.310174693603273 -0.022336900000000  82.460738460876641
+0.000000 0.000000 5.158416 -0.519320200000000  75.008330280833221  134.234170747874515  125.314953887914996 -0.022336900000000  83.437505793691457
+0.000000 0.000000 5.207921 -0.519320200000000  75.505044682959877  134.227001608814788  125.319736193755304 -0.022336900000000  84.421753344265753
+0.000000 0.000000 5.257426 -0.519320200000000  76.395848360645658  133.609007764954839 -55.334403488815767 -0.022336900000000  85.413730175944494
+0.000000 0.000000 5.306931 -0.519320200000000  76.510208437036184  134.212645688202826  125.328432132822982 -0.022336900000000  86.413697244680478
+0.000000 0.000000 5.356436 -0.519320200000000  77.018926208817874  134.205457635082666  125.332825489141413 -0.022336900000000  87.421928785271419
+0.000000 0.000000 5.405941 -0.519320200000000  77.921941944066660  133.587666951921790 -55.319678794762069 -0.022336900000000  88.438713462644870
+0.000000 0.000000 5.455446 -0.519320200000000  78.049352173761676  134.191066259538275  125.340827360120443 -0.022336900000000  89.464354613722321
+0.000000 0.000000 5.504950 -0.519320200000000  78.571372387484999  134.183862499383793  125.344550216033639 -0.022336900000000  90.499172383093352
+0.000000 0.000000 5.554455 -0.519320200000000  79.487968707921169  133.566276553104103 -55.303732038464155 -0.022336900000000  91.543504157600523
+0.000000 0.000000 5.603960 -0.519320200000000  79.629872477500768  134.169438287360549  125.351787652541503 -0.022336900000000  92.597706798839269
+0.000000 0.000000 5.653465 -0.519320200000000  80.166716553818361  134.162220913655062  125.354990739926407 -0.022336900000000  93.662156865118817
+0.000000 0.000000 5.702970 -0.519320200000000  81.098501603682195  133.544841256223151 -55.286319593537108 -0.022336900000000  94.737254195569150
+0.000000 0.000000 5.752475 -0.519320200000000  81.646143766585595  133.537686924723317 -55.280078684277662 -0.022336900000000  95.823422467634970
+0.000000 0.000000 5.801980 -0.519320200000000  81.810070771238657  134.140537304647665  125.364248638495610 -0.022336900000000  96.921112173118615
+0.000000 0.000000 5.851485 -0.519320200000000  82.369545502108338  134.133300456739960  125.366713159046810 -0.022336900000000  98.030799921844178
+0.000000 0.000000 5.900990 -0.519320200000000  83.324620529366513  133.516197921663377 -55.260511951680570 -0.022336900000000  99.152997574616805
+0.000000 0.000000 5.950495 -0.519320200000000  83.507538634092583  134.118814664123505  125.371641748894390 -0.022336900000000  100.288248990944723
+0.000000 0.000000 6.000000 -0.519320200000000  84.475827487142254  133.501851693551544 -55.246488273144521 -0.022336900000000  101.437135833363357
\ No newline at end of file
diff --git a/Documentation/figures/s2-11.dat b/Documentation/figures/s2-11.dat
new file mode 100644
index 0000000..d7152c2
--- /dev/null
+++ b/Documentation/figures/s2-11.dat
@@ -0,0 +1,13 @@
+#h k l                 mu             komega              kappa               kphi              delta              gamma
+0.000000 0.000000 1.000000 -0.519320200000000  40.400329236644197  134.704182457760055  124.948883370711130 -0.022336900000000  14.824478351069212
+0.000000 0.000000 1.454545 -0.519320200000000  43.806822259635425  134.699173900458135  124.898672413928125 -0.022336900000000  21.631028056870033
+0.000000 0.000000 1.909091 -0.519320200000000  47.666702644755155  134.047872361703469 -55.491588294618381 -0.022336900000000  28.515821860138853
+0.000000 0.000000 2.363636 -0.519320200000000  50.799541387867684  134.614380549324750  124.961746059168973 -0.022336900000000  35.507536665234397
+0.000000 0.000000 2.818182 -0.519320200000000  54.794302282671516  133.944457972434719 -55.460725265976656 -0.022336900000000  42.638809512821538
+0.000000 0.000000 3.272727 -0.519320200000000  58.093602860961269  134.499317735381396  125.081329926466793 -0.022336900000000  49.947951719613890
+0.000000 0.000000 3.727273 -0.519320200000000  62.292294949359636  133.824368147138216 -55.430755343635212 -0.022336900000000  57.481389999561081
+0.000000 0.000000 4.181818 -0.519320200000000  65.848702052342148  134.373935705441085  125.204188941124343 -0.022336900000000  65.297336829530153
+0.000000 0.000000 4.636364 -0.519320200000000  69.977235130767554  134.309331490772053  125.259769927030717 -0.022336900000000  73.471599833259461
+0.000000 0.000000 5.090909 -0.519320200000000  74.727450273359395  133.632870840586037 -55.349394177548099 -0.022336900000000  82.107358214859715
+0.000000 0.000000 5.545455 -0.519320200000000  79.391840719389251  133.567574367273352 -55.304697131003159 -0.022336900000000  91.352902175861374
+0.000000 0.000000 6.000000 -0.519320200000000  84.475827487142254  133.501851693551544 -55.246488273144521 -0.022336900000000  101.437135833363357
\ No newline at end of file
diff --git a/Documentation/figures/sirius.c b/Documentation/figures/sirius.c
new file mode 100644
index 0000000..9e72dac
--- /dev/null
+++ b/Documentation/figures/sirius.c
@@ -0,0 +1,208 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ */
+#include "hkl/api2/hkl2.h"
+#include "hkl/ccan/array_size/array_size.h"
+#include "hkl/ccan/generator/generator.h"
+#include "hkl-geometry-private.h"
+#include "hkl-trajectory-private.h"
+
+static void hkl_geometry_save_as_dat(FILE *f, const HklGeometry *self)
+{
+	HklParameter **axis;
+	darray_foreach(axis, self->axes){
+		double value = hkl_parameter_value_get(*axis, HKL_UNIT_USER);
+		fprintf(f, " % 18.15f", value);
+	}
+}
+
+static void GeometryList_save_as_dat(const char *filename,  const struct Trajectory trajectory, const HklGeometryList *geometries)
+{
+	HklParameter **axis;
+	const HklGeometryListItem *item;
+	const struct Engine *econfig;
+	generator_t(struct Engine) gen = trajectory_gen(trajectory);
+	FILE *f = fopen(filename, "w+");
+
+	/* print the header */
+	econfig = generator_next(gen);
+	fprintf(f, "#");
+	Engine_header(f, *econfig);
+
+	item = hkl_geometry_list_items_first_get(geometries);
+	darray_foreach(axis, item->geometry->axes){
+		fprintf(f, "%19s", (*axis)->name);
+	}
+
+	/* save the first point */
+	fprintf(f, "\n");
+	Engine_save_as_dat(f, *econfig);
+	hkl_geometry_save_as_dat(f, item->geometry);
+
+	while((econfig = generator_next(gen)) != NULL){
+		fprintf(f, "\n");
+		Engine_save_as_dat(f, *econfig);
+		item = hkl_geometry_list_items_next_get(geometries, item);
+		hkl_geometry_save_as_dat(f, item->geometry);
+	}
+	fclose(f);
+
+	generator_free(gen);
+}
+
+static double hkl_geometry_list_kphi_range(const HklGeometryList *self)
+{
+	uint idx = 0;
+	double min, max;
+	const HklGeometryListItem *item;
+	HklParameter **axis;
+
+	/* get the kphi index */
+	item = hkl_geometry_list_items_first_get(self);
+	darray_foreach(axis, item->geometry->axes){
+		if (!strcmp((*axis)->name, "kphi"))
+			break;
+		idx++;
+	}
+
+	min = max = hkl_parameter_value_get(darray_item(item->geometry->axes, idx), HKL_UNIT_USER);
+	for(;item;item = hkl_geometry_list_items_next_get(self, item)){
+		double current = hkl_parameter_value_get(darray_item(item->geometry->axes, idx), HKL_UNIT_USER);
+		min = current < min ? current : min;
+		max = current >= max ? current : max;
+	}
+
+	return max - min;
+}
+
+typedef struct _XY XY;
+
+struct _XY {
+	darray(int) x;
+	darray(double) y;
+};
+
+static void xy_init(XY *xy) {
+	darray_init(xy->x);
+	darray_init(xy->y);
+}
+
+static void xy_add(XY *xy, int x, double y)
+{
+	darray_append(xy->x, x);
+	darray_append(xy->y, y);
+}
+
+static void xy_free(XY *xy)
+{
+	darray_free(xy->x);
+	darray_free(xy->y);
+};
+
+static void xy_save_as_dat(XY *xy, const char *filename)
+{
+	uint i;
+	FILE *f = fopen(filename, "w+");
+	fprintf(f, "# x y");
+	for(i=0; i<darray_size(xy->x); ++i)
+		fprintf(f, "\n%d %f",
+			darray_item(xy->x, i),
+			darray_item(xy->y, i));
+	fclose(f);
+}
+
+int main(void)
+{
+	uint i;
+	HklGeometryList *solutions;
+	XY plot;
+
+	xy_init(&plot);
+
+	static struct Sample gaas = {
+		.name = "GaAs",
+		.lattice = Cubic(5.6533),
+		.ux = -90.003382 * HKL_DEGTORAD,
+		.uy = 0.12907 * HKL_DEGTORAD,
+		.uz = -159.91372 * HKL_DEGTORAD,
+	};
+
+	static struct Geometry gconfig =	\
+		SoleilSiriusKappa(1.458637,
+				  -0.5193202, 64.7853160, 133.5621380, -80.9690000, -0.0223369, 30.0000299);
+
+	static struct Geometry gconfig2 =	\
+		SoleilSiriusKappa(1.458637,
+				  -0.5193202, 64.7853160, 133.5621380, 124.9690000, -0.0223369, 30.0000299);
+
+	/* Trajectory */
+	struct Mode mode = ModeHklBissectorVertical;
+	struct Trajectory tconfig1 = TrajectoryHklFromTo(0, 0, 1, 0, 0, 6, 11, mode);
+	struct Trajectory tconfig2 = TrajectoryHklFromTo(0, 0, 1, 0, 0, 6, 101, mode);
+	/* move between each step */
+	solutions = Trajectory_solve(tconfig1, gconfig, gaas, TRUE);
+	GeometryList_save_as_dat("m1-11.dat", tconfig1, solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig1, gconfig2, gaas, TRUE);
+	GeometryList_save_as_dat("m2-11.dat", tconfig1, solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig, gaas, TRUE);
+	GeometryList_save_as_dat("m1-101.dat", tconfig2, solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig2, gaas, TRUE);
+	GeometryList_save_as_dat("m2-101.dat", tconfig2, solutions);
+	hkl_geometry_list_free(solutions);
+
+	/* do not move between each steps */
+	solutions = Trajectory_solve(tconfig1, gconfig, gaas, FALSE);
+	GeometryList_save_as_dat("s1-11.dat", tconfig1, solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig1, gconfig2, gaas, FALSE);
+	GeometryList_save_as_dat("s2-11.dat", tconfig1, solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig, gaas, FALSE);
+	GeometryList_save_as_dat("s1-101.dat", tconfig2, solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig2, gaas, FALSE);
+	GeometryList_save_as_dat("s2-101.dat", tconfig2, solutions);
+	hkl_geometry_list_free(solutions);
+
+	for(i=1; i<102; ++i){
+		double range;
+		struct Trajectory tconfig3 = TrajectoryHklFromTo(0, 0, 1, 0, 0, 6, i, mode);
+
+		solutions = Trajectory_solve(tconfig3, gconfig2, gaas, TRUE);
+		range = hkl_geometry_list_kphi_range(solutions);
+		xy_add(&plot, i, range);
+		hkl_geometry_list_free(solutions);
+	}
+
+	xy_save_as_dat(&plot, "traj_n.dat");
+	xy_free(&plot);
+
+	return 0;
+}
diff --git a/Documentation/figures/traj_n.dat b/Documentation/figures/traj_n.dat
new file mode 100644
index 0000000..424d1b8
--- /dev/null
+++ b/Documentation/figures/traj_n.dat
@@ -0,0 +1,102 @@
+# x y
+1 180.195371
+2 180.813073
+3 0.424843
+4 180.590416
+5 180.792872
+6 180.868850
+7 180.824758
+8 180.851837
+9 180.431954
+10 180.889088
+11 180.794561
+12 180.815754
+13 180.842793
+14 180.858062
+15 180.504292
+16 180.880547
+17 180.908082
+18 180.909971
+19 180.486832
+20 180.913101
+21 180.914589
+22 180.490879
+23 180.492126
+24 0.474524
+25 0.474049
+26 0.474404
+27 0.474810
+28 0.474845
+29 0.475107
+30 0.475227
+31 0.475243
+32 0.475180
+33 0.475246
+34 0.475028
+35 0.474779
+36 0.474893
+37 0.475082
+38 0.475165
+39 0.475251
+40 0.475291
+41 0.475288
+42 0.475247
+43 0.475172
+44 0.475067
+45 0.474936
+46 0.474979
+47 0.475110
+48 0.475203
+49 0.475262
+50 0.475291
+51 0.475293
+52 0.475269
+53 0.475223
+54 0.475155
+55 0.475070
+56 0.475070
+57 0.475160
+58 0.475226
+59 0.475269
+60 0.475291
+61 0.475375
+62 0.475348
+63 0.475307
+64 0.475252
+65 0.475184
+66 0.475158
+67 0.475219
+68 0.475264
+69 0.475292
+70 0.475306
+71 0.475307
+72 0.475295
+73 0.475270
+74 0.475235
+75 0.475189
+76 0.475161
+77 0.475181
+78 0.475225
+79 0.475255
+80 0.475274
+81 0.475282
+82 0.475279
+83 0.475266
+84 0.475244
+85 0.475213
+86 0.475187
+87 0.475229
+88 0.475262
+89 0.475285
+90 0.475298
+91 0.475303
+92 0.475300
+93 0.475289
+94 0.475270
+95 0.475245
+96 0.475213
+97 0.475247
+98 0.475274
+99 0.475292
+100 0.475303
+101 0.475307
\ No newline at end of file
diff --git a/Documentation/figures/zaxis.asy b/Documentation/figures/zaxis.asy
index 2466fa3..24951b7 100644
--- a/Documentation/figures/zaxis.asy
+++ b/Documentation/figures/zaxis.asy
@@ -1,5 +1,8 @@
 import solids;
 
+currentprojection=orthographic(1,0,0);
+currentlight=White;
+
 size(300,0);
 
 real k = 2;
@@ -67,5 +70,3 @@ draw(C1--P1, blue);
 dot("$P_2$", P2, blue);
 draw(C1--P2, blue);
 draw(Parc, blue, Arrows3());
-
-
diff --git a/Documentation/figures/zaxis.png b/Documentation/figures/zaxis.png
index 4626aed..f177e00 100644
Binary files a/Documentation/figures/zaxis.png and b/Documentation/figures/zaxis.png differ
diff --git a/Documentation/hkl-default.el b/Documentation/hkl-default.el
index bca9646..816f7d7 100644
--- a/Documentation/hkl-default.el
+++ b/Documentation/hkl-default.el
@@ -1,6 +1,6 @@
 ;;; hkl-default.el --- Hkl specific emacsen startup code.
 
-;; Copyright (C) 2003-2016 Synchrotron SOLEIL
+;; Copyright (C) 2003-2017 Synchrotron SOLEIL
 ;;                         L'Orme des Merisiers Saint-Aubin
 ;;                         BP 48 91192 GIF-sur-YVETTE CEDEX
 
@@ -43,7 +43,8 @@
    (quote
     ((latex . t)
      (python . t)
-     (emacs-lisp . t))))
+     (emacs-lisp . t)
+     (gnuplot . t))))
  '(org-confirm-babel-evaluate nil)
  '(org-latex-listings (quote minted))
  '(org-latex-minted-langs
@@ -58,6 +59,36 @@
    (quote
     ("pdflatex -interaction nonstopmode --shell-escape -output-directory %o %f" "pdflatex -interaction nonstopmode --shell-escape -output-directory %o %f" "pdflatex -interaction nonstopmode --shell-escape -output-directory %o %f")))
  '(org-export-with-sub-superscripts nil)
- '(org-src-fontify-natively t))
+ '(org-src-fontify-natively t)
+ '(org-publish-project-alist
+   (quote
+    (("hkl"
+     :base-directory "."
+     :base-extension "org"
+     :publishing-directory "/ssh:picca at people.debian.org:~/public_html/hkl/"
+     :publishing-function org-html-publish-to-html
+     :headline-levels 3
+     :section-numbers t
+     :with-toc t
+     :html-head "<link rel=\"stylesheet\"
+                       href=\"../css/style.css\" type=\"text/css\"/>"
+     :html-preamble t)
+
+    ("images"
+     :base-directory "figures/"
+     :base-extension "svg\\|jpg\\|gif\\|png"
+     :publishing-directory "/ssh:picca at people.debian.org:~/public_html/hkl/figures/"
+     :publishing-function org-publish-attachment)
+
+    ("css"
+     :base-directory "css/"
+     :base-extension "css"
+     :publishing-directory "/ssh:picca at people.debian.org:~/public_html/hkl/css/"
+     :publishing-function org-publish-attachment)
+
+    ))))
+
+(require 'ox-publish)
+
 (provide 'hkl-default)
 ;;; hkl-default ends here
diff --git a/Documentation/hkl.html b/Documentation/hkl.html
index 755ca99..2696d6f 100644
--- a/Documentation/hkl.html
+++ b/Documentation/hkl.html
@@ -3,8 +3,8 @@
 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
 <head>
-<title>Welcome to hkl's 5.0.0.2173 documentation!</title>
-<!-- 2016-09-19 lun. 22:20 -->
+<title>Welcome to hkl's 5.0.0.2428 documentation!</title>
+<!-- 2017-12-02 sam. 16:29 -->
 <meta  http-equiv="Content-Type" content="text/html;charset=utf-8" />
 <meta  name="generator" content="Org-mode" />
 <meta  name="author" content="Picca Frédéric-Emmanuel" />
@@ -88,12 +88,7 @@
     { background-color: #ffff00; color: #000000; font-weight: bold; }
   /*]]>*/-->
 </style>
-<link rel="stylesheet" type="text/css" href="http://www.pirilampo.org/styles/readtheorg/css/htmlize.css"/>
-<link rel="stylesheet" type="text/css" href="http://www.pirilampo.org/styles/readtheorg/css/readtheorg.css"/>
-<script src="http://code.jquery.com/jquery-2.2.0.min.js"></script>
-<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
-<script type="text/javascript" src="http://www.pirilampo.org/styles/lib/js/jquery.stickytableheaders.js"></script>
-<script type="text/javascript" src="http://www.pirilampo.org/styles/readtheorg/js/readtheorg.js"></script>
+<link href="css/style.css" rel="stylesheet" type="text/css" />
 <script type="text/javascript">
 /*
 @licstart  The following is the entire license notice for the
@@ -140,7 +135,7 @@ for the JavaScript code in this tag.
  }
 /*]]>*///-->
 </script>
-<script type="text/javascript" src="/usr/share/javascript/mathjax/MathJax.js"></script>
+<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-AMS_HTML"></script>
 <script type="text/javascript">
 <!--/*--><![CDATA[/*><!--*/
     MathJax.Hub.Config({
@@ -185,7 +180,7 @@ for the JavaScript code in this tag.
 </head>
 <body>
 <div id="content">
-<h1 class="title">Welcome to hkl's 5.0.0.2173 documentation!</h1>
+<h1 class="title">Welcome to hkl's 5.0.0.2428 documentation!</h1>
 <div id="table-of-contents">
 <h2>Table of Contents</h2>
 <div id="text-table-of-contents">
@@ -258,60 +253,66 @@ for the JavaScript code in this tag.
 <li><a href="#sec-3-5-2">3.5.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-6">3.6. PETRA3 P09 EH2</a>
+<li><a href="#sec-3-6">3.6. PETRA3 P08 LISA</a>
 <ul>
 <li><a href="#sec-3-6-1">3.6.1. Axes:</a></li>
 <li><a href="#sec-3-6-2">3.6.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-7">3.7. SOLEIL MARS</a>
+<li><a href="#sec-3-7">3.7. PETRA3 P09 EH2</a>
 <ul>
 <li><a href="#sec-3-7-1">3.7.1. Axes:</a></li>
 <li><a href="#sec-3-7-2">3.7.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-8">3.8. SOLEIL SIRIUS KAPPA</a>
+<li><a href="#sec-3-8">3.8. SOLEIL MARS</a>
 <ul>
 <li><a href="#sec-3-8-1">3.8.1. Axes:</a></li>
 <li><a href="#sec-3-8-2">3.8.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-9">3.9. SOLEIL SIRIUS TURRET</a>
+<li><a href="#sec-3-9">3.9. SOLEIL SIRIUS KAPPA</a>
 <ul>
 <li><a href="#sec-3-9-1">3.9.1. Axes:</a></li>
 <li><a href="#sec-3-9-2">3.9.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-10">3.10. SOLEIL SIXS MED1+2</a>
+<li><a href="#sec-3-10">3.10. SOLEIL SIRIUS TURRET</a>
 <ul>
 <li><a href="#sec-3-10-1">3.10.1. Axes:</a></li>
 <li><a href="#sec-3-10-2">3.10.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-11">3.11. SOLEIL SIXS MED2+2</a>
+<li><a href="#sec-3-11">3.11. SOLEIL SIXS MED1+2</a>
 <ul>
 <li><a href="#sec-3-11-1">3.11.1. Axes:</a></li>
 <li><a href="#sec-3-11-2">3.11.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-12">3.12. SOLEIL SIXS MED2+3</a>
+<li><a href="#sec-3-12">3.12. SOLEIL SIXS MED2+2</a>
 <ul>
 <li><a href="#sec-3-12-1">3.12.1. Axes:</a></li>
 <li><a href="#sec-3-12-2">3.12.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-13">3.13. TwoC</a>
+<li><a href="#sec-3-13">3.13. SOLEIL SIXS MED2+3</a>
 <ul>
 <li><a href="#sec-3-13-1">3.13.1. Axes:</a></li>
 <li><a href="#sec-3-13-2">3.13.2. Engines:</a></li>
 </ul>
 </li>
-<li><a href="#sec-3-14">3.14. ZAXIS</a>
+<li><a href="#sec-3-14">3.14. TwoC</a>
 <ul>
 <li><a href="#sec-3-14-1">3.14.1. Axes:</a></li>
 <li><a href="#sec-3-14-2">3.14.2. Engines:</a></li>
 </ul>
 </li>
+<li><a href="#sec-3-15">3.15. ZAXIS</a>
+<ul>
+<li><a href="#sec-3-15-1">3.15.1. Axes:</a></li>
+<li><a href="#sec-3-15-2">3.15.2. Engines:</a></li>
+</ul>
+</li>
 </ul>
 </li>
 <li><a href="#sec-4">4. Developpement</a>
@@ -339,9 +340,11 @@ for the JavaScript code in this tag.
 </li>
 <li><a href="#sec-6">6. Releases</a>
 <ul>
-<li><a href="#sec-6-1">6.1. 5.0.0.2173</a>
+<li><a href="#sec-6-1">6.1. 5.0.0.2428</a>
 <ul>
-<li><a href="#sec-6-1-1">6.1.1. <span class="done DONE">DONE</span> Fix for multiarch (headers) <span class="timestamp-wrapper"><span class="timestamp"><2016-05-04 mer.></span></span></a></li>
+<li><a href="#sec-6-1-1">6.1.1. <span class="done DONE">DONE</span> add emergence on all e4c diffractometers <span class="timestamp-wrapper"><span class="timestamp"><2017-03-16 Thu></span></span></a></li>
+<li><a href="#sec-6-1-2">6.1.2. <span class="done DONE">DONE</span> Fix for multiarch (headers) <span class="timestamp-wrapper"><span class="timestamp"><2016-05-04 mer.></span></span></a></li>
+<li><a href="#sec-6-1-3">6.1.3. <span class="done DONE">DONE</span> Fix the FTBFS with the new bullet 2.86.1 version <span class="timestamp-wrapper"><span class="timestamp"><2017-08-13 dim.></span></span></a></li>
 </ul>
 </li>
 <li><a href="#sec-6-2">6.2. 5.0.0.2080 <span class="timestamp-wrapper"><span class="timestamp"><2016-04-27 mer.></span></span></a>
@@ -383,24 +386,25 @@ for the JavaScript code in this tag.
 <ul>
 <li><a href="#sec-7-1-1">7.1.1. <span class="todo TODO">TODO</span> <code>HklEngine</code> <b>q/q2</b></a></li>
 <li><a href="#sec-7-1-2">7.1.2. <span class="todo TODO">TODO</span> HklSource</a></li>
-<li><a href="#sec-7-1-3">7.1.3. <span class="todo TODO">TODO</span> <code>[0/2]</code> PetraIII</a></li>
-<li><a href="#sec-7-1-4">7.1.4. <span class="todo TODO">TODO</span> <code>[2/4]</code> HklParameter</a></li>
-<li><a href="#sec-7-1-5">7.1.5. <span class="todo TODO">TODO</span> This will help for the documentation and the gui.</a></li>
-<li><a href="#sec-7-1-6">7.1.6. <span class="todo TODO">TODO</span> HklGeometryList different method to help select a solution.</a></li>
-<li><a href="#sec-7-1-7">7.1.7. <span class="todo TODO">TODO</span> add a fit on the Hklaxis offsets.</a></li>
-<li><a href="#sec-7-1-8">7.1.8. <span class="todo TODO">TODO</span> API to put a detector and a sample on the Geometry.</a></li>
-<li><a href="#sec-7-1-9">7.1.9. <span class="todo TODO">TODO</span> HklSample</a></li>
-<li><a href="#sec-7-1-10">7.1.10. <span class="todo TODO">TODO</span> HklEngine "zone"</a></li>
-<li><a href="#sec-7-1-11">7.1.11. <span class="todo TODO">TODO</span> HklEngine "custom"</a></li>
-<li><a href="#sec-7-1-12">7.1.12. <span class="todo TODO">TODO</span> HklEngine "q/q2" add a "reflectivity" mode</a></li>
-<li><a href="#sec-7-1-13">7.1.13. <span class="todo TODO">TODO</span> create a macro to help compare two real the right way</a></li>
-<li><a href="#sec-7-1-14">7.1.14. <span class="todo TODO">TODO</span> add an hkl_sample_set_lattice_unit()</a></li>
-<li><a href="#sec-7-1-15">7.1.15. <span class="todo TODO">TODO</span> SOLEIL SIXS</a></li>
-<li><a href="#sec-7-1-16">7.1.16. <span class="todo TODO">TODO</span> generalisation of the z-axis hkl solver</a></li>
-<li><a href="#sec-7-1-17">7.1.17. <span class="todo TODO">TODO</span> investigate the prigo geometry.</a></li>
-<li><a href="#sec-7-1-18">7.1.18. <span class="todo TODO">TODO</span> augeas/elektra for the plugin configure part.</a></li>
-<li><a href="#sec-7-1-19">7.1.19. <span class="todo TODO">TODO</span> logging</a></li>
-<li><a href="#sec-7-1-20">7.1.20. <span class="todo TODO">TODO</span> performances</a></li>
+<li><a href="#sec-7-1-3">7.1.3. <span class="todo TODO">TODO</span> SOLEIL SIRIUS KAPPA</a></li>
+<li><a href="#sec-7-1-4">7.1.4. <span class="todo TODO">TODO</span> <code>[0/2]</code> PetraIII</a></li>
+<li><a href="#sec-7-1-5">7.1.5. <span class="todo TODO">TODO</span> <code>[2/4]</code> HklParameter</a></li>
+<li><a href="#sec-7-1-6">7.1.6. <span class="todo TODO">TODO</span> This will help for the documentation and the gui.</a></li>
+<li><a href="#sec-7-1-7">7.1.7. <span class="todo TODO">TODO</span> HklGeometryList different method to help select a solution.</a></li>
+<li><a href="#sec-7-1-8">7.1.8. <span class="todo TODO">TODO</span> add a fit on the Hklaxis offsets.</a></li>
+<li><a href="#sec-7-1-9">7.1.9. <span class="todo TODO">TODO</span> API to put a detector and a sample on the Geometry.</a></li>
+<li><a href="#sec-7-1-10">7.1.10. <span class="todo TODO">TODO</span> HklSample</a></li>
+<li><a href="#sec-7-1-11">7.1.11. <span class="todo TODO">TODO</span> HklEngine "zone"</a></li>
+<li><a href="#sec-7-1-12">7.1.12. <span class="todo TODO">TODO</span> HklEngine "custom"</a></li>
+<li><a href="#sec-7-1-13">7.1.13. <span class="todo TODO">TODO</span> HklEngine "q/q2" add a "reflectivity" mode</a></li>
+<li><a href="#sec-7-1-14">7.1.14. <span class="todo TODO">TODO</span> create a macro to help compare two real the right way</a></li>
+<li><a href="#sec-7-1-15">7.1.15. <span class="todo TODO">TODO</span> add an hkl_sample_set_lattice_unit()</a></li>
+<li><a href="#sec-7-1-16">7.1.16. <span class="todo TODO">TODO</span> SOLEIL SIXS</a></li>
+<li><a href="#sec-7-1-17">7.1.17. <span class="todo TODO">TODO</span> generalisation of the z-axis hkl solver</a></li>
+<li><a href="#sec-7-1-18">7.1.18. <span class="todo TODO">TODO</span> investigate the prigo geometry.</a></li>
+<li><a href="#sec-7-1-19">7.1.19. <span class="todo TODO">TODO</span> augeas/elektra for the plugin configure part.</a></li>
+<li><a href="#sec-7-1-20">7.1.20. <span class="todo TODO">TODO</span> logging</a></li>
+<li><a href="#sec-7-1-21">7.1.21. <span class="todo TODO">TODO</span> performances</a></li>
 </ul>
 </li>
 <li><a href="#sec-7-2">7.2. documentation</a>
@@ -500,9 +504,11 @@ pattern is located at each points of the lattice node. Positions of
 those nodes are given by:
 </p>
 
-\begin{displaymath}
-R_{uvw}=u\cdot\vec{a}+v\cdot\vec{b}+w\cdot\vec{c}
-\end{displaymath}
+<p>
+\[
+    R_{uvw}=u\cdot\vec{a}+v\cdot\vec{b}+w\cdot\vec{c}
+    \]
+</p>
 
 <p>
 \(\vec{a}\), \(\vec{b}\), \(\vec{c}\) are the former vector of a base of the
@@ -569,9 +575,11 @@ c^{\star} & = & \frac{\sin\gamma}{cD}
 where
 </p>
 
-\begin{displaymath}
-D=\sqrt{1-\cos^{2}\alpha-\cos^{2}\beta-\cos^{2}\gamma+2\cos\alpha\cos\beta\cos\gamma}
-\end{displaymath}
+<p>
+\[
+    D=\sqrt{1-\cos^{2}\alpha-\cos^{2}\beta-\cos^{2}\gamma+2\cos\alpha\cos\beta\cos\gamma}
+    \]
+</p>
 
 <p>
 To compute the angles between the reciprocal space vectors, it is once
@@ -590,21 +598,24 @@ sines and cosines of the angles \(\alpha^\star\), \(\beta^\star\) and
 the volume of the lattice can be compute this way:
 </p>
 
-\begin{displaymath}
-V = abcD
-\end{displaymath}
+<p>
+\[
+    V = abcD
+    \]
+</p>
 
 <p>
 or
 </p>
 
-\begin{displaymath}
-V = \vec{a} \dot (\vec{b} \wedge \vec{c}) = \vec{b} \dot (\vec{c} \wedge \vec{a}) = \vec{c} \dot (\vec{a} \wedge \vec{b})
-\end{displaymath}
+<p>
+\[
+    V = \vec{a} \dot (\vec{b} \wedge \vec{c}) = \vec{b} \dot (\vec{c} \wedge \vec{a}) = \vec{c} \dot (\vec{a} \wedge \vec{b})
+    \]
+</p>
 </div>
 </div>
 
-
 <div id="outline-container-sec-1-3-2" class="outline-4">
 <h4 id="sec-1-3-2"><span class="section-number-4">1.3.2</span> Diffraction</h4>
 <div class="outline-text-4" id="text-1-3-2">
@@ -615,9 +626,11 @@ The \(\vec{k_{d}}\) vector wavelength of the diffracted beam. There is
 diffusion if the diffusion vector \(\vec{q}\) can be expressed as follows:
 </p>
 
-\begin{displaymath}
-\vec{q}=\vec{k_{d}}-\vec{k_{i}}=h.\vec{a}^{*}+k.\vec{b}^{*}+l.\vec{c}^{*}
-\end{displaymath}
+<p>
+\[
+    \vec{q}=\vec{k_{d}}-\vec{k_{i}}=h.\vec{a}^{*}+k.\vec{b}^{*}+l.\vec{c}^{*}
+    \]
+</p>
 
 <p>
 where \((h,k,l)\in\mathbb{N}^{3}\) and \((h,k,l)\neq(0,0,0)\). Theses
@@ -629,9 +642,11 @@ Another way of looking at things has been given by Bragg and that famous
 relationship:
 </p>
 
-\begin{displaymath}
-n\lambda=2d\sin\theta
-\end{displaymath}
+<p>
+\[
+    n\lambda=2d\sin\theta
+    \]
+</p>
 
 <p>
 where \(d\) is the inter-plan distance and \(n \in \mathbb{N}\).
@@ -659,34 +674,42 @@ Theses quaternions can represent 3D rotations. There is different way to
 describe then like complex numbers.
 </p>
 
-\begin{displaymath}
-q=a+bi+cj+dk
-\end{displaymath}
+<p>
+\[
+     q=a+bi+cj+dk
+     \]
+</p>
 
 <p>
 or
 </p>
 
-\begin{displaymath}
-q=[a,\vec{v}]
-\end{displaymath}
+<p>
+\[
+     q=[a,\vec{v}]
+     \]
+</p>
 
 <p>
 To compute the quaternion's norm, we can proceed like for complex
 numbers
 </p>
 
-\begin{displaymath}
-\lvert q \rvert = \sqrt{a{{}^2}+b{{}^2}+c{{}^2}+d{{}^2}}
-\end{displaymath}
+<p>
+\[
+     \|q\|=\sqrt{a²+b²+c²+d²}
+     \]
+</p>
 
 <p>
 Its conjugate is :
 </p>
 
-\begin{displaymath}
-q^{*}=[a,-\vec{u}]=a-bi-cj-dk
-\end{displaymath}
+<p>
+\[
+     q^{*}=[a,-\vec{u}]=a-bi-cj-dk
+     \]
+</p>
 </div>
 </li>
 
@@ -696,11 +719,15 @@ The difference with the complex number algebra is about
 non-commutativity.
 </p>
 
-\begin{displaymath}
-qp \neq pq
-\end{displaymath}
+<p>
+\[
+     qp \neq pq
+     \]
+</p>
 
-\begin{displaymath}
+<p>
+\[
+</p>
 \begin{bmatrix}
 ~ & 1 & i  & j  & k \cr
 1 & 1 & i  & j  & k \cr
@@ -708,7 +735,9 @@ i & i & -1 & k  & -j \cr
 j & j & -k & -1 & i \cr
 k & k & j  & -i & -1
 \end{bmatrix}
-\end{displaymath}
+<p>
+\]
+</p>
 
 <p>
 The product of two quaternions can be express by the Grassman product
@@ -724,17 +753,21 @@ p &= t+\vec{v} = t+xi+yj+zk
 we got
 </p>
 
-\begin{displaymath}
-pq = at - \vec{u} \cdot \vec{v} + a \vec{v} + t \vec{u} + \vec{v} \times \vec{u}
-\end{displaymath}
+<p>
+\[
+     pq = at - \vec{u} \cdot \vec{v} + a \vec{v} + t \vec{u} + \vec{v} \times \vec{u}
+     \]
+</p>
 
 <p>
 or equivalent
 </p>
 
-\begin{displaymath}
-pq = (at - bx - cy - dz) + (bt + ax + cz - dy) i + (ct + ay + dx - bz) j + (dt + az + by - cx) k
-\end{displaymath}
+<p>
+\[
+     pq = (at - bx - cy - dz) + (bt + ax + cz - dy) i + (ct + ay + dx - bz) j + (dt + az + by - cx) k
+     \]
+</p>
 </div>
 </li>
 
@@ -756,9 +789,11 @@ rotation d'angle \(\theta\) autour de l'origine, dans l'espace 3D
 l'expression équivalente est:
 </p>
 
-\begin{displaymath}
-z'=qzq^{-1}
-\end{displaymath}
+<p>
+\[
+     z'=qzq^{-1}
+     \]
+</p>
 
 <p>
 où \(q\) est le quaternion de norme 1 représentant la rotation dans
@@ -772,22 +807,28 @@ Dans le cas des quaternions de norme 1, il est très facile de calculer
 rotation d'angle \(-\theta\). On a donc directement:
 </p>
 
-\begin{displaymath}
-q^{-1}=[\cos\frac{-\theta}{2},\sin\frac{-\theta}{2}\vec{u}]=[\cos\frac{\theta}{2},-\sin\frac{\theta}{2}\vec{u}]=q^{*}
-\end{displaymath}
+<p>
+\[
+     q^{-1}=[\cos\frac{-\theta}{2},\sin\frac{-\theta}{2}\vec{u}]=[\cos\frac{\theta}{2},-\sin\frac{\theta}{2}\vec{u}]=q^{*}
+     \]
+</p>
 
 <p>
 Le passage aux matrices de rotation se fait par la formule suivante
 \(q\rightarrow M\).
 </p>
 
-\begin{displaymath}
+<p>
+\[
+</p>
 \begin{bmatrix}
 a{{}^2}+b{{}^2}-c{{}^2}-d{{}^2} & 2bc-2ad & 2ac+2bd\\
 2ad+2bc & a{{}^2}-b{{}^2}+c{{}^2}-d{{}^2} & 2cd-2ab\\
 2bd-2ac & 2ab+2cd & a{{}^2}-b{{}^2}-c{{}^2}+d{{}^2}
 \end{bmatrix}
-\end{displaymath}
+<p>
+\]
+</p>
 
 <p>
 La composition de rotation se fait simplement en multipliant les
@@ -837,14 +878,18 @@ Si l'on connaît les paramètres cristallins du cristal étudié, il est
 très simple de calculer \(B\):
 </p>
 
-\begin{displaymath}
+<p>
+\[
 B=
+</p>
 \begin{bmatrix}
 a^{\star} & b^{\star}\cos\gamma^{\star} & c^{\star}\cos\beta^{\star}\\
 0 & b^{\star}\sin\gamma^{\star} & -c^{\star}\sin\beta^{\star}\cos\alpha\\
 0 & 0 & 1/c
 \end{bmatrix}
-\end{displaymath}
+<p>
+\]
+</p>
 </div>
 </div>
 
@@ -894,17 +939,21 @@ trièdres orthonormé \(T_{\vec{h}}\) et \(T_{\vec{Q}}\) à partir des vecteurs
 simplement:
 </p>
 
-\begin{displaymath}
-U \cdot T_{\vec{h}} = T_{\vec{Q}}
-\end{displaymath}
+<p>
+\[
+    U \cdot T_{\vec{h}} = T_{\vec{Q}}
+    \]
+</p>
 
 <p>
 Et donc
 </p>
 
-\begin{displaymath}
-U = T_{\vec{Q}} \cdot \tilde{T}_{\vec{h}}
-\end{displaymath}
+<p>
+\[
+    U = T_{\vec{Q}} \cdot \tilde{T}_{\vec{h}}
+    \]
+</p>
 </div>
 </div>
 
@@ -920,9 +969,11 @@ d'euler. il faut donc être en mesure de passer d'une représentation
 eulérien à cette matrice :math::U et réciproquement.
 </p>
 
-\begin{displaymath}
-U = X \cdot Y \cdot Z
-\end{displaymath}
+<p>
+\[
+    U = X \cdot Y \cdot Z
+    \]
+</p>
 
 <p>
 où \(X\) est la matrice rotation suivant l'axe Ox et le premier angle
@@ -960,14 +1011,18 @@ Oz.
 et donc:
 </p>
 
-\begin{displaymath}
+<p>
+\[
 U=
+</p>
 \begin{bmatrix}
 CE & -CF & D\\
 BDE+AF & -BDF+AE & -BC\\
 -ADE+BF & ADF+BE & AC
 \end{bmatrix}
-\end{displaymath}
+<p>
+\]
+</p>
 
 <p>
 Il est donc facile de passer des angles d'Euler à la matrice
@@ -1058,9 +1113,11 @@ or 2nd one
 where
 </p>
 
-\begin{displaymath}
-p = \arcsin\left(\frac{\tan\frac{\chi}{2}}{\tan\alpha}\right)
-\end{displaymath}
+<p>
+\[
+   p = \arcsin\left(\frac{\tan\frac{\chi}{2}}{\tan\alpha}\right)
+   \]
+</p>
 
 <p>
 and \(\alpha\) is the angle of the kappa axis with the \(\vec{y}\) axis.
@@ -1095,9 +1152,11 @@ or 2nd one
 where
 </p>
 
-\begin{displaymath}
-p = \arctan\left(\tan\frac{\kappa}{2} \cos\alpha\right)
-\end{displaymath}
+<p>
+\[
+   p = \arctan\left(\tan\frac{\kappa}{2} \cos\alpha\right)
+   \]
+</p>
 
 
 <div class="figure">
@@ -1632,6 +1691,42 @@ This section is automatically generating by introspecting the hkl library.
 </li>
 </ul>
 </div>
+</li>
+<li><a id="sec-3-2-2-5" name="sec-3-2-2-5"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-2-2-5">
+<ul class="org-ul">
+<li>pseudo axes:
+<ul class="org-ul">
+<li>"<b>emergence</b>" : incidence of the outgoing beam.
+</li>
+
+<li>"<b>azimuth</b>" : azimuth of the sample surface (projection of \(\vec{n}\) on the \(yOz\) plan
+</li>
+</ul>
+</li>
+</ul>
+
+
+<ul class="org-ul">
+<li>mode: "<b>emergence</b>"
+<ul class="org-ul">
+<li>axes (read) : "<b>omega</b>", "<b>chi</b>", "<b>phi</b>", "<b>tth</b>"
+</li>
+<li>axes (write): 
+</li>
+<li>parameters: 
+<ul class="org-ul">
+<li><b>x</b> [0.0]: the x coordinate of the surface \(\vec{n}\)
+</li>
+<li><b>y</b> [1.0]: the y coordinate of the surface \(\vec{n}\)
+</li>
+<li><b>z</b> [0.0]: the z coordinate of the surface \(\vec{n}\)
+</li>
+</ul>
+</li>
+</ul>
+</li>
+</ul>
+</div>
 </li></ol>
 </div>
 </div>
@@ -2820,12 +2915,98 @@ This section is automatically generating by introspecting the hkl library.
 </div>
 </div>
 <div id="outline-container-sec-3-6" class="outline-3">
-<h3 id="sec-3-6"><span class="section-number-3">3.6</span> PETRA3 P09 EH2</h3>
+<h3 id="sec-3-6"><span class="section-number-3">3.6</span> PETRA3 P08 LISA</h3>
 <div class="outline-text-3" id="text-3-6">
 </div><div id="outline-container-sec-3-6-1" class="outline-4">
 <h4 id="sec-3-6-1"><span class="section-number-4">3.6.1</span> Axes:</h4>
 <div class="outline-text-4" id="text-3-6-1">
 <ul class="org-ul">
+<li>"<b>mchi</b>": rotation around the <b>[1.0, 0.0, 0.0]</b> axis
+</li>
+<li>"<b>sphi</b>": rotation around the <b>[0.0, 0.0, 1.0]</b> axis
+</li>
+<li>"<b>dtth</b>": rotation around the <b>[0.0, 0.0, -1.0]</b> axis
+</li>
+<li>"<b>dh</b>": rotation around the <b>[0.0, 0.0, 1.0]</b> axis
+</li>
+<li>"<b>drot</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
+</li>
+</ul>
+</div>
+</div>
+<div id="outline-container-sec-3-6-2" class="outline-4">
+<h4 id="sec-3-6-2"><span class="section-number-4">3.6.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-6-2">
+</div><ol class="org-ol"><li><a id="sec-3-6-2-1" name="sec-3-6-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-6-2-1">
+<ul class="org-ul">
+<li>pseudo axes:
+<ul class="org-ul">
+<li>"<b>h</b>" : h coordinate of the diffracting plan
+</li>
+
+<li>"<b>k</b>" : k coordinate of the diffracting plan
+</li>
+
+<li>"<b>l</b>" : l coordinate of the diffracting plan
+</li>
+</ul>
+</li>
+</ul>
+
+
+<ul class="org-ul">
+<li>mode: "<b>k_parallel_incident</b>"
+<ul class="org-ul">
+<li>axes (read) : "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>axes (write): "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>parameters: No parameter
+</li>
+</ul>
+</li>
+<li>mode: "<b>alpha_eq_beta</b>"
+<ul class="org-ul">
+<li>axes (read) : "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>axes (write): "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>parameters: No parameter
+</li>
+</ul>
+</li>
+<li>mode: "<b>th_eq_tth2</b>"
+<ul class="org-ul">
+<li>axes (read) : "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>axes (write): "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>parameters: No parameter
+</li>
+</ul>
+</li>
+<li>mode: "<b>k_parallel_outgoing</b>"
+<ul class="org-ul">
+<li>axes (read) : "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>axes (write): "<b>mchi</b>", "<b>sphi</b>", "<b>dtth</b>", "<b>drot</b>"
+</li>
+<li>parameters: No parameter
+</li>
+</ul>
+</li>
+</ul>
+</div>
+</li></ol>
+</div>
+</div>
+<div id="outline-container-sec-3-7" class="outline-3">
+<h3 id="sec-3-7"><span class="section-number-3">3.7</span> PETRA3 P09 EH2</h3>
+<div class="outline-text-3" id="text-3-7">
+</div><div id="outline-container-sec-3-7-1" class="outline-4">
+<h4 id="sec-3-7-1"><span class="section-number-4">3.7.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-7-1">
+<ul class="org-ul">
 <li>"<b>mu</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
 </li>
 <li>"<b>omega</b>": rotation around the <b>[0.0, 0.0, 1.0]</b> axis
@@ -2841,10 +3022,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-6-2" class="outline-4">
-<h4 id="sec-3-6-2"><span class="section-number-4">3.6.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-6-2">
-</div><ol class="org-ol"><li><a id="sec-3-6-2-1" name="sec-3-6-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-6-2-1">
+<div id="outline-container-sec-3-7-2" class="outline-4">
+<h4 id="sec-3-7-2"><span class="section-number-4">3.7.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-7-2">
+</div><ol class="org-ol"><li><a id="sec-3-7-2-1" name="sec-3-7-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-7-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -2977,12 +3158,12 @@ This section is automatically generating by introspecting the hkl library.
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-7" class="outline-3">
-<h3 id="sec-3-7"><span class="section-number-3">3.7</span> SOLEIL MARS</h3>
-<div class="outline-text-3" id="text-3-7">
-</div><div id="outline-container-sec-3-7-1" class="outline-4">
-<h4 id="sec-3-7-1"><span class="section-number-4">3.7.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-7-1">
+<div id="outline-container-sec-3-8" class="outline-3">
+<h3 id="sec-3-8"><span class="section-number-3">3.8</span> SOLEIL MARS</h3>
+<div class="outline-text-3" id="text-3-8">
+</div><div id="outline-container-sec-3-8-1" class="outline-4">
+<h4 id="sec-3-8-1"><span class="section-number-4">3.8.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-8-1">
 <ul class="org-ul">
 <li>"<b>omega</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
 </li>
@@ -2995,10 +3176,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-7-2" class="outline-4">
-<h4 id="sec-3-7-2"><span class="section-number-4">3.7.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-7-2">
-</div><ol class="org-ol"><li><a id="sec-3-7-2-1" name="sec-3-7-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-7-2-1">
+<div id="outline-container-sec-3-8-2" class="outline-4">
+<h4 id="sec-3-8-2"><span class="section-number-4">3.8.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-8-2">
+</div><ol class="org-ol"><li><a id="sec-3-8-2-1" name="sec-3-8-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-8-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3097,7 +3278,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-7-2-2" name="sec-3-7-2-2"></a>"<b>psi</b>":<br  /><div class="outline-text-5" id="text-3-7-2-2">
+<li><a id="sec-3-8-2-2" name="sec-3-8-2-2"></a>"<b>psi</b>":<br  /><div class="outline-text-5" id="text-3-8-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3130,7 +3311,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-7-2-3" name="sec-3-7-2-3"></a>"<b>q</b>":<br  /><div class="outline-text-5" id="text-3-7-2-3">
+<li><a id="sec-3-8-2-3" name="sec-3-8-2-3"></a>"<b>q</b>":<br  /><div class="outline-text-5" id="text-3-8-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3155,7 +3336,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-7-2-4" name="sec-3-7-2-4"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-7-2-4">
+<li><a id="sec-3-8-2-4" name="sec-3-8-2-4"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-8-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3190,15 +3371,51 @@ This section is automatically generating by introspecting the hkl library.
 </li>
 </ul>
 </div>
+</li>
+<li><a id="sec-3-8-2-5" name="sec-3-8-2-5"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-8-2-5">
+<ul class="org-ul">
+<li>pseudo axes:
+<ul class="org-ul">
+<li>"<b>emergence</b>" : incidence of the outgoing beam.
+</li>
+
+<li>"<b>azimuth</b>" : azimuth of the sample surface (projection of \(\vec{n}\) on the \(yOz\) plan
+</li>
+</ul>
+</li>
+</ul>
+
+
+<ul class="org-ul">
+<li>mode: "<b>emergence</b>"
+<ul class="org-ul">
+<li>axes (read) : "<b>omega</b>", "<b>chi</b>", "<b>phi</b>", "<b>tth</b>"
+</li>
+<li>axes (write): 
+</li>
+<li>parameters: 
+<ul class="org-ul">
+<li><b>x</b> [0.0]: the x coordinate of the surface \(\vec{n}\)
+</li>
+<li><b>y</b> [1.0]: the y coordinate of the surface \(\vec{n}\)
+</li>
+<li><b>z</b> [0.0]: the z coordinate of the surface \(\vec{n}\)
+</li>
+</ul>
+</li>
+</ul>
+</li>
+</ul>
+</div>
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-8" class="outline-3">
-<h3 id="sec-3-8"><span class="section-number-3">3.8</span> SOLEIL SIRIUS KAPPA</h3>
-<div class="outline-text-3" id="text-3-8">
-</div><div id="outline-container-sec-3-8-1" class="outline-4">
-<h4 id="sec-3-8-1"><span class="section-number-4">3.8.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-8-1">
+<div id="outline-container-sec-3-9" class="outline-3">
+<h3 id="sec-3-9"><span class="section-number-3">3.9</span> SOLEIL SIRIUS KAPPA</h3>
+<div class="outline-text-3" id="text-3-9">
+</div><div id="outline-container-sec-3-9-1" class="outline-4">
+<h4 id="sec-3-9-1"><span class="section-number-4">3.9.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-9-1">
 <ul class="org-ul">
 <li>"<b>mu</b>": rotation around the <b>[0.0, 0.0, -1.0]</b> axis
 </li>
@@ -3215,10 +3432,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-8-2" class="outline-4">
-<h4 id="sec-3-8-2"><span class="section-number-4">3.8.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-8-2">
-</div><ol class="org-ol"><li><a id="sec-3-8-2-1" name="sec-3-8-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-8-2-1">
+<div id="outline-container-sec-3-9-2" class="outline-4">
+<h4 id="sec-3-9-2"><span class="section-number-4">3.9.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-9-2">
+</div><ol class="org-ol"><li><a id="sec-3-9-2-1" name="sec-3-9-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-9-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3433,7 +3650,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-2" name="sec-3-8-2-2"></a>"<b>eulerians</b>":<br  /><div class="outline-text-5" id="text-3-8-2-2">
+<li><a id="sec-3-9-2-2" name="sec-3-9-2-2"></a>"<b>eulerians</b>":<br  /><div class="outline-text-5" id="text-3-9-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3468,7 +3685,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-3" name="sec-3-8-2-3"></a>"<b>psi</b>":<br  /><div class="outline-text-5" id="text-3-8-2-3">
+<li><a id="sec-3-9-2-3" name="sec-3-9-2-3"></a>"<b>psi</b>":<br  /><div class="outline-text-5" id="text-3-9-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3501,7 +3718,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-4" name="sec-3-8-2-4"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-8-2-4">
+<li><a id="sec-3-9-2-4" name="sec-3-9-2-4"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-9-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3529,7 +3746,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-5" name="sec-3-8-2-5"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-8-2-5">
+<li><a id="sec-3-9-2-5" name="sec-3-9-2-5"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-9-2-5">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3565,7 +3782,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-6" name="sec-3-8-2-6"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-8-2-6">
+<li><a id="sec-3-9-2-6" name="sec-3-9-2-6"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-9-2-6">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3593,7 +3810,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-7" name="sec-3-8-2-7"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-8-2-7">
+<li><a id="sec-3-9-2-7" name="sec-3-9-2-7"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-9-2-7">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3629,7 +3846,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-8-2-8" name="sec-3-8-2-8"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-8-2-8">
+<li><a id="sec-3-9-2-8" name="sec-3-9-2-8"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-9-2-8">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3667,12 +3884,12 @@ This section is automatically generating by introspecting the hkl library.
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-9" class="outline-3">
-<h3 id="sec-3-9"><span class="section-number-3">3.9</span> SOLEIL SIRIUS TURRET</h3>
-<div class="outline-text-3" id="text-3-9">
-</div><div id="outline-container-sec-3-9-1" class="outline-4">
-<h4 id="sec-3-9-1"><span class="section-number-4">3.9.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-9-1">
+<div id="outline-container-sec-3-10" class="outline-3">
+<h3 id="sec-3-10"><span class="section-number-3">3.10</span> SOLEIL SIRIUS TURRET</h3>
+<div class="outline-text-3" id="text-3-10">
+</div><div id="outline-container-sec-3-10-1" class="outline-4">
+<h4 id="sec-3-10-1"><span class="section-number-4">3.10.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-10-1">
 <ul class="org-ul">
 <li>"<b>basepitch</b>": rotation around the <b>[0.0, 1.0, 0.0]</b> axis
 </li>
@@ -3689,10 +3906,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-9-2" class="outline-4">
-<h4 id="sec-3-9-2"><span class="section-number-4">3.9.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-9-2">
-</div><ol class="org-ol"><li><a id="sec-3-9-2-1" name="sec-3-9-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-9-2-1">
+<div id="outline-container-sec-3-10-2" class="outline-4">
+<h4 id="sec-3-10-2"><span class="section-number-4">3.10.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-10-2">
+</div><ol class="org-ol"><li><a id="sec-3-10-2-1" name="sec-3-10-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-10-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3723,7 +3940,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-9-2-2" name="sec-3-9-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-9-2-2">
+<li><a id="sec-3-10-2-2" name="sec-3-10-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-10-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3751,7 +3968,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-9-2-3" name="sec-3-9-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-9-2-3">
+<li><a id="sec-3-10-2-3" name="sec-3-10-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-10-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3787,7 +4004,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-9-2-4" name="sec-3-9-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-9-2-4">
+<li><a id="sec-3-10-2-4" name="sec-3-10-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-10-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3815,7 +4032,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-9-2-5" name="sec-3-9-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-9-2-5">
+<li><a id="sec-3-10-2-5" name="sec-3-10-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-10-2-5">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3851,7 +4068,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-9-2-6" name="sec-3-9-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-9-2-6">
+<li><a id="sec-3-10-2-6" name="sec-3-10-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-10-2-6">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3889,12 +4106,12 @@ This section is automatically generating by introspecting the hkl library.
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-10" class="outline-3">
-<h3 id="sec-3-10"><span class="section-number-3">3.10</span> SOLEIL SIXS MED1+2</h3>
-<div class="outline-text-3" id="text-3-10">
-</div><div id="outline-container-sec-3-10-1" class="outline-4">
-<h4 id="sec-3-10-1"><span class="section-number-4">3.10.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-10-1">
+<div id="outline-container-sec-3-11" class="outline-3">
+<h3 id="sec-3-11"><span class="section-number-3">3.11</span> SOLEIL SIXS MED1+2</h3>
+<div class="outline-text-3" id="text-3-11">
+</div><div id="outline-container-sec-3-11-1" class="outline-4">
+<h4 id="sec-3-11-1"><span class="section-number-4">3.11.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-11-1">
 <ul class="org-ul">
 <li>"<b>pitch</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
 </li>
@@ -3907,10 +4124,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-10-2" class="outline-4">
-<h4 id="sec-3-10-2"><span class="section-number-4">3.10.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-10-2">
-</div><ol class="org-ol"><li><a id="sec-3-10-2-1" name="sec-3-10-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-10-2-1">
+<div id="outline-container-sec-3-11-2" class="outline-4">
+<h4 id="sec-3-11-2"><span class="section-number-4">3.11.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-11-2">
+</div><ol class="org-ol"><li><a id="sec-3-11-2-1" name="sec-3-11-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-11-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3951,7 +4168,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-10-2-2" name="sec-3-10-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-10-2-2">
+<li><a id="sec-3-11-2-2" name="sec-3-11-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-11-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -3979,7 +4196,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-10-2-3" name="sec-3-10-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-10-2-3">
+<li><a id="sec-3-11-2-3" name="sec-3-11-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-11-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4015,7 +4232,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-10-2-4" name="sec-3-10-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-10-2-4">
+<li><a id="sec-3-11-2-4" name="sec-3-11-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-11-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4043,7 +4260,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-10-2-5" name="sec-3-10-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-10-2-5">
+<li><a id="sec-3-11-2-5" name="sec-3-11-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-11-2-5">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4079,7 +4296,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-10-2-6" name="sec-3-10-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-10-2-6">
+<li><a id="sec-3-11-2-6" name="sec-3-11-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-11-2-6">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4117,12 +4334,12 @@ This section is automatically generating by introspecting the hkl library.
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-11" class="outline-3">
-<h3 id="sec-3-11"><span class="section-number-3">3.11</span> SOLEIL SIXS MED2+2</h3>
-<div class="outline-text-3" id="text-3-11">
-</div><div id="outline-container-sec-3-11-1" class="outline-4">
-<h4 id="sec-3-11-1"><span class="section-number-4">3.11.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-11-1">
+<div id="outline-container-sec-3-12" class="outline-3">
+<h3 id="sec-3-12"><span class="section-number-3">3.12</span> SOLEIL SIXS MED2+2</h3>
+<div class="outline-text-3" id="text-3-12">
+</div><div id="outline-container-sec-3-12-1" class="outline-4">
+<h4 id="sec-3-12-1"><span class="section-number-4">3.12.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-12-1">
 <ul class="org-ul">
 <li>"<b>beta</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
 </li>
@@ -4137,10 +4354,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-11-2" class="outline-4">
-<h4 id="sec-3-11-2"><span class="section-number-4">3.11.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-11-2">
-</div><ol class="org-ol"><li><a id="sec-3-11-2-1" name="sec-3-11-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-11-2-1">
+<div id="outline-container-sec-3-12-2" class="outline-4">
+<h4 id="sec-3-12-2"><span class="section-number-4">3.12.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-12-2">
+</div><ol class="org-ol"><li><a id="sec-3-12-2-1" name="sec-3-12-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-12-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4201,7 +4418,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-11-2-2" name="sec-3-11-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-11-2-2">
+<li><a id="sec-3-12-2-2" name="sec-3-12-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-12-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4229,7 +4446,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-11-2-3" name="sec-3-11-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-11-2-3">
+<li><a id="sec-3-12-2-3" name="sec-3-12-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-12-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4265,7 +4482,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-11-2-4" name="sec-3-11-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-11-2-4">
+<li><a id="sec-3-12-2-4" name="sec-3-12-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-12-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4293,7 +4510,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-11-2-5" name="sec-3-11-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-11-2-5">
+<li><a id="sec-3-12-2-5" name="sec-3-12-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-12-2-5">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4329,7 +4546,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-11-2-6" name="sec-3-11-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-11-2-6">
+<li><a id="sec-3-12-2-6" name="sec-3-12-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-12-2-6">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4367,12 +4584,12 @@ This section is automatically generating by introspecting the hkl library.
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-12" class="outline-3">
-<h3 id="sec-3-12"><span class="section-number-3">3.12</span> SOLEIL SIXS MED2+3</h3>
-<div class="outline-text-3" id="text-3-12">
-</div><div id="outline-container-sec-3-12-1" class="outline-4">
-<h4 id="sec-3-12-1"><span class="section-number-4">3.12.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-12-1">
+<div id="outline-container-sec-3-13" class="outline-3">
+<h3 id="sec-3-13"><span class="section-number-3">3.13</span> SOLEIL SIXS MED2+3</h3>
+<div class="outline-text-3" id="text-3-13">
+</div><div id="outline-container-sec-3-13-1" class="outline-4">
+<h4 id="sec-3-13-1"><span class="section-number-4">3.13.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-13-1">
 <ul class="org-ul">
 <li>"<b>beta</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
 </li>
@@ -4389,10 +4606,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-12-2" class="outline-4">
-<h4 id="sec-3-12-2"><span class="section-number-4">3.12.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-12-2">
-</div><ol class="org-ol"><li><a id="sec-3-12-2-1" name="sec-3-12-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-12-2-1">
+<div id="outline-container-sec-3-13-2" class="outline-4">
+<h4 id="sec-3-13-2"><span class="section-number-4">3.13.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-13-2">
+</div><ol class="org-ol"><li><a id="sec-3-13-2-1" name="sec-3-13-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-13-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4453,7 +4670,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-12-2-2" name="sec-3-12-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-12-2-2">
+<li><a id="sec-3-13-2-2" name="sec-3-13-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-13-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4481,7 +4698,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-12-2-3" name="sec-3-12-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-12-2-3">
+<li><a id="sec-3-13-2-3" name="sec-3-13-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-13-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4517,7 +4734,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-12-2-4" name="sec-3-12-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-12-2-4">
+<li><a id="sec-3-13-2-4" name="sec-3-13-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-13-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4545,7 +4762,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-12-2-5" name="sec-3-12-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-12-2-5">
+<li><a id="sec-3-13-2-5" name="sec-3-13-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-13-2-5">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4581,7 +4798,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-12-2-6" name="sec-3-12-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-12-2-6">
+<li><a id="sec-3-13-2-6" name="sec-3-13-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-13-2-6">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4619,12 +4836,12 @@ This section is automatically generating by introspecting the hkl library.
 </li></ol>
 </div>
 </div>
-<div id="outline-container-sec-3-13" class="outline-3">
-<h3 id="sec-3-13"><span class="section-number-3">3.13</span> TwoC</h3>
-<div class="outline-text-3" id="text-3-13">
-</div><div id="outline-container-sec-3-13-1" class="outline-4">
-<h4 id="sec-3-13-1"><span class="section-number-4">3.13.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-13-1">
+<div id="outline-container-sec-3-14" class="outline-3">
+<h3 id="sec-3-14"><span class="section-number-3">3.14</span> TwoC</h3>
+<div class="outline-text-3" id="text-3-14">
+</div><div id="outline-container-sec-3-14-1" class="outline-4">
+<h4 id="sec-3-14-1"><span class="section-number-4">3.14.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-14-1">
 <ul class="org-ul">
 <li>"<b>omega</b>": rotation around the <b>[0.0, -1.0, 0.0]</b> axis
 </li>
@@ -4633,16 +4850,16 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-13-2" class="outline-4">
-<h4 id="sec-3-13-2"><span class="section-number-4">3.13.2</span> Engines:</h4>
+<div id="outline-container-sec-3-14-2" class="outline-4">
+<h4 id="sec-3-14-2"><span class="section-number-4">3.14.2</span> Engines:</h4>
 </div>
 </div>
-<div id="outline-container-sec-3-14" class="outline-3">
-<h3 id="sec-3-14"><span class="section-number-3">3.14</span> ZAXIS</h3>
-<div class="outline-text-3" id="text-3-14">
-</div><div id="outline-container-sec-3-14-1" class="outline-4">
-<h4 id="sec-3-14-1"><span class="section-number-4">3.14.1</span> Axes:</h4>
-<div class="outline-text-4" id="text-3-14-1">
+<div id="outline-container-sec-3-15" class="outline-3">
+<h3 id="sec-3-15"><span class="section-number-3">3.15</span> ZAXIS</h3>
+<div class="outline-text-3" id="text-3-15">
+</div><div id="outline-container-sec-3-15-1" class="outline-4">
+<h4 id="sec-3-15-1"><span class="section-number-4">3.15.1</span> Axes:</h4>
+<div class="outline-text-4" id="text-3-15-1">
 <ul class="org-ul">
 <li>"<b>mu</b>": rotation around the <b>[0.0, 0.0, 1.0]</b> axis
 </li>
@@ -4655,10 +4872,10 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-3-14-2" class="outline-4">
-<h4 id="sec-3-14-2"><span class="section-number-4">3.14.2</span> Engines:</h4>
-<div class="outline-text-4" id="text-3-14-2">
-</div><ol class="org-ol"><li><a id="sec-3-14-2-1" name="sec-3-14-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-14-2-1">
+<div id="outline-container-sec-3-15-2" class="outline-4">
+<h4 id="sec-3-15-2"><span class="section-number-4">3.15.2</span> Engines:</h4>
+<div class="outline-text-4" id="text-3-15-2">
+</div><ol class="org-ol"><li><a id="sec-3-15-2-1" name="sec-3-15-2-1"></a>"<b>hkl</b>":<br  /><div class="outline-text-5" id="text-3-15-2-1">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4699,7 +4916,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-14-2-2" name="sec-3-14-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-14-2-2">
+<li><a id="sec-3-15-2-2" name="sec-3-15-2-2"></a>"<b>q2</b>":<br  /><div class="outline-text-5" id="text-3-15-2-2">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4727,7 +4944,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-14-2-3" name="sec-3-14-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-14-2-3">
+<li><a id="sec-3-15-2-3" name="sec-3-15-2-3"></a>"<b>qper_qpar</b>":<br  /><div class="outline-text-5" id="text-3-15-2-3">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4763,7 +4980,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-14-2-4" name="sec-3-14-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-14-2-4">
+<li><a id="sec-3-15-2-4" name="sec-3-15-2-4"></a>"<b>tth2</b>":<br  /><div class="outline-text-5" id="text-3-15-2-4">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4791,7 +5008,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-14-2-5" name="sec-3-14-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-14-2-5">
+<li><a id="sec-3-15-2-5" name="sec-3-15-2-5"></a>"<b>incidence</b>":<br  /><div class="outline-text-5" id="text-3-15-2-5">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4827,7 +5044,7 @@ This section is automatically generating by introspecting the hkl library.
 </ul>
 </div>
 </li>
-<li><a id="sec-3-14-2-6" name="sec-3-14-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-14-2-6">
+<li><a id="sec-3-15-2-6" name="sec-3-15-2-6"></a>"<b>emergence</b>":<br  /><div class="outline-text-5" id="text-3-15-2-6">
 <ul class="org-ul">
 <li>pseudo axes:
 <ul class="org-ul">
@@ -4903,7 +5120,7 @@ then checkout the next branch like this:
 
 <div class="org-src-container">
 
-<pre class="src src-sh">cd hkl
+<pre class="src src-sh"><span style="font-weight: bold;">cd</span> hkl
 git checkout -b next origin/next
 </pre>
 </div>
@@ -5029,7 +5246,7 @@ You can find the bug tracker here
 <li>Other OS
 
 <p>
-You just need to send an <a href="mailto:submit at bugs.debian.org?subject=%20My%20problem%20with%20hkl...&body=Package:%20hkl%0AVersion:%205.0.0.2173%0A%0AI%20found%20this%20problem%20in%20hkl">email</a>
+You just need to send an <a href="mailto:submit at bugs.debian.org?subject=%20My%20problem%20with%20hkl...&body=Package:%20hkl%0AVersion:%205.0.0.2428%0A%0AI%20found%20this%20problem%20in%20hkl">email</a>
 </p>
 </li>
 </ul>
@@ -5099,7 +5316,7 @@ patches for review.
 
 <div class="org-src-container">
 
-<pre class="src src-sh">git config sendemail.to "picca at synchrotron-soleil.fr"
+<pre class="src src-sh">git config sendemail.to <span style="font-style: italic;">"picca at synchrotron-soleil.fr"</span>
 </pre>
 </div>
 
@@ -5167,7 +5384,7 @@ the process a make target was written. You just need to type:
 </p>
 <div class="org-src-container">
 
-<pre class="src src-sh">cd Documentation
+<pre class="src src-sh"><span style="font-weight: bold;">cd</span> Documentation
 make doc-edit
 </pre>
 </div>
@@ -5212,7 +5429,7 @@ these commandes if ipython is installed.
 
 <div class="org-src-container">
 
-<pre class="src src-sh">cd tests/bindings
+<pre class="src src-sh"><span style="font-weight: bold;">cd</span> tests/bindings
 make ipython
 </pre>
 </div>
@@ -5357,12 +5574,20 @@ use only the closest solution for the next points of the trajectory.
 <h2 id="sec-6"><span class="section-number-2">6</span> Releases</h2>
 <div class="outline-text-2" id="text-6">
 </div><div id="outline-container-sec-6-1" class="outline-3">
-<h3 id="sec-6-1"><span class="section-number-3">6.1</span> 5.0.0.2173</h3>
+<h3 id="sec-6-1"><span class="section-number-3">6.1</span> 5.0.0.2428</h3>
 <div class="outline-text-3" id="text-6-1">
 </div><div id="outline-container-sec-6-1-1" class="outline-4">
-<h4 id="sec-6-1-1"><span class="section-number-4">6.1.1</span> <span class="done DONE">DONE</span> Fix for multiarch (headers) <span class="timestamp-wrapper"><span class="timestamp"><2016-05-04 mer.></span></span></h4>
+<h4 id="sec-6-1-1"><span class="section-number-4">6.1.1</span> <span class="done DONE">DONE</span> add emergence on all e4c diffractometers <span class="timestamp-wrapper"><span class="timestamp"><2017-03-16 Thu></span></span></h4>
 <div class="outline-text-4" id="text-6-1-1">
 <p>
+The emergence pseudo axis is was added to <code>SOLEIL MARS</code> and <code>E4CV</code>
+</p>
+</div>
+</div>
+<div id="outline-container-sec-6-1-2" class="outline-4">
+<h4 id="sec-6-1-2"><span class="section-number-4">6.1.2</span> <span class="done DONE">DONE</span> Fix for multiarch (headers) <span class="timestamp-wrapper"><span class="timestamp"><2016-05-04 mer.></span></span></h4>
+<div class="outline-text-4" id="text-6-1-2">
+<p>
 The <code>ccan_config.h</code> generated file is arch specific. It is then
 necessary to install this file under /usr/include/<triplet> on
 Debian like systems. This way it will be possible to co-installa
@@ -5371,6 +5596,19 @@ x86_64, etc&#x2026;)
 </p>
 </div>
 </div>
+<div id="outline-container-sec-6-1-3" class="outline-4">
+<h4 id="sec-6-1-3"><span class="section-number-4">6.1.3</span> <span class="done DONE">DONE</span> Fix the FTBFS with the new bullet 2.86.1 version <span class="timestamp-wrapper"><span class="timestamp"><2017-08-13 dim.></span></span></h4>
+<div class="outline-text-4" id="text-6-1-3">
+<p>
+In order to update the internal structures of <code>Hkl3DObject</code> (the
+<code>is-colliding</code> member), we were using a callback which became
+un-effectiv with this new version of bullet. The logic was
+rewritten in order to be much more efficent using the manifold
+informations. Now we iterate on <code>Hkl3DObject</code> object only once
+(n) complexity instead of (n²) with the previous one.
+</p>
+</div>
+</div>
 </div>
 <div id="outline-container-sec-6-2" class="outline-3">
 <h3 id="sec-6-2"><span class="section-number-3">6.2</span> 5.0.0.2080 <span class="timestamp-wrapper"><span class="timestamp"><2016-04-27 mer.></span></span></h3>
@@ -5411,8 +5649,8 @@ possible to get the sample or the detector rotation expressed as a
 </p>
 <div class="org-src-container">
 
-<pre class="src src-python">qr = geometry.sample_rotation_get(sample)
-qd = geometry.detector_rotation_get(detector)
+<pre class="src src-python"><span style="font-weight: bold; font-style: italic;">qr</span> = geometry.sample_rotation_get(sample)
+<span style="font-weight: bold; font-style: italic;">qd</span> = geometry.detector_rotation_get(detector)
 </pre>
 </div>
 </div>
@@ -5427,15 +5665,15 @@ into a numpy array when used from the python binding
 </p>
 <div class="org-src-container">
 
-<pre class="src src-python">def hkl_matrix_to_numpy(m):
-    M = empty((3, 3))
-    for i in range(3):
-	for j in range(3):
-	    M[i, j] = m.get(i, j)
-    return M
+<pre class="src src-python"><span style="font-weight: bold;">def</span> <span style="font-weight: bold;">hkl_matrix_to_numpy</span>(m):
+    <span style="font-weight: bold; font-style: italic;">M</span> = empty((3, 3))
+    <span style="font-weight: bold;">for</span> i <span style="font-weight: bold;">in</span> <span style="font-weight: bold;">range</span>(3):
+        <span style="font-weight: bold;">for</span> j <span style="font-weight: bold;">in</span> <span style="font-weight: bold;">range</span>(3):
+            <span style="font-weight: bold; font-style: italic;">M</span>[i, j] = m.get(i, j)
+    <span style="font-weight: bold;">return</span> M
 
 
-M = hkl_matrix_to_numpy(q.to_matrix())
+<span style="font-weight: bold; font-style: italic;">M</span> = hkl_matrix_to_numpy(q.to_matrix())
 </pre>
 </div>
 </div>
@@ -5535,11 +5773,11 @@ possible values are stored in the <code>HklEngineDependencies</code> enum.
 <div class="org-src-container">
 
 <pre class="src src-c">dependencies = hkl_engine_dependencies_get(engine);
-if (dependencies & HKL_ENGINE_DEPENDENCIES_ENERGY) {
-	...
+<span style="font-weight: bold;">if</span> (dependencies & HKL_ENGINE_DEPENDENCIES_ENERGY) {
+        ...
 }
-if (dependencies & HKL_ENGINE_DEPENDENCIES_SAMPLE) {
-	...
+<span style="font-weight: bold;">if</span> (dependencies & HKL_ENGINE_DEPENDENCIES_SAMPLE) {
+        ...
 }
 ...
 </pre>
@@ -5594,7 +5832,7 @@ gamma in the bindings.
 </p>
 <div class="org-src-container">
 
-<pre class="src src-python">a = lattice.a_get()
+<pre class="src src-python"><span style="font-weight: bold; font-style: italic;">a</span> = lattice.a_get()
 lattice.a_set(a)
 </pre>
 </div>
@@ -5609,10 +5847,10 @@ via the bindings.
 </p>
 <div class="org-src-container">
 
-<pre class="src src-python">flag = reflection.flag_get()
+<pre class="src src-python"><span style="font-weight: bold; font-style: italic;">flag</span> = reflection.flag_get()
 reflection.flag_set(flag)
 
-geometry = reflection.geometry_get()
+<span style="font-weight: bold; font-style: italic;">geometry</span> = reflection.geometry_get()
 geometry.axes_values_set([omega, chi, phi, ...])
 reflection.geometry_set(geometry)
 </pre>
@@ -5651,9 +5889,66 @@ hkl_geometry_vawelength get/set
 </div>
 </div>
 <div id="outline-container-sec-7-1-3" class="outline-4">
-<h4 id="sec-7-1-3"><span class="section-number-4">7.1.3</span> <span class="todo TODO">TODO</span> <code>[0/2]</code> PetraIII</h4>
+<h4 id="sec-7-1-3"><span class="section-number-4">7.1.3</span> <span class="todo TODO">TODO</span> SOLEIL SIRIUS KAPPA</h4>
 <div class="outline-text-4" id="text-7-1-3">
-</div><ol class="org-ol"><li><a id="sec-7-1-3-1" name="sec-7-1-3-1"></a><span class="todo TODO">TODO</span> computation problem<br  /><div class="outline-text-5" id="text-7-1-3-1">
+<p>
+Investigation of a problem saw on Sirius Kappa geometry. The idea
+is to compute a trajectory from \([0, 0, 1]\) to \([0, 0, 6]\) on a
+\(GaAs\) sample.
+</p>
+
+<div class="org-src-container">
+
+<pre class="src src-sh">Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,40.795148838481424,134.08834052117254,-55.57809067120416,-2.23369e-2,14.824478553649875]) (Just [Parameter <span style="font-style: italic;">"mu"</span> (-0.5193202) (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"komega"</span> 40.795148838481424 (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"kappa"</span> 134.08834052117254 (Range (-180.0) [...]
+[Engine <span style="font-style: italic;">"hkl"</span> [Parameter <span style="font-style: italic;">"h"</span> 2.1481674408578524e-8 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"k"</span> 6.392014061803081e-8 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"l"</span> 1.0000000132413767 (Range (-1.0) 1.0)] (Mode <span style="font-style: italic;">"bissector_vertical"</span> []),Engine <span style="font-style: italic;">"eulerians"</span> [Parameter <span st [...]
+Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,47.97247473743512,134.654265266118,124.92415016158583,-2.23369e-2,29.904632884360968]) (Just [Parameter <span style="font-style: italic;">"mu"</span> (-0.5193202) (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"komega"</span> 47.97247473743512 (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"kappa"</span> 134.654265266118 (Range (-180.0) 180.0),Parameter <span style= [...]
+[Engine <span style="font-style: italic;">"hkl"</span> [Parameter <span style="font-style: italic;">"h"</span> (-1.3839931497468412e-9) (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"k"</span> (-4.913404854447784e-10) (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"l"</span> 2.000000003360829 (Range (-1.0) 1.0)] (Mode <span style="font-style: italic;">"bissector_vertical"</span> []),Engine <span style="font-style: italic;">"eulerians"</span> [Parameter <s [...]
+Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,56.25907471532187,133.92128004831832,-55.45556970293517,-2.23369e-2,45.53873596992208]) (Just [Parameter <span style="font-style: italic;">"mu"</span> (-0.5193202) (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"komega"</span> 56.25907471532187 (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"kappa"</span> 133.92128004831832 (Range (-180.0) 180.0),Parameter <span sty [...]
+[Engine <span style="font-style: italic;">"hkl"</span> [Parameter <span style="font-style: italic;">"h"</span> 8.37724528421826e-9 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"k"</span> 2.018612859089285e-8 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"l"</span> 2.999999983141756 (Range (-1.0) 1.0)] (Mode <span style="font-style: italic;">"bissector_vertical"</span> []),Engine <span style="font-style: italic;">"eulerians"</span> [Parameter <span style [...]
+Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,64.64191214924969,133.78682078017752,-55.41938838621407,-2.23369e-2,62.132688461209455]) (Just [Parameter <span style="font-style: italic;">"mu"</span> (-0.5193202) (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"komega"</span> 64.64191214924969 (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"kappa"</span> 133.78682078017752 (Range (-180.0) 180.0),Parameter <span st [...]
+[Engine <span style="font-style: italic;">"hkl"</span> [Parameter <span style="font-style: italic;">"h"</span> 9.177457430250849e-9 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"k"</span> 2.5693823994163015e-8 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"l"</span> 3.9999999929703476 (Range (-1.0) 1.0)] (Mode <span style="font-style: italic;">"bissector_vertical"</span> []),Engine <span style="font-style: italic;">"eulerians"</span> [Parameter <span st [...]
+Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,73.83399863752925,133.64586701159254,-55.35712475482595,-2.23369e-2,80.33702663350934]) (Just [Parameter <span style="font-style: italic;">"mu"</span> (-0.5193202) (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"komega"</span> 73.83399863752925 (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"kappa"</span> 133.64586701159254 (Range (-180.0) 180.0),Parameter <span sty [...]
+[Engine <span style="font-style: italic;">"hkl"</span> [Parameter <span style="font-style: italic;">"h"</span> 2.7577312257761425e-9 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"k"</span> 7.650403950118726e-9 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"l"</span> 4.999999999622215 (Range (-1.0) 1.0)] (Mode <span style="font-style: italic;">"bissector_vertical"</span> []),Engine <span style="font-style: italic;">"eulerians"</span> [Parameter <span sty [...]
+Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,84.086619565407,134.11156620489382,125.37371040144704,-2.23369e-2,101.43713587367031]) (Just [Parameter <span style="font-style: italic;">"mu"</span> (-0.5193202) (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"komega"</span> 84.086619565407 (Range (-180.0) 180.0),Parameter <span style="font-style: italic;">"kappa"</span> 134.11156620489382 (Range (-180.0) 180.0),Parameter <span style= [...]
+[Engine <span style="font-style: italic;">"hkl"</span> [Parameter <span style="font-style: italic;">"h"</span> 8.392762843275724e-10 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"k"</span> 2.459154264227675e-9 (Range (-1.0) 1.0),Parameter <span style="font-style: italic;">"l"</span> 6.0000000015375905 (Range (-1.0) 1.0)] (Mode <span style="font-style: italic;">"bissector_vertical"</span> []),Engine <span style="font-style: italic;">"eulerians"</span> [Parameter <span st [...]
+</pre>
+</div>
+
+<p>
+As we can see the phi and kphi motor switch from time to time to
+another solution which is at around 180° of the other solutions.
+</p>
+
+
+<div class="figure">
+<p><img src="figures/sirius-s.svg" alt="sirius-s.svg" />
+</p>
+</div>
+
+
+<div class="figure">
+<p><img src="figures/sirius-m.svg" alt="sirius-m.svg" />
+</p>
+</div>
+
+
+<div class="figure">
+<p><img src="figures/sirius-m-zoom.svg" alt="sirius-m-zoom.svg" />
+</p>
+</div>
+
+
+<div class="figure">
+<p><img src="figures/traj_n.svg" alt="traj_n.svg" />
+</p>
+</div>
+</div>
+</div>
+
+<div id="outline-container-sec-7-1-4" class="outline-4">
+<h4 id="sec-7-1-4"><span class="section-number-4">7.1.4</span> <span class="todo TODO">TODO</span> <code>[0/2]</code> PetraIII</h4>
+<div class="outline-text-4" id="text-7-1-4">
+</div><ol class="org-ol"><li><a id="sec-7-1-4-1" name="sec-7-1-4-1"></a><span class="todo TODO">TODO</span> computation problem<br  /><div class="outline-text-5" id="text-7-1-4-1">
 <p>
 Dear Teresa,
 </p>
@@ -5807,7 +6102,7 @@ SaveDirectory <i>home/p09user/crystals</i>
 </div>
 </li>
 
-<li><a id="sec-7-1-3-2" name="sec-7-1-3-2"></a><span class="todo TODO">TODO</span> another question<br  /><div class="outline-text-5" id="text-7-1-3-2">
+<li><a id="sec-7-1-4-2" name="sec-7-1-4-2"></a><span class="todo TODO">TODO</span> another question<br  /><div class="outline-text-5" id="text-7-1-4-2">
 <p>
 J'ai un probleme avec la position que le controlleur calcule avec la
 matrice UB que nous t'avons envoye.
@@ -5830,9 +6125,9 @@ ta librairie ?
 </div>
 </li></ol>
 </div>
-<div id="outline-container-sec-7-1-4" class="outline-4">
-<h4 id="sec-7-1-4"><span class="section-number-4">7.1.4</span> <span class="todo TODO">TODO</span> <code>[2/4]</code> HklParameter</h4>
-<div class="outline-text-4" id="text-7-1-4">
+<div id="outline-container-sec-7-1-5" class="outline-4">
+<h4 id="sec-7-1-5"><span class="section-number-4">7.1.5</span> <span class="todo TODO">TODO</span> <code>[2/4]</code> HklParameter</h4>
+<div class="outline-text-4" id="text-7-1-5">
 <ul class="org-ul">
 <li><code>[X]</code> method to use min/max to check for the validity
 </li>
@@ -5850,28 +6145,28 @@ for this degenerescencence.
 </ul>
 </div>
 </div>
-<div id="outline-container-sec-7-1-5" class="outline-4">
-<h4 id="sec-7-1-5"><span class="section-number-4">7.1.5</span> <span class="todo TODO">TODO</span> This will help for the documentation and the gui.</h4>
-</div>
 <div id="outline-container-sec-7-1-6" class="outline-4">
-<h4 id="sec-7-1-6"><span class="section-number-4">7.1.6</span> <span class="todo TODO">TODO</span> HklGeometryList different method to help select a solution.</h4>
-<div class="outline-text-4" id="text-7-1-6">
+<h4 id="sec-7-1-6"><span class="section-number-4">7.1.6</span> <span class="todo TODO">TODO</span> This will help for the documentation and the gui.</h4>
+</div>
+<div id="outline-container-sec-7-1-7" class="outline-4">
+<h4 id="sec-7-1-7"><span class="section-number-4">7.1.7</span> <span class="todo TODO">TODO</span> HklGeometryList different method to help select a solution.</h4>
+<div class="outline-text-4" id="text-7-1-7">
 <p>
 this select solution can depend on the geometry
 for example the kappa axis must be in one side of the plane.
 </p>
 </div>
 </div>
-<div id="outline-container-sec-7-1-7" class="outline-4">
-<h4 id="sec-7-1-7"><span class="section-number-4">7.1.7</span> <span class="todo TODO">TODO</span> add a fit on the Hklaxis offsets.</h4>
-</div>
 <div id="outline-container-sec-7-1-8" class="outline-4">
-<h4 id="sec-7-1-8"><span class="section-number-4">7.1.8</span> <span class="todo TODO">TODO</span> API to put a detector and a sample on the Geometry.</h4>
+<h4 id="sec-7-1-8"><span class="section-number-4">7.1.8</span> <span class="todo TODO">TODO</span> add a fit on the Hklaxis offsets.</h4>
 </div>
 <div id="outline-container-sec-7-1-9" class="outline-4">
-<h4 id="sec-7-1-9"><span class="section-number-4">7.1.9</span> <span class="todo TODO">TODO</span> HklSample</h4>
-<div class="outline-text-4" id="text-7-1-9">
-</div><ol class="org-ol"><li><a id="sec-7-1-9-1" name="sec-7-1-9-1"></a><span class="todo TODO">TODO</span> unit test: hkl_sample_affine.<br  /><div class="outline-text-5" id="text-7-1-9-1">
+<h4 id="sec-7-1-9"><span class="section-number-4">7.1.9</span> <span class="todo TODO">TODO</span> API to put a detector and a sample on the Geometry.</h4>
+</div>
+<div id="outline-container-sec-7-1-10" class="outline-4">
+<h4 id="sec-7-1-10"><span class="section-number-4">7.1.10</span> <span class="todo TODO">TODO</span> HklSample</h4>
+<div class="outline-text-4" id="text-7-1-10">
+</div><ol class="org-ol"><li><a id="sec-7-1-10-1" name="sec-7-1-10-1"></a><span class="todo TODO">TODO</span> unit test: hkl_sample_affine.<br  /><div class="outline-text-5" id="text-7-1-10-1">
 <p>
 Check this:
 lattice=1.540000;1.540000;1.540000;90.000000;90.000000;90.000000;0;0;0;0;0;0
@@ -5893,42 +6188,42 @@ warn the user about this.
 </div>
 </li></ol>
 </div>
-<div id="outline-container-sec-7-1-10" class="outline-4">
-<h4 id="sec-7-1-10"><span class="section-number-4">7.1.10</span> <span class="todo TODO">TODO</span> HklEngine "zone"</h4>
-</div>
 <div id="outline-container-sec-7-1-11" class="outline-4">
-<h4 id="sec-7-1-11"><span class="section-number-4">7.1.11</span> <span class="todo TODO">TODO</span> HklEngine "custom"</h4>
-<div class="outline-text-4" id="text-7-1-11">
+<h4 id="sec-7-1-11"><span class="section-number-4">7.1.11</span> <span class="todo TODO">TODO</span> HklEngine "zone"</h4>
+</div>
+<div id="outline-container-sec-7-1-12" class="outline-4">
+<h4 id="sec-7-1-12"><span class="section-number-4">7.1.12</span> <span class="todo TODO">TODO</span> HklEngine "custom"</h4>
+<div class="outline-text-4" id="text-7-1-12">
 <p>
 for now this pseudoaxis let you select the axis you
 want to use for the computation.
 </p>
 </div>
 </div>
-<div id="outline-container-sec-7-1-12" class="outline-4">
-<h4 id="sec-7-1-12"><span class="section-number-4">7.1.12</span> <span class="todo TODO">TODO</span> HklEngine "q/q2" add a "reflectivity" mode</h4>
-<div class="outline-text-4" id="text-7-1-12">
+<div id="outline-container-sec-7-1-13" class="outline-4">
+<h4 id="sec-7-1-13"><span class="section-number-4">7.1.13</span> <span class="todo TODO">TODO</span> HklEngine "q/q2" add a "reflectivity" mode</h4>
+<div class="outline-text-4" id="text-7-1-13">
 <p>
 This mode should have the surface as parameters and the incident
 angle is equal to the emergence angle.
 </p>
 </div>
 </div>
-<div id="outline-container-sec-7-1-13" class="outline-4">
-<h4 id="sec-7-1-13"><span class="section-number-4">7.1.13</span> <span class="todo TODO">TODO</span> create a macro to help compare two real the right way</h4>
-<div class="outline-text-4" id="text-7-1-13">
+<div id="outline-container-sec-7-1-14" class="outline-4">
+<h4 id="sec-7-1-14"><span class="section-number-4">7.1.14</span> <span class="todo TODO">TODO</span> create a macro to help compare two real the right way</h4>
+<div class="outline-text-4" id="text-7-1-14">
 <p>
 fabs(a-b) < epsilon * max(1, abs(a), abs(b))
 </p>
 </div>
 </div>
-<div id="outline-container-sec-7-1-14" class="outline-4">
-<h4 id="sec-7-1-14"><span class="section-number-4">7.1.14</span> <span class="todo TODO">TODO</span> add an hkl_sample_set_lattice_unit()</h4>
-</div>
 <div id="outline-container-sec-7-1-15" class="outline-4">
-<h4 id="sec-7-1-15"><span class="section-number-4">7.1.15</span> <span class="todo TODO">TODO</span> SOLEIL SIXS</h4>
-<div class="outline-text-4" id="text-7-1-15">
-</div><ol class="org-ol"><li><a id="sec-7-1-15-1" name="sec-7-1-15-1"></a><span class="done DONE">DONE</span> find the right solutions.&#xa0;&#xa0;&#xa0;<span class="tag"><span class="zaxis">zaxis</span></span><br  /><div class="outline-text-5" id="text-7-1-15-1">
+<h4 id="sec-7-1-15"><span class="section-number-4">7.1.15</span> <span class="todo TODO">TODO</span> add an hkl_sample_set_lattice_unit()</h4>
+</div>
+<div id="outline-container-sec-7-1-16" class="outline-4">
+<h4 id="sec-7-1-16"><span class="section-number-4">7.1.16</span> <span class="todo TODO">TODO</span> SOLEIL SIXS</h4>
+<div class="outline-text-4" id="text-7-1-16">
+</div><ol class="org-ol"><li><a id="sec-7-1-16-1" name="sec-7-1-16-1"></a><span class="done DONE">DONE</span> find the right solutions.&#xa0;&#xa0;&#xa0;<span class="tag"><span class="zaxis">zaxis</span></span><br  /><div class="outline-text-5" id="text-7-1-16-1">
 <p>
 The cosinus and sinus properties are not enough to find the solution expected by the users.
 The idea is to use the Ewalds construction to generate a valid solution from the first one
@@ -5940,7 +6235,7 @@ special feature in the Mode. So it will be possible to add thoses special cases
 </p>
 </div>
 </li>
-<li><a id="sec-7-1-15-2" name="sec-7-1-15-2"></a><span class="todo TODO">TODO</span> Add the DEP diffractometer geometry<br  /><div class="outline-text-5" id="text-7-1-15-2">
+<li><a id="sec-7-1-16-2" name="sec-7-1-16-2"></a><span class="todo TODO">TODO</span> Add the DEP diffractometer geometry<br  /><div class="outline-text-5" id="text-7-1-16-2">
 <p>
 This diffractometer is a Newport one based on the kappa 6 circles ones.
 But instead of a kappa head, they use an Hexapod head.
@@ -5949,25 +6244,25 @@ This head can be put horizontally or vertically.
 </div>
 </li></ol>
 </div>
-<div id="outline-container-sec-7-1-16" class="outline-4">
-<h4 id="sec-7-1-16"><span class="section-number-4">7.1.16</span> <span class="todo TODO">TODO</span> generalisation of the z-axis hkl solver</h4>
-<div class="outline-text-4" id="text-7-1-16">
+<div id="outline-container-sec-7-1-17" class="outline-4">
+<h4 id="sec-7-1-17"><span class="section-number-4">7.1.17</span> <span class="todo TODO">TODO</span> generalisation of the z-axis hkl solver</h4>
+<div class="outline-text-4" id="text-7-1-17">
 <p>
 first we need the degenerated member of the Axis. thaht way it could be possible
 to find the last non degenerated axis for the detector fit.
 </p>
 </div>
 </div>
-<div id="outline-container-sec-7-1-17" class="outline-4">
-<h4 id="sec-7-1-17"><span class="section-number-4">7.1.17</span> <span class="todo TODO">TODO</span> investigate the prigo geometry.</h4>
-</div>
 <div id="outline-container-sec-7-1-18" class="outline-4">
-<h4 id="sec-7-1-18"><span class="section-number-4">7.1.18</span> <span class="todo TODO">TODO</span> augeas/elektra for the plugin configure part.</h4>
+<h4 id="sec-7-1-18"><span class="section-number-4">7.1.18</span> <span class="todo TODO">TODO</span> investigate the prigo geometry.</h4>
 </div>
 <div id="outline-container-sec-7-1-19" class="outline-4">
-<h4 id="sec-7-1-19"><span class="section-number-4">7.1.19</span> <span class="todo TODO">TODO</span> logging</h4>
-<div class="outline-text-4" id="text-7-1-19">
-</div><ol class="org-ol"><li><a id="sec-7-1-19-1" name="sec-7-1-19-1"></a><span class="todo TODO">TODO</span> <code>[1/2]</code> add in a few methods.<br  /><div class="outline-text-5" id="text-7-1-19-1">
+<h4 id="sec-7-1-19"><span class="section-number-4">7.1.19</span> <span class="todo TODO">TODO</span> augeas/elektra for the plugin configure part.</h4>
+</div>
+<div id="outline-container-sec-7-1-20" class="outline-4">
+<h4 id="sec-7-1-20"><span class="section-number-4">7.1.20</span> <span class="todo TODO">TODO</span> logging</h4>
+<div class="outline-text-4" id="text-7-1-20">
+</div><ol class="org-ol"><li><a id="sec-7-1-20-1" name="sec-7-1-20-1"></a><span class="todo TODO">TODO</span> <code>[1/2]</code> add in a few methods.<br  /><div class="outline-text-5" id="text-7-1-20-1">
 <ul class="org-ul">
 <li><code>[X]</code> hkl_pseudo_axes_values_set
 </li>
@@ -5976,7 +6271,7 @@ to find the last non degenerated axis for the detector fit.
 </ul>
 </div>
 </li>
-<li><a id="sec-7-1-19-2" name="sec-7-1-19-2"></a><span class="todo TODO">TODO</span> gir logging<br  /><div class="outline-text-5" id="text-7-1-19-2">
+<li><a id="sec-7-1-20-2" name="sec-7-1-20-2"></a><span class="todo TODO">TODO</span> gir logging<br  /><div class="outline-text-5" id="text-7-1-20-2">
 <p>
 It would be nice to generate the library logging using the .gir
 information. So instead of writing the logging code for each
@@ -5985,7 +6280,7 @@ purpose.
 </p>
 </div>
 </li>
-<li><a id="sec-7-1-19-3" name="sec-7-1-19-3"></a><span class="todo TODO">TODO</span> parsable logging information.<br  /><div class="outline-text-5" id="text-7-1-19-3">
+<li><a id="sec-7-1-20-3" name="sec-7-1-20-3"></a><span class="todo TODO">TODO</span> parsable logging information.<br  /><div class="outline-text-5" id="text-7-1-20-3">
 <p>
 A parsable logging format would help to setup some re-play unit
 test. This way it could help during the developpement process
@@ -5995,9 +6290,9 @@ computation are ok.
 </div>
 </li></ol>
 </div>
-<div id="outline-container-sec-7-1-20" class="outline-4">
-<h4 id="sec-7-1-20"><span class="section-number-4">7.1.20</span> <span class="todo TODO">TODO</span> performances</h4>
-<div class="outline-text-4" id="text-7-1-20">
+<div id="outline-container-sec-7-1-21" class="outline-4">
+<h4 id="sec-7-1-21"><span class="section-number-4">7.1.21</span> <span class="todo TODO">TODO</span> performances</h4>
+<div class="outline-text-4" id="text-7-1-21">
 <ul class="org-ul">
 <li>Investigate <a href="http://liboil.freedesktop.org/wiki/">liboil</a> to speed calculation (in HklVector, HklMatrix
 and HklQuaternion)
@@ -6008,6 +6303,7 @@ and HklQuaternion)
 </div>
 </div>
 </div>
+
 <div id="outline-container-sec-7-2" class="outline-3">
 <h3 id="sec-7-2"><span class="section-number-3">7.2</span> documentation</h3>
 <div class="outline-text-3" id="text-7-2">
@@ -6097,8 +6393,8 @@ pseudo axes and the mode parameters.
 </div></div>
 <div id="postamble" class="status">
 <p class="author">Author: Picca Frédéric-Emmanuel</p>
-<p class="date">Created: 2016-09-19 lun. 22:20</p>
-<p class="creator"><a href="http://www.gnu.org/software/emacs/">Emacs</a> 24.5.1 (<a href="http://orgmode.org">Org</a> mode 8.2.10)</p>
+<p class="date">Created: 2017-12-02 sam. 16:29</p>
+<p class="creator"><a href="http://www.gnu.org/software/emacs/">Emacs</a> 25.2.2 (<a href="http://orgmode.org">Org</a> mode 8.2.10)</p>
 <p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
 </div>
 </body>
diff --git a/Documentation/hkl.org.in b/Documentation/hkl.org.in
index 4097a1c..8842e80 100644
--- a/Documentation/hkl.org.in
+++ b/Documentation/hkl.org.in
@@ -2,16 +2,9 @@
 #+AUTHOR: Picca Frédéric-Emmanuel
 #+EMAIL: picca at synchrotron dash soleil dot fr
 #+LANGUAGE: en
-#+HTML_MATHJAX: path:"/usr/share/javascript/mathjax/MathJax.js"
 #+STYLE: <style>table.center {margin-left:auto; margin- right:auto;}</style>
-
-#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="http://www.pirilampo.org/styles/readtheorg/css/htmlize.css"/>
-#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="http://www.pirilampo.org/styles/readtheorg/css/readtheorg.css"/>
-
-#+HTML_HEAD: <script src="http://code.jquery.com/jquery-2.2.0.min.js"></script>
-#+HTML_HEAD: <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
-#+HTML_HEAD: <script type="text/javascript" src="http://www.pirilampo.org/styles/lib/js/jquery.stickytableheaders.js"></script>
-#+HTML_HEAD: <script type="text/javascript" src="http://www.pirilampo.org/styles/readtheorg/js/readtheorg.js"></script>
+#+HTML_HEAD: <link href="css/style.css" rel="stylesheet" type="text/css" />
+#+HTML_MATHJAX:  path:"https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js?config=TeX-AMS_HTML"
 
 * Introduction
   The purpose of the library is to factorize single crystal
@@ -45,9 +38,9 @@
     pattern is located at each points of the lattice node. Positions of
     those nodes are given by:
 
-    \begin{displaymath}
+    \[
     R_{uvw}=u\cdot\vec{a}+v\cdot\vec{b}+w\cdot\vec{c}
-    \end{displaymath}
+    \]
 
     $\vec{a}$, $\vec{b}$, $\vec{c}$ are the former vector of a base of the
     space. =u=, =v=, =w= are integers. The pattern contain atoms
@@ -96,9 +89,9 @@
 
     where
 
-    \begin{displaymath}
+    \[
     D=\sqrt{1-\cos^{2}\alpha-\cos^{2}\beta-\cos^{2}\gamma+2\cos\alpha\cos\beta\cos\gamma}
-    \end{displaymath}
+    \]
 
     To compute the angles between the reciprocal space vectors, it is once
     again possible to use the previous equations reciprocal to obtain the
@@ -113,16 +106,15 @@
 
     the volume of the lattice can be compute this way:
 
-    \begin{displaymath}
+    \[
     V = abcD
-    \end{displaymath}
+    \]
 
     or
 
-    \begin{displaymath}
+    \[
     V = \vec{a} \dot (\vec{b} \wedge \vec{c}) = \vec{b} \dot (\vec{c} \wedge \vec{a}) = \vec{c} \dot (\vec{a} \wedge \vec{b})
-    \end{displaymath}
-
+    \]
 
 *** Diffraction
 
@@ -131,9 +123,9 @@
     The $\vec{k_{d}}$ vector wavelength of the diffracted beam. There is
     diffusion if the diffusion vector $\vec{q}$ can be expressed as follows:
 
-    \begin{displaymath}
+    \[
     \vec{q}=\vec{k_{d}}-\vec{k_{i}}=h.\vec{a}^{*}+k.\vec{b}^{*}+l.\vec{c}^{*}
-    \end{displaymath}
+    \]
 
     where $(h,k,l)\in\mathbb{N}^{3}$ and $(h,k,l)\neq(0,0,0)$. Theses
     indices $(h,k,l)$ are named Miller indices.
@@ -141,9 +133,9 @@
     Another way of looking at things has been given by Bragg and that famous
     relationship:
 
-    \begin{displaymath}
+    \[
     n\lambda=2d\sin\theta
-    \end{displaymath}
+    \]
 
     where $d$ is the inter-plan distance and $n \in \mathbb{N}$.
 
@@ -160,39 +152,39 @@
      Theses quaternions can represent 3D rotations. There is different way to
      describe then like complex numbers.
 
-     \begin{displaymath}
+     \[
      q=a+bi+cj+dk
-     \end{displaymath}
+     \]
 
      or
 
-     \begin{displaymath}
+     \[
      q=[a,\vec{v}]
-     \end{displaymath}
+     \]
 
      To compute the quaternion's norm, we can proceed like for complex
      numbers
 
-     \begin{displaymath}
-     \lvert q \rvert = \sqrt{a{{}^2}+b{{}^2}+c{{}^2}+d{{}^2}}
-     \end{displaymath}
+     \[
+     \|q\|=\sqrt{a²+b²+c²+d²}
+     \]
 
      Its conjugate is :
 
-     \begin{displaymath}
+     \[
      q^{*}=[a,-\vec{u}]=a-bi-cj-dk
-     \end{displaymath}
+     \]
 
 **** Operations
 
      The difference with the complex number algebra is about
      non-commutativity.
 
-     \begin{displaymath}
+     \[
      qp \neq pq
-     \end{displaymath}
+     \]
 
-     \begin{displaymath}
+     \[
      \begin{bmatrix}
      ~ & 1 & i  & j  & k \cr
      1 & 1 & i  & j  & k \cr
@@ -200,7 +192,7 @@
      j & j & -k & -1 & i \cr
      k & k & j  & -i & -1
      \end{bmatrix}
-     \end{displaymath}
+     \]
 
      The product of two quaternions can be express by the Grassman product
      Grassman product. So for two quaternions $p$ and $q$:
@@ -212,15 +204,15 @@
 
      we got
 
-     \begin{displaymath}
+     \[
      pq = at - \vec{u} \cdot \vec{v} + a \vec{v} + t \vec{u} + \vec{v} \times \vec{u}
-     \end{displaymath}
+     \]
 
      or equivalent
 
-     \begin{displaymath}
+     \[
      pq = (at - bx - cy - dz) + (bt + ax + cz - dy) i + (ct + ay + dx - bz) j + (dt + az + by - cx) k
-     \end{displaymath}
+     \]
 
 **** 3D rotations
 
@@ -237,9 +229,9 @@
      rotation d'angle $\theta$ autour de l'origine, dans l'espace 3D
      l'expression équivalente est:
 
-     \begin{displaymath}
+     \[
      z'=qzq^{-1}
-     \end{displaymath}
+     \]
 
      où $q$ est le quaternion de norme 1 représentant la rotation dans
      l'espace et $z$ le quaternion représentant le vecteur qui subit la
@@ -249,20 +241,20 @@
      $q^{-1}$. En effet l'inverse d'une rotation d'angle $\theta$ est la
      rotation d'angle $-\theta$. On a donc directement:
 
-     \begin{displaymath}
+     \[
      q^{-1}=[\cos\frac{-\theta}{2},\sin\frac{-\theta}{2}\vec{u}]=[\cos\frac{\theta}{2},-\sin\frac{\theta}{2}\vec{u}]=q^{*}
-     \end{displaymath}
+     \]
 
      Le passage aux matrices de rotation se fait par la formule suivante
      $q\rightarrow M$.
 
-     \begin{displaymath}
+     \[
      \begin{bmatrix}
      a{{}^2}+b{{}^2}-c{{}^2}-d{{}^2} & 2bc-2ad & 2ac+2bd\\
      2ad+2bc & a{{}^2}-b{{}^2}+c{{}^2}-d{{}^2} & 2cd-2ab\\
      2bd-2ac & 2ab+2cd & a{{}^2}-b{{}^2}-c{{}^2}+d{{}^2}
      \end{bmatrix}
-     \end{displaymath}
+     \]
 
      La composition de rotation se fait simplement en multipliant les
      quaternions entre eux. Si l'on à $q$
@@ -295,14 +287,14 @@
     Si l'on connaît les paramètres cristallins du cristal étudié, il est
     très simple de calculer $B$:
 
-    \begin{displaymath}
+    \[
     B=
     \begin{bmatrix}
     a^{\star} & b^{\star}\cos\gamma^{\star} & c^{\star}\cos\beta^{\star}\\
     0 & b^{\star}\sin\gamma^{\star} & -c^{\star}\sin\beta^{\star}\cos\alpha\\
     0 & 0 & 1/c
     \end{bmatrix}
-    \end{displaymath}
+    \]
 
 *** Calcule de U
 
@@ -338,15 +330,15 @@
     $(\tilde{R}_{1}\vec{Q}_{1},\tilde{R}_{2}\vec{Q}_{2})$. On a alors très
     simplement:
 
-    \begin{displaymath}
+    \[
     U \cdot T_{\vec{h}} = T_{\vec{Q}}
-    \end{displaymath}
+    \]
 
     Et donc
 
-    \begin{displaymath}
+    \[
     U = T_{\vec{Q}} \cdot \tilde{T}_{\vec{h}}
-    \end{displaymath}
+    \]
 
 *** Affinement par la méthode du simplex
 
@@ -357,9 +349,9 @@
     d'euler. il faut donc être en mesure de passer d'une représentation
     eulérien à cette matrice :math::U et réciproquement.
 
-    \begin{displaymath}
+    \[
     U = X \cdot Y \cdot Z
-    \end{displaymath}
+    \]
 
     où $X$ est la matrice rotation suivant l'axe Ox et le premier angle
     d'Euler, $Y$ la matrice de rotation suivant l'axe Oy et le deuxième
@@ -373,14 +365,14 @@
 
     et donc:
 
-    \begin{displaymath}
+    \[
     U=
     \begin{bmatrix}
     CE & -CF & D\\
     BDE+AF & -BDF+AE & -BC\\
     -ADE+BF & ADF+BE & AC
     \end{bmatrix}
-    \end{displaymath}
+    \]
 
     Il est donc facile de passer des angles d'Euler à la matrice
     d'orientation.
@@ -426,9 +418,9 @@
 
    where
 
-   \begin{displaymath}
+   \[
    p = \arcsin\left(\frac{\tan\frac{\chi}{2}}{\tan\alpha}\right)
-   \end{displaymath}
+   \]
 
    and $\alpha$ is the angle of the kappa axis with the $\vec{y}$ axis.
 
@@ -452,9 +444,9 @@
 
    where
 
-   \begin{displaymath}
+   \[
    p = \arctan\left(\tan\frac{\kappa}{2} \cos\alpha\right)
-   \end{displaymath}
+   \]
 
    #+CAPTION: $\omega = 0$, $\chi = 0$, $\phi = 0$, 1st solution
    [[./figures/e2k_1.png]]
@@ -864,12 +856,21 @@ git clone git://repo.or.cz/hkl.git
    #+END_QUOTE
 * Releases
 ** @VERSION@
+*** DONE add emergence on all e4c diffractometers <2017-03-16 Thu>
+    The emergence pseudo axis is was added to =SOLEIL MARS= and =E4CV=
 *** DONE Fix for multiarch (headers) <2016-05-04 mer.>
     The =ccan_config.h= generated file is arch specific. It is then
     necessary to install this file under /usr/include/<triplet> on
     Debian like systems. This way it will be possible to co-installa
     32/64 bit version of hkl, or to do cross-compilation (arm on
     x86_64, etc...)
+*** DONE Fix the FTBFS with the new bullet 2.86.1 version <2017-08-13 dim.>
+    In order to update the internal structures of =Hkl3DObject= (the
+    =is-colliding= member), we were using a callback which became
+    un-effectiv with this new version of bullet. The logic was
+    rewritten in order to be much more efficent using the manifold
+    informations. Now we iterate on =Hkl3DObject= object only once
+    (n) complexity instead of (n²) with the previous one.
 ** 5.0.0.2080 <2016-04-27 mer.>
 *** DONE =HklEngine= <2016-01-20 mer.>
     emergence_fixed for the SOLEIL SIX MED 2+2 geometry.
@@ -898,8 +899,8 @@ git clone git://repo.or.cz/hkl.git
           for j in range(3):
               M[i, j] = m.get(i, j)
       return M
-  
-  
+
+
   M = hkl_matrix_to_numpy(q.to_matrix())
 #+END_SRC
 *** DONE Soleil Sirius Turret <2016-04-26 mar.>
@@ -988,6 +989,81 @@ git clone git://repo.or.cz/hkl.git
     Create a parameter for the wavelength. This is just internally for
     the futur trajectory system, so no need to change the signature of
     hkl_geometry_vawelength get/set
+*** TODO [#A] SOLEIL SIRIUS KAPPA
+    Investigation of a problem saw on Sirius Kappa geometry. The idea
+    is to compute a trajectory from $[0, 0, 1]$ to $[0, 0, 6]$ on a
+    $GaAs$ sample.
+
+    #+BEGIN_SRC sh
+      Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,40.795148838481424,134.08834052117254,-55.57809067120416,-2.23369e-2,14.824478553649875]) (Just [Parameter "mu" (-0.5193202) (Range (-180.0) 180.0),Parameter "komega" 40.795148838481424 (Range (-180.0) 180.0),Parameter "kappa" 134.08834052117254 (Range (-180.0) 180.0),Parameter "kphi" (-55.57809067120416) (Range (-180.0) 180.0),Parameter "delta" (-2.23369e-2) (Range (-180.0) 180.0),Parameter "gamma" [...]
+      [Engine "hkl" [Parameter "h" 2.1481674408578524e-8 (Range (-1.0) 1.0),Parameter "k" 6.392014061803081e-8 (Range (-1.0) 1.0),Parameter "l" 1.0000000132413767 (Range (-1.0) 1.0)] (Mode "bissector_vertical" []),Engine "eulerians" [Parameter "omega" 7.412239314132745 (Range (-180.0) 180.0),Parameter "chi" 89.72020738176312 (Range (-180.0) 180.0),Parameter "phi" 91.03899980444716 (Range (-180.0) 180.0)] (Mode "eulerians" [Parameter "solutions" 1.0 (Range 0.0 1.0)]),Engine "psi" [Paramet [...]
+      Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,47.97247473743512,134.654265266118,124.92415016158583,-2.23369e-2,29.904632884360968]) (Just [Parameter "mu" (-0.5193202) (Range (-180.0) 180.0),Parameter "komega" 47.97247473743512 (Range (-180.0) 180.0),Parameter "kappa" 134.654265266118 (Range (-180.0) 180.0),Parameter "kphi" 124.92415016158583 (Range (-180.0) 180.0),Parameter "delta" (-2.23369e-2) (Range (-180.0) 180.0),Parameter "gamma" 29.9046 [...]
+      [Engine "hkl" [Parameter "h" (-1.3839931497468412e-9) (Range (-1.0) 1.0),Parameter "k" (-4.913404854447784e-10) (Range (-1.0) 1.0),Parameter "l" 2.000000003360829 (Range (-1.0) 1.0)] (Mode "bissector_vertical" []),Engine "eulerians" [Parameter "omega" 14.95231642186499 (Range (-180.0) 180.0),Parameter "chi" 89.9575990161042 (Range (-180.0) 180.0),Parameter "phi" 271.9039918460157 (Range (-180.0) 180.0)] (Mode "eulerians" [Parameter "solutions" 1.0 (Range 0.0 1.0)]),Engine "psi" [Pa [...]
+      Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,56.25907471532187,133.92128004831832,-55.45556970293517,-2.23369e-2,45.53873596992208]) (Just [Parameter "mu" (-0.5193202) (Range (-180.0) 180.0),Parameter "komega" 56.25907471532187 (Range (-180.0) 180.0),Parameter "kappa" 133.92128004831832 (Range (-180.0) 180.0),Parameter "kphi" (-55.45556970293517) (Range (-180.0) 180.0),Parameter "delta" (-2.23369e-2) (Range (-180.0) 180.0),Parameter "gamma" 45 [...]
+      [Engine "hkl" [Parameter "h" 8.37724528421826e-9 (Range (-1.0) 1.0),Parameter "k" 2.018612859089285e-8 (Range (-1.0) 1.0),Parameter "l" 2.999999983141756 (Range (-1.0) 1.0)] (Mode "bissector_vertical" []),Engine "eulerians" [Parameter "omega" 22.76936798418434 (Range (-180.0) 180.0),Parameter "chi" 89.64969149765572 (Range (-180.0) 180.0),Parameter "phi" 91.0547235659273 (Range (-180.0) 180.0)] (Mode "eulerians" [Parameter "solutions" 1.0 (Range 0.0 1.0)]),Engine "psi" [Parameter " [...]
+      Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,64.64191214924969,133.78682078017752,-55.41938838621407,-2.23369e-2,62.132688461209455]) (Just [Parameter "mu" (-0.5193202) (Range (-180.0) 180.0),Parameter "komega" 64.64191214924969 (Range (-180.0) 180.0),Parameter "kappa" 133.78682078017752 (Range (-180.0) 180.0),Parameter "kphi" (-55.41938838621407) (Range (-180.0) 180.0),Parameter "delta" (-2.23369e-2) (Range (-180.0) 180.0),Parameter "gamma" 6 [...]
+      [Engine "hkl" [Parameter "h" 9.177457430250849e-9 (Range (-1.0) 1.0),Parameter "k" 2.5693823994163015e-8 (Range (-1.0) 1.0),Parameter "l" 3.9999999929703476 (Range (-1.0) 1.0)] (Mode "bissector_vertical" []),Engine "eulerians" [Parameter "omega" 31.06634423136446 (Range (-180.0) 180.0),Parameter "chi" 89.5927920859556 (Range (-180.0) 180.0),Parameter "phi" 91.00504369590071 (Range (-180.0) 180.0)] (Mode "eulerians" [Parameter "solutions" 1.0 (Range 0.0 1.0)]),Engine "psi" [Paramete [...]
+      Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,73.83399863752925,133.64586701159254,-55.35712475482595,-2.23369e-2,80.33702663350934]) (Just [Parameter "mu" (-0.5193202) (Range (-180.0) 180.0),Parameter "komega" 73.83399863752925 (Range (-180.0) 180.0),Parameter "kappa" 133.64586701159254 (Range (-180.0) 180.0),Parameter "kphi" (-55.35712475482595) (Range (-180.0) 180.0),Parameter "delta" (-2.23369e-2) (Range (-180.0) 180.0),Parameter "gamma" 80 [...]
+      [Engine "hkl" [Parameter "h" 2.7577312257761425e-9 (Range (-1.0) 1.0),Parameter "k" 7.650403950118726e-9 (Range (-1.0) 1.0),Parameter "l" 4.999999999622215 (Range (-1.0) 1.0)] (Mode "bissector_vertical" []),Engine "eulerians" [Parameter "omega" 40.168513316578995 (Range (-180.0) 180.0),Parameter "chi" 89.53300638651663 (Range (-180.0) 180.0),Parameter "phi" 90.9773899242238 (Range (-180.0) 180.0)] (Mode "eulerians" [Parameter "solutions" 1.0 (Range 0.0 1.0)]),Engine "psi" [Paramete [...]
+      Geometry SOLEIL SIRIUS KAPPA (Source 1.4586370000000007e-9 m) (fromList [-0.5193202,84.086619565407,134.11156620489382,125.37371040144704,-2.23369e-2,101.43713587367031]) (Just [Parameter "mu" (-0.5193202) (Range (-180.0) 180.0),Parameter "komega" 84.086619565407 (Range (-180.0) 180.0),Parameter "kappa" 134.11156620489382 (Range (-180.0) 180.0),Parameter "kphi" 125.37371040144704 (Range (-180.0) 180.0),Parameter "delta" (-2.23369e-2) (Range (-180.0) 180.0),Parameter "gamma" 101.437 [...]
+      [Engine "hkl" [Parameter "h" 8.392762843275724e-10 (Range (-1.0) 1.0),Parameter "k" 2.459154264227675e-9 (Range (-1.0) 1.0),Parameter "l" 6.0000000015375905 (Range (-1.0) 1.0)] (Mode "bissector_vertical" []),Engine "eulerians" [Parameter "omega" 50.718567936651276 (Range (-180.0) 180.0),Parameter "chi" 89.72999512595882 (Range (-180.0) 180.0),Parameter "phi" 272.0056587726913 (Range (-180.0) 180.0)] (Mode "eulerians" [Parameter "solutions" 1.0 (Range 0.0 1.0)]),Engine "psi" [Parame [...]
+    #+END_SRC
+
+    As we can see the phi and kphi motor switch from time to time to
+    another solution which is at around 180° of the other solutions.
+
+    #+CAPTION: plot the [0,0,1] -> [0,0,6] trajectory from two different starting point and different step size.
+    #+BEGIN_SRC gnuplot :file figures/sirius-s.svg
+    reset
+    set title '[0,0,1] -> [0,0,6] s1/s2 (starting point) 10/100 (steps)'
+    set xlabel 'l'
+    set ylabel 'kphi'
+    plot \
+    'figures/s1-11.dat' u 3:7 w lp t 's1-10',\
+    'figures/s2-11.dat' u 3:7 w lp t 's2-10',\
+    'figures/s1-101.dat' u 3:7 w lp t 's1-100',\
+    'figures/s2-101.dat' u 3:7 w lp t 's2-100'
+    #+END_SRC
+
+    #+CAPTION: plot the [0,0,1] -> [0,0,6] idem previous figure but move the diffractometer.
+    #+BEGIN_SRC gnuplot :file figures/sirius-m.svg
+    reset
+    set title '[0,0,1] -> [0,0,6] s1/s2 (starting point) 10/100 (steps)'
+    set xlabel 'l'
+    set ylabel 'kphi'
+    plot \
+    'figures/m1-11.dat' u 3:7 w lp t 'm1-10',\
+    'figures/m2-11.dat' u 3:7 w lp t 'm2-10',\
+    'figures/m1-101.dat' u 3:7 w lp t 'm1-100',\
+    'figures/m2-101.dat' u 3:7 w lp t 'm2-100'
+    #+END_SRC
+
+    #+CAPTION: zoom on the 2 solutions.
+    #+BEGIN_SRC gnuplot :file figures/sirius-m-zoom.svg
+    reset
+    set title '[0,0,1] -> [0,0,6] s1/s2 (starting point) 10/100 (steps)'
+    set xlabel 'l'
+
+    set ylabel 'kphi m1'
+    set ytics nomirror
+
+    set y2label 'kphi m2'
+    set y2tics
+    plot \
+    'figures/m1-101.dat' using 3:7 axis x1y1 with lp title 'm1-100',\
+    'figures/m2-101.dat' using 3:7 axis x1y2 with lp title 'm2-100'
+    #+END_SRC
+
+    #+CAPTION: plot the [0,0,1] -> [0,0,6]  for different number of steps
+    #+BEGIN_SRC gnuplot :file figures/traj_n.svg
+    reset
+    set title '[0,0,1] -> [0,0,6] 1 -> 100 (steps)'
+    set xlabel 'n steps'
+
+    set ylabel 'range'
+    plot 'figures/traj_n.dat' using 1:2 with lp title 'kphi range'
+    #+END_SRC
+
 *** TODO [0/2] PetraIII
 **** TODO computation problem
      Dear Teresa,
@@ -1167,6 +1243,7 @@ git clone git://repo.or.cz/hkl.git
     + Investigate [[http://liboil.freedesktop.org/wiki/][liboil]] to speed calculation (in HklVector, HklMatrix
       and HklQuaternion)
     + Avoid to call =hkl_engine_prepare_internal= at each computation.
+
 ** documentation
 *** TODO [1/6] rewrite documentation in org-mode
     - [-] embedding code into the org file
diff --git a/Documentation/sphinx/Makefile.in b/Documentation/sphinx/Makefile.in
index f7e178b..0ca6877 100644
--- a/Documentation/sphinx/Makefile.in
+++ b/Documentation/sphinx/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -370,6 +370,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/INSTALL b/INSTALL
index 2099840..8865734 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,8 +1,8 @@
 Installation Instructions
 *************************
 
-Copyright (C) 1994-1996, 1999-2002, 2004-2013 Free Software Foundation,
-Inc.
+   Copyright (C) 1994-1996, 1999-2002, 2004-2016 Free Software
+Foundation, Inc.
 
    Copying and distribution of this file, with or without modification,
 are permitted in any medium without royalty provided the copyright
@@ -12,97 +12,96 @@ without warranty of any kind.
 Basic Installation
 ==================
 
-   Briefly, the shell command `./configure && make && make install'
+   Briefly, the shell command './configure && make && make install'
 should configure, build, and install this package.  The following
-more-detailed instructions are generic; see the `README' file for
+more-detailed instructions are generic; see the 'README' file for
 instructions specific to this package.  Some packages provide this
-`INSTALL' file but do not implement all of the features documented
+'INSTALL' file but do not implement all of the features documented
 below.  The lack of an optional feature in a given package is not
 necessarily a bug.  More recommendations for GNU packages can be found
 in *note Makefile Conventions: (standards)Makefile Conventions.
 
-   The `configure' shell script attempts to guess correct values for
+   The 'configure' shell script attempts to guess correct values for
 various system-dependent variables used during compilation.  It uses
-those values to create a `Makefile' in each directory of the package.
-It may also create one or more `.h' files containing system-dependent
-definitions.  Finally, it creates a shell script `config.status' that
+those values to create a 'Makefile' in each directory of the package.
+It may also create one or more '.h' files containing system-dependent
+definitions.  Finally, it creates a shell script 'config.status' that
 you can run in the future to recreate the current configuration, and a
-file `config.log' containing compiler output (useful mainly for
-debugging `configure').
+file 'config.log' containing compiler output (useful mainly for
+debugging 'configure').
 
-   It can also use an optional file (typically called `config.cache'
-and enabled with `--cache-file=config.cache' or simply `-C') that saves
-the results of its tests to speed up reconfiguring.  Caching is
-disabled by default to prevent problems with accidental use of stale
-cache files.
+   It can also use an optional file (typically called 'config.cache' and
+enabled with '--cache-file=config.cache' or simply '-C') that saves the
+results of its tests to speed up reconfiguring.  Caching is disabled by
+default to prevent problems with accidental use of stale cache files.
 
    If you need to do unusual things to compile the package, please try
-to figure out how `configure' could check whether to do them, and mail
-diffs or instructions to the address given in the `README' so they can
+to figure out how 'configure' could check whether to do them, and mail
+diffs or instructions to the address given in the 'README' so they can
 be considered for the next release.  If you are using the cache, and at
-some point `config.cache' contains results you don't want to keep, you
+some point 'config.cache' contains results you don't want to keep, you
 may remove or edit it.
 
-   The file `configure.ac' (or `configure.in') is used to create
-`configure' by a program called `autoconf'.  You need `configure.ac' if
-you want to change it or regenerate `configure' using a newer version
-of `autoconf'.
+   The file 'configure.ac' (or 'configure.in') is used to create
+'configure' by a program called 'autoconf'.  You need 'configure.ac' if
+you want to change it or regenerate 'configure' using a newer version of
+'autoconf'.
 
    The simplest way to compile this package is:
 
-  1. `cd' to the directory containing the package's source code and type
-     `./configure' to configure the package for your system.
+  1. 'cd' to the directory containing the package's source code and type
+     './configure' to configure the package for your system.
 
-     Running `configure' might take a while.  While running, it prints
+     Running 'configure' might take a while.  While running, it prints
      some messages telling which features it is checking for.
 
-  2. Type `make' to compile the package.
+  2. Type 'make' to compile the package.
 
-  3. Optionally, type `make check' to run any self-tests that come with
+  3. Optionally, type 'make check' to run any self-tests that come with
      the package, generally using the just-built uninstalled binaries.
 
-  4. Type `make install' to install the programs and any data files and
+  4. Type 'make install' to install the programs and any data files and
      documentation.  When installing into a prefix owned by root, it is
      recommended that the package be configured and built as a regular
-     user, and only the `make install' phase executed with root
+     user, and only the 'make install' phase executed with root
      privileges.
 
-  5. Optionally, type `make installcheck' to repeat any self-tests, but
+  5. Optionally, type 'make installcheck' to repeat any self-tests, but
      this time using the binaries in their final installed location.
      This target does not install anything.  Running this target as a
-     regular user, particularly if the prior `make install' required
+     regular user, particularly if the prior 'make install' required
      root privileges, verifies that the installation completed
      correctly.
 
   6. You can remove the program binaries and object files from the
-     source code directory by typing `make clean'.  To also remove the
-     files that `configure' created (so you can compile the package for
-     a different kind of computer), type `make distclean'.  There is
-     also a `make maintainer-clean' target, but that is intended mainly
+     source code directory by typing 'make clean'.  To also remove the
+     files that 'configure' created (so you can compile the package for
+     a different kind of computer), type 'make distclean'.  There is
+     also a 'make maintainer-clean' target, but that is intended mainly
      for the package's developers.  If you use it, you may have to get
      all sorts of other programs in order to regenerate files that came
      with the distribution.
 
-  7. Often, you can also type `make uninstall' to remove the installed
+  7. Often, you can also type 'make uninstall' to remove the installed
      files again.  In practice, not all packages have tested that
      uninstallation works correctly, even though it is required by the
      GNU Coding Standards.
 
-  8. Some packages, particularly those that use Automake, provide `make
+  8. Some packages, particularly those that use Automake, provide 'make
      distcheck', which can by used by developers to test that all other
-     targets like `make install' and `make uninstall' work correctly.
+     targets like 'make install' and 'make uninstall' work correctly.
      This target is generally not run by end users.
 
 Compilers and Options
 =====================
 
    Some systems require unusual options for compilation or linking that
-the `configure' script does not know about.  Run `./configure --help'
+the 'configure' script does not know about.  Run './configure --help'
 for details on some of the pertinent environment variables.
 
-   You can give `configure' initial values for configuration parameters
-by setting variables in the command line or in the environment.  Here
-is an example:
+   You can give 'configure' initial values for configuration parameters
+by setting variables in the command line or in the environment.  Here is
+an example:
 
      ./configure CC=c99 CFLAGS=-g LIBS=-lposix
 
@@ -113,21 +112,21 @@ Compiling For Multiple Architectures
 
    You can compile the package for more than one kind of computer at the
 same time, by placing the object files for each architecture in their
-own directory.  To do this, you can use GNU `make'.  `cd' to the
+own directory.  To do this, you can use GNU 'make'.  'cd' to the
 directory where you want the object files and executables to go and run
-the `configure' script.  `configure' automatically checks for the
-source code in the directory that `configure' is in and in `..'.  This
-is known as a "VPATH" build.
+the 'configure' script.  'configure' automatically checks for the source
+code in the directory that 'configure' is in and in '..'.  This is known
+as a "VPATH" build.
 
-   With a non-GNU `make', it is safer to compile the package for one
+   With a non-GNU 'make', it is safer to compile the package for one
 architecture at a time in the source code directory.  After you have
-installed the package for one architecture, use `make distclean' before
+installed the package for one architecture, use 'make distclean' before
 reconfiguring for another architecture.
 
    On MacOS X 10.5 and later systems, you can create libraries and
 executables that work on multiple system types--known as "fat" or
-"universal" binaries--by specifying multiple `-arch' options to the
-compiler but only a single `-arch' option to the preprocessor.  Like
+"universal" binaries--by specifying multiple '-arch' options to the
+compiler but only a single '-arch' option to the preprocessor.  Like
 this:
 
      ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
@@ -136,105 +135,104 @@ this:
 
    This is not guaranteed to produce working output in all cases, you
 may have to build one architecture at a time and combine the results
-using the `lipo' tool if you have problems.
+using the 'lipo' tool if you have problems.
 
 Installation Names
 ==================
 
-   By default, `make install' installs the package's commands under
-`/usr/local/bin', include files under `/usr/local/include', etc.  You
-can specify an installation prefix other than `/usr/local' by giving
-`configure' the option `--prefix=PREFIX', where PREFIX must be an
+   By default, 'make install' installs the package's commands under
+'/usr/local/bin', include files under '/usr/local/include', etc.  You
+can specify an installation prefix other than '/usr/local' by giving
+'configure' the option '--prefix=PREFIX', where PREFIX must be an
 absolute file name.
 
    You can specify separate installation prefixes for
 architecture-specific files and architecture-independent files.  If you
-pass the option `--exec-prefix=PREFIX' to `configure', the package uses
+pass the option '--exec-prefix=PREFIX' to 'configure', the package uses
 PREFIX as the prefix for installing programs and libraries.
 Documentation and other data files still use the regular prefix.
 
    In addition, if you use an unusual directory layout you can give
-options like `--bindir=DIR' to specify different values for particular
-kinds of files.  Run `configure --help' for a list of the directories
-you can set and what kinds of files go in them.  In general, the
-default for these options is expressed in terms of `${prefix}', so that
-specifying just `--prefix' will affect all of the other directory
+options like '--bindir=DIR' to specify different values for particular
+kinds of files.  Run 'configure --help' for a list of the directories
+you can set and what kinds of files go in them.  In general, the default
+for these options is expressed in terms of '${prefix}', so that
+specifying just '--prefix' will affect all of the other directory
 specifications that were not explicitly provided.
 
    The most portable way to affect installation locations is to pass the
-correct locations to `configure'; however, many packages provide one or
+correct locations to 'configure'; however, many packages provide one or
 both of the following shortcuts of passing variable assignments to the
-`make install' command line to change installation locations without
+'make install' command line to change installation locations without
 having to reconfigure or recompile.
 
    The first method involves providing an override variable for each
-affected directory.  For example, `make install
+affected directory.  For example, 'make install
 prefix=/alternate/directory' will choose an alternate location for all
 directory configuration variables that were expressed in terms of
-`${prefix}'.  Any directories that were specified during `configure',
-but not in terms of `${prefix}', must each be overridden at install
-time for the entire installation to be relocated.  The approach of
-makefile variable overrides for each directory variable is required by
-the GNU Coding Standards, and ideally causes no recompilation.
-However, some platforms have known limitations with the semantics of
-shared libraries that end up requiring recompilation when using this
-method, particularly noticeable in packages that use GNU Libtool.
-
-   The second method involves providing the `DESTDIR' variable.  For
-example, `make install DESTDIR=/alternate/directory' will prepend
-`/alternate/directory' before all installation names.  The approach of
-`DESTDIR' overrides is not required by the GNU Coding Standards, and
+'${prefix}'.  Any directories that were specified during 'configure',
+but not in terms of '${prefix}', must each be overridden at install time
+for the entire installation to be relocated.  The approach of makefile
+variable overrides for each directory variable is required by the GNU
+Coding Standards, and ideally causes no recompilation.  However, some
+platforms have known limitations with the semantics of shared libraries
+that end up requiring recompilation when using this method, particularly
+noticeable in packages that use GNU Libtool.
+
+   The second method involves providing the 'DESTDIR' variable.  For
+example, 'make install DESTDIR=/alternate/directory' will prepend
+'/alternate/directory' before all installation names.  The approach of
+'DESTDIR' overrides is not required by the GNU Coding Standards, and
 does not work on platforms that have drive letters.  On the other hand,
 it does better at avoiding recompilation issues, and works well even
-when some directory options were not specified in terms of `${prefix}'
-at `configure' time.
+when some directory options were not specified in terms of '${prefix}'
+at 'configure' time.
 
 Optional Features
 =================
 
    If the package supports it, you can cause programs to be installed
-with an extra prefix or suffix on their names by giving `configure' the
-option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
-
-   Some packages pay attention to `--enable-FEATURE' options to
-`configure', where FEATURE indicates an optional part of the package.
-They may also pay attention to `--with-PACKAGE' options, where PACKAGE
-is something like `gnu-as' or `x' (for the X Window System).  The
-`README' should mention any `--enable-' and `--with-' options that the
+with an extra prefix or suffix on their names by giving 'configure' the
+option '--program-prefix=PREFIX' or '--program-suffix=SUFFIX'.
+
+   Some packages pay attention to '--enable-FEATURE' options to
+'configure', where FEATURE indicates an optional part of the package.
+They may also pay attention to '--with-PACKAGE' options, where PACKAGE
+is something like 'gnu-as' or 'x' (for the X Window System).  The
+'README' should mention any '--enable-' and '--with-' options that the
 package recognizes.
 
-   For packages that use the X Window System, `configure' can usually
+   For packages that use the X Window System, 'configure' can usually
 find the X include and library files automatically, but if it doesn't,
-you can use the `configure' options `--x-includes=DIR' and
-`--x-libraries=DIR' to specify their locations.
+you can use the 'configure' options '--x-includes=DIR' and
+'--x-libraries=DIR' to specify their locations.
 
    Some packages offer the ability to configure how verbose the
-execution of `make' will be.  For these packages, running `./configure
+execution of 'make' will be.  For these packages, running './configure
 --enable-silent-rules' sets the default to minimal output, which can be
-overridden with `make V=1'; while running `./configure
+overridden with 'make V=1'; while running './configure
 --disable-silent-rules' sets the default to verbose, which can be
-overridden with `make V=0'.
+overridden with 'make V=0'.
 
 Particular systems
 ==================
 
-   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
-CC is not installed, it is recommended to use the following options in
+   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU CC
+is not installed, it is recommended to use the following options in
 order to use an ANSI C compiler:
 
      ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
 
 and if that doesn't work, install pre-built binaries of GCC for HP-UX.
 
-   HP-UX `make' updates targets which have the same time stamps as
-their prerequisites, which makes it generally unusable when shipped
-generated files such as `configure' are involved.  Use GNU `make'
-instead.
+   HP-UX 'make' updates targets which have the same time stamps as their
+prerequisites, which makes it generally unusable when shipped generated
+files such as 'configure' are involved.  Use GNU 'make' instead.
 
    On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
-parse its `<wchar.h>' header file.  The option `-nodtk' can be used as
-a workaround.  If GNU CC is not installed, it is therefore recommended
-to try
+parse its '<wchar.h>' header file.  The option '-nodtk' can be used as a
+workaround.  If GNU CC is not installed, it is therefore recommended to
+try
 
      ./configure CC="cc"
 
@@ -242,26 +240,26 @@ and if that doesn't work, try
 
      ./configure CC="cc -nodtk"
 
-   On Solaris, don't put `/usr/ucb' early in your `PATH'.  This
+   On Solaris, don't put '/usr/ucb' early in your 'PATH'.  This
 directory contains several dysfunctional programs; working variants of
-these programs are available in `/usr/bin'.  So, if you need `/usr/ucb'
-in your `PATH', put it _after_ `/usr/bin'.
+these programs are available in '/usr/bin'.  So, if you need '/usr/ucb'
+in your 'PATH', put it _after_ '/usr/bin'.
 
-   On Haiku, software installed for all users goes in `/boot/common',
-not `/usr/local'.  It is recommended to use the following options:
+   On Haiku, software installed for all users goes in '/boot/common',
+not '/usr/local'.  It is recommended to use the following options:
 
      ./configure --prefix=/boot/common
 
 Specifying the System Type
 ==========================
 
-   There may be some features `configure' cannot figure out
+   There may be some features 'configure' cannot figure out
 automatically, but needs to determine by the type of machine the package
 will run on.  Usually, assuming the package is built to be run on the
-_same_ architectures, `configure' can figure that out, but if it prints
+_same_ architectures, 'configure' can figure that out, but if it prints
 a message saying it cannot guess the machine type, give it the
-`--build=TYPE' option.  TYPE can either be a short name for the system
-type, such as `sun4', or a canonical name which has the form:
+'--build=TYPE' option.  TYPE can either be a short name for the system
+type, such as 'sun4', or a canonical name which has the form:
 
      CPU-COMPANY-SYSTEM
 
@@ -270,101 +268,101 @@ where SYSTEM can have one of these forms:
      OS
      KERNEL-OS
 
-   See the file `config.sub' for the possible values of each field.  If
-`config.sub' isn't included in this package, then this package doesn't
+   See the file 'config.sub' for the possible values of each field.  If
+'config.sub' isn't included in this package, then this package doesn't
 need to know the machine type.
 
    If you are _building_ compiler tools for cross-compiling, you should
-use the option `--target=TYPE' to select the type of system they will
+use the option '--target=TYPE' to select the type of system they will
 produce code for.
 
    If you want to _use_ a cross compiler, that generates code for a
 platform different from the build platform, you should specify the
 "host" platform (i.e., that on which the generated programs will
-eventually be run) with `--host=TYPE'.
+eventually be run) with '--host=TYPE'.
 
 Sharing Defaults
 ================
 
-   If you want to set default values for `configure' scripts to share,
-you can create a site shell script called `config.site' that gives
-default values for variables like `CC', `cache_file', and `prefix'.
-`configure' looks for `PREFIX/share/config.site' if it exists, then
-`PREFIX/etc/config.site' if it exists.  Or, you can set the
-`CONFIG_SITE' environment variable to the location of the site script.
-A warning: not all `configure' scripts look for a site script.
+   If you want to set default values for 'configure' scripts to share,
+you can create a site shell script called 'config.site' that gives
+default values for variables like 'CC', 'cache_file', and 'prefix'.
+'configure' looks for 'PREFIX/share/config.site' if it exists, then
+'PREFIX/etc/config.site' if it exists.  Or, you can set the
+'CONFIG_SITE' environment variable to the location of the site script.
+A warning: not all 'configure' scripts look for a site script.
 
 Defining Variables
 ==================
 
    Variables not defined in a site shell script can be set in the
-environment passed to `configure'.  However, some packages may run
+environment passed to 'configure'.  However, some packages may run
 configure again during the build, and the customized values of these
 variables may be lost.  In order to avoid this problem, you should set
-them in the `configure' command line, using `VAR=value'.  For example:
+them in the 'configure' command line, using 'VAR=value'.  For example:
 
      ./configure CC=/usr/local2/bin/gcc
 
-causes the specified `gcc' to be used as the C compiler (unless it is
+causes the specified 'gcc' to be used as the C compiler (unless it is
 overridden in the site shell script).
 
-Unfortunately, this technique does not work for `CONFIG_SHELL' due to
-an Autoconf limitation.  Until the limitation is lifted, you can use
-this workaround:
+Unfortunately, this technique does not work for 'CONFIG_SHELL' due to an
+Autoconf limitation.  Until the limitation is lifted, you can use this
+workaround:
 
      CONFIG_SHELL=/bin/bash ./configure CONFIG_SHELL=/bin/bash
 
-`configure' Invocation
+'configure' Invocation
 ======================
 
-   `configure' recognizes the following options to control how it
+   'configure' recognizes the following options to control how it
 operates.
 
-`--help'
-`-h'
-     Print a summary of all of the options to `configure', and exit.
+'--help'
+'-h'
+     Print a summary of all of the options to 'configure', and exit.
 
-`--help=short'
-`--help=recursive'
+'--help=short'
+'--help=recursive'
      Print a summary of the options unique to this package's
-     `configure', and exit.  The `short' variant lists options used
-     only in the top level, while the `recursive' variant lists options
-     also present in any nested packages.
+     'configure', and exit.  The 'short' variant lists options used only
+     in the top level, while the 'recursive' variant lists options also
+     present in any nested packages.
 
-`--version'
-`-V'
-     Print the version of Autoconf used to generate the `configure'
+'--version'
+'-V'
+     Print the version of Autoconf used to generate the 'configure'
      script, and exit.
 
-`--cache-file=FILE'
+'--cache-file=FILE'
      Enable the cache: use and save the results of the tests in FILE,
-     traditionally `config.cache'.  FILE defaults to `/dev/null' to
+     traditionally 'config.cache'.  FILE defaults to '/dev/null' to
      disable caching.
 
-`--config-cache'
-`-C'
-     Alias for `--cache-file=config.cache'.
+'--config-cache'
+'-C'
+     Alias for '--cache-file=config.cache'.
 
-`--quiet'
-`--silent'
-`-q'
+'--quiet'
+'--silent'
+'-q'
      Do not print messages saying which checks are being made.  To
-     suppress all normal output, redirect it to `/dev/null' (any error
+     suppress all normal output, redirect it to '/dev/null' (any error
      messages will still be shown).
 
-`--srcdir=DIR'
+'--srcdir=DIR'
      Look for the package's source code in directory DIR.  Usually
-     `configure' can determine that directory automatically.
+     'configure' can determine that directory automatically.
 
-`--prefix=DIR'
-     Use DIR as the installation prefix.  *note Installation Names::
-     for more details, including other options available for fine-tuning
-     the installation locations.
+'--prefix=DIR'
+     Use DIR as the installation prefix.  *note Installation Names:: for
+     more details, including other options available for fine-tuning the
+     installation locations.
 
-`--no-create'
-`-n'
+'--no-create'
+'-n'
      Run the configure checks, but stop before creating any output
      files.
 
-`configure' also accepts some other, not widely useful, options.  Run
-`configure --help' for more details.
+'configure' also accepts some other, not widely useful, options.  Run
+'configure --help' for more details.
diff --git a/Makefile.am b/Makefile.am
index 0246bb4..31ca0f4 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -7,13 +7,13 @@ SUBDIRS = hkl
 if HKL3D
 SUBDIRS += hkl3d data
 endif
+SUBDIRS += tests
 if GUI
 SUBDIRS += gui
 endif
 if HKL_DOC
 SUBDIRS += Documentation
 endif
-SUBDIRS += tests
 if CONTRIB
 SUBDIRS += contrib
 endif
@@ -32,13 +32,16 @@ noinst_DATA = hkl3d.pc
 endif
 
 release:
+	git clean -xdf
 	git fetch
 	git checkout next
-	cd scripts && ./clean-all
-	git commit -a -m "pre-release"
+#cd scripts && ./clean-all
+#git commit -a -m "pre-release"
 	git checkout maint
 	git merge -m "release" next
 	./autogen.sh
+	./configure $(AM_DISTCHECK_CONFIGURE_FLAGS)
+	$(MAKE)
 	$(MAKE) distcheck
 	git tag v`./configure -V | head -n 1 | awk '{print $$3}'`
 	git checkout next
@@ -85,10 +88,10 @@ dist-hook:
 ## Update the ccan library
 
 CCAN_PUBLIC_MODULES=darray
-CCAN_PRIVATE_MODULES=array_size container_of autodata list
+CCAN_PRIVATE_MODULES=array_size container_of autodata list generator
 CCAN_LOCAL_REPO=/tmp/ccan
 CCAN_LOCAL_EXTRACT=/tmp/ccan.tmp
-CCAN_URL=git://git.ozlabs.org/~ccan/ccan
+CCAN_URL=https://github.com/rustyrussell/ccan.git
 CCAN_CREATE_TREE=rm -rf $(CCAN_LOCAL_EXTRACT) && cd $(CCAN_LOCAL_REPO) && tools/create-ccan-tree -b automake $(CCAN_LOCAL_EXTRACT)
 CCAN_DEST=$(top_srcdir)/hkl/
 CCAN_TMP_DEST=/tmp/ccan.next
@@ -107,6 +110,8 @@ ccan-update:
 	@rsync -av --exclude=Makefile.am $(CCAN_LOCAL_EXTRACT)/* $(CCAN_TMP_DEST)
 	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name '*.[ch]' | xargs sed -i -e 's,ccan/,hkl/ccan/,'
 	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name '*.[ch]' | xargs sed -i -e 's,"config.h",<hkl/ccan/ccan_config.h>,'
+	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name '_info' | xargs rm -f
+	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name 'test' | xargs rm -rf
 
 	@$(CCAN_CREATE_TREE) $(CCAN_PUBLIC_MODULES)
 
@@ -143,5 +148,3 @@ ccan-update:
 	@echo purge the previous ccan directory
 	cd $(CCAN_DEST) && rm -rf licenses && find ccan -mindepth 1 -type d \! -name ".*" | xargs rm -rf
 	rsync -av $(CCAN_TMP_DEST)/* $(top_srcdir)/hkl
-
-
diff --git a/Makefile.in b/Makefile.in
index c519065..48815b3 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -197,7 +197,7 @@ am__define_uniq_tagged_files = \
 ETAGS = etags
 CTAGS = ctags
 CSCOPE = cscope
-DIST_SUBDIRS = hkl hkl3d data gui Documentation tests contrib
+DIST_SUBDIRS = hkl hkl3d data tests gui Documentation contrib
 am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \
 	$(srcdir)/hkl.pc.in $(srcdir)/hkl3d.pc.in \
 	$(top_srcdir)/Documentation/sphinx/source/conf.py.in \
@@ -206,8 +206,8 @@ am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/config.h.in \
 	$(top_srcdir)/config/install-sh $(top_srcdir)/config/ltmain.sh \
 	$(top_srcdir)/config/missing AUTHORS COPYING ChangeLog INSTALL \
 	NEWS README config/compile config/config.guess \
-	config/config.sub config/install-sh config/ltmain.sh \
-	config/missing
+	config/config.sub config/depcomp config/install-sh \
+	config/ltmain.sh config/missing
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 distdir = $(PACKAGE)-$(VERSION)
 top_distdir = $(distdir)
@@ -293,6 +293,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -422,7 +423,7 @@ top_srcdir = @top_srcdir@
 version_info = @version_info@
 ACLOCAL_AMFLAGS = -I m4
 AM_DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-introspection --enable-hkl3d
-SUBDIRS = hkl $(am__append_1) $(am__append_2) $(am__append_3) tests \
+SUBDIRS = hkl $(am__append_1) tests $(am__append_2) $(am__append_3) \
 	$(am__append_4)
 EXTRA_DIST = hkl.pc.in hkl3d.pc.in
 installed_mainheaderdir = $(includedir)/hkl- at VMAJ@
@@ -433,10 +434,10 @@ pkgconfig_DATA = hkl.pc
 #for not do not install
 @HKL3D_TRUE at noinst_DATA = hkl3d.pc
 CCAN_PUBLIC_MODULES = darray
-CCAN_PRIVATE_MODULES = array_size container_of autodata list
+CCAN_PRIVATE_MODULES = array_size container_of autodata list generator
 CCAN_LOCAL_REPO = /tmp/ccan
 CCAN_LOCAL_EXTRACT = /tmp/ccan.tmp
-CCAN_URL = git://git.ozlabs.org/~ccan/ccan
+CCAN_URL = https://github.com/rustyrussell/ccan.git
 CCAN_CREATE_TREE = rm -rf $(CCAN_LOCAL_EXTRACT) && cd $(CCAN_LOCAL_REPO) && tools/create-ccan-tree -b automake $(CCAN_LOCAL_EXTRACT)
 CCAN_DEST = $(top_srcdir)/hkl/
 CCAN_TMP_DEST = /tmp/ccan.next
@@ -724,7 +725,7 @@ distdir: $(DISTFILES)
 	  ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
 	|| chmod -R a+r "$(distdir)"
 dist-gzip: distdir
-	tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
+	tardir=$(distdir) && $(am__tar) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).tar.gz
 	$(am__post_remove_distdir)
 
 dist-bzip2: distdir
@@ -750,7 +751,7 @@ dist-shar: distdir
 	@echo WARNING: "Support for shar distribution archives is" \
 	               "deprecated." >&2
 	@echo WARNING: "It will be removed altogether in Automake 2.0" >&2
-	shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
+	shar $(distdir) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).shar.gz
 	$(am__post_remove_distdir)
 
 dist-zip: distdir
@@ -768,7 +769,7 @@ dist dist-all:
 distcheck: dist
 	case '$(DIST_ARCHIVES)' in \
 	*.tar.gz*) \
-	  GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
+	  eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\
 	*.tar.bz2*) \
 	  bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
 	*.tar.lz*) \
@@ -778,7 +779,7 @@ distcheck: dist
 	*.tar.Z*) \
 	  uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
 	*.shar.gz*) \
-	  GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
+	  eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\
 	*.zip*) \
 	  unzip $(distdir).zip ;;\
 	esac
@@ -983,13 +984,16 @@ uninstall-am: uninstall-dist_installed_mainheaderDATA \
 
 
 release:
+	git clean -xdf
 	git fetch
 	git checkout next
-	cd scripts && ./clean-all
-	git commit -a -m "pre-release"
+#cd scripts && ./clean-all
+#git commit -a -m "pre-release"
 	git checkout maint
 	git merge -m "release" next
 	./autogen.sh
+	./configure $(AM_DISTCHECK_CONFIGURE_FLAGS)
+	$(MAKE)
 	$(MAKE) distcheck
 	git tag v`./configure -V | head -n 1 | awk '{print $$3}'`
 	git checkout next
@@ -1044,6 +1048,8 @@ ccan-update:
 	@rsync -av --exclude=Makefile.am $(CCAN_LOCAL_EXTRACT)/* $(CCAN_TMP_DEST)
 	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name '*.[ch]' | xargs sed -i -e 's,ccan/,hkl/ccan/,'
 	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name '*.[ch]' | xargs sed -i -e 's,"config.h",<hkl/ccan/ccan_config.h>,'
+	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name '_info' | xargs rm -f
+	@find $(CCAN_TMP_DEST)/ccan -maxdepth 2 -name 'test' | xargs rm -rf
 
 	@$(CCAN_CREATE_TREE) $(CCAN_PUBLIC_MODULES)
 
diff --git a/aclocal.m4 b/aclocal.m4
index ff62e6c..817a0b6 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,6 +1,6 @@
-# generated automatically by aclocal 1.15 -*- Autoconf -*-
+# generated automatically by aclocal 1.15.1 -*- Autoconf -*-
 
-# Copyright (C) 1996-2014 Free Software Foundation, Inc.
+# Copyright (C) 1996-2017 Free Software Foundation, Inc.
 
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -21,7 +21,7 @@ If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
 
 # ===========================================================================
-#      http://www.gnu.org/software/autoconf-archive/ax_append_flag.html
+#      https://www.gnu.org/software/autoconf-archive/ax_append_flag.html
 # ===========================================================================
 #
 # SYNOPSIS
@@ -56,7 +56,7 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.])
 #   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/>.
+#   with this program. If not, see <https://www.gnu.org/licenses/>.
 #
 #   As a special exception, the respective Autoconf Macro's copyright owner
 #   gives unlimited permission to copy, distribute and modify the configure
@@ -71,7 +71,7 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.])
 #   modified version of the Autoconf Macro, you may extend this special
 #   exception to the GPL to apply to your modified version as well.
 
-#serial 6
+#serial 7
 
 AC_DEFUN([AX_APPEND_FLAG],
 [dnl
@@ -93,7 +93,7 @@ AS_VAR_POPDEF([FLAGS])dnl
 ])dnl AX_APPEND_FLAG
 
 # ===========================================================================
-#    http://www.gnu.org/software/autoconf-archive/ax_cflags_warn_all.html
+#    https://www.gnu.org/software/autoconf-archive/ax_cflags_warn_all.html
 # ===========================================================================
 #
 # SYNOPSIS
@@ -137,7 +137,7 @@ AS_VAR_POPDEF([FLAGS])dnl
 #   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/>.
+#   with this program. If not, see <https://www.gnu.org/licenses/>.
 #
 #   As a special exception, the respective Autoconf Macro's copyright owner
 #   gives unlimited permission to copy, distribute and modify the configure
@@ -152,7 +152,7 @@ AS_VAR_POPDEF([FLAGS])dnl
 #   modified version of the Autoconf Macro, you may extend this special
 #   exception to the GPL to apply to your modified version as well.
 
-#serial 15
+#serial 16
 
 AC_DEFUN([AX_FLAGS_WARN_ALL],[dnl
 AS_VAR_PUSHDEF([FLAGS],[_AC_LANG_PREFIX[]FLAGS])dnl
@@ -216,7 +216,7 @@ AC_LANG_POP([Fortran])
 ])
 
 # ===========================================================================
-#    http://www.gnu.org/software/autoconf-archive/ax_require_defined.html
+#    https://www.gnu.org/software/autoconf-archive/ax_require_defined.html
 # ===========================================================================
 #
 # SYNOPSIS
@@ -247,7 +247,7 @@ AC_LANG_POP([Fortran])
 #   and this notice are preserved. This file is offered as-is, without any
 #   warranty.
 
-#serial 1
+#serial 2
 
 AC_DEFUN([AX_REQUIRE_DEFINED], [dnl
   m4_ifndef([$1], [m4_fatal([macro ]$1[ is not defined; is a m4 file missing?])])
@@ -1001,7 +1001,7 @@ AS_VAR_COPY([$1], [pkg_cv_][$1])
 AS_VAR_IF([$1], [""], [$5], [$4])dnl
 ])dnl PKG_CHECK_VAR
 
-# Copyright (C) 2002-2014 Free Software Foundation, Inc.
+# Copyright (C) 2002-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1016,7 +1016,7 @@ AC_DEFUN([AM_AUTOMAKE_VERSION],
 [am__api_version='1.15'
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.15], [],
+m4_if([$1], [1.15.1], [],
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 ])
 
@@ -1032,14 +1032,14 @@ m4_define([_AM_AUTOCONF_VERSION], [])
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.15])dnl
+[AM_AUTOMAKE_VERSION([1.15.1])dnl
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
-# Copyright (C) 2001-2014 Free Software Foundation, Inc.
+# Copyright (C) 2001-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1091,7 +1091,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd`
 
 # AM_COND_IF                                            -*- Autoconf -*-
 
-# Copyright (C) 2008-2014 Free Software Foundation, Inc.
+# Copyright (C) 2008-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1128,7 +1128,7 @@ fi[]dnl
 
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 
-# Copyright (C) 1997-2014 Free Software Foundation, Inc.
+# Copyright (C) 1997-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1159,7 +1159,7 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 
-# Copyright (C) 1999-2014 Free Software Foundation, Inc.
+# Copyright (C) 1999-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1350,7 +1350,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
 
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 
-# Copyright (C) 1999-2014 Free Software Foundation, Inc.
+# Copyright (C) 1999-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1426,7 +1426,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 
 # Do all the work for Automake.                             -*- Autoconf -*-
 
-# Copyright (C) 1996-2014 Free Software Foundation, Inc.
+# Copyright (C) 1996-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1623,7 +1623,7 @@ for _am_header in $config_headers :; do
 done
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
-# Copyright (C) 2001-2014 Free Software Foundation, Inc.
+# Copyright (C) 2001-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1644,7 +1644,7 @@ if test x"${install_sh+set}" != xset; then
 fi
 AC_SUBST([install_sh])])
 
-# Copyright (C) 2003-2014 Free Software Foundation, Inc.
+# Copyright (C) 2003-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1665,7 +1665,7 @@ AC_SUBST([am__leading_dot])])
 
 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 
-# Copyright (C) 2001-2014 Free Software Foundation, Inc.
+# Copyright (C) 2001-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1715,7 +1715,7 @@ rm -f confinc confmf
 
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
-# Copyright (C) 1997-2014 Free Software Foundation, Inc.
+# Copyright (C) 1997-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1754,7 +1754,7 @@ fi
 
 # Helper functions for option handling.                     -*- Autoconf -*-
 
-# Copyright (C) 2001-2014 Free Software Foundation, Inc.
+# Copyright (C) 2001-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1783,7 +1783,7 @@ AC_DEFUN([_AM_SET_OPTIONS],
 AC_DEFUN([_AM_IF_OPTION],
 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
-# Copyright (C) 1999-2014 Free Software Foundation, Inc.
+# Copyright (C) 1999-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1830,7 +1830,7 @@ AC_LANG_POP([C])])
 # For backward compatibility.
 AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
 
-# Copyright (C) 2001-2014 Free Software Foundation, Inc.
+# Copyright (C) 2001-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1849,7 +1849,7 @@ AC_DEFUN([AM_RUN_LOG],
 
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
-# Copyright (C) 1996-2014 Free Software Foundation, Inc.
+# Copyright (C) 1996-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1930,7 +1930,7 @@ AC_CONFIG_COMMANDS_PRE(
 rm -f conftest.file
 ])
 
-# Copyright (C) 2009-2014 Free Software Foundation, Inc.
+# Copyright (C) 2009-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -1990,7 +1990,7 @@ AC_SUBST([AM_BACKSLASH])dnl
 _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
 ])
 
-# Copyright (C) 2001-2014 Free Software Foundation, Inc.
+# Copyright (C) 2001-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -2018,7 +2018,7 @@ fi
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
-# Copyright (C) 2006-2014 Free Software Foundation, Inc.
+# Copyright (C) 2006-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -2037,7 +2037,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 
 # Check how to create a tarball.                            -*- Autoconf -*-
 
-# Copyright (C) 2004-2014 Free Software Foundation, Inc.
+# Copyright (C) 2004-2017 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
diff --git a/config/config.guess b/config/config.guess
index 0967f2a..2e9ad7f 100755
--- a/config/config.guess
+++ b/config/config.guess
@@ -2,7 +2,7 @@
 # Attempt to guess a canonical system name.
 #   Copyright 1992-2016 Free Software Foundation, Inc.
 
-timestamp='2016-04-02'
+timestamp='2016-10-02'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -186,9 +186,12 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
 	    *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
 	esac
 	# The Operating System including object format, if it has switched
-	# to ELF recently, or will in the future.
+	# to ELF recently (or will in the future) and ABI.
 	case "${UNAME_MACHINE_ARCH}" in
-	    arm*|earm*|i386|m68k|ns32k|sh3*|sparc|vax)
+	    earm*)
+		os=netbsdelf
+		;;
+	    arm*|i386|m68k|ns32k|sh3*|sparc|vax)
 		eval $set_cc_for_build
 		if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
 			| grep -q __ELF__
@@ -997,6 +1000,9 @@ EOF
 	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
 	test x"${CPU}" != x && { echo "${CPU}-unknown-linux-${LIBC}"; exit; }
 	;;
+    mips64el:Linux:*:*)
+	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+	exit ;;
     openrisc*:Linux:*:*)
 	echo or1k-unknown-linux-${LIBC}
 	exit ;;
@@ -1029,6 +1035,9 @@ EOF
     ppcle:Linux:*:*)
 	echo powerpcle-unknown-linux-${LIBC}
 	exit ;;
+    riscv32:Linux:*:* | riscv64:Linux:*:*)
+	echo ${UNAME_MACHINE}-unknown-linux-${LIBC}
+	exit ;;
     s390:Linux:*:* | s390x:Linux:*:*)
 	echo ${UNAME_MACHINE}-ibm-linux-${LIBC}
 	exit ;;
@@ -1408,18 +1417,17 @@ esac
 cat >&2 <<EOF
 $0: unable to guess system type
 
-This script, last modified $timestamp, has failed to recognize
-the operating system you are using. It is advised that you
-download the most up to date version of the config scripts from
+This script (version $timestamp), has failed to recognize the
+operating system you are using. If your script is old, overwrite
+config.guess and config.sub with the latest versions from:
 
   http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess
 and
   http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub
 
-If the version you run ($0) is already up to date, please
-send the following data and any information you think might be
-pertinent to <config-patches at gnu.org> in order to provide the needed
-information to handle your system.
+If $0 has already been updated, send the following data and any
+information you think might be pertinent to config-patches at gnu.org to
+provide the necessary information to handle your system.
 
 config.guess timestamp = $timestamp
 
diff --git a/config/config.sub b/config/config.sub
index 8d39c4b..dd2ca93 100755
--- a/config/config.sub
+++ b/config/config.sub
@@ -2,7 +2,7 @@
 # Configuration validation subroutine script.
 #   Copyright 1992-2016 Free Software Foundation, Inc.
 
-timestamp='2016-03-30'
+timestamp='2016-11-04'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -117,7 +117,7 @@ case $maybe_os in
   nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
   linux-musl* | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
   knetbsd*-gnu* | netbsd*-gnu* | netbsd*-eabi* | \
-  kopensolaris*-gnu* | \
+  kopensolaris*-gnu* | cloudabi*-eabi* | \
   storm-chaos* | os2-emx* | rtmk-nova*)
     os=-$maybe_os
     basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
@@ -301,6 +301,7 @@ case $basic_machine in
 	| open8 | or1k | or1knd | or32 \
 	| pdp10 | pdp11 | pj | pjl \
 	| powerpc | powerpc64 | powerpc64le | powerpcle \
+	| pru \
 	| pyramid \
 	| riscv32 | riscv64 \
 	| rl78 | rx \
@@ -428,6 +429,7 @@ case $basic_machine in
 	| orion-* \
 	| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
 	| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
+	| pru-* \
 	| pyramid-* \
 	| riscv32-* | riscv64-* \
 	| rl78-* | romp-* | rs6000-* | rx-* \
@@ -643,6 +645,14 @@ case $basic_machine in
 		basic_machine=m68k-bull
 		os=-sysv3
 		;;
+	e500v[12])
+		basic_machine=powerpc-unknown
+		os=$os"spe"
+		;;
+	e500v[12]-*)
+		basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=$os"spe"
+		;;
 	ebmon29k)
 		basic_machine=a29k-amd
 		os=-ebmon
@@ -1022,7 +1032,7 @@ case $basic_machine in
 	ppc-* | ppcbe-*)
 		basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
 		;;
-	ppcle | powerpclittle | ppc-le | powerpc-little)
+	ppcle | powerpclittle)
 		basic_machine=powerpcle-unknown
 		;;
 	ppcle-* | powerpclittle-*)
@@ -1032,7 +1042,7 @@ case $basic_machine in
 		;;
 	ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
 		;;
-	ppc64le | powerpc64little | ppc64-le | powerpc64-little)
+	ppc64le | powerpc64little)
 		basic_machine=powerpc64le-unknown
 		;;
 	ppc64le-* | powerpc64little-*)
@@ -1389,7 +1399,7 @@ case $os in
 	      | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
 	      | -chorusos* | -chorusrdb* | -cegcc* \
 	      | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
-	      | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
+	      | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \
 	      | -linux-newlib* | -linux-musl* | -linux-uclibc* \
 	      | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \
 	      | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
@@ -1399,7 +1409,7 @@ case $os in
 	      | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
 	      | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
 	      | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \
-	      | -onefs* | -tirtos*)
+	      | -onefs* | -tirtos* | -phoenix* | -fuchsia*)
 	# Remember, each alternative MUST END IN *, to match a version number.
 		;;
 	-qnx*)
diff --git a/config/depcomp b/config/depcomp
index fc98710..b39f98f 100755
--- a/config/depcomp
+++ b/config/depcomp
@@ -1,9 +1,9 @@
 #! /bin/sh
 # depcomp - compile a program generating dependencies as side-effects
 
-scriptversion=2013-05-30.07; # UTC
+scriptversion=2016-01-11.22; # UTC
 
-# Copyright (C) 1999-2014 Free Software Foundation, Inc.
+# Copyright (C) 1999-2017 Free Software Foundation, Inc.
 
 # 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
@@ -786,6 +786,6 @@ exit 0
 # eval: (add-hook 'write-file-hooks 'time-stamp)
 # time-stamp-start: "scriptversion="
 # time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-time-zone: "UTC"
+# time-stamp-time-zone: "UTC0"
 # time-stamp-end: "; # UTC"
 # End:
diff --git a/configure b/configure
index fc70528..a7a1ec3 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for hkl 5.0.0.2173.
+# Generated by GNU Autoconf 2.69 for hkl 5.0.0.2428.
 #
 # Report bugs to <picca at synchrotron-soleil.fr>.
 #
@@ -590,8 +590,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='hkl'
 PACKAGE_TARNAME='hkl'
-PACKAGE_VERSION='5.0.0.2173'
-PACKAGE_STRING='hkl 5.0.0.2173'
+PACKAGE_VERSION='5.0.0.2428'
+PACKAGE_STRING='hkl 5.0.0.2428'
 PACKAGE_BUGREPORT='picca at synchrotron-soleil.fr'
 PACKAGE_URL=''
 
@@ -686,6 +686,7 @@ GTKDOC_MKPDF
 GTKDOC_REBASE
 GTKDOC_CHECK_PATH
 GTKDOC_CHECK
+GNUPLOT
 EMACS
 ASY
 HKL_DOC_FALSE
@@ -1441,7 +1442,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures hkl 5.0.0.2173 to adapt to many kinds of systems.
+\`configure' configures hkl 5.0.0.2428 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1512,7 +1513,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of hkl 5.0.0.2173:";;
+     short | recursive ) echo "Configuration of hkl 5.0.0.2428:";;
    esac
   cat <<\_ACEOF
 
@@ -1668,7 +1669,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-hkl configure 5.0.0.2173
+hkl configure 5.0.0.2428
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2342,7 +2343,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by hkl $as_me 5.0.0.2173, which was
+It was created by hkl $as_me 5.0.0.2428, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -3210,7 +3211,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='hkl'
- VERSION='5.0.0.2173'
+ VERSION='5.0.0.2428'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -16664,7 +16665,7 @@ _ACEOF
 
 
 cat >>confdefs.h <<_ACEOF
-#define VREV 2173
+#define VREV 2428
 _ACEOF
 
 version_info="5:0:0"
@@ -18585,6 +18586,47 @@ $as_echo "no" >&6; }
 fi
 
 
+	    	    # Extract the first word of "gnuplot", so it can be a program name with args.
+set dummy gnuplot; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_path_GNUPLOT+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $GNUPLOT in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_GNUPLOT="$GNUPLOT" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+    ac_cv_path_GNUPLOT="$as_dir/$ac_word$ac_exec_ext"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+  test -z "$ac_cv_path_GNUPLOT" && ac_cv_path_GNUPLOT="echo"
+  ;;
+esac
+fi
+GNUPLOT=$ac_cv_path_GNUPLOT
+if test -n "$GNUPLOT"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNUPLOT" >&5
+$as_echo "$GNUPLOT" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
 
 fi
 
@@ -19839,7 +19881,7 @@ fi
 
 fi
 
-ac_config_files="$ac_config_files Makefile hkl/Makefile hkl/ccan/Makefile hkl.pc hkl3d/Makefile hkl3d.pc tests/Makefile tests/bindings/Makefile tests/tap/Makefile Documentation/Makefile Documentation/hkl.org Documentation/api/Makefile Documentation/figures/Makefile Documentation/sphinx/Makefile Documentation/sphinx/source/conf.py gui/Makefile data/Makefile contrib/Makefile contrib/sixs/Makefile"
+ac_config_files="$ac_config_files Makefile hkl/Makefile hkl/api2/Makefile hkl/ccan/Makefile hkl.pc hkl3d/Makefile hkl3d.pc tests/Makefile tests/bindings/Makefile tests/tap/Makefile Documentation/Makefile Documentation/hkl.org Documentation/api/Makefile Documentation/figures/Makefile Documentation/sphinx/Makefile Documentation/sphinx/source/conf.py gui/Makefile data/Makefile contrib/Makefile contrib/sixs/Makefile"
 
 
 cat >confcache <<\_ACEOF
@@ -20424,7 +20466,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by hkl $as_me 5.0.0.2173, which was
+This file was extended by hkl $as_me 5.0.0.2428, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -20490,7 +20532,7 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-hkl config.status 5.0.0.2173
+hkl config.status 5.0.0.2428
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
@@ -21005,6 +21047,7 @@ do
     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
     "hkl/Makefile") CONFIG_FILES="$CONFIG_FILES hkl/Makefile" ;;
+    "hkl/api2/Makefile") CONFIG_FILES="$CONFIG_FILES hkl/api2/Makefile" ;;
     "hkl/ccan/Makefile") CONFIG_FILES="$CONFIG_FILES hkl/ccan/Makefile" ;;
     "hkl.pc") CONFIG_FILES="$CONFIG_FILES hkl.pc" ;;
     "hkl3d/Makefile") CONFIG_FILES="$CONFIG_FILES hkl3d/Makefile" ;;
diff --git a/configure.ac b/configure.ac
index 64af153..00980c3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -140,6 +140,8 @@ AM_COND_IF([HKL_DOC],
 	    AC_PATH_PROG([ASY], [asy], [echo])
 	    dnl *** emacs ***
 	    AC_PATH_PROG([EMACS], [emacs], [no])
+	    dnl *** gnuplot ***
+	    AC_PATH_PROG([GNUPLOT], [gnuplot], [echo])
 	   ])
 
 dnl *** gtk-doc ***
@@ -206,6 +208,7 @@ AM_COND_IF([CONTRIB],
 
 AC_CONFIG_FILES([Makefile
 		 hkl/Makefile
+		 hkl/api2/Makefile
 		 hkl/ccan/Makefile
 		 hkl.pc
 		 hkl3d/Makefile
diff --git a/contrib/Makefile.in b/contrib/Makefile.in
index a5965f4..f6a929b 100644
--- a/contrib/Makefile.in
+++ b/contrib/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -225,6 +225,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/contrib/sixs/Makefile.in b/contrib/sixs/Makefile.in
index 8edc892..1564c6e 100644
--- a/contrib/sixs/Makefile.in
+++ b/contrib/sixs/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -216,6 +216,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/contrib/sixs/hkl3d.c b/contrib/sixs/hkl3d.c
index 0f639fd..36f11d6 100644
--- a/contrib/sixs/hkl3d.c
+++ b/contrib/sixs/hkl3d.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/data/Makefile.in b/data/Makefile.in
index feaafe0..14370f8 100644
--- a/data/Makefile.in
+++ b/data/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -195,6 +195,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/gtk-doc.make b/gtk-doc.make
index e4a12a5..263193e 100644
--- a/gtk-doc.make
+++ b/gtk-doc.make
@@ -81,55 +81,54 @@ $(REPORT_FILES): sgml-build.stamp
 
 #### setup ####
 
-GTK_DOC_V_SETUP=$(GTK_DOC_V_SETUP_$(V))
-GTK_DOC_V_SETUP_=$(GTK_DOC_V_SETUP_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_SETUP=$(GTK_DOC_V_SETUP_ at AM_V@)
+GTK_DOC_V_SETUP_=$(GTK_DOC_V_SETUP_ at AM_DEFAULT_V@)
 GTK_DOC_V_SETUP_0=@echo "  DOC   Preparing build";
 
 setup-build.stamp:
 	-$(GTK_DOC_V_SETUP)if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
-	    files=`echo $(SETUP_FILES) $(DOC_MODULE).types`; \
-	    if test "x$$files" != "x" ; then \
-	        for file in $$files ; do \
-	            destdir=`dirname $(abs_builddir)/$$file`; \
-	            test -d "$$destdir" || mkdir -p "$$destdir"; \
-	            test -f $(abs_srcdir)/$$file && \
-	                cp -pf $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
-	        done; \
-	    fi; \
+	  files=`echo $(SETUP_FILES) $(DOC_MODULE).types`; \
+	  if test "x$$files" != "x" ; then \
+	    for file in $$files ; do \
+	      destdir=`dirname $(abs_builddir)/$$file`; \
+	      test -d "$$destdir" || mkdir -p "$$destdir"; \
+	      test -f $(abs_srcdir)/$$file && \
+	        cp -pf $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
+	    done; \
+	  fi; \
 	fi
 	$(AM_V_at)touch setup-build.stamp
 
-
 #### scan ####
 
-GTK_DOC_V_SCAN=$(GTK_DOC_V_SCAN_$(V))
-GTK_DOC_V_SCAN_=$(GTK_DOC_V_SCAN_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_SCAN=$(GTK_DOC_V_SCAN_ at AM_V@)
+GTK_DOC_V_SCAN_=$(GTK_DOC_V_SCAN_ at AM_DEFAULT_V@)
 GTK_DOC_V_SCAN_0=@echo "  DOC   Scanning header files";
 
-GTK_DOC_V_INTROSPECT=$(GTK_DOC_V_INTROSPECT_$(V))
-GTK_DOC_V_INTROSPECT_=$(GTK_DOC_V_INTROSPECT_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_INTROSPECT=$(GTK_DOC_V_INTROSPECT_ at AM_V@)
+GTK_DOC_V_INTROSPECT_=$(GTK_DOC_V_INTROSPECT_ at AM_DEFAULT_V@)
 GTK_DOC_V_INTROSPECT_0=@echo "  DOC   Introspecting gobjects";
 
 scan-build.stamp: setup-build.stamp $(HFILE_GLOB) $(CFILE_GLOB)
 	$(GTK_DOC_V_SCAN)_source_dir='' ; \
 	for i in $(DOC_SOURCE_DIR) ; do \
-	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
+	  _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
 	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES)
 	$(GTK_DOC_V_INTROSPECT)if grep -l '^..*$$' $(DOC_MODULE).types > /dev/null 2>&1 ; then \
-	    scanobj_options=""; \
-	    gtkdoc-scangobj 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
-	    if test "$$?" = "0"; then \
-	        if test "x$(V)" = "x1"; then \
-	            scanobj_options="--verbose"; \
-	        fi; \
+	  scanobj_options=""; \
+	  gtkdoc-scangobj 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
+	  if test "$$?" = "0"; then \
+	    if test "x$(V)" = "x1"; then \
+	      scanobj_options="--verbose"; \
 	    fi; \
-	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
-	    gtkdoc-scangobj $(SCANGOBJ_OPTIONS) $$scanobj_options --module=$(DOC_MODULE); \
+	  fi; \
+	  CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
+	  gtkdoc-scangobj $(SCANGOBJ_OPTIONS) $$scanobj_options --module=$(DOC_MODULE); \
 	else \
-	    for i in $(SCANOBJ_FILES) ; do \
-	        test -f $$i || touch $$i ; \
-	    done \
+	  for i in $(SCANOBJ_FILES) ; do \
+	    test -f $$i || touch $$i ; \
+	  done \
 	fi
 	$(AM_V_at)touch scan-build.stamp
 
@@ -138,14 +137,14 @@ $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)
 
 #### xml ####
 
-GTK_DOC_V_XML=$(GTK_DOC_V_XML_$(V))
-GTK_DOC_V_XML_=$(GTK_DOC_V_XML_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_XML=$(GTK_DOC_V_XML_ at AM_V@)
+GTK_DOC_V_XML_=$(GTK_DOC_V_XML_ at AM_DEFAULT_V@)
 GTK_DOC_V_XML_0=@echo "  DOC   Building XML";
 
 sgml-build.stamp: setup-build.stamp $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(HFILE_GLOB) $(CFILE_GLOB) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt $(expand_content_files) xml/gtkdocentities.ent
 	$(GTK_DOC_V_XML)_source_dir='' ; \
 	for i in $(DOC_SOURCE_DIR) ; do \
-	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
+	  _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
 	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)
 	$(AM_V_at)touch sgml-build.stamp
@@ -166,12 +165,12 @@ xml/gtkdocentities.ent: Makefile
 
 #### html ####
 
-GTK_DOC_V_HTML=$(GTK_DOC_V_HTML_$(V))
-GTK_DOC_V_HTML_=$(GTK_DOC_V_HTML_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_HTML=$(GTK_DOC_V_HTML_ at AM_V@)
+GTK_DOC_V_HTML_=$(GTK_DOC_V_HTML_ at AM_DEFAULT_V@)
 GTK_DOC_V_HTML_0=@echo "  DOC   Building HTML";
 
-GTK_DOC_V_XREF=$(GTK_DOC_V_XREF_$(V))
-GTK_DOC_V_XREF_=$(GTK_DOC_V_XREF_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_XREF=$(GTK_DOC_V_XREF_ at AM_V@)
+GTK_DOC_V_XREF_=$(GTK_DOC_V_XREF_ at AM_DEFAULT_V@)
 GTK_DOC_V_XREF_0=@echo "  DOC   Fixing cross-references";
 
 html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files) $(expand_content_files)
@@ -190,20 +189,17 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files) $(expand_con
 	cd html && gtkdoc-mkhtml $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
 	- at test "x$(HTML_IMAGES)" = "x" || \
 	for file in $(HTML_IMAGES) ; do \
-	  if test -f $(abs_srcdir)/$$file ; then \
-	    cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
-	  fi; \
-	  if test -f $(abs_builddir)/$$file ; then \
-	    cp $(abs_builddir)/$$file $(abs_builddir)/html; \
-	  fi; \
+	  test -f $(abs_srcdir)/$$file && cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
+	  test -f $(abs_builddir)/$$file && cp $(abs_builddir)/$$file $(abs_builddir)/html; \
+	  test -f $$file && cp $$file $(abs_builddir)/html; \
 	done;
 	$(GTK_DOC_V_XREF)gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
 	$(AM_V_at)touch html-build.stamp
 
 #### pdf ####
 
-GTK_DOC_V_PDF=$(GTK_DOC_V_PDF_$(V))
-GTK_DOC_V_PDF_=$(GTK_DOC_V_PDF_$(AM_DEFAULT_VERBOSITY))
+GTK_DOC_V_PDF=$(GTK_DOC_V_PDF_ at AM_V@)
+GTK_DOC_V_PDF_=$(GTK_DOC_V_PDF_ at AM_DEFAULT_V@)
 GTK_DOC_V_PDF_0=@echo "  DOC   Building PDF";
 
 pdf-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files) $(expand_content_files)
diff --git a/gui/Makefile.in b/gui/Makefile.in
index 2d71615..1cde367 100644
--- a/gui/Makefile.in
+++ b/gui/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -295,6 +295,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/gui/hkl-gui-3d.c b/gui/hkl-gui-3d.c
index 5b504ea..7edf4d6 100644
--- a/gui/hkl-gui-3d.c
+++ b/gui/hkl-gui-3d.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/gui/hkl-gui-3d.h b/gui/hkl-gui-3d.h
index 780882e..a05f3d6 100644
--- a/gui/hkl-gui-3d.h
+++ b/gui/hkl-gui-3d.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/gui/hkl-gui-macros.h b/gui/hkl-gui-macros.h
index de02048..4f20cf9 100644
--- a/gui/hkl-gui-macros.h
+++ b/gui/hkl-gui-macros.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/gui/hkl-gui.c b/gui/hkl-gui.c
index ca895c0..f2c59b9 100644
--- a/gui/hkl-gui.c
+++ b/gui/hkl-gui.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -2166,88 +2166,88 @@ hkl_gui_window_toolbutton_setUB_clicked_cb(GtkToolButton* _sender, gpointer user
 	hkl_matrix_free(UB);
 }
 
-				 void
-				 hkl_gui_window_toolbutton_computeUB_clicked_cb (GtkToolButton* _sender, gpointer user_data)
-				 {
-					 HklGuiWindow *self = HKL_GUI_WINDOW(user_data);
-					 HklGuiWindowPrivate *priv = HKL_GUI_WINDOW_GET_PRIVATE(user_data);
-					 GtkTreeSelection* selection = NULL;
-					 guint nb_rows = 0U;
-
-					 selection = gtk_tree_view_get_selection (priv->treeview_reflections);
-					 nb_rows = gtk_tree_selection_count_selected_rows (selection);
-					 if (nb_rows > 1) {
-						 GtkTreeModel* model = NULL;
-						 GList* list;
-						 GtkTreeIter iter = {0};
-						 GtkTreePath *path;
-						 HklSampleReflection *ref1, *ref2;
-						 GError *error = NULL;
-
-						 model = GTK_TREE_MODEL(priv->liststore_reflections);
-						 list = gtk_tree_selection_get_selected_rows (selection, &model);
-
-						 /* get the first reflection */
-						 path = g_list_nth_data(list, 0);
-						 gtk_tree_model_get_iter (GTK_TREE_MODEL(priv->liststore_reflections),
-									  &iter,
-									  path);
-						 gtk_tree_model_get (GTK_TREE_MODEL(priv->liststore_reflections), &iter,
-								     REFLECTION_COL_REFLECTION, &ref1,
-								     -1);
-
-						 /* get the second one */
-						 path = g_list_nth_data(list, 1);
-						 gtk_tree_model_get_iter (GTK_TREE_MODEL(priv->liststore_reflections),
-									  &iter,
-									  path);
-						 gtk_tree_model_get (GTK_TREE_MODEL(priv->liststore_reflections), &iter,
-								     REFLECTION_COL_REFLECTION, &ref2,
-								     -1);
-
-						 if(!hkl_sample_compute_UB_busing_levy(priv->sample,
-										       ref1, ref2, &error)){
-							 raise_error(self, &error);
-						 }else{
-							 if(priv->diffractometer)
-								 diffractometer_set_sample(priv->diffractometer,
-											   priv->sample);
-
-							 update_UB (self);
-							 update_ux_uy_uz (self);
-							 update_pseudo_axes (self);
-							 update_pseudo_axes_frames (self);
-						 }
-						 g_list_free_full (list, (GDestroyNotify) gtk_tree_path_free);
-					 } else {
-						 gtk_statusbar_push (priv->statusbar, 0,
-								     "Please select at least two reflection.");
-					 }
-				 }
-
-				 void
-				 hkl_gui_window_toolbutton_affiner_clicked_cb (GtkToolButton* _sender, gpointer user_data)
-				 {
-					 HklGuiWindow *self = HKL_GUI_WINDOW(user_data);
-					 HklGuiWindowPrivate *priv = HKL_GUI_WINDOW_GET_PRIVATE(user_data);
-					 GError *error = NULL;
-
-					 if(!hkl_sample_affine (priv->sample, &error)){
-						 raise_error(self, &error);
-					 }else{
-						 if(priv->diffractometer)
-							 diffractometer_set_sample(priv->diffractometer,
-										   priv->sample);
-
-						 update_lattice (self);
-						 update_crystal_model (self);
-						 update_reciprocal_lattice (self);
-						 update_UB (self);
-						 update_ux_uy_uz (self);
-						 update_pseudo_axes (self);
-						 update_pseudo_axes_frames (self);
-					 }
-				 }
+void
+hkl_gui_window_toolbutton_computeUB_clicked_cb (GtkToolButton* _sender, gpointer user_data)
+{
+	HklGuiWindow *self = HKL_GUI_WINDOW(user_data);
+	HklGuiWindowPrivate *priv = HKL_GUI_WINDOW_GET_PRIVATE(user_data);
+	GtkTreeSelection* selection = NULL;
+	guint nb_rows = 0U;
+
+	selection = gtk_tree_view_get_selection (priv->treeview_reflections);
+	nb_rows = gtk_tree_selection_count_selected_rows (selection);
+	if (nb_rows > 1) {
+		GtkTreeModel* model = NULL;
+		GList* list;
+		GtkTreeIter iter = {0};
+		GtkTreePath *path;
+		HklSampleReflection *ref1, *ref2;
+		GError *error = NULL;
+
+		model = GTK_TREE_MODEL(priv->liststore_reflections);
+		list = gtk_tree_selection_get_selected_rows (selection, &model);
+
+		/* get the first reflection */
+		path = g_list_nth_data(list, 0);
+		gtk_tree_model_get_iter (GTK_TREE_MODEL(priv->liststore_reflections),
+					 &iter,
+					 path);
+		gtk_tree_model_get (GTK_TREE_MODEL(priv->liststore_reflections), &iter,
+				    REFLECTION_COL_REFLECTION, &ref1,
+				    -1);
+
+		/* get the second one */
+		path = g_list_nth_data(list, 1);
+		gtk_tree_model_get_iter (GTK_TREE_MODEL(priv->liststore_reflections),
+					 &iter,
+					 path);
+		gtk_tree_model_get (GTK_TREE_MODEL(priv->liststore_reflections), &iter,
+				    REFLECTION_COL_REFLECTION, &ref2,
+				    -1);
+
+		if(!hkl_sample_compute_UB_busing_levy(priv->sample,
+						      ref1, ref2, &error)){
+			raise_error(self, &error);
+		}else{
+			if(priv->diffractometer)
+				diffractometer_set_sample(priv->diffractometer,
+							  priv->sample);
+
+			update_UB (self);
+			update_ux_uy_uz (self);
+			update_pseudo_axes (self);
+			update_pseudo_axes_frames (self);
+		}
+		g_list_free_full (list, (GDestroyNotify) gtk_tree_path_free);
+	} else {
+		gtk_statusbar_push (priv->statusbar, 0,
+				    "Please select at least two reflection.");
+	}
+}
+
+void
+hkl_gui_window_toolbutton_affiner_clicked_cb (GtkToolButton* _sender, gpointer user_data)
+{
+	HklGuiWindow *self = HKL_GUI_WINDOW(user_data);
+	HklGuiWindowPrivate *priv = HKL_GUI_WINDOW_GET_PRIVATE(user_data);
+	GError *error = NULL;
+
+	if(!hkl_sample_affine (priv->sample, &error)){
+		raise_error(self, &error);
+	}else{
+		if(priv->diffractometer)
+			diffractometer_set_sample(priv->diffractometer,
+						  priv->sample);
+
+		update_lattice (self);
+		update_crystal_model (self);
+		update_reciprocal_lattice (self);
+		update_UB (self);
+		update_ux_uy_uz (self);
+		update_pseudo_axes (self);
+		update_pseudo_axes_frames (self);
+	}
+}
 
 #define TOGGLE_LATTICE_CB(_parameter)					\
 	void hkl_gui_window_checkbutton_ ## _parameter ## _toggled_cb(GtkCheckButton *checkbutton, \
diff --git a/gui/hkl-gui.h b/gui/hkl-gui.h
index f74ea2f..1def2d3 100644
--- a/gui/hkl-gui.h
+++ b/gui/hkl-gui.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl.h b/hkl.h
index 38ac127..37ad6d9 100644
--- a/hkl.h
+++ b/hkl.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -100,6 +100,10 @@ struct _HklVector
 	double data[3];
 };
 
+#define HKL_VECTOR_X {{1, 0, 0}}
+#define HKL_VECTOR_Y {{0, 1, 0}}
+#define HKL_VECTOR_Z {{0, 0, 1}}
+
 HKLAPI void hkl_vector_init(HklVector *self, double x, double y, double z);
 
 /**************/
@@ -122,13 +126,13 @@ HKLAPI void hkl_quaternion_to_matrix(const HklQuaternion *self, HklMatrix *m) HK
 /* Matrix */
 /**********/
 
-HKLAPI HklMatrix *hkl_matrix_new(void);
+HKLAPI HklMatrix *hkl_matrix_new(void) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI HklMatrix *hkl_matrix_new_full(double m11, double m12, double m13,
 				      double m21, double m22, double m23,
-				      double m31, double m32, double m33);
+				      double m31, double m32, double m33) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklMatrix *hkl_matrix_new_euler(double euler_x, double euler_y, double euler_z);
+HKLAPI HklMatrix *hkl_matrix_new_euler(double euler_x, double euler_y, double euler_z) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI double hkl_matrix_get(const HklMatrix *self, unsigned int i, unsigned int j) HKL_ARG_NONNULL(1);
 
@@ -161,15 +165,15 @@ typedef struct _HklParameter HklParameter;
 
 /* HklParameter */
 
-HKLAPI HklParameter *hkl_parameter_new_copy(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI HklParameter *hkl_parameter_new_copy(const HklParameter *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_parameter_free(HklParameter *self) HKL_ARG_NONNULL(1);
 
-HKLAPI const char *hkl_parameter_name_get(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_parameter_name_get(const HklParameter *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const char *hkl_parameter_default_unit_get(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_parameter_default_unit_get(const HklParameter *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const char *hkl_parameter_user_unit_get(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_parameter_user_unit_get(const HklParameter *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI double hkl_parameter_value_get(const HklParameter *self,
 				      HklUnitEnum unit_type) HKL_ARG_NONNULL(1);
@@ -191,11 +195,11 @@ HKLAPI void hkl_parameter_randomize(HklParameter *self) HKL_ARG_NONNULL(1);
 
 /* getter and setter specific to certain type of HklParameter */
 
-HKLAPI const HklVector *hkl_parameter_axis_v_get(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklVector *hkl_parameter_axis_v_get(const HklParameter *self) HKL_ARG_NONNULL(1)HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklQuaternion *hkl_parameter_quaternion_get(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklQuaternion *hkl_parameter_quaternion_get(const HklParameter *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const char *hkl_parameter_description_get(const HklParameter *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_parameter_description_get(const HklParameter *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 /************/
 /* Detector */
@@ -207,9 +211,9 @@ typedef enum _HklDetectorType
 	HKL_DETECTOR_TYPE_0D
 } HklDetectorType;
 
-HKLAPI HklDetector *hkl_detector_factory_new(HklDetectorType type);
+HKLAPI HklDetector *hkl_detector_factory_new(HklDetectorType type) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklDetector *hkl_detector_new_copy(const HklDetector *src) HKL_ARG_NONNULL(1);
+HKLAPI HklDetector *hkl_detector_new_copy(const HklDetector *src) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_detector_free(HklDetector *self) HKL_ARG_NONNULL(1);
 
@@ -226,13 +230,13 @@ typedef struct _HklSample HklSample; /* forwarded declaration */
 
 /* HklGeometry */
 
-HKLAPI HklGeometry *hkl_geometry_new_copy(const HklGeometry *self) HKL_ARG_NONNULL(1);
+HKLAPI HklGeometry *hkl_geometry_new_copy(const HklGeometry *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_geometry_free(HklGeometry *self) HKL_ARG_NONNULL(1);
 
 HKLAPI int hkl_geometry_set(HklGeometry *self, const HklGeometry *src) HKL_ARG_NONNULL(1, 2);
 
-HKLAPI const darray_string *hkl_geometry_axis_names_get(const HklGeometry *self) HKL_ARG_NONNULL(1);
+HKLAPI const darray_string *hkl_geometry_axis_names_get(const HklGeometry *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI const HklParameter *hkl_geometry_axis_get(const HklGeometry *self, const char *name,
 						 GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
@@ -250,7 +254,7 @@ HKLAPI int hkl_geometry_axis_values_set(HklGeometry *self,
 					HklUnitEnum unit_type,
 					GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const char *hkl_geometry_name_get(const HklGeometry *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_geometry_name_get(const HklGeometry *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI double hkl_geometry_wavelength_get(const HklGeometry *self,
 					  HklUnitEnum unit_type) HKL_ARG_NONNULL(1);
@@ -282,14 +286,14 @@ HKLAPI void hkl_geometry_list_free(HklGeometryList *self) HKL_ARG_NONNULL(1);
 
 HKLAPI size_t hkl_geometry_list_n_items_get(const HklGeometryList *self) HKL_ARG_NONNULL(1);
 
-HKLAPI const HklGeometryListItem *hkl_geometry_list_items_first_get(const HklGeometryList *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklGeometryListItem *hkl_geometry_list_items_first_get(const HklGeometryList *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI const HklGeometryListItem *hkl_geometry_list_items_next_get(const HklGeometryList *self,
-								   const HklGeometryListItem *item) HKL_ARG_NONNULL(1, 2);
+								   const HklGeometryListItem *item) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
 /* HklGeometryListItem */
 
-HKLAPI const HklGeometry *hkl_geometry_list_item_geometry_get(const HklGeometryListItem *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklGeometry *hkl_geometry_list_item_geometry_get(const HklGeometryListItem *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 /**********/
 /* Sample */
@@ -304,43 +308,43 @@ HKLAPI HklLattice *hkl_lattice_new(double a, double b, double c,
 				   double alpha, double beta, double gamma,
 				   GError **error) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklLattice *hkl_lattice_new_copy(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI HklLattice *hkl_lattice_new_copy(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklLattice *hkl_lattice_new_default(void);
+HKLAPI HklLattice *hkl_lattice_new_default(void) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_lattice_free(HklLattice *self) HKL_ARG_NONNULL(1);
 
-HKLAPI const HklParameter *hkl_lattice_a_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_a_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_a_set(HklLattice *self, const HklParameter *parameter,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_lattice_b_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_b_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_b_set(HklLattice *self, const HklParameter *parameter,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_lattice_c_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_c_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_c_set(HklLattice *self, const HklParameter *parameter,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_lattice_alpha_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_alpha_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_alpha_set(HklLattice *self, const HklParameter *parameter,
 				 GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_lattice_beta_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_beta_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_beta_set(HklLattice *self, const HklParameter *parameter,
 				GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_lattice_gamma_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_gamma_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_gamma_set(HklLattice *self, const HklParameter *parameter,
 				 GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_lattice_volume_get(const HklLattice *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_lattice_volume_get(const HklLattice *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_lattice_set(HklLattice *self,
 			   double a, double b, double c,
@@ -360,40 +364,40 @@ HKLAPI int hkl_lattice_reciprocal(const HklLattice *self, HklLattice *reciprocal
 
 /* HklSample */
 
-HKLAPI HklSample *hkl_sample_new(const char *name) HKL_ARG_NONNULL(1);
+HKLAPI HklSample *hkl_sample_new(const char *name) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklSample *hkl_sample_new_copy(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI HklSample *hkl_sample_new_copy(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_sample_free(HklSample *self) HKL_ARG_NONNULL(1);
 
-HKLAPI const char *hkl_sample_name_get(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_sample_name_get(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_sample_name_set(HklSample *self, const char *name) HKL_ARG_NONNULL(1, 2);
 
-HKLAPI const HklLattice *hkl_sample_lattice_get(HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklLattice *hkl_sample_lattice_get(HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_sample_lattice_set(HklSample *self, const HklLattice *lattice) HKL_ARG_NONNULL(1, 2);
 
-HKLAPI const HklParameter *hkl_sample_ux_get(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_sample_ux_get(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_sample_ux_set(HklSample *self, const HklParameter *ux,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_sample_uy_get(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_sample_uy_get(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_sample_uy_set(HklSample *self, const HklParameter *uy,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklParameter *hkl_sample_uz_get(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklParameter *hkl_sample_uz_get(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_sample_uz_set(HklSample *self, const HklParameter *uz,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const HklMatrix *hkl_sample_U_get(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklMatrix *hkl_sample_U_get(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_sample_U_set(HklSample *self, const HklMatrix *U, GError **error) HKL_ARG_NONNULL(1);
 
-HKLAPI const HklMatrix *hkl_sample_UB_get(const HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklMatrix *hkl_sample_UB_get(const HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_sample_UB_set(HklSample *self, const HklMatrix *UB,
 			     GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
@@ -404,10 +408,10 @@ HKLAPI size_t hkl_sample_n_reflections_get(const HklSample *self) HKL_ARG_NONNUL
 							 (_item);	\
 							 (_item)=hkl_sample_reflections_next_get((_list), (_item)))
 
-HKLAPI HklSampleReflection *hkl_sample_reflections_first_get(HklSample *self) HKL_ARG_NONNULL(1);
+HKLAPI HklSampleReflection *hkl_sample_reflections_first_get(HklSample *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI HklSampleReflection *hkl_sample_reflections_next_get(HklSample *self,
-							    HklSampleReflection *reflection) HKL_ARG_NONNULL(1, 2);
+							    HklSampleReflection *reflection) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_sample_del_reflection(HklSample *self,
 				      HklSampleReflection *reflection) HKL_ARG_NONNULL(1, 2);
@@ -448,7 +452,7 @@ HKLAPI int hkl_sample_reflection_flag_get(const HklSampleReflection *self) HKL_A
 
 HKLAPI void hkl_sample_reflection_flag_set(HklSampleReflection *self, int flag) HKL_ARG_NONNULL(1);
 
-HKLAPI const HklGeometry *hkl_sample_reflection_geometry_get(HklSampleReflection *self) HKL_ARG_NONNULL(1);
+HKLAPI const HklGeometry *hkl_sample_reflection_geometry_get(HklSampleReflection *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI void hkl_sample_reflection_geometry_set(HklSampleReflection *self,
 					       const HklGeometry *geometry) HKL_ARG_NONNULL(1, 2);
@@ -464,11 +468,11 @@ typedef darray(HklEngine *) darray_engine;
 
 /* HklEngine */
 
-HKLAPI const char *hkl_engine_name_get(const HklEngine *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_engine_name_get(const HklEngine *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI unsigned int hkl_engine_len(const HklEngine *self) HKL_ARG_NONNULL(1);
 
-HKLAPI const darray_string *hkl_engine_pseudo_axis_names_get(HklEngine *self) HKL_ARG_NONNULL(1);
+HKLAPI const darray_string *hkl_engine_pseudo_axis_names_get(HklEngine *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_engine_pseudo_axis_values_get(HklEngine *self,
 					     double values[], size_t n_values,
@@ -500,9 +504,9 @@ HKLAPI void hkl_engine_fprintf(FILE *f, const HklEngine *self) HKL_ARG_NONNULL(1
 
 /* mode */
 
-HKLAPI const darray_string *hkl_engine_modes_names_get(const HklEngine *self) HKL_ARG_NONNULL(1);
+HKLAPI const darray_string *hkl_engine_modes_names_get(const HklEngine *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const char *hkl_engine_current_mode_get(const HklEngine *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_engine_current_mode_get(const HklEngine *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_engine_current_mode_set(HklEngine *self, const char *name, GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
 
@@ -513,9 +517,9 @@ typedef enum _HklEngineAxisNamesGet
 } HklEngineAxisNamesGet;
 
 HKLAPI const darray_string *hkl_engine_axis_names_get(const HklEngine *self,
-						      HklEngineAxisNamesGet mode) HKL_ARG_NONNULL(1);
+						      HklEngineAxisNamesGet mode) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const darray_string *hkl_engine_parameters_names_get(const HklEngine *self) HKL_ARG_NONNULL(1);
+HKLAPI const darray_string *hkl_engine_parameters_names_get(const HklEngine *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI const HklParameter *hkl_engine_parameter_get(const HklEngine *self, const char *name,
 						    GError **error) HKL_ARG_NONNULL(1, 2) HKL_WARN_UNUSED_RESULT;
@@ -546,9 +550,9 @@ HKLAPI unsigned int hkl_engine_dependencies_get(const HklEngine *self) HKL_ARG_N
 
 HKLAPI void hkl_engine_list_free(HklEngineList *self) HKL_ARG_NONNULL(1);
 
-HKLAPI darray_engine *hkl_engine_list_engines_get(HklEngineList *self) HKL_ARG_NONNULL(1);
+HKLAPI darray_engine *hkl_engine_list_engines_get(HklEngineList *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklGeometry *hkl_engine_list_geometry_get(HklEngineList *self) HKL_ARG_NONNULL(1);
+HKLAPI HklGeometry *hkl_engine_list_geometry_get(HklEngineList *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI int hkl_engine_list_geometry_set(HklEngineList *self, const HklGeometry *geometry) HKL_ARG_NONNULL(1, 2);
 
@@ -575,16 +579,16 @@ HKLAPI void hkl_engine_list_fprintf(FILE *f,
 
 typedef struct _HklFactory HklFactory;
 
-HKLAPI HklFactory **hkl_factory_get_all(size_t *n) HKL_ARG_NONNULL(1);
+HKLAPI HklFactory **hkl_factory_get_all(size_t *n) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 HKLAPI HklFactory *hkl_factory_get_by_name(const char *name,
 					   GError **error) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI const char *hkl_factory_name_get(const HklFactory *self) HKL_ARG_NONNULL(1);
+HKLAPI const char *hkl_factory_name_get(const HklFactory *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklGeometry *hkl_factory_create_new_geometry(const HklFactory *self) HKL_ARG_NONNULL(1);
+HKLAPI HklGeometry *hkl_factory_create_new_geometry(const HklFactory *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
-HKLAPI HklEngineList *hkl_factory_create_new_engine_list(const HklFactory *self) HKL_ARG_NONNULL(1);
+HKLAPI HklEngineList *hkl_factory_create_new_engine_list(const HklFactory *self) HKL_ARG_NONNULL(1) HKL_WARN_UNUSED_RESULT;
 
 G_END_DECLS
 
diff --git a/hkl/Makefile.am b/hkl/Makefile.am
index bbc8774..33e8537 100644
--- a/hkl/Makefile.am
+++ b/hkl/Makefile.am
@@ -1,5 +1,5 @@
 ## Process this file with automake to produce Makefile.in
-SUBDIRS = ccan
+SUBDIRS = ccan . api2
 
 AM_LDFLAGS = \
 	-no-undefined -version-info 5:0:0 \
@@ -36,6 +36,7 @@ hkl_c_sources = \
 	hkl-engine-k4c.c \
 	hkl-engine-e6c.c \
 	hkl-engine-k6c.c \
+	hkl-engine-petra3-p08-lisa.c \
 	hkl-engine-petra3-p09-eh2.c \
 	hkl-engine-soleil-sirius-turret.c \
 	hkl-engine-soleil-sixs-med.c \
@@ -43,6 +44,7 @@ hkl_c_sources = \
 	hkl-quaternion.c \
 	hkl-sample.c \
 	hkl-source.c \
+	hkl-trajectory.c \
 	hkl-unit.c \
 	hkl-vector.c
 
@@ -69,6 +71,7 @@ hkl_private_h_sources = \
 	hkl-quaternion-private.h \
 	hkl-sample-private.h \
 	hkl-source-private.h \
+	hkl-trajectory-private.h \
 	hkl-unit-private.h \
 	hkl-vector-private.h
 
diff --git a/hkl/Makefile.in b/hkl/Makefile.in
index beeaac1..b2fc6ee 100644
--- a/hkl/Makefile.in
+++ b/hkl/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -159,9 +159,10 @@ am__libhkl_la_SOURCES_DIST = hkl-axis.c hkl-detector.c \
 	hkl-pseudoaxis-common-psi.c hkl-pseudoaxis-common-q.c \
 	hkl-pseudoaxis-common-readonly.c hkl-pseudoaxis-common-tth.c \
 	hkl-engine-2c.c hkl-engine-e4c.c hkl-engine-k4c.c \
-	hkl-engine-e6c.c hkl-engine-k6c.c hkl-engine-petra3-p09-eh2.c \
-	hkl-engine-soleil-sirius-turret.c hkl-engine-soleil-sixs-med.c \
-	hkl-engine-zaxis.c hkl-quaternion.c hkl-sample.c hkl-source.c \
+	hkl-engine-e6c.c hkl-engine-k6c.c hkl-engine-petra3-p08-lisa.c \
+	hkl-engine-petra3-p09-eh2.c hkl-engine-soleil-sirius-turret.c \
+	hkl-engine-soleil-sixs-med.c hkl-engine-zaxis.c \
+	hkl-quaternion.c hkl-sample.c hkl-source.c hkl-trajectory.c \
 	hkl-unit.c hkl-vector.c hkl-axis-private.h \
 	hkl-detector-private.h hkl-factory-private.h \
 	hkl-geometry-private.h hkl-interval-private.h \
@@ -174,7 +175,8 @@ am__libhkl_la_SOURCES_DIST = hkl-axis.c hkl-detector.c \
 	hkl-pseudoaxis-common-q-private.h \
 	hkl-pseudoaxis-common-readonly-private.h \
 	hkl-pseudoaxis-common-tth-private.h hkl-quaternion-private.h \
-	hkl-sample-private.h hkl-source-private.h hkl-unit-private.h \
+	hkl-sample-private.h hkl-source-private.h \
+	hkl-trajectory-private.h hkl-unit-private.h \
 	hkl-vector-private.h hkl-types.c hkl-types.h \
 	hkl-type-builtins.c hkl-type-builtins.h hkl-binding.c \
 	hkl-binding-private.h
@@ -193,12 +195,14 @@ am__objects_1 = libhkl_la-hkl-axis.lo libhkl_la-hkl-detector.lo \
 	libhkl_la-hkl-engine-2c.lo libhkl_la-hkl-engine-e4c.lo \
 	libhkl_la-hkl-engine-k4c.lo libhkl_la-hkl-engine-e6c.lo \
 	libhkl_la-hkl-engine-k6c.lo \
+	libhkl_la-hkl-engine-petra3-p08-lisa.lo \
 	libhkl_la-hkl-engine-petra3-p09-eh2.lo \
 	libhkl_la-hkl-engine-soleil-sirius-turret.lo \
 	libhkl_la-hkl-engine-soleil-sixs-med.lo \
 	libhkl_la-hkl-engine-zaxis.lo libhkl_la-hkl-quaternion.lo \
 	libhkl_la-hkl-sample.lo libhkl_la-hkl-source.lo \
-	libhkl_la-hkl-unit.lo libhkl_la-hkl-vector.lo
+	libhkl_la-hkl-trajectory.lo libhkl_la-hkl-unit.lo \
+	libhkl_la-hkl-vector.lo
 am__objects_2 =
 @HAVE_INTROSPECTION_TRUE at am__objects_3 = libhkl_la-hkl-types.lo \
 @HAVE_INTROSPECTION_TRUE@	libhkl_la-hkl-type-builtins.lo \
@@ -357,6 +361,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -484,7 +489,7 @@ top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 version_info = @version_info@
-SUBDIRS = ccan
+SUBDIRS = ccan . api2
 AM_LDFLAGS = -no-undefined -version-info 5:0:0 $(GLIB_LIBS) \
 	$(GSL_LIBS) $(am__append_2)
 AM_CFLAGS = -DG_LOG_DOMAIN=\"Hkl\" -I$(top_srcdir) -I$(top_builddir) \
@@ -513,6 +518,7 @@ hkl_c_sources = \
 	hkl-engine-k4c.c \
 	hkl-engine-e6c.c \
 	hkl-engine-k6c.c \
+	hkl-engine-petra3-p08-lisa.c \
 	hkl-engine-petra3-p09-eh2.c \
 	hkl-engine-soleil-sirius-turret.c \
 	hkl-engine-soleil-sixs-med.c \
@@ -520,6 +526,7 @@ hkl_c_sources = \
 	hkl-quaternion.c \
 	hkl-sample.c \
 	hkl-source.c \
+	hkl-trajectory.c \
 	hkl-unit.c \
 	hkl-vector.c
 
@@ -545,6 +552,7 @@ hkl_private_h_sources = \
 	hkl-quaternion-private.h \
 	hkl-sample-private.h \
 	hkl-source-private.h \
+	hkl-trajectory-private.h \
 	hkl-unit-private.h \
 	hkl-vector-private.h
 
@@ -711,6 +719,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-e6c.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-k4c.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-k6c.Plo at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-petra3-p08-lisa.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-petra3-p09-eh2.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-soleil-sirius-turret.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-engine-soleil-sixs-med.Plo at am__quote@
@@ -733,6 +742,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-quaternion.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-sample.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-source.Plo at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-trajectory.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-type-builtins.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-types.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/libhkl_la-hkl-unit.Plo at am__quote@
@@ -923,6 +933,13 @@ libhkl_la-hkl-engine-k6c.lo: hkl-engine-k6c.c
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -c -o libhkl_la-hkl-engine-k6c.lo `test -f 'hkl-engine-k6c.c' || echo '$(srcdir)/'`hkl-engine-k6c.c
 
+libhkl_la-hkl-engine-petra3-p08-lisa.lo: hkl-engine-petra3-p08-lisa.c
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -MT libhkl_la-hkl-engine-petra3-p08-lisa.lo -MD -MP -MF $(DEPDIR)/libhkl_la-hkl-engine-petra3-p08-lisa.Tpo -c -o libhkl_la-hkl-engine-petra3-p08-lisa.lo `test -f 'hkl-engine-petra3-p08-lisa.c' || echo '$(srcdir)/'`hkl-engine-petra3-p08-lisa.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libhkl_la-hkl-engine-petra3-p08-lisa.Tpo $(DEPDIR)/libhkl_la-hkl-engine-petra3-p08-lisa.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='hkl-engine-petra3-p08-lisa.c' object='libhkl_la-hkl-engine-petra3-p08-lisa.lo' libtool=yes @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -c -o libhkl_la-hkl-engine-petra3-p08-lisa.lo `test -f 'hkl-engine-petra3-p08-lisa.c' || echo '$(srcdir)/'`hkl-engine-petra3-p08-lisa.c
+
 libhkl_la-hkl-engine-petra3-p09-eh2.lo: hkl-engine-petra3-p09-eh2.c
 @am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -MT libhkl_la-hkl-engine-petra3-p09-eh2.lo -MD -MP -MF $(DEPDIR)/libhkl_la-hkl-engine-petra3-p09-eh2.Tpo -c -o libhkl_la-hkl-engine-petra3-p09-eh2.lo `test -f 'hkl-engine-petra3-p09-eh2.c' || echo '$(srcdir)/'`hkl-engine-petra3-p09-eh2.c
 @am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libhkl_la-hkl-engine-petra3-p09-eh2.Tpo $(DEPDIR)/libhkl_la-hkl-engine-petra3-p09-eh2.Plo
@@ -972,6 +989,13 @@ libhkl_la-hkl-source.lo: hkl-source.c
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -c -o libhkl_la-hkl-source.lo `test -f 'hkl-source.c' || echo '$(srcdir)/'`hkl-source.c
 
+libhkl_la-hkl-trajectory.lo: hkl-trajectory.c
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -MT libhkl_la-hkl-trajectory.lo -MD -MP -MF $(DEPDIR)/libhkl_la-hkl-trajectory.Tpo -c -o libhkl_la-hkl-trajectory.lo `test -f 'hkl-trajectory.c' || echo '$(srcdir)/'`hkl-trajectory.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libhkl_la-hkl-trajectory.Tpo $(DEPDIR)/libhkl_la-hkl-trajectory.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='hkl-trajectory.c' object='libhkl_la-hkl-trajectory.lo' libtool=yes @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -c -o libhkl_la-hkl-trajectory.lo `test -f 'hkl-trajectory.c' || echo '$(srcdir)/'`hkl-trajectory.c
+
 libhkl_la-hkl-unit.lo: hkl-unit.c
 @am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libhkl_la_CFLAGS) $(CFLAGS) -MT libhkl_la-hkl-unit.lo -MD -MP -MF $(DEPDIR)/libhkl_la-hkl-unit.Tpo -c -o libhkl_la-hkl-unit.lo `test -f 'hkl-unit.c' || echo '$(srcdir)/'`hkl-unit.c
 @am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libhkl_la-hkl-unit.Tpo $(DEPDIR)/libhkl_la-hkl-unit.Plo
diff --git a/hkl/api2/Makefile.am b/hkl/api2/Makefile.am
new file mode 100644
index 0000000..1d9d7e0
--- /dev/null
+++ b/hkl/api2/Makefile.am
@@ -0,0 +1,14 @@
+AM_CPPFLAGS = -Wextra -D_DEFAULT_SOURCE \
+	-I$(top_srcdir) \
+	-I$(top_srcdir)/hkl \
+	$(GLIB_CFLAGS) \
+	$(GSL_CFLAGS)
+
+LDADD = $(top_builddir)/hkl/libhkl.la \
+	$(GLIB_LIBS) \
+	$(GSL_LIBS)
+
+noinst_LTLIBRARIES=libhkl2.la
+libhkl2_la_SOURCES = \
+	hkl2.c \
+	hkl2.h
diff --git a/tests/tap/Makefile.in b/hkl/api2/Makefile.in
similarity index 90%
copy from tests/tap/Makefile.in
copy to hkl/api2/Makefile.in
index 22df8e3..de4a50c 100644
--- a/tests/tap/Makefile.in
+++ b/hkl/api2/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -13,6 +13,7 @@
 # PARTICULAR PURPOSE.
 
 @SET_MAKE@
+
 VPATH = @srcdir@
 am__is_gnu_make = { \
   if test -z '$(MAKELEVEL)'; then \
@@ -87,7 +88,7 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-subdir = tests/tap
+subdir = hkl/api2
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/m4/gtk-doc.m4 \
 	$(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
@@ -100,16 +101,14 @@ mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
-ARFLAGS = cru
-AM_V_AR = $(am__v_AR_ at AM_V@)
-am__v_AR_ = $(am__v_AR_ at AM_DEFAULT_V@)
-am__v_AR_0 = @echo "  AR      " $@;
-am__v_AR_1 = 
-libtap_a_AR = $(AR) $(ARFLAGS)
-libtap_a_LIBADD =
-am_libtap_a_OBJECTS = basic.$(OBJEXT) float.$(OBJEXT) \
-	hkl-tap.$(OBJEXT)
-libtap_a_OBJECTS = $(am_libtap_a_OBJECTS)
+LTLIBRARIES = $(noinst_LTLIBRARIES)
+libhkl2_la_LIBADD =
+am_libhkl2_la_OBJECTS = hkl2.lo
+libhkl2_la_OBJECTS = $(am_libhkl2_la_OBJECTS)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 AM_V_P = $(am__v_P_ at AM_V@)
 am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
 am__v_P_0 = false
@@ -128,10 +127,6 @@ am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-AM_V_lt = $(am__v_lt_ at AM_V@)
-am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
-am__v_lt_0 = --silent
-am__v_lt_1 = 
 LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
 	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
@@ -148,8 +143,8 @@ AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
 am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
 am__v_CCLD_0 = @echo "  CCLD    " $@;
 am__v_CCLD_1 = 
-SOURCES = $(libtap_a_SOURCES)
-DIST_SOURCES = $(libtap_a_SOURCES)
+SOURCES = $(libhkl2_la_SOURCES)
+DIST_SOURCES = $(libhkl2_la_SOURCES)
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -219,6 +214,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -346,21 +342,20 @@ top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 version_info = @version_info@
-AM_CFLAGS = \
+AM_CPPFLAGS = -Wextra -D_DEFAULT_SOURCE \
 	-I$(top_srcdir) \
-	-I$(abs_top_srcdir)/tests \
+	-I$(top_srcdir)/hkl \
 	$(GLIB_CFLAGS) \
 	$(GSL_CFLAGS)
 
-check_LIBRARIES = libtap.a
-libtap_a_SOURCES = \
-	basic.c \
-	basic.h \
-	float.h \
-	float.c \
-	macros.h \
-	hkl-tap.h \
-	hkl-tap.c
+LDADD = $(top_builddir)/hkl/libhkl.la \
+	$(GLIB_LIBS) \
+	$(GSL_LIBS)
+
+noinst_LTLIBRARIES = libhkl2.la
+libhkl2_la_SOURCES = \
+	hkl2.c \
+	hkl2.h
 
 all: all-am
 
@@ -375,9 +370,9 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	      exit 1;; \
 	  esac; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/tap/Makefile'; \
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu hkl/api2/Makefile'; \
 	$(am__cd) $(top_srcdir) && \
-	  $(AUTOMAKE) --gnu tests/tap/Makefile
+	  $(AUTOMAKE) --gnu hkl/api2/Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	  *config.status*) \
@@ -396,13 +391,19 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(am__aclocal_m4_deps):
 
-clean-checkLIBRARIES:
-	-test -z "$(check_LIBRARIES)" || rm -f $(check_LIBRARIES)
+clean-noinstLTLIBRARIES:
+	-test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+	@list='$(noinst_LTLIBRARIES)'; \
+	locs=`for p in $$list; do echo $$p; done | \
+	      sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
+	      sort -u`; \
+	test -z "$$locs" || { \
+	  echo rm -f $${locs}; \
+	  rm -f $${locs}; \
+	}
 
-libtap.a: $(libtap_a_OBJECTS) $(libtap_a_DEPENDENCIES) $(EXTRA_libtap_a_DEPENDENCIES) 
-	$(AM_V_at)-rm -f libtap.a
-	$(AM_V_AR)$(libtap_a_AR) libtap.a $(libtap_a_OBJECTS) $(libtap_a_LIBADD)
-	$(AM_V_at)$(RANLIB) libtap.a
+libhkl2.la: $(libhkl2_la_OBJECTS) $(libhkl2_la_DEPENDENCIES) $(EXTRA_libhkl2_la_DEPENDENCIES) 
+	$(AM_V_CCLD)$(LINK)  $(libhkl2_la_OBJECTS) $(libhkl2_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -410,9 +411,7 @@ mostlyclean-compile:
 distclean-compile:
 	-rm -f *.tab.c
 
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/basic.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/float.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-tap.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl2.Plo at am__quote@
 
 .c.o:
 @am__fastdepCC_TRUE@	$(AM_V_CC)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\
@@ -527,9 +526,8 @@ distdir: $(DISTFILES)
 	  fi; \
 	done
 check-am: all-am
-	$(MAKE) $(AM_MAKEFLAGS) $(check_LIBRARIES)
 check: check-am
-all-am: Makefile
+all-am: Makefile $(LTLIBRARIES)
 installdirs:
 install: install-am
 install-exec: install-exec-am
@@ -563,7 +561,7 @@ maintainer-clean-generic:
 	@echo "it deletes files that may require special tools to rebuild."
 clean: clean-am
 
-clean-am: clean-checkLIBRARIES clean-generic clean-libtool \
+clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \
 	mostlyclean-am
 
 distclean: distclean-am
@@ -632,11 +630,11 @@ ps-am:
 
 uninstall-am:
 
-.MAKE: check-am install-am install-strip
+.MAKE: install-am install-strip
 
-.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \
-	clean-checkLIBRARIES clean-generic clean-libtool cscopelist-am \
-	ctags ctags-am distclean distclean-compile distclean-generic \
+.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
+	clean-libtool clean-noinstLTLIBRARIES cscopelist-am ctags \
+	ctags-am distclean distclean-compile distclean-generic \
 	distclean-libtool distclean-tags distdir dvi dvi-am html \
 	html-am info info-am install install-am install-data \
 	install-data-am install-dvi install-dvi-am install-exec \
@@ -651,13 +649,6 @@ uninstall-am:
 .PRECIOUS: Makefile
 
 
-# Support for GNU Flymake, in Emacs.
-check-syntax: AM_CFLAGS += -fsyntax-only -pipe
-check-syntax:
-	test -z "$(CHK_SOURCES)" || $(COMPILE) $(CHK_SOURCES)
-
-.PHONY: check-syntax
-
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
diff --git a/hkl/api2/hkl2.c b/hkl/api2/hkl2.c
new file mode 100644
index 0000000..8a3e3ff
--- /dev/null
+++ b/hkl/api2/hkl2.c
@@ -0,0 +1,326 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2012 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ */
+#include <stdarg.h>
+
+#include "hkl/hkl-matrix-private.h"
+#include "hkl/hkl-macros-private.h"
+#include "hkl/hkl-pseudoaxis-private.h"
+#include "hkl/hkl-trajectory-private.h"
+#include "hkl/api2/hkl2.h"
+
+static const HklFactory *getFactory(struct Geometry geometry)
+{
+	const HklFactory *self = NULL;
+
+	switch(geometry.tag) {
+	case GEOMETRY_E4CH:
+		self = hkl_factory_get_by_name("E4CH", NULL);
+		break;
+	case GEOMETRY_E4CV:
+		self = hkl_factory_get_by_name("E4CV", NULL);
+		break;
+	case GEOMETRY_E6C:
+		self = hkl_factory_get_by_name("E6C", NULL);
+		break;
+	case GEOMETRY_K4CH:
+		self = hkl_factory_get_by_name("K4CH", NULL);
+		break;
+	case GEOMETRY_K4CV:
+		self = hkl_factory_get_by_name("K4CV", NULL);
+		break;
+	case GEOMETRY_K6C:
+		self = hkl_factory_get_by_name("K6C", NULL);
+		break;
+	case GEOMETRY_SOLEIL_SIRIUS_KAPPA:
+		self = hkl_factory_get_by_name("SOLEIL SIRIUS KAPPA", NULL);
+		break;
+	case GEOMETRY_SOLEIL_SIXS_MED_2_3:
+		self = hkl_factory_get_by_name("SOLEIL SIXS MED2+3", NULL);
+		break;
+	case GEOMETRY_ZAXIS:
+		self = hkl_factory_get_by_name("ZAXIS", NULL);
+		break;
+	}
+	return self;
+}
+
+HklEngineList *newEngines(struct Geometry geometry)
+{
+	return hkl_factory_create_new_engine_list(getFactory(geometry));
+}
+
+HklGeometry *newGeometry(struct Geometry geometry)
+{
+	HklGeometry *self = hkl_factory_create_new_geometry(getFactory(geometry));
+
+#define NEW_GEOMETRY(type_) do{						\
+		if(!hkl_geometry_axis_values_set(self,			\
+						 geometry.type_.positions, \
+						 ARRAY_SIZE(geometry.type_.positions), \
+						 HKL_UNIT_USER, NULL)){	\
+			goto failed;					\
+		}							\
+		if(!hkl_geometry_wavelength_set(self, geometry.type_.wavelength, \
+						HKL_UNIT_DEFAULT, NULL)){ \
+			goto failed;					\
+		}							\
+	}while(0)
+
+	switch (geometry.tag) {
+	case GEOMETRY_E4CH: NEW_GEOMETRY(e4ch); break;
+	case GEOMETRY_E4CV: NEW_GEOMETRY(e4cv); break;
+	case GEOMETRY_E6C: NEW_GEOMETRY(e6c); break;
+	case GEOMETRY_K4CH: NEW_GEOMETRY(k4ch); break;
+	case GEOMETRY_K4CV: NEW_GEOMETRY(k4cv); break;
+	case GEOMETRY_K6C: NEW_GEOMETRY(k6c); break;
+	case GEOMETRY_SOLEIL_SIRIUS_KAPPA: NEW_GEOMETRY(soleil_sirius_kappa); break;
+	case GEOMETRY_SOLEIL_SIXS_MED_2_3: NEW_GEOMETRY(soleil_sixs_med_2_3); break;
+	case GEOMETRY_ZAXIS: NEW_GEOMETRY(zaxis); break;
+	}
+	return self;
+failed:
+	hkl_geometry_free(self);
+	return NULL;
+#undef NEW_GEOMETRY
+}
+
+/* Lattice */
+
+HklLattice *newLattice(struct Lattice lattice)
+{
+	HklLattice *self = NULL;
+
+	switch (lattice.tag) {
+	case LATTICE_CUBIC:
+		self = hkl_lattice_new(lattice.cubic.a,
+				       lattice.cubic.a,
+				       lattice.cubic.a,
+				       90*HKL_DEGTORAD,
+				       90*HKL_DEGTORAD,
+				       90*HKL_DEGTORAD,
+				       NULL);
+		break;
+	case LATTICE_HEXAGONAL:
+		self = hkl_lattice_new(lattice.hexagonal.a,
+				       lattice.hexagonal.a,
+				       lattice.hexagonal.c,
+				       90*HKL_DEGTORAD,
+				       90*HKL_DEGTORAD,
+				       120*HKL_DEGTORAD,
+				       NULL);
+		break;
+	case LATTICE_TETRAGONAL:
+		self = hkl_lattice_new(lattice.tetragonal.a,
+				       lattice.tetragonal.a,
+				       lattice.tetragonal.c,
+				       90*HKL_DEGTORAD,
+				       90*HKL_DEGTORAD,
+				       90*HKL_DEGTORAD,
+				       NULL);
+		break;
+	}
+
+	return self;
+}
+
+/* Sample */
+
+HklSample *newSample(struct Sample sample)
+{
+	HklSample *self;
+	HklLattice *lattice;
+	HklMatrix *U;
+
+	self = hkl_sample_new(sample.name);
+	lattice = newLattice(sample.lattice);
+	hkl_sample_lattice_set(self, lattice);
+	hkl_lattice_free(lattice);
+	U = hkl_matrix_new_euler(sample.ux, sample.uy, sample.uz);
+	hkl_sample_U_set(self, U, NULL);
+	hkl_matrix_free(U);
+
+	return self;
+}
+
+const struct Sample cu = {
+	.name = "default",
+	.lattice = Cubic(1.54),
+	.ux = 0.0 * HKL_DEGTORAD,
+	.uy = 0.0 * HKL_DEGTORAD,
+	.uz = 0.0 * HKL_DEGTORAD,
+};
+
+/* Mode */
+
+const char *getModeName(struct Mode mode)
+{
+	const char *name = NULL;
+
+	switch(mode.tag){
+	case MODE_HKL_BISSECTOR_VERTICAL: name = "bissector_vertical"; break;
+	case MODE_HKL_E4CH_CONSTANT_PHI: name = "constant_phi"; break;
+	}
+
+	return name;
+}
+
+/* Engine */
+
+void Engine_fprintf(FILE *f, struct Engine engine)
+{
+	switch(engine.tag){
+	case ENGINE_HKL:
+	{
+		fprintf(f, "hkl: %f %f %f\n", engine.hkl.h, engine.hkl.k, engine.hkl.l);
+	}
+	break;
+	}
+}
+
+void Engine_header(FILE *f, const struct Engine engine)
+{
+	switch(engine.tag){
+	case ENGINE_HKL:
+	{
+		fprintf(f, "h k l");
+	}
+	break;
+	}
+}
+
+void Engine_save_as_dat(FILE *f, const struct Engine engine)
+{
+	switch(engine.tag){
+	case ENGINE_HKL:
+	{
+		fprintf(f, "%f %f %f", engine.hkl.h, engine.hkl.k, engine.hkl.l);
+	}
+	break;
+	}
+}
+
+HklGeometryList *Engine_solve(HklEngineList *engines, struct Engine econfig)
+{
+	HklGeometryList *geometries = NULL;
+
+	switch(econfig.tag) {
+	case ENGINE_HKL:
+	{
+		double values[3] = {econfig.hkl.h, econfig.hkl.k, econfig.hkl.l};
+		HklEngine *engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
+		const char *mode_name = getModeName(econfig.hkl.mode);
+		if(hkl_engine_current_mode_set(engine, mode_name, NULL)){
+
+			geometries = hkl_engine_pseudo_axis_values_set(engine,
+								       values, ARRAY_SIZE(values),
+								       HKL_UNIT_DEFAULT, NULL);
+		}
+	}
+	break;
+	}
+
+	return geometries;
+}
+
+/* HklTrajectory */
+
+generator_def(trajectory_gen, struct Engine, struct Trajectory, tconfig)
+{
+	switch(tconfig.tag){
+	case TRAJECTORY_HKL_FROM_TO:
+	{
+		uint i;
+		double dh = (tconfig.hklfromto.h1 - tconfig.hklfromto.h0) / (tconfig.hklfromto.n);
+		double dk = (tconfig.hklfromto.k1 - tconfig.hklfromto.k0) / (tconfig.hklfromto.n);
+		double dl = (tconfig.hklfromto.l1 - tconfig.hklfromto.l0) / (tconfig.hklfromto.n);
+		for(i=0; i<tconfig.hklfromto.n + 1; ++i){
+			double h = i * dh + tconfig.hklfromto.h0;
+			double k = i * dk + tconfig.hklfromto.k0;
+			double l = i * dl + tconfig.hklfromto.l0;
+
+			struct Engine econfig = EngineHkl(h, k, l, tconfig.hklfromto.mode);
+			generator_yield(econfig);
+		}
+	}
+	break;
+	}
+}
+
+uint Trajectory_len(struct Trajectory tconfig)
+{
+	uint n = 0;
+	switch(tconfig.tag){
+	case TRAJECTORY_HKL_FROM_TO:
+	{
+		n = tconfig.hklfromto.n + 1;
+	}
+	break;
+	}
+	return n;
+}
+
+HklGeometryList *Trajectory_solve(struct Trajectory tconfig,
+				  struct Geometry gconfig,
+				  struct Sample sconfig,
+				  uint move)
+{
+	const struct Engine *econfig;
+	HklGeometryList *solutions = hkl_geometry_list_new();
+	generator_t(struct Engine) gen = trajectory_gen(tconfig);
+
+	HklGeometry *geometry = newGeometry(gconfig);
+	HklEngineList *engines = newEngines(gconfig);
+	HklSample *sample = newSample(sconfig);
+	HklDetector *detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
+	HklTrajectoryStats *stats = hkl_trajectory_stats_new(Trajectory_len(tconfig));
+
+	hkl_engine_list_init(engines, geometry, detector, sample);
+
+	while((econfig = generator_next(gen)) != NULL){
+		/* Engine_fprintf(stdout, *econfig); */
+		HklGeometryList *geometries = Engine_solve(engines, *econfig);
+		if(NULL != geometries){
+			const HklGeometryListItem *solution;
+
+			hkl_trajectory_stats_add(stats, geometries);
+			solution = hkl_geometry_list_items_first_get(geometries);
+			if(move)
+				hkl_engine_list_select_solution(engines, solution);
+
+			hkl_geometry_list_add(solutions,
+					      hkl_geometry_list_item_geometry_get(solution));
+			/* hkl_geometry_list_fprintf(stdout, geometries); */
+			hkl_geometry_list_free(geometries);
+		}
+	}
+
+	/* hkl_trajectory_stats_fprintf(stdout, stats); */
+
+	hkl_trajectory_stats_free(stats);
+	hkl_detector_free(detector);
+	hkl_sample_free(sample);
+	hkl_engine_list_free(engines);
+	hkl_geometry_free(geometry);
+	generator_free(gen);
+
+	return solutions;
+}
diff --git a/hkl/api2/hkl2.h b/hkl/api2/hkl2.h
new file mode 100644
index 0000000..628c3f9
--- /dev/null
+++ b/hkl/api2/hkl2.h
@@ -0,0 +1,306 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ */
+#ifndef __HKL_HKL2_H__
+#define __HKL_HKL2_H__
+
+#include "hkl.h"
+#include "hkl/ccan/generator/generator.h"
+
+G_BEGIN_DECLS
+
+/* Geometry */
+
+enum geometry_e {
+	GEOMETRY_E4CH,
+	GEOMETRY_E4CV,
+	GEOMETRY_E6C,
+	GEOMETRY_K4CH,
+	GEOMETRY_K4CV,
+	GEOMETRY_K6C,
+	GEOMETRY_SOLEIL_SIRIUS_KAPPA,
+	GEOMETRY_SOLEIL_SIXS_MED_2_3,
+	GEOMETRY_ZAXIS,
+};
+
+struct Geometry {
+	enum geometry_e tag;
+	union {
+		struct {
+			double wavelength;
+			union {
+				double positions[4];
+				struct {
+					double omega;
+					double chi;
+					double phi;
+					double tth;
+				};
+			};
+		} e4ch;
+		struct {
+			double wavelength;
+			union {
+				double positions[4];
+				struct {
+					double omega;
+					double chi;
+					double phi;
+					double tth;
+				};
+			};
+		} e4cv;
+		struct {
+			double wavelength;
+			union {
+				double positions[6];
+				struct {
+					double mu;
+					double komega;
+					double kappa;
+					double kphi;
+					double gamma;
+					double delta;
+				};
+			};
+		} e6c;
+		struct {
+			double wavelength;
+			union {
+				double positions[4];
+				struct {
+					double komega;
+					double kappa;
+					double kphi;
+					double tth;
+				};
+			};
+		} k4ch;
+		struct {
+			double wavelength;
+			union {
+				double positions[4];
+				struct {
+					double komega;
+					double kappa;
+					double kphi;
+					double tth;
+				};
+			};
+		} k4cv;
+		struct {
+			double wavelength;
+			union {
+				double positions[6];
+				struct {
+					double mu;
+					double komega;
+					double kappa;
+					double kphi;
+					double gamma;
+					double delta;
+				};
+			};
+		} k6c;
+		struct {
+			double wavelength;
+			union {
+				double positions[6];
+				struct {
+					double mu;
+					double komega;
+					double kappa;
+					double kphi;
+					double delta;
+					double gamma;
+				};
+			};
+		} soleil_sirius_kappa;
+		struct {
+			double wavelength;
+			union {
+				double positions[6];
+				struct {
+					double beta;
+					double mu;
+					double omega;
+					double gamma;
+					double delta;
+					double eta_a;
+				};
+			};
+		} soleil_sixs_med_2_3;
+		struct {
+			double wavelength;
+			union {
+				double positions[4];
+				struct {
+					double mu;
+					double omega;
+					double delta;
+					double gamma;
+				};
+			};
+		} zaxis;
+	};
+};
+
+#define E4ch(_w, _o, _c, _p, _t)			\
+	{.tag=GEOMETRY_E4CH,				\
+			.e4ch={_w, {{_o, _c, _p, _t}}}}
+#define E4cv(_w, _o, _c, _p, _t)			\
+	{.tag=GEOMETRY_E4CV,				\
+			.e4cv={_w, {{_o, _c, _p, _t}}}}
+#define E6c(_w, _m, _ko, _ka, _kp, _g, _d)				\
+	{.tag=GEOMETRY_E6C,						\
+			.e6c={_w, {{_m, _ko, _ka, _kp, _g, _d}}}}
+#define K4ch(_w, _o, _c, _p, _t)			\
+	{.tag=GEOMETRY_K4CH,				\
+			.k4ch={_w, {{_o, _c, _p, _t}}}}
+#define K4cv(_w, _o, _c, _p, _t)			\
+	{.tag=GEOMETRY_K4CV,				\
+			.k4cv={_w, {{_o, _c, _p, _t}}}}
+#define K6c(_w, _m, _ko, _ka, _kp, _g, _d)				\
+	{.tag=GEOMETRY_K6C,						\
+			.k6c={_w, {{_m, _ko, _ka, _kp, _g, _d}}}}
+#define SoleilSiriusKappa(_w,  _m, _ko, _ka, _kp, _d, _g)		\
+	{.tag=GEOMETRY_SOLEIL_SIRIUS_KAPPA,				\
+			.soleil_sirius_kappa={_w, {{_m, _ko, _ka, _kp, _d, _g}}}}
+#define SoleilSixsMed2_3(_w, _b, _m, _o, _g, _d, _e)			\
+	{.tag=GEOMETRY_SOLEIL_SIXS_MED_2_3,				\
+			.soleil_sixs_med_2_3={_w, {{_b, _m, _o, _g, _d, _e}}}}
+#define Zaxis(_w, _m, _o, _d, _g)				\
+	{.tag=GEOMETRY_ZAXIS,					\
+			.zaxis={_w, {{_m, _o, _d, _g}}}}
+
+extern HklGeometry *newGeometry(struct Geometry geometry);
+
+/* Engines */
+
+extern HklEngineList *newEngines(struct Geometry geometry);
+
+/* Lattice */
+
+enum lattice_e {
+	LATTICE_CUBIC,
+	LATTICE_HEXAGONAL,
+	LATTICE_TETRAGONAL,
+};
+
+struct Lattice {
+	enum lattice_e tag;
+	union {
+		struct { double a; } cubic;
+		struct { double a; double c; } hexagonal;
+		struct { double a; double c; } tetragonal;
+	};
+};
+
+#define Cubic(_a) {.tag=LATTICE_CUBIC, .cubic={_a}}
+#define Hexagonal(_a, _c) {.tag=LATTICE_HEXAGONAL, .hexagonal={_a, _c}}
+#define Tetragonal(_a, _c) {.tag=LATTICE_TETRAGONAL, .tetragonal={_a, _c}}
+
+extern HklLattice *newLattice(struct Lattice lattice);
+
+/* Sample */
+
+struct Sample {
+	const char *name;
+	struct Lattice lattice;
+	double ux;
+	double uy;
+	double uz;
+};
+
+extern HklSample *newSample(struct Sample sample);
+
+extern const struct Sample cu;
+
+
+/* Mode */
+
+enum mode_e {
+	MODE_HKL_BISSECTOR_VERTICAL,
+	MODE_HKL_E4CH_CONSTANT_PHI,
+};
+
+struct Mode {
+	enum mode_e tag;
+};
+
+#define ModeHklBissectorVertical { .tag=MODE_HKL_BISSECTOR_VERTICAL }
+#define ModeHklE4CHConstantPhi { .tag=MODE_HKL_E4CH_CONSTANT_PHI }
+
+extern const char *getModeName(struct Mode mode);
+
+/* Engine */
+
+enum engine_e {
+	ENGINE_HKL,
+};
+
+struct Engine {
+	enum engine_e tag;
+	union {
+		struct {double h; double k; double l; struct Mode mode;} hkl;
+	};
+};
+
+#define EngineHkl(h_, k_, l_, mode_) {.tag=ENGINE_HKL, .hkl={h_, k_, l_, mode_}}
+
+extern void Engine_fprintf(FILE *f, struct Engine engine);
+
+extern void Engine_header(FILE *f, const struct Engine engine);
+
+extern void Engine_save_as_dat(FILE *f, const struct Engine engine);
+
+extern HklGeometryList *Engine_solve(HklEngineList *engines,
+				     struct Engine econfig);
+
+/* HklTrajectory */
+
+enum trajectory_e {
+	TRAJECTORY_HKL_FROM_TO,
+};
+
+struct Trajectory {
+	enum trajectory_e tag;
+	union {
+		struct {double h0; double k0; double l0;
+			double h1; double k1; double l1;
+			uint n; struct Mode mode;} hklfromto;
+	};
+};
+
+#define TrajectoryHklFromTo(h0_, k0_, l0_, h1_, k1_, l1_, n_, mode_) {.tag=TRAJECTORY_HKL_FROM_TO, .hklfromto={h0_, k0_, l0_, h1_, k1_, l1_, n_, .mode=mode_}}
+
+extern generator_declare(trajectory_gen, struct Engine, struct Trajectory, tconfig);
+
+extern uint Trajectory_len(struct Trajectory tconfig);
+
+extern HklGeometryList *Trajectory_solve(struct Trajectory tconfig,
+					 struct Geometry gconfig,
+					 struct Sample sconfig,
+					 uint move);
+
+G_END_DECLS
+
+#endif /* __HKL_TAP_H__ */
diff --git a/hkl/ccan/Makefile.am b/hkl/ccan/Makefile.am
index 44405d2..8a5582a 100644
--- a/hkl/ccan/Makefile.am
+++ b/hkl/ccan/Makefile.am
@@ -15,16 +15,24 @@ libccan_la_SOURCES = \
 	str/str_debug.h \
 	str/str.c \
 	str/debug.c \
+	generator/generator.h \
+	generator/generator.c \
 	darray/darray.h \
+	coroutine/coroutine.h \
+	coroutine/coroutine.c \
+	cppmagic/cppmagic.h \
 	compiler/compiler.h \
 	autodata/autodata.h \
 	autodata/autodata.c \
 	container_of/container_of.h \
 	build_assert/build_assert.h \
+	typesafe_cb/typesafe_cb.h \
 	list/list.c \
 	list/list.h \
+	alignof/alignof.h \
 	ptr_valid/ptr_valid.c \
-	ptr_valid/ptr_valid.h
+	ptr_valid/ptr_valid.h \
+	ptrint/ptrint.h
 
 ccanincludedir=$(includedir)/hkl- at VMAJ@/hkl/ccan
 nobase_ccaninclude_HEADERS= \
diff --git a/hkl/ccan/Makefile.in b/hkl/ccan/Makefile.in
index 0891296..819ea03 100644
--- a/hkl/ccan/Makefile.in
+++ b/hkl/ccan/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -109,6 +109,7 @@ LTLIBRARIES = $(noinst_LTLIBRARIES)
 libccan_la_LIBADD =
 am__dirstamp = $(am__leading_dot)dirstamp
 am_libccan_la_OBJECTS = noerr/noerr.lo str/str.lo str/debug.lo \
+	generator/generator.lo coroutine/coroutine.lo \
 	autodata/autodata.lo list/list.lo ptr_valid/ptr_valid.lo
 libccan_la_OBJECTS = $(am_libccan_la_OBJECTS)
 AM_V_lt = $(am__v_lt_ at AM_V@)
@@ -254,6 +255,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -394,16 +396,24 @@ libccan_la_SOURCES = \
 	str/str_debug.h \
 	str/str.c \
 	str/debug.c \
+	generator/generator.h \
+	generator/generator.c \
 	darray/darray.h \
+	coroutine/coroutine.h \
+	coroutine/coroutine.c \
+	cppmagic/cppmagic.h \
 	compiler/compiler.h \
 	autodata/autodata.h \
 	autodata/autodata.c \
 	container_of/container_of.h \
 	build_assert/build_assert.h \
+	typesafe_cb/typesafe_cb.h \
 	list/list.c \
 	list/list.h \
+	alignof/alignof.h \
 	ptr_valid/ptr_valid.c \
-	ptr_valid/ptr_valid.h
+	ptr_valid/ptr_valid.h \
+	ptrint/ptrint.h
 
 ccanincludedir = $(includedir)/hkl- at VMAJ@/hkl/ccan
 nobase_ccaninclude_HEADERS = \
@@ -472,6 +482,22 @@ str/$(DEPDIR)/$(am__dirstamp):
 	@: > str/$(DEPDIR)/$(am__dirstamp)
 str/str.lo: str/$(am__dirstamp) str/$(DEPDIR)/$(am__dirstamp)
 str/debug.lo: str/$(am__dirstamp) str/$(DEPDIR)/$(am__dirstamp)
+generator/$(am__dirstamp):
+	@$(MKDIR_P) generator
+	@: > generator/$(am__dirstamp)
+generator/$(DEPDIR)/$(am__dirstamp):
+	@$(MKDIR_P) generator/$(DEPDIR)
+	@: > generator/$(DEPDIR)/$(am__dirstamp)
+generator/generator.lo: generator/$(am__dirstamp) \
+	generator/$(DEPDIR)/$(am__dirstamp)
+coroutine/$(am__dirstamp):
+	@$(MKDIR_P) coroutine
+	@: > coroutine/$(am__dirstamp)
+coroutine/$(DEPDIR)/$(am__dirstamp):
+	@$(MKDIR_P) coroutine/$(DEPDIR)
+	@: > coroutine/$(DEPDIR)/$(am__dirstamp)
+coroutine/coroutine.lo: coroutine/$(am__dirstamp) \
+	coroutine/$(DEPDIR)/$(am__dirstamp)
 autodata/$(am__dirstamp):
 	@$(MKDIR_P) autodata
 	@: > autodata/$(am__dirstamp)
@@ -516,6 +542,10 @@ mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
 	-rm -f autodata/*.$(OBJEXT)
 	-rm -f autodata/*.lo
+	-rm -f coroutine/*.$(OBJEXT)
+	-rm -f coroutine/*.lo
+	-rm -f generator/*.$(OBJEXT)
+	-rm -f generator/*.lo
 	-rm -f list/*.$(OBJEXT)
 	-rm -f list/*.lo
 	-rm -f noerr/*.$(OBJEXT)
@@ -530,6 +560,8 @@ distclean-compile:
 
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/configurator.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at autodata/$(DEPDIR)/autodata.Plo at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at coroutine/$(DEPDIR)/coroutine.Plo at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at generator/$(DEPDIR)/generator.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at list/$(DEPDIR)/list.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at noerr/$(DEPDIR)/noerr.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ptr_valid/$(DEPDIR)/ptr_valid.Plo at am__quote@
@@ -566,6 +598,8 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 	-rm -rf autodata/.libs autodata/_libs
+	-rm -rf coroutine/.libs coroutine/_libs
+	-rm -rf generator/.libs generator/_libs
 	-rm -rf list/.libs list/_libs
 	-rm -rf noerr/.libs noerr/_libs
 	-rm -rf ptr_valid/.libs ptr_valid/_libs
@@ -736,6 +770,10 @@ distclean-generic:
 	-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
 	-rm -f autodata/$(DEPDIR)/$(am__dirstamp)
 	-rm -f autodata/$(am__dirstamp)
+	-rm -f coroutine/$(DEPDIR)/$(am__dirstamp)
+	-rm -f coroutine/$(am__dirstamp)
+	-rm -f generator/$(DEPDIR)/$(am__dirstamp)
+	-rm -f generator/$(am__dirstamp)
 	-rm -f list/$(DEPDIR)/$(am__dirstamp)
 	-rm -f list/$(am__dirstamp)
 	-rm -f noerr/$(DEPDIR)/$(am__dirstamp)
@@ -755,7 +793,7 @@ clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \
 	clean-noinstPROGRAMS mostlyclean-am
 
 distclean: distclean-am
-	-rm -rf ./$(DEPDIR) autodata/$(DEPDIR) list/$(DEPDIR) noerr/$(DEPDIR) ptr_valid/$(DEPDIR) str/$(DEPDIR)
+	-rm -rf ./$(DEPDIR) autodata/$(DEPDIR) coroutine/$(DEPDIR) generator/$(DEPDIR) list/$(DEPDIR) noerr/$(DEPDIR) ptr_valid/$(DEPDIR) str/$(DEPDIR)
 	-rm -f Makefile
 distclean-am: clean-am distclean-compile distclean-generic \
 	distclean-tags
@@ -802,7 +840,7 @@ install-ps-am:
 installcheck-am:
 
 maintainer-clean: maintainer-clean-am
-	-rm -rf ./$(DEPDIR) autodata/$(DEPDIR) list/$(DEPDIR) noerr/$(DEPDIR) ptr_valid/$(DEPDIR) str/$(DEPDIR)
+	-rm -rf ./$(DEPDIR) autodata/$(DEPDIR) coroutine/$(DEPDIR) generator/$(DEPDIR) list/$(DEPDIR) noerr/$(DEPDIR) ptr_valid/$(DEPDIR) str/$(DEPDIR)
 	-rm -f Makefile
 maintainer-clean-am: distclean-am maintainer-clean-generic
 
diff --git a/hkl/ccan/alignof/alignof.h b/hkl/ccan/alignof/alignof.h
new file mode 100644
index 0000000..07d58ee
--- /dev/null
+++ b/hkl/ccan/alignof/alignof.h
@@ -0,0 +1,20 @@
+/* CC0 (Public domain) - see LICENSE file for details */
+#ifndef CCAN_ALIGNOF_H
+#define CCAN_ALIGNOF_H
+#include <hkl/ccan/ccan_config.h>
+
+/**
+ * ALIGNOF - get the alignment of a type
+ * @t: the type to test
+ *
+ * This returns a safe alignment for the given type.
+ */
+#if HAVE_ALIGNOF
+/* A GCC extension. */
+#define ALIGNOF(t) __alignof__(t)
+#else
+/* Alignment by measuring structure padding. */
+#define ALIGNOF(t) ((char *)(&((struct { char c; t _h; } *)0)->_h) - (char *)0)
+#endif
+
+#endif /* CCAN_ALIGNOF_H */
diff --git a/hkl/ccan/autodata/autodata.c b/hkl/ccan/autodata/autodata.c
index 53ef62d..a31b37b 100644
--- a/hkl/ccan/autodata/autodata.c
+++ b/hkl/ccan/autodata/autodata.c
@@ -11,7 +11,7 @@ void *autodata_get_section(void *start, void *stop, size_t *nump)
 	return start;
 }
 
-void autodata_free(void *table)
+void autodata_free(void *table UNNEEDED)
 {
 }
 #else
diff --git a/hkl/ccan/ccan_config.h b/hkl/ccan/ccan_config.h
index 23c9bbf..4fade21 100644
--- a/hkl/ccan/ccan_config.h
+++ b/hkl/ccan/ccan_config.h
@@ -4,8 +4,9 @@
 #ifndef _GNU_SOURCE
 #define _GNU_SOURCE /* Always use GNU extensions. */
 #endif
-#define CCAN_COMPILER "i686-linux-gnu-gcc"
+#define CCAN_COMPILER "gcc"
 #define CCAN_CFLAGS ""
+#define CCAN_OUTPUT_EXE_CFLAG "-o"
 
 #define HAVE_CCAN 1
 #define HAVE_32BIT_OFF_T 1
@@ -60,12 +61,13 @@
 #define HAVE_STATEMENT_EXPR 1
 #define HAVE_SYS_FILIO_H 0
 #define HAVE_SYS_TERMIOS_H 1
+#define HAVE_SYS_UNISTD_H 1
 #define HAVE_TYPEOF 1
 #define HAVE_UNALIGNED_ACCESS 1
 #define HAVE_UTIME 1
 #define HAVE_WARN_UNUSED_RESULT 1
 #define HAVE_OPENMP 1
-#define HAVE_VALGRIND_MEMCHECK_H 0
+#define HAVE_VALGRIND_MEMCHECK_H 1
 #define HAVE_UCONTEXT 1
 #define HAVE_POINTER_SAFE_MAKECONTEXT 1
 #endif /* CCAN_CONFIG_H */
diff --git a/hkl/ccan/configurator.c b/hkl/ccan/configurator.c
index 5d959cf..52c0243 100644
--- a/hkl/ccan/configurator.c
+++ b/hkl/ccan/configurator.c
@@ -3,6 +3,9 @@
  *
  * Copyright 2011 Rusty Russell <rusty at rustcorp.com.au>.  MIT license.
  *
+ * c12r_err, c12r_errx functions copied from ccan/err/err.c
+ * Copyright Rusty Russell <rusty at rustcorp.com.au>. CC0 (Public domain) License.
+ *
  * Permission is hereby granted, free of charge, to any person obtaining a copy
  * of this software and associated documentation files (the "Software"), to deal
  * in the Software without restriction, including without limitation the rights
@@ -21,23 +24,46 @@
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  * THE SOFTWARE.
  */
+#define _POSIX_C_SOURCE 200809L                /* For pclose, popen, strdup */
+
+#include <errno.h>
 #include <stdio.h>
+#include <stdarg.h>
 #include <stdbool.h>
 #include <stdlib.h>
-#include <unistd.h>
-#include <err.h>
-#include <sys/types.h>
-#include <sys/wait.h>
-#include <sys/stat.h>
-#include <fcntl.h>
 #include <string.h>
 
+#ifdef _MSC_VER
+#define popen _popen
+#define pclose _pclose
+#endif
+
+#ifdef _MSC_VER
+#define DEFAULT_COMPILER "cl"
+/* Note:  Dash options avoid POSIX path conversion when used under msys bash
+ *        and are therefore preferred to slash (e.g. -nologo over /nologo)
+ * Note:  Disable Warning 4200 "nonstandard extension used : zero-sized array
+ *        in struct/union" for flexible array members.
+ */
+#define DEFAULT_FLAGS "-nologo -Zi -W4 -wd4200 " \
+	"-D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS"
+#define DEFAULT_OUTPUT_EXE_FLAG "-Fe:"
+#else
 #define DEFAULT_COMPILER "cc"
 #define DEFAULT_FLAGS "-g3 -ggdb -Wall -Wundef -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wold-style-definition"
+#define DEFAULT_OUTPUT_EXE_FLAG "-o"
+#endif
 
 #define OUTPUT_FILE "configurator.out"
 #define INPUT_FILE "configuratortest.c"
 
+#ifdef _WIN32
+#define DIR_SEP   "\\"
+#else
+#define DIR_SEP   "/"
+#endif
+
+static const char *progname = "";
 static int verbose;
 
 enum test_style {
@@ -62,7 +88,7 @@ struct test {
 };
 
 static struct test tests[] = {
-	{ "HAVE_32BIT_OFF_T", DEFINES_EVERYTHING|EXECUTE, NULL, NULL,
+	{ "HAVE_32BIT_OFF_T", DEFINES_EVERYTHING|EXECUTE|MAY_NOT_COMPILE, NULL, NULL,
 	  "#include <sys/types.h>\n"
 	  "int main(void) {\n"
 	  "	return sizeof(off_t) == 4 ? 0 : 1;\n"
@@ -167,7 +193,7 @@ static struct test tests[] = {
 	{ "HAVE_COMPOUND_LITERALS", INSIDE_MAIN, NULL, NULL,
 	  "int *foo = (int[]) { 1, 2, 3, 4 };\n"
 	  "return foo[0] ? 0 : 1;" },
-	{ "HAVE_FCHDIR", DEFINES_EVERYTHING|EXECUTE, NULL, NULL,
+	{ "HAVE_FCHDIR", DEFINES_EVERYTHING|EXECUTE|MAY_NOT_COMPILE, NULL, NULL,
 	  "#include <sys/types.h>\n"
 	  "#include <sys/stat.h>\n"
 	  "#include <fcntl.h>\n"
@@ -188,7 +214,7 @@ static struct test tests[] = {
 	  "	if (arg == 4)\n"
 	  "		warnx(\"warn %u\", arg);\n"
 	  "}\n" },
-	{ "HAVE_FILE_OFFSET_BITS", DEFINES_EVERYTHING|EXECUTE,
+	{ "HAVE_FILE_OFFSET_BITS", DEFINES_EVERYTHING|EXECUTE|MAY_NOT_COMPILE,
 	  "HAVE_32BIT_OFF_T", NULL,
 	  "#define _FILE_OFFSET_BITS 64\n"
 	  "#include <sys/types.h>\n"
@@ -196,8 +222,9 @@ static struct test tests[] = {
 	  "	return sizeof(off_t) == 8 ? 0 : 1;\n"
 	  "}\n" },
 	{ "HAVE_FOR_LOOP_DECLARATION", INSIDE_MAIN, NULL, NULL,
-	  "for (int i = 0; i < argc; i++) { return 0; };\n"
-	  "return 1;" },
+	  "int ret = 1;\n"
+	  "for (int i = 0; i < argc; i++) { ret = 0; };\n"
+	  "return ret;" },
 	{ "HAVE_FLEXIBLE_ARRAY_MEMBER", OUTSIDE_MAIN, NULL, NULL,
 	  "struct foo { unsigned int x; int arr[]; };" },
 	{ "HAVE_GETPAGESIZE", DEFINES_FUNC, NULL, NULL,
@@ -234,7 +261,7 @@ static struct test tests[] = {
 	  "static void *func(int fd) {\n"
 	  "	return mmap(0, 65536, PROT_READ, MAP_SHARED, fd, 0);\n"
 	  "}" },
-	{ "HAVE_PROC_SELF_MAPS", DEFINES_EVERYTHING|EXECUTE, NULL, NULL,
+	{ "HAVE_PROC_SELF_MAPS", DEFINES_EVERYTHING|EXECUTE|MAY_NOT_COMPILE, NULL, NULL,
 	  "#include <sys/types.h>\n"
 	  "#include <sys/stat.h>\n"
 	  "#include <fcntl.h>\n"
@@ -271,7 +298,8 @@ static struct test tests[] = {
 	  "	return __stop_mysec - __start_mysec;\n"
 	  "}\n" },
 	{ "HAVE_STACK_GROWS_UPWARDS", DEFINES_EVERYTHING|EXECUTE, NULL, NULL,
-	  "static long nest(const void *base, unsigned int i)\n"
+	  "#include <stddef.h>\n"
+	  "static ptrdiff_t nest(const void *base, unsigned int i)\n"
 	  "{\n"
 	  "	if (i == 0)\n"
 	  "		return (const char *)&i - (const char *)base;\n"
@@ -287,6 +315,8 @@ static struct test tests[] = {
 	  "#include <sys/filio.h>\n" },
 	{ "HAVE_SYS_TERMIOS_H", OUTSIDE_MAIN, NULL, NULL,
 	  "#include <sys/termios.h>\n" },
+	{ "HAVE_SYS_UNISTD_H", OUTSIDE_MAIN, NULL, NULL,
+	  "#include <sys/unistd.h>\n" },
 	{ "HAVE_TYPEOF", INSIDE_MAIN, NULL, NULL,
 	  "__typeof__(argc) i; i = argc; return i == argc ? 0 : 1;" },
 	{ "HAVE_UNALIGNED_ACCESS", DEFINES_EVERYTHING|EXECUTE, NULL, NULL,
@@ -319,7 +349,7 @@ static struct test tests[] = {
 	  "-Werror -fopenmp" },
 	{ "HAVE_VALGRIND_MEMCHECK_H", OUTSIDE_MAIN, NULL, NULL,
 	  "#include <valgrind/memcheck.h>\n" },
-	{ "HAVE_UCONTEXT", DEFINES_EVERYTHING|EXECUTE,
+	{ "HAVE_UCONTEXT", DEFINES_EVERYTHING|EXECUTE|MAY_NOT_COMPILE,
 	  NULL, NULL,
 	  "#include <ucontext.h>\n"
 	  "static int x = 0;\n"
@@ -330,7 +360,7 @@ static struct test tests[] = {
 	  "	setcontext(&b);\n"
 	  "	x |= 4;\n"
 	  "}\n"
-	  "int main(int argc, char *argv[]) {\n"
+	  "int main(void) {\n"
 	  "	x |= 1;\n"
 	  "	getcontext(&a);\n"
 	  "	a.uc_stack.ss_sp = stack;\n"
@@ -340,7 +370,7 @@ static struct test tests[] = {
 	  "	return (x == 3) ? 0 : 1;\n"
 	  "}\n"
 	},
-	{ "HAVE_POINTER_SAFE_MAKECONTEXT", DEFINES_EVERYTHING|EXECUTE,
+	{ "HAVE_POINTER_SAFE_MAKECONTEXT", DEFINES_EVERYTHING|EXECUTE|MAY_NOT_COMPILE,
 	  "HAVE_UCONTEXT", NULL,
 	  "#include <stddef.h>\n"
 	  "#include <ucontext.h>\n"
@@ -354,7 +384,7 @@ static struct test tests[] = {
 	  "		worked = 1;\n"
 	  "	setcontext(&b);\n"
 	  "}\n"
-	  "int main(int argc, char *argv[]) {\n"
+	  "int main(void) {\n"
 	  "	void *ap = &worked;\n"
 	  "	void *aq = (void *)(~((ptrdiff_t)ap));\n"
 	  "	getcontext(&a);\n"
@@ -367,71 +397,95 @@ static struct test tests[] = {
 	},
 };
 
-static char *grab_fd(int fd)
+static void c12r_err(int eval, const char *fmt, ...)
 {
-	int ret;
-	size_t max, size = 0;
+	int err_errno = errno;
+	va_list ap;
+
+	fprintf(stderr, "%s: ", progname);
+	va_start(ap, fmt);
+	vfprintf(stderr, fmt, ap);
+	va_end(ap);
+	fprintf(stderr, ": %s\n", strerror(err_errno));
+	exit(eval);
+}
+
+static void c12r_errx(int eval, const char *fmt, ...)
+{
+	va_list ap;
+
+	fprintf(stderr, "%s: ", progname);
+	va_start(ap, fmt);
+	vfprintf(stderr, fmt, ap);
+	va_end(ap);
+	fprintf(stderr, "\n");
+	exit(eval);
+}
+
+static size_t fcopy(FILE *fsrc, FILE *fdst)
+{
+	char buffer[BUFSIZ];
+	size_t rsize, wsize;
+	size_t copied = 0;
+
+	while ((rsize = fread(buffer, 1, BUFSIZ, fsrc)) > 0) {
+		wsize = fwrite(buffer, 1, rsize, fdst);
+		copied += wsize;
+		if (wsize != rsize)
+			break;
+	}
+
+	return copied;
+}
+
+static char *grab_stream(FILE *file)
+{
+	size_t max, ret, size = 0;
 	char *buffer;
 
-	max = 16384;
-	buffer = malloc(max+1);
-	while ((ret = read(fd, buffer + size, max - size)) > 0) {
+	max = BUFSIZ;
+	buffer = malloc(max);
+	while ((ret = fread(buffer+size, 1, max - size, file)) == max - size) {
 		size += ret;
-		if (size == max)
-			buffer = realloc(buffer, max *= 2);
+		buffer = realloc(buffer, max *= 2);
 	}
-	if (ret < 0)
-		err(1, "reading from command");
+	size += ret;
+	if (ferror(file))
+		c12r_err(1, "reading from command");
 	buffer[size] = '\0';
 	return buffer;
 }
 
 static char *run(const char *cmd, int *exitstatus)
 {
-	pid_t pid;
-	int p[2];
+	static const char redir[] = " 2>&1";
+	size_t cmdlen;
+	char *cmdredir;
+	FILE *cmdout;
 	char *ret;
-	int status;
 
-	if (pipe(p) != 0)
-		err(1, "creating pipe");
-
-	pid = fork();
-	if (pid == -1)
-		err(1, "forking");
-
-	if (pid == 0) {
-		if (dup2(p[1], STDOUT_FILENO) != STDOUT_FILENO
-		    || dup2(p[1], STDERR_FILENO) != STDERR_FILENO
-		    || close(p[0]) != 0
-		    || close(STDIN_FILENO) != 0
-		    || open("/dev/null", O_RDONLY) != STDIN_FILENO)
-			exit(128);
-
-		status = system(cmd);
-		if (WIFEXITED(status))
-			exit(WEXITSTATUS(status));
-		/* Here's a hint... */
-		exit(128 + WTERMSIG(status));
-	}
+	cmdlen = strlen(cmd);
+	cmdredir = malloc(cmdlen + sizeof(redir));
+	memcpy(cmdredir, cmd, cmdlen);
+	memcpy(cmdredir + cmdlen, redir, sizeof(redir));
+
+	cmdout = popen(cmdredir, "r");
+	if (!cmdout)
+		c12r_err(1, "popen \"%s\"", cmdredir);
 
-	close(p[1]);
-	ret = grab_fd(p[0]);
-	/* This shouldn't fail... */
-	if (waitpid(pid, &status, 0) != pid)
-		err(1, "Failed to wait for child");
-	close(p[0]);
-	if (WIFEXITED(status))
-		*exitstatus = WEXITSTATUS(status);
-	else
-		*exitstatus = -WTERMSIG(status);
+	free(cmdredir);
+
+	ret = grab_stream(cmdout);
+	*exitstatus = pclose(cmdout);
 	return ret;
 }
 
-static char *connect_args(const char *argv[], const char *extra)
+static char *connect_args(const char *argv[], const char *outflag,
+		const char *files)
 {
-	unsigned int i, len = strlen(extra) + 1;
+	unsigned int i;
 	char *ret;
+	size_t len = strlen(outflag) + strlen(files) + 1;
 
 	for (i = 1; argv[i]; i++)
 		len += 1 + strlen(argv[i]);
@@ -441,10 +495,12 @@ static char *connect_args(const char *argv[], const char *extra)
 	for (i = 1; argv[i]; i++) {
 		strcpy(ret + len, argv[i]);
 		len += strlen(argv[i]);
-		if (argv[i+1])
+		if (argv[i+1] || *outflag)
 			ret[len++] = ' ';
 	}
-	strcpy(ret + len, extra);
+	strcpy(ret + len, outflag);
+	len += strlen(outflag);
+	strcpy(ret + len, files);
 	return ret;
 }
 
@@ -483,7 +539,7 @@ static bool run_test(const char *cmd, struct test *test)
 		char *dep;
 
 		/* Space-separated dependencies, could be ! for inverse. */
-		while ((len = strcspn(deps, " "))) {
+		while ((len = strcspn(deps, " ")) != 0) {
 			bool positive = true;
 			if (deps[len]) {
 				dep = strdup(deps);
@@ -509,9 +565,9 @@ static bool run_test(const char *cmd, struct test *test)
 		}
 	}
 
-	outf = fopen(INPUT_FILE, "w");
+	outf = fopen(INPUT_FILE, verbose > 1 ? "w+" : "w");
 	if (!outf)
-		err(1, "creating %s", INPUT_FILE);
+		c12r_err(1, "creating %s", INPUT_FILE);
 
 	fprintf(outf, "%s", PRE_BOILERPLATE);
 	switch (test->style & ~(EXECUTE|MAY_NOT_COMPILE)) {
@@ -540,11 +596,13 @@ static bool run_test(const char *cmd, struct test *test)
 		abort();
 
 	}
-	fclose(outf);
 
-	if (verbose > 1)
-		if (system("cat " INPUT_FILE) == -1)
-			;
+	if (verbose > 1) {
+		fseek(outf, 0, SEEK_SET);
+		fcopy(outf, stdout);
+	}
+
+	fclose(outf);
 
 	newcmd = strdup(cmd);
 
@@ -576,8 +634,8 @@ static bool run_test(const char *cmd, struct test *test)
 			       status ? "fail" : "warning",
 			       test->name, status, output);
 		if ((test->style & EXECUTE) && !(test->style & MAY_NOT_COMPILE))
-			errx(1, "Test for %s did not compile:\n%s",
-			     test->name, output);
+			c12r_errx(1, "Test for %s did not compile:\n%s",
+				  test->name, output);
 		test->answer = false;
 		free(output);
 	} else {
@@ -585,10 +643,10 @@ static bool run_test(const char *cmd, struct test *test)
 		free(output);
 		/* We run INSIDE_MAIN tests for sanity checking. */
 		if ((test->style & EXECUTE) || (test->style & INSIDE_MAIN)) {
-			output = run("./" OUTPUT_FILE, &status);
+			output = run("." DIR_SEP OUTPUT_FILE, &status);
 			if (!(test->style & EXECUTE) && status != 0)
-				errx(1, "Test for %s failed with %i:\n%s",
-				     test->name, status, output);
+				c12r_errx(1, "Test for %s failed with %i:\n%s",
+					  test->name, status, output);
 			if (verbose && status)
 				printf("%s exited %i\n", test->name, status);
 			free(output);
@@ -611,36 +669,53 @@ int main(int argc, const char *argv[])
 	unsigned int i;
 	const char *default_args[]
 		= { "", DEFAULT_COMPILER, DEFAULT_FLAGS, NULL };
+	const char *outflag = DEFAULT_OUTPUT_EXE_FLAG;
 
-	if (argc > 1) {
+	if (argc > 0)
+		progname = argv[0];
+
+	while (argc > 1) {
 		if (strcmp(argv[1], "--help") == 0) {
-			printf("Usage: configurator [-v] [<compiler> <flags>...]\n"
-			       "  <compiler> <flags> will have \"-o <outfile> <infile.c>\" appended\n"
-			       "Default: %s %s\n",
-			       DEFAULT_COMPILER, DEFAULT_FLAGS);
+			printf("Usage: configurator [-v] [-O<outflag>] [<compiler> <flags>...]\n"
+			       "  <compiler> <flags> will have \"<outflag> <outfile> <infile.c>\" appended\n"
+			       "Default: %s %s %s\n",
+			       DEFAULT_COMPILER, DEFAULT_FLAGS,
+			       DEFAULT_OUTPUT_EXE_FLAG);
 			exit(0);
 		}
-		if (strcmp(argv[1], "-v") == 0) {
+		if (strncmp(argv[1], "-O", 2) == 0) {
+			argc--;
+			argv++;
+			outflag = argv[1] + 2;
+			if (!*outflag) {
+				fprintf(stderr,
+					"%s: option requires an argument -- O\n",
+					argv[0]);
+				exit(1);
+			}
+		} else if (strcmp(argv[1], "-v") == 0) {
 			argc--;
 			argv++;
-			verbose = 1;
+			verbose++;
 		} else if (strcmp(argv[1], "-vv") == 0) {
 			argc--;
 			argv++;
-			verbose = 2;
+			verbose += 2;
+		} else {
+			break;
 		}
 	}
 
 	if (argc == 1)
 		argv = default_args;
 
-	cmd = connect_args(argv, " -o " OUTPUT_FILE " " INPUT_FILE);
+	cmd = connect_args(argv, outflag, OUTPUT_FILE " " INPUT_FILE);
 	for (i = 0; i < sizeof(tests)/sizeof(tests[0]); i++)
 		run_test(cmd, &tests[i]);
 	free(cmd);
 
-	unlink(OUTPUT_FILE);
-	unlink(INPUT_FILE);
+	remove(OUTPUT_FILE);
+	remove(INPUT_FILE);
 
 	printf("/* Generated by CCAN configurator */\n"
 	       "#ifndef CCAN_CONFIG_H\n"
@@ -649,9 +724,10 @@ int main(int argc, const char *argv[])
 	printf("#define _GNU_SOURCE /* Always use GNU extensions. */\n");
 	printf("#endif\n");
 	printf("#define CCAN_COMPILER \"%s\"\n", argv[1]);
-	cmd = connect_args(argv+1, "");
-	printf("#define CCAN_CFLAGS \"%s\"\n\n", cmd);
+	cmd = connect_args(argv + 1, "", "");
+	printf("#define CCAN_CFLAGS \"%s\"\n", cmd);
 	free(cmd);
+	printf("#define CCAN_OUTPUT_EXE_CFLAG \"%s\"\n\n", outflag);
 	/* This one implies "#include <ccan/..." works, eg. for tdb2.h */
 	printf("#define HAVE_CCAN 1\n");
 	for (i = 0; i < sizeof(tests)/sizeof(tests[0]); i++)
diff --git a/hkl/ccan/coroutine/coroutine.c b/hkl/ccan/coroutine/coroutine.c
new file mode 100644
index 0000000..b22cce3
--- /dev/null
+++ b/hkl/ccan/coroutine/coroutine.c
@@ -0,0 +1,229 @@
+/* GNU LGPL version 2 (or later) - see LICENSE file for details */
+#include <assert.h>
+#include <string.h>
+#include <stdio.h>
+#include <inttypes.h>
+#include <stdlib.h>
+
+#include <unistd.h>
+#include <sys/mman.h>
+
+#include <hkl/ccan/ptrint/ptrint.h>
+#include <hkl/ccan/compiler/compiler.h>
+#include <hkl/ccan/build_assert/build_assert.h>
+#include <hkl/ccan/coroutine/coroutine.h>
+
+/*
+ * Stack management
+ */
+
+/* Returns lowest stack addres, regardless of growth direction */
+static UNNEEDED void *coroutine_stack_base(struct coroutine_stack *stack)
+{
+#if HAVE_STACK_GROWS_UPWARDS
+	return (char *)(stack + 1);
+#else
+	return (char *)stack - stack->size;
+#endif
+}
+
+#if HAVE_VALGRIND_MEMCHECK_H
+#include <valgrind/memcheck.h>
+static void vg_register_stack(struct coroutine_stack *stack)
+{
+	char *base = coroutine_stack_base(stack);
+
+	VALGRIND_MAKE_MEM_UNDEFINED(base, stack->size);
+	stack->valgrind_id = VALGRIND_STACK_REGISTER(base,
+						     base + stack->size - 1);
+}
+
+static void vg_deregister_stack(struct coroutine_stack *stack)
+{
+	VALGRIND_MAKE_MEM_UNDEFINED(coroutine_stack_base(stack), stack->size);
+	VALGRIND_STACK_DEREGISTER(stack->valgrind_id);
+}
+static bool vg_addressable(void *p, size_t len)
+{
+	return !VALGRIND_CHECK_MEM_IS_ADDRESSABLE(p, len);
+}
+#else
+#define vg_register_stack(stack)		do { } while (0)
+#define vg_deregister_stack(stack)		do { } while (0)
+#define vg_addressable(p, len)			(true)
+#endif
+
+struct coroutine_stack *coroutine_stack_init(void *buf, size_t bufsize,
+					     size_t metasize)
+{
+	struct coroutine_stack *stack;
+	size_t size = bufsize - sizeof(*stack) - metasize;
+
+#ifdef MINSIGSTKSZ
+	BUILD_ASSERT(COROUTINE_MIN_STKSZ >= MINSIGSTKSZ);
+#endif
+
+	if (bufsize < (COROUTINE_MIN_STKSZ + sizeof(*stack) + metasize))
+		return NULL;
+
+#if HAVE_STACK_GROWS_UPWARDS
+	stack = (char *)buf + metasize;
+#else
+	stack = (struct coroutine_stack *)
+		((char *)buf + bufsize - metasize) - 1;
+#endif
+
+	stack->magic = COROUTINE_STACK_MAGIC_BUF;
+	stack->size = size;
+	vg_register_stack(stack);
+	return stack;
+}
+
+struct coroutine_stack *coroutine_stack_alloc(size_t totalsize, size_t metasize)
+{
+	struct coroutine_stack *stack;
+	size_t pgsz = getpagesize();
+	size_t mapsize;
+	char *map, *guard;
+	int rc;
+
+	mapsize = ((totalsize + (pgsz - 1)) & ~(pgsz - 1)) + pgsz;
+
+	map = mmap(NULL, mapsize, PROT_READ | PROT_WRITE,
+		   MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
+	if (map == MAP_FAILED)
+		return NULL;
+
+#if HAVE_STACK_GROWS_UPWARDS
+	guard = map + mapsize - pgsz;
+	stack = (struct coroutine_stack *)(guard - totalsize + metasize);
+#else
+	guard = map;
+	stack = (struct coroutine_stack *)(map + pgsz + totalsize - metasize)
+		- 1;
+#endif
+
+	rc = mprotect(guard, pgsz, PROT_NONE);
+	if (rc != 0) {
+		munmap(map, mapsize);
+		return NULL;
+	}
+
+	stack->magic = COROUTINE_STACK_MAGIC_ALLOC;
+	stack->size = totalsize - sizeof(*stack) - metasize;
+
+	vg_register_stack(stack);
+
+	return stack;
+}
+
+static void coroutine_stack_free(struct coroutine_stack *stack, size_t metasize)
+{
+	void *map;
+	size_t pgsz = getpagesize();
+	size_t totalsize = stack->size + sizeof(*stack) + metasize;
+	size_t mapsize = ((totalsize + (pgsz - 1)) & ~(pgsz - 1)) + pgsz;
+
+#if HAVE_STACK_GROWS_UPWARDS
+	map = (char *)(stack + 1) + stack->size + pgsz - mapsize;
+#else
+	map = (char *)stack - stack->size - pgsz;
+#endif
+
+	munmap(map, mapsize);
+}
+
+void coroutine_stack_release(struct coroutine_stack *stack, size_t metasize)
+{
+	vg_deregister_stack(stack);
+
+	switch (stack->magic) {
+	case COROUTINE_STACK_MAGIC_BUF:
+		memset(stack, 0, sizeof(*stack));
+		break;
+
+	case COROUTINE_STACK_MAGIC_ALLOC:
+		coroutine_stack_free(stack, metasize);
+		break;
+
+	default:
+		abort();
+	}
+}
+
+struct coroutine_stack *coroutine_stack_check(struct coroutine_stack *stack,
+					      const char *abortstr)
+{
+	if (stack && vg_addressable(stack, sizeof(*stack))
+	    && ((stack->magic == COROUTINE_STACK_MAGIC_BUF)
+		|| (stack->magic == COROUTINE_STACK_MAGIC_ALLOC))
+	    && (stack->size >= COROUTINE_MIN_STKSZ))
+		return stack;
+
+	if (abortstr) {
+		if (!stack)
+			fprintf(stderr, "%s: NULL coroutine stack\n", abortstr);
+		else
+			fprintf(stderr,
+				"%s: Bad coroutine stack at %p (magic=0x%"PRIx64" size=%zd)\n",
+				abortstr, stack, stack->magic, stack->size);
+		abort();
+	}
+	return NULL;
+}
+
+size_t coroutine_stack_size(const struct coroutine_stack *stack)
+{
+	return stack->size;
+}
+
+#if HAVE_UCONTEXT
+static void coroutine_uc_stack(stack_t *uc_stack,
+			       const struct coroutine_stack *stack)
+{
+	uc_stack->ss_size = coroutine_stack_size(stack);
+	uc_stack->ss_sp = coroutine_stack_base((struct coroutine_stack *)stack);
+}
+#endif /* HAVE_UCONTEXT */
+
+/*
+ * Coroutine switching
+ */
+
+#if HAVE_UCONTEXT
+void coroutine_init_(struct coroutine_state *cs,
+		     void (*fn)(void *), void *arg,
+		     struct coroutine_stack *stack)
+{
+	getcontext (&cs->uc);
+
+	coroutine_uc_stack(&cs->uc.uc_stack, stack);
+
+        if (HAVE_POINTER_SAFE_MAKECONTEXT) {
+                makecontext(&cs->uc, (void *)fn, 1, arg);
+        } else {
+                ptrdiff_t si = ptr2int(arg);
+                ptrdiff_t mask = (1UL << (sizeof(int) * 8)) - 1;
+                int lo = si & mask;
+                int hi = si >> (sizeof(int) * 8);
+
+                makecontext(&cs->uc, (void *)fn, 2, lo, hi);
+        }
+	
+}
+
+void coroutine_jump(const struct coroutine_state *to)
+{
+	setcontext(&to->uc);
+	assert(0);
+}
+
+void coroutine_switch(struct coroutine_state *from,
+		      const struct coroutine_state *to)
+{
+	int rc;
+
+	rc = swapcontext(&from->uc, &to->uc);
+	assert(rc == 0);
+}
+#endif /* HAVE_UCONTEXT */
diff --git a/hkl/ccan/coroutine/coroutine.h b/hkl/ccan/coroutine/coroutine.h
new file mode 100644
index 0000000..13f62f5
--- /dev/null
+++ b/hkl/ccan/coroutine/coroutine.h
@@ -0,0 +1,260 @@
+/* Licensed under LGPLv2.1+ - see LICENSE file for details */
+#ifndef CCAN_COROUTINE_H
+#define CCAN_COROUTINE_H
+/*#define CCAN_COROUTINE_DEBUG 1*/
+#include <hkl/ccan/ccan_config.h>
+
+#include <stddef.h>
+#include <stdint.h>
+#include <stdbool.h>
+#include <assert.h>
+
+#include <hkl/ccan/compiler/compiler.h>
+#include <hkl/ccan/typesafe_cb/typesafe_cb.h>
+
+/**
+ * struct coroutine_stack
+ *
+ * Describes a stack suitable for executing a coroutine.  This
+ * structure is always contained within the stack it describes.
+ */
+struct coroutine_stack {
+	uint64_t magic;
+	size_t size;
+	int valgrind_id;
+};
+
+/**
+ * struct coroutine_state
+ *
+ * Describes the state of an in-progress coroutine.
+ */
+struct coroutine_state;
+
+/*
+ * Stack management
+ */
+
+/**
+ * COROUTINE_STK_OVERHEAD - internal stack overhead
+ *
+ * Number of bytes of a stack which coroutine needs for its own
+ * tracking information.
+ */
+#define COROUTINE_STK_OVERHEAD	sizeof(struct coroutine_stack)
+
+/**
+ * COROUTINE_MIN_STKSZ - Minimum coroutine stack size
+ *
+ * Contains the minimum size for a coroutine stack (not including
+ * overhead).  On systems with MINSTKSZ, guaranteed to be at least as
+ * large as MINSTKSZ.
+ */
+#define COROUTINE_MIN_STKSZ		2048
+
+/**
+ * COROUTINE_STACK_MAGIC_BUF - Magic number for coroutine stacks in a user
+ *                             supplied buffer
+ */
+#define COROUTINE_STACK_MAGIC_BUF	0xc040c040574cb00f
+
+/**
+ * COROUTINE_STACK_MAGIC_ALLOC - Magic number for coroutine stacks
+ *                               allocated by this module
+ */
+#define COROUTINE_STACK_MAGIC_ALLOC	0xc040c040574ca110
+
+/**
+ * coroutine_stack_init - Prepare a coroutine stack in an existing buffer
+ * @buf: buffer to use for the coroutine stack
+ * @bufsize: size of @buf
+ * @metasize: size of metadata to add to the stack (not including
+ *            coroutine internal overhead)
+ *
+ * Prepares @buf for use as a coroutine stack, returning a
+ * coroutine_stack *, allocated from within the buffer.  Returns NULL
+ * on failure.
+ *
+ * This will fail if the bufsize < (COROUTINE_MIN_STKSZ +
+ * COROUTINE_STK_OVERHEAD + metasize).
+ */
+struct coroutine_stack *coroutine_stack_init(void *buf, size_t bufsize,
+					     size_t metasize);
+
+/**
+ * coroutine_stack_alloc - Allocate a coroutine stack
+ * @totalsize: total size to allocate
+ * @metasize: size of metadata to add to the stack (not including
+ *            coroutine internal overhead)
+ *
+ * Allocates a coroutine stack of size @totalsize, including both
+ * internal overhead (COROUTINE_STK_OVERHEAD) and metadata of size
+ * @metasize.  Where available this will also create a guard page, so
+ * that overruning the stack will result in an immediate crash, rather
+ * than data corruption.
+ *
+ * This will fail if the totalsize < (COROUTINE_MIN_STKSZ +
+ * COROUTINE_STK_OVERHEAD + metasize).
+ */
+struct coroutine_stack *coroutine_stack_alloc(size_t bufsize, size_t metasize);
+
+/**
+ * coroutine_stack_release - Stop using a coroutine stack
+ * @stack: coroutine stack to release
+ * @metasize: size of metadata
+ *
+ * This releases @stack, making it no longer suitable for use as a
+ * coroutine stack.  @metasize must be equal to the metasize passed to
+ * coroutine_stack_init.
+ */
+void coroutine_stack_release(struct coroutine_stack *stack, size_t metasize);
+
+/**
+ * coroutine_stack_check - Validate and return a coroutine stack
+ * @stack: stack to check
+ * @abortstr: the location to print on aborting, or NULL.
+ *
+ * Debugging check if @stack doesn't appear to be a valid coroutine
+ * stack, and @abortstr is non-NULL it will be printed and the
+ * function will abort.
+ *
+ * Returns @stack if it appears valid, NULL if not (it can never
+ * return NULL if @abortstr is set).
+ */
+struct coroutine_stack *coroutine_stack_check(struct coroutine_stack *stack,
+					      const char *abortstr);
+
+/**
+ * coroutine_stack_to_metadata - Returns pointer to user's metadata
+ *                               allocated within the stack
+ * @stack: coroutine stack
+ * @metasize: size of metadata
+ *
+ * Returns a pointer to the metadata area within @stack.  This is of
+ * size given at initialization time, and won't be overwritten by
+ * coroutines executing on the stack.  It's up to the caller what to
+ * put in here. @metasize must be equal to the value passed to
+ * coroutine_stack_init().
+ */
+static inline void *coroutine_stack_to_metadata(struct coroutine_stack *stack,
+						size_t metasize)
+{
+#if HAVE_STACK_GROWS_UPWARDS
+	return (char *)stack - metasize;
+#else
+	return (char *)stack + COROUTINE_STK_OVERHEAD;
+#endif
+}
+
+/**
+ * coroutine_stack_from_metadata - Returns pointer to coroutine stack
+ *                                 pointer given pointer to user metadata
+ * @metadat: user metadata within a stack
+ * @metasize: size of metadata
+ *
+ * Returns a pointer to the coroutine_stack handle within a stack.
+ * The argument must be a pointer returned by
+ * coroutine_stack_to_metadata() at an earlier time. @metasize must be
+ * equal to the value passed to coroutine_stack_init().
+ */
+static inline struct coroutine_stack *
+coroutine_stack_from_metadata(void *metadata, size_t metasize)
+{
+#if HAVE_STACK_GROWS_UPWARDS
+	return (struct coroutine_stack *)((char *)metadata + metasize);
+#else
+	return (struct coroutine_stack *)((char *)metadata
+					  - COROUTINE_STK_OVERHEAD);
+#endif
+}
+
+/**
+ * coroutine_stack_size - Return size of a coroutine stack
+ * @stack: coroutine stack
+ *
+ * Returns the size of the coroutine stack @stack.  This does not
+ * include the overhead of struct coroutine_stack or metdata.
+ */
+size_t coroutine_stack_size(const struct coroutine_stack *stack);
+
+/*
+ * Coroutine switching
+ */
+
+#if HAVE_UCONTEXT
+#include <ucontext.h>
+#define COROUTINE_AVAILABLE		1
+#else
+#define COROUTINE_AVAILABLE		0
+#endif
+
+struct coroutine_state {
+#if HAVE_UCONTEXT
+	ucontext_t uc;
+#endif /* HAVE_UCONTEXT */
+};
+
+#if COROUTINE_AVAILABLE
+
+/**
+ * coroutine_init - Prepare a coroutine for execution
+ * @cs: coroutine_state structure to initialize
+ * @fn: function to start executing in the coroutine
+ * @arg: argument for @fn
+ * @stack: stack to use for the coroutine
+ *
+ * Prepares @cs as a new coroutine which will execute starting with
+ * function @fn, using stack @stack.
+ */
+void coroutine_init_(struct coroutine_state *cs,
+		     void (*fn)(void *), void *arg,
+		     struct coroutine_stack *stack);
+#define coroutine_init(cs, fn, arg, stack)				\
+	coroutine_init_((cs),                                           \
+			typesafe_cb(void, void *, (fn), (arg)),		\
+			(arg), (stack))
+
+/**
+ * coroutine_jump - Irreversibly switch to executing a coroutine
+ * @to: coroutine to switch to
+ *
+ * Immediately jump to executing coroutine @to (at whatever point in
+ * execution it was up to).  Never returns.
+ */
+void NORETURN coroutine_jump(const struct coroutine_state *to);
+
+/**
+ * coroutine_switch - Switch coroutines
+ * @from: coroutine in which to store current execution state
+ * @to: coroutine to switch to
+ *
+ * Stop executing the current routine, saving its state in @from, and
+ * switch to executing the coroutine @to.  Returns only when something
+ * switches or jumps back to @from.
+ */
+void coroutine_switch(struct coroutine_state *from,
+		      const struct coroutine_state *to);
+
+#else
+
+static inline void coroutine_init(struct coroutine_state *cs,
+				  void (*fn)(void *), void *arg,
+				  struct coroutine_stack *stack)
+{
+	assert(0);
+}
+
+static inline void NORETURN coroutine_jump(const struct coroutine_state *to)
+{
+	assert(0);
+}
+
+static inline void coroutine_switch(struct coroutine_state *from,
+				    const struct coroutine_state *to)
+{
+	assert(0);
+}
+
+#endif /* !COROUTINE_AVAILABLE */
+
+#endif /* CCAN_COROUTINE_H */
diff --git a/hkl/ccan/cppmagic/cppmagic.h b/hkl/ccan/cppmagic/cppmagic.h
new file mode 100644
index 0000000..f1f6868
--- /dev/null
+++ b/hkl/ccan/cppmagic/cppmagic.h
@@ -0,0 +1,191 @@
+/* MIT (BSD) license - see LICENSE file for details */
+#ifndef CCAN_CPPMAGIC_H
+#define CCAN_CPPMAGIC_H
+
+/**
+ * CPPMAGIC_NOTHING - expands to nothing
+ */
+#define CPPMAGIC_NOTHING()
+
+/**
+ * CPPMAGIC_STRINGIFY - convert arguments to a string literal
+ */
+#define _CPPMAGIC_STRINGIFY(...)	#__VA_ARGS__
+#define CPPMAGIC_STRINGIFY(...)		_CPPMAGIC_STRINGIFY(__VA_ARGS__)
+
+/**
+ * CPPMAGIC_GLUE2 - glue arguments together
+ *
+ * CPPMAGIC_GLUE2(@a_, @b_)
+ *	expands to the expansion of @a_ followed immediately
+ *	(combining tokens) by the expansion of @b_
+ */
+#define _CPPMAGIC_GLUE2(a_, b_)		a_##b_
+#define CPPMAGIC_GLUE2(a_, b_)		_CPPMAGIC_GLUE2(a_, b_)
+
+/**
+ * CPPMAGIC_1ST - return 1st argument
+ *
+ * CPPMAGIC_1ST(@a_, ...)
+ *	expands to the expansion of @a_
+ */
+#define CPPMAGIC_1ST(a_, ...)		a_
+
+/**
+ * CPPMAGIC_2ND - return 2nd argument
+ *
+ * CPPMAGIC_2ST(@a_, @b_, ...)
+ *	expands to the expansion of @b_
+ */
+#define CPPMAGIC_2ND(a_, b_, ...)	b_
+
+/**
+ * CPPMAGIC_ISZERO - is argument '0'
+ *
+ * CPPMAGIC_ISZERO(@a)
+ *	expands to '1' if @a is '0', otherwise expands to '0'.
+ */
+#define _CPPMAGIC_ISPROBE(...)		CPPMAGIC_2ND(__VA_ARGS__, 0)
+#define _CPPMAGIC_PROBE()		$, 1
+#define _CPPMAGIC_ISZERO_0		_CPPMAGIC_PROBE()
+#define CPPMAGIC_ISZERO(a_)		\
+	_CPPMAGIC_ISPROBE(CPPMAGIC_GLUE2(_CPPMAGIC_ISZERO_, a_))
+
+/**
+ * CPPMAGIC_NONZERO - is argument not '0'
+ *
+ * CPPMAGIC_NONZERO(@a)
+ *	expands to '0' if @a is '0', otherwise expands to '1'.
+ */
+#define CPPMAGIC_NONZERO(a_)		CPPMAGIC_ISZERO(CPPMAGIC_ISZERO(a_))
+
+/**
+ * CPPMAGIC_NONEMPTY - does the macro have any arguments?
+ *
+ * CPPMAGIC_NONEMPTY()
+ * 	expands to '0'
+ * CPPMAGIC_NONEMPTY(@a)
+ * CPPMAGIC_NONEMPTY(@a, ...)
+ * 	expand to '1'
+ */
+#define _CPPMAGIC_EOA()			0
+#define CPPMAGIC_NONEMPTY(...)		\
+	CPPMAGIC_NONZERO(CPPMAGIC_1ST(_CPPMAGIC_EOA __VA_ARGS__)())
+
+/**
+ * CPPMAGIC_ISEMPTY - does the macro have no arguments?
+ *
+ * CPPMAGIC_ISEMPTY()
+ * 	expands to '1'
+ * CPPMAGIC_ISEMPTY(@a)
+ * CPPMAGIC_ISEMPTY(@a, ...)
+ * 	expand to '0'
+ */
+#define CPPMAGIC_ISEMPTY(...)		\
+	CPPMAGIC_ISZERO(CPPMAGIC_NONEMPTY(__VA_ARGS__))
+
+/*
+ * CPPMAGIC_IFELSE - preprocessor conditional
+ *
+ * CPPMAGIC_IFELSE(@cond)(@if)(@else)
+ *	expands to @else if @cond is '0', otherwise expands to @if
+ */
+#define _CPPMAGIC_IF_0(...)		_CPPMAGIC_IF_0_ELSE
+#define _CPPMAGIC_IF_1(...)		__VA_ARGS__ _CPPMAGIC_IF_1_ELSE
+#define _CPPMAGIC_IF_0_ELSE(...)	__VA_ARGS__
+#define _CPPMAGIC_IF_1_ELSE(...)
+#define _CPPMAGIC_IFELSE(cond_)		CPPMAGIC_GLUE2(_CPPMAGIC_IF_, cond_)
+#define CPPMAGIC_IFELSE(cond_)		\
+	_CPPMAGIC_IFELSE(CPPMAGIC_NONZERO(cond_))
+
+/**
+ * CPPMAGIC_EVAL - force multiple expansion passes
+ *
+ * Forces macros in the arguments to be expanded repeatedly (up to
+ * 1024 times) even when CPP would usually stop expanding.
+ */
+#define CPPMAGIC_EVAL1(...)		__VA_ARGS__
+#define CPPMAGIC_EVAL2(...)		\
+	CPPMAGIC_EVAL1(CPPMAGIC_EVAL1(__VA_ARGS__))
+#define CPPMAGIC_EVAL4(...)		\
+	CPPMAGIC_EVAL2(CPPMAGIC_EVAL2(__VA_ARGS__))
+#define CPPMAGIC_EVAL8(...)		\
+	CPPMAGIC_EVAL4(CPPMAGIC_EVAL4(__VA_ARGS__))
+#define CPPMAGIC_EVAL16(...)		\
+	CPPMAGIC_EVAL8(CPPMAGIC_EVAL8(__VA_ARGS__))
+#define CPPMAGIC_EVAL32(...)		\
+	CPPMAGIC_EVAL16(CPPMAGIC_EVAL16(__VA_ARGS__))
+#define CPPMAGIC_EVAL64(...)		\
+	CPPMAGIC_EVAL32(CPPMAGIC_EVAL32(__VA_ARGS__))
+#define CPPMAGIC_EVAL128(...)		\
+	CPPMAGIC_EVAL64(CPPMAGIC_EVAL64(__VA_ARGS__))
+#define CPPMAGIC_EVAL256(...)		\
+	CPPMAGIC_EVAL128(CPPMAGIC_EVAL128(__VA_ARGS__))
+#define CPPMAGIC_EVAL512(...)		\
+	CPPMAGIC_EVAL256(CPPMAGIC_EVAL256(__VA_ARGS__))
+#define CPPMAGIC_EVAL1024(...)		\
+	CPPMAGIC_EVAL512(CPPMAGIC_EVAL512(__VA_ARGS__))
+#define CPPMAGIC_EVAL(...)		CPPMAGIC_EVAL1024(__VA_ARGS__)
+
+/**
+ * CPPMAGIC_DEFER1, CPPMAGIC_DEFER2 - defer expansion
+ */
+#define CPPMAGIC_DEFER1(a_)	a_ CPPMAGIC_NOTHING()
+#define CPPMAGIC_DEFER2(a_)	a_ CPPMAGIC_NOTHING CPPMAGIC_NOTHING()()
+
+/**
+ * CPPMAGIC_MAP - iterate another macro across arguments
+ * @m: name of a one argument macro
+ *
+ * CPPMAGIC_MAP(@m, @a1, @a2, ... @an)
+ *	expands to the expansion of @m(@a1) , @m(@a2) , ... , @m(@an)
+ */
+#define _CPPMAGIC_MAP_()		_CPPMAGIC_MAP
+#define _CPPMAGIC_MAP(m_, a_, ...)					\
+	m_(a_)								\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(, CPPMAGIC_DEFER2(_CPPMAGIC_MAP_)()(m_, __VA_ARGS__))	\
+		()
+#define CPPMAGIC_MAP(m_, ...)						\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(CPPMAGIC_EVAL(_CPPMAGIC_MAP(m_, __VA_ARGS__)))		\
+		()
+
+/**
+ * CPPMAGIC_2MAP - iterate another macro across pairs of arguments
+ * @m: name of a two argument macro
+ *
+ * CPPMAGIC_2MAP(@m, @a1, @b1, @a2, @b2, ..., @an, @bn)
+ *	expands to the expansion of
+ *		 @m(@a1, @b1) , @m(@a2, @b2) , ... , @m(@an, @bn)
+ */
+#define _CPPMAGIC_2MAP_()		_CPPMAGIC_2MAP
+#define _CPPMAGIC_2MAP(m_, a_, b_, ...)				\
+	m_(a_, b_)							\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(, CPPMAGIC_DEFER2(_CPPMAGIC_2MAP_)()(m_, __VA_ARGS__)) \
+		()
+#define CPPMAGIC_2MAP(m_, ...)					\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(CPPMAGIC_EVAL(_CPPMAGIC_2MAP(m_, __VA_ARGS__)))	\
+		()
+
+/**
+ * CPPMAGIC_JOIN - separate arguments with given delimiter
+ * @d: delimiter
+ *
+ * CPPMAGIC_JOIN(@d, @a1, @a2, ..., @an)
+ *	expands to the expansion of @a1 @d @a2 @d ... @d @an
+ */
+#define _CPPMAGIC_JOIN_()		_CPPMAGIC_JOIN
+#define _CPPMAGIC_JOIN(d_, a_, ...)					\
+	a_								\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(d_ CPPMAGIC_DEFER2(_CPPMAGIC_JOIN_)()(d_, __VA_ARGS__)) \
+		()
+#define CPPMAGIC_JOIN(d_, ...)					\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(CPPMAGIC_EVAL(_CPPMAGIC_JOIN(d_, __VA_ARGS__)))	\
+		()
+
+#endif /* CCAN_CPPMAGIC_H */
diff --git a/hkl/ccan/darray/darray.h b/hkl/ccan/darray/darray.h
index 12a4990..384ff3c 100644
--- a/hkl/ccan/darray/darray.h
+++ b/hkl/ccan/darray/darray.h
@@ -56,6 +56,7 @@
  *
  *     void   darray_append(darray(T) arr, T item);
  *     void   darray_prepend(darray(T) arr, T item);
+ *     void   darray_insert(darray(T) arr, size_t index, T item);
  *     void   darray_push(darray(T) arr, T item); // same as darray_append
  *
  * Insertion (multiple items):
@@ -169,36 +170,42 @@ typedef darray(unsigned long)  darray_ulong;
 		memmove((arr).item+1, (arr).item, ((arr).size-1)*sizeof(*(arr).item)); \
 		(arr).item[0] = (__VA_ARGS__); \
 	} while(0)
+#define darray_insert(arr, i, ...) do { \
+		size_t index_ = (i); \
+		darray_resize(arr, (arr).size+1); \
+		memmove((arr).item+index_+1, (arr).item+index_, ((arr).size-index_-1)*sizeof(*(arr).item)); \
+		(arr).item[index_] = (__VA_ARGS__); \
+	} while(0)
 #define darray_push(arr, ...) darray_append(arr, __VA_ARGS__)
 
 
 /*** Insertion (multiple items) ***/
 
 #define darray_append_items(arr, items, count) do { \
-		size_t __count = (count), __oldSize = (arr).size; \
-		darray_resize(arr, __oldSize + __count); \
-		memcpy((arr).item + __oldSize, items, __count * sizeof(*(arr).item)); \
+		size_t count_ = (count), oldSize_ = (arr).size; \
+		darray_resize(arr, oldSize_ + count_); \
+		memcpy((arr).item + oldSize_, items, count_ * sizeof(*(arr).item)); \
 	} while(0)
 
 #define darray_prepend_items(arr, items, count) do { \
-		size_t __count = (count), __oldSize = (arr).size; \
-		darray_resize(arr, __count + __oldSize); \
-		memmove((arr).item + __count, (arr).item, __oldSize * sizeof(*(arr).item)); \
-		memcpy((arr).item, items, __count * sizeof(*(arr).item)); \
+		size_t count_ = (count), oldSize_ = (arr).size; \
+		darray_resize(arr, count_ + oldSize_); \
+		memmove((arr).item + count_, (arr).item, oldSize_ * sizeof(*(arr).item)); \
+		memcpy((arr).item, items, count_ * sizeof(*(arr).item)); \
 	} while(0)
 
 #define darray_append_items_nullterminate(arr, items, count) do { \
-		size_t __count = (count), __oldSize = (arr).size; \
-		darray_resize(arr, __oldSize + __count + 1); \
-		memcpy((arr).item + __oldSize, items, __count * sizeof(*(arr).item)); \
+		size_t count_ = (count), oldSize_ = (arr).size; \
+		darray_resize(arr, oldSize_ + count_ + 1); \
+		memcpy((arr).item + oldSize_, items, count_ * sizeof(*(arr).item)); \
 		(arr).item[--(arr).size] = 0; \
 	} while(0)
 
 #define darray_prepend_items_nullterminate(arr, items, count) do { \
-		size_t __count = (count), __oldSize = (arr).size; \
-		darray_resize(arr, __count + __oldSize + 1); \
-		memmove((arr).item + __count, (arr).item, __oldSize * sizeof(*(arr).item)); \
-		memcpy((arr).item, items, __count * sizeof(*(arr).item)); \
+		size_t count_ = (count), oldSize_ = (arr).size; \
+		darray_resize(arr, count_ + oldSize_ + 1); \
+		memmove((arr).item + count_, (arr).item, oldSize_ * sizeof(*(arr).item)); \
+		memcpy((arr).item, items, count_ * sizeof(*(arr).item)); \
 		(arr).item[--(arr).size] = 0; \
 	} while(0)
 
@@ -208,12 +215,12 @@ typedef darray(unsigned long)  darray_ulong;
 #endif
 
 #define darray_appends_t(arr, type, ...) do { \
-		type __src[] = {__VA_ARGS__}; \
-		darray_append_items(arr, __src, sizeof(__src)/sizeof(*__src)); \
+		type src_[] = {__VA_ARGS__}; \
+		darray_append_items(arr, src_, sizeof(src_)/sizeof(*src_)); \
 	} while(0)
 #define darray_prepends_t(arr, type, ...) do { \
-		type __src[] = {__VA_ARGS__}; \
-		darray_prepend_items(arr, __src, sizeof(__src)/sizeof(*__src)); \
+		type src_[] = {__VA_ARGS__}; \
+		darray_prepend_items(arr, src_, sizeof(src_)/sizeof(*src_)); \
 	} while(0)
 
 
@@ -223,32 +230,33 @@ typedef darray(unsigned long)  darray_ulong;
 #define darray_pop(arr) ((arr).item[--(arr).size])
 #define darray_pop_check(arr) ((arr).size ? darray_pop(arr) : NULL)
 /* Warning, slow: Requires copying all elements after removed item. */
-#define darray_remove(arr, index) do { \
-	if (index < arr.size-1)    \
-		memmove(&(arr).item[index], &(arr).item[index+1], ((arr).size-1-i)*sizeof(*(arr).item)); \
+#define darray_remove(arr, i) do { \
+	size_t index_ = (i); \
+	if (index_ < arr.size-1)    \
+		memmove(&(arr).item[index_], &(arr).item[index_+1], ((arr).size-1-index_)*sizeof(*(arr).item)); \
 	(arr).size--;  \
 	} while(0)
 
 
 /*** Replacement ***/
 
-#define darray_from_items(arr, items, count) do {size_t __count = (count); darray_resize(arr, __count); memcpy((arr).item, items, __count*sizeof(*(arr).item));} while(0)
+#define darray_from_items(arr, items, count) do {size_t count_ = (count); darray_resize(arr, count_); memcpy((arr).item, items, count_*sizeof(*(arr).item));} while(0)
 #define darray_from_c(arr, c_array) darray_from_items(arr, c_array, sizeof(c_array)/sizeof(*(c_array)))
 
 
 /*** String buffer ***/
 
-#define darray_append_string(arr, str) do {const char *__str = (str); darray_append_items(arr, __str, strlen(__str)+1); (arr).size--;} while(0)
+#define darray_append_string(arr, str) do {const char *str_ = (str); darray_append_items(arr, str_, strlen(str_)+1); (arr).size--;} while(0)
 #define darray_append_lit(arr, stringLiteral) do {darray_append_items(arr, stringLiteral, sizeof(stringLiteral)); (arr).size--;} while(0)
 
 #define darray_prepend_string(arr, str) do { \
-		const char *__str = (str); \
-		darray_prepend_items_nullterminate(arr, __str, strlen(__str)); \
+		const char *str_ = (str); \
+		darray_prepend_items_nullterminate(arr, str_, strlen(str_)); \
 	} while(0)
 #define darray_prepend_lit(arr, stringLiteral) \
 	darray_prepend_items_nullterminate(arr, stringLiteral, sizeof(stringLiteral) - 1)
 
-#define darray_from_string(arr, str) do {const char *__str = (str); darray_from_items(arr, __str, strlen(__str)+1); (arr).size--;} while(0)
+#define darray_from_string(arr, str) do {const char *str_ = (str); darray_from_items(arr, str_, strlen(str_)+1); (arr).size--;} while(0)
 #define darray_from_lit(arr, stringLiteral) do {darray_from_items(arr, stringLiteral, sizeof(stringLiteral)); (arr).size--;} while(0)
 
 
@@ -256,11 +264,11 @@ typedef darray(unsigned long)  darray_ulong;
 
 #define darray_resize(arr, newSize) darray_growalloc(arr, (arr).size = (newSize))
 #define darray_resize0(arr, newSize) do { \
-		size_t __oldSize = (arr).size, __newSize = (newSize); \
-		(arr).size = __newSize; \
-		if (__newSize > __oldSize) { \
-			darray_growalloc(arr, __newSize); \
-			memset(&(arr).item[__oldSize], 0, (__newSize - __oldSize) * sizeof(*(arr).item)); \
+		size_t oldSize_ = (arr).size, newSize_ = (newSize); \
+		(arr).size = newSize_; \
+		if (newSize_ > oldSize_) { \
+			darray_growalloc(arr, newSize_); \
+			memset(&(arr).item[oldSize_], 0, (newSize_ - oldSize_) * sizeof(*(arr).item)); \
 		} \
 	} while(0)
 
@@ -268,9 +276,9 @@ typedef darray(unsigned long)  darray_ulong;
 		(arr).item = realloc((arr).item, ((arr).alloc = (newAlloc)) * sizeof(*(arr).item)); \
 	} while(0)
 #define darray_growalloc(arr, need) do { \
-		size_t __need = (need); \
-		if (__need > (arr).alloc) \
-			darray_realloc(arr, darray_next_alloc((arr).alloc, __need)); \
+		size_t need_ = (need); \
+		if (need_ > (arr).alloc) \
+			darray_realloc(arr, darray_next_alloc((arr).alloc, need_)); \
 	} while(0)
 
 #if HAVE_STATEMENT_EXPR==1
diff --git a/hkl/ccan/generator/generator.c b/hkl/ccan/generator/generator.c
new file mode 100644
index 0000000..98b05e3
--- /dev/null
+++ b/hkl/ccan/generator/generator.c
@@ -0,0 +1,55 @@
+/* Licensed LGPLv2.1+ - see LICENSE file for details */
+#include <stdlib.h>
+#include <stdbool.h>
+#include <stddef.h>
+
+#include <hkl/ccan/alignof/alignof.h>
+
+#include <hkl/ccan/generator/generator.h>
+
+#define DEFAULT_STATE_SIZE	8192
+#define STATE_ALIGN		ALIGNOF(struct generator_)
+
+static size_t generator_metasize(size_t retsize)
+{
+	retsize = (retsize + STATE_ALIGN) & ~(STATE_ALIGN - 1);
+	return sizeof(struct generator_) + retsize;
+}
+
+void *generator_new_(void (*fn)(void *), size_t retsize)
+{
+	char *base;
+	size_t size = DEFAULT_STATE_SIZE;
+	size_t metasize = generator_metasize(retsize);
+	struct coroutine_stack *stack;
+	void *ret;
+	struct generator_ *gen;
+
+	base = malloc(size);
+	if (!base)
+		abort();
+
+	retsize = (retsize + STATE_ALIGN) & ~(STATE_ALIGN - 1);
+
+	stack = coroutine_stack_init(base, size, metasize);
+	gen = coroutine_stack_to_metadata(stack, metasize);
+	ret = gen + 1;
+
+	gen->base = base;
+	gen->complete = false;
+
+	coroutine_init(&gen->gen, fn, ret, stack);
+
+	return ret;
+}
+
+void generator_free_(void *ret, size_t retsize)
+{
+	struct generator_ *gen = generator_state_(ret);
+	size_t metasize = generator_metasize(retsize);
+	struct coroutine_stack *stack;
+
+	stack = coroutine_stack_from_metadata(gen, metasize);
+	coroutine_stack_release(stack, metasize);
+	free(gen->base);
+}
diff --git a/hkl/ccan/generator/generator.h b/hkl/ccan/generator/generator.h
new file mode 100644
index 0000000..d3e621f
--- /dev/null
+++ b/hkl/ccan/generator/generator.h
@@ -0,0 +1,220 @@
+/* Licensed under LGPLv2.1+ - see LICENSE file for details */
+#ifndef CCAN_GENERATOR_H
+#define CCAN_GENERATOR_H
+#include <hkl/ccan/ccan_config.h>
+
+#if !HAVE_TYPEOF
+#error Generators require typeof
+#endif
+
+#if !HAVE_STATEMENT_EXPR
+#error Generators require statement expressions
+#endif
+
+#include <assert.h>
+#include <stddef.h>
+#include <stdbool.h>
+
+#include <hkl/ccan/cppmagic/cppmagic.h>
+#include <hkl/ccan/compiler/compiler.h>
+#include <hkl/ccan/coroutine/coroutine.h>
+
+#if !COROUTINE_AVAILABLE
+#error Generators require coroutines
+#endif
+
+/*
+ * Internals - included just for the use of inlines and macros
+ */
+
+struct generator_ {
+	struct coroutine_state gen;
+	struct coroutine_state caller;
+	bool complete;
+	void *base;
+};
+
+static inline struct generator_ *generator_state_(const void *ret)
+{
+	return (struct generator_ *)ret - 1;
+}
+
+static inline void *generator_argp_(const void *ret)
+{
+	return generator_state_(ret)->base;
+}
+
+struct generator_incomplete_;
+
+#define generator_rtype_(gen_)			\
+	typeof((*(gen_))((struct generator_incomplete_ *)NULL))
+
+void *generator_new_(void (*fn)(void *), size_t retsize);
+void generator_free_(void *ret, size_t retsize);
+
+/*
+ * API
+ */
+
+/**
+ * generator_t - type for an in-progress generator
+ * @rtype: type of values the generator yield
+ */
+#define generator_t(rtype_)			\
+	typeof(rtype_ (*)(struct generator_incomplete_ *))
+
+/**
+ * generator_declare - declare (but don't define) a generator function
+ * @name: name for the generator
+ * @rtype: return type for the generator
+ *
+ * Declares (as an extern) a generator function named @name, which
+ * will yield return values of type @rtype.
+ *
+ * Example:
+ *	generator_declare(count_to_3, int);
+ */
+#define generator_declare(name_, rtype_, ...)	\
+	generator_t(rtype_) name_(generator_parms_outer_(__VA_ARGS__))
+
+/**
+ * generator_def - define a generator function
+ * @name: name for the generator
+ * @rtype: return type for the generator
+ *
+ * Define a generator function named @name yielding return values of
+ * type @rtype.  The generator_def() line is followed immediately by a
+ * block containing the generator's code.
+ *
+ * Example:
+ *	generator_def(count_to_3, int)
+ *	{
+ *		generator_yield(1);
+ *		generator_yield(2);
+ *		generator_yield(3);
+ *	}
+ */
+#define generator_parm_(t_, n_)			t_ n_
+#define generator_parms_(...)						\
+	CPPMAGIC_2MAP(generator_parm_, __VA_ARGS__)
+#define generator_parms_inner_(...)					\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(, generator_parms_(__VA_ARGS__))()
+#define generator_parms_outer_(...)					\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))	\
+		(generator_parms_(__VA_ARGS__))(void)
+#define generator_argfield_(t_, n_)		t_ n_;
+#define generator_argstruct_(...)					\
+	struct {							\
+		CPPMAGIC_JOIN(, CPPMAGIC_2MAP(generator_argfield_,	\
+					      __VA_ARGS__))		\
+	}
+#define generator_arg_unpack_(t_, n_)		args->n_
+#define generator_args_unpack_(...)		\
+	CPPMAGIC_IFELSE(CPPMAGIC_NONEMPTY(__VA_ARGS__))			\
+		(, CPPMAGIC_2MAP(generator_arg_unpack_, __VA_ARGS__))()
+#define generator_arg_pack_(t_, n_)		args->n_ = n_
+#define generator_args_pack_(...)					\
+	CPPMAGIC_JOIN(;, CPPMAGIC_2MAP(generator_arg_pack_, __VA_ARGS__))
+#define generator_def_(name_, rtype_, storage_, ...)			\
+	static void name_##_generator_(rtype_ *ret_			\
+				       generator_parms_inner_(__VA_ARGS__)); \
+	static void name_##_generator__(void *ret)			\
+	{								\
+		struct generator_ *gen;					\
+		UNNEEDED generator_argstruct_(__VA_ARGS__) *args;	\
+		gen = generator_state_(ret);				\
+		args = generator_argp_(ret);				\
+		name_##_generator_(ret generator_args_unpack_(__VA_ARGS__)); \
+		gen->complete = true;					\
+		coroutine_jump(&gen->caller);				\
+		assert(0);						\
+	}								\
+	storage_ generator_t(rtype_)					\
+	name_(generator_parms_outer_(__VA_ARGS__))			\
+	{								\
+		generator_t(rtype_) gen = generator_new_(name_##_generator__, \
+							 sizeof(rtype_)); \
+		UNNEEDED generator_argstruct_(__VA_ARGS__) *args =	\
+			generator_argp_(gen);				\
+		generator_args_pack_(__VA_ARGS__);			\
+		return gen;						\
+	}								\
+	static void name_##_generator_(rtype_ *ret_			\
+				       generator_parms_inner_(__VA_ARGS__))
+#define generator_def(name_, rtype_, ...)	\
+	generator_def_(name_, rtype_, , __VA_ARGS__)
+
+/**
+ * generator_def_static - define a private / local generator function
+ * @name: name for the generator
+ * @rtype: return type for the generator
+ *
+ * As generator_def, but the resulting generator function will be
+ * local to this module.
+ */
+#define generator_def_static(name_, rtype_, ...)	\
+	generator_def_(name_, rtype_, static, __VA_ARGS__)
+
+/**
+ * generator_yield - yield (return) a value from a generator
+ * @val: value to yield
+ *
+ * Invoke only from within a generator.  Yield the given value to the
+ * caller.  This will stop execution of the generator code until the
+ * caller next invokes generator_next(), at which point it will
+ * continue from the generator_yield statement.
+ */
+#define generator_yield(val_)						\
+	do {								\
+		struct generator_ *gen_ = generator_state_(ret_);	\
+		*(ret_) = (val_);					\
+		coroutine_switch(&gen_->gen, &gen_->caller);		\
+	} while (0)
+
+/**
+ * generator_next - get next value from a generator
+ * @gen: a generator state variable
+ *
+ * Returns a pointer to a (correctly typed) buffer containing the next
+ * value yielded by @gen, or NULL if @gen is finished.  The buffer
+ * contents is only valid until the next time @gen is called or
+ * manipulated.
+ */
+static inline void *generator_next_(void *ret_)
+{
+	struct generator_ *gen = generator_state_(ret_);
+
+	if (gen->complete)
+		return NULL;
+
+	coroutine_switch(&gen->caller, &gen->gen);
+
+	return gen->complete ? NULL : ret_;
+}
+#define generator_next(gen_)				\
+	((generator_rtype_(gen_) *)generator_next_(gen_))
+
+/**
+ * generator_next_val - store next value from a generator
+ * @val: a variable of type suitable to store the generator's return
+ *       type (lvalue)
+ * @gen: a generator state variable
+ *
+ * Returns 'true' if @gen yielded a new value, false if @gen is
+ * complete.  If a new value was yielded, it is stored in @val.
+ */
+#define generator_next_val(val_, gen_)			\
+	({						\
+		generator_rtype_(gen_) *ret;		\
+		ret = generator_next(gen_);		\
+		if (ret)				\
+			(val_) = *ret;			\
+		!!ret;					\
+	})
+
+#define generator_free(gen_)					\
+	generator_free_((generator_rtype_(gen_) *)(gen_),	\
+			sizeof(generator_rtype_(gen_)))
+
+#endif /* CCAN_GENERATOR_H */
diff --git a/hkl/ccan/list/list.h b/hkl/ccan/list/list.h
index 13355ca..6ef0b19 100644
--- a/hkl/ccan/list/list.h
+++ b/hkl/ccan/list/list.h
@@ -292,6 +292,21 @@ static inline bool list_empty_nodebug(const struct list_head *h)
 #endif
 
 /**
+ * list_empty_nocheck - is a list empty?
+ * @h: the list_head
+ *
+ * If the list is empty, returns true. This doesn't perform any
+ * debug check for list consistency, so it can be called without
+ * locks, racing with the list being modified. This is ok for
+ * checks where an incorrect result is not an issue (optimized
+ * bail out path for example).
+ */
+static inline bool list_empty_nocheck(const struct list_head *h)
+{
+	return h->n.next == &h->n;
+}
+
+/**
  * list_del - delete an entry from an (unknown) linked list.
  * @n: the list_node to delete from the list.
  *
@@ -701,12 +716,12 @@ static inline void list_prepend_list_(struct list_head *to,
  * so you can break and continue as normal.
  *
  * WARNING! Being the low-level macro that it is, this wrapper doesn't know
- * nor care about the type of @i. The only assumtion made is that @i points
+ * nor care about the type of @i. The only assumption made is that @i points
  * to a chunk of memory that at some @offset, relative to @i, contains a
- * properly filled `struct node_list' which in turn contains pointers to
- * memory chunks and it's turtles all the way down. Whith all that in mind
+ * properly filled `struct list_node' which in turn contains pointers to
+ * memory chunks and it's turtles all the way down. With all that in mind
  * remember that given the wrong pointer/offset couple this macro will
- * happilly churn all you memory untill SEGFAULT stops it, in other words
+ * happily churn all you memory until SEGFAULT stops it, in other words
  * caveat emptor.
  *
  * It is worth mentioning that one of legitimate use-cases for that wrapper
diff --git a/hkl/ccan/ptr_valid/ptr_valid.c b/hkl/ccan/ptr_valid/ptr_valid.c
index 98c7dd7..84e2974 100644
--- a/hkl/ccan/ptr_valid/ptr_valid.c
+++ b/hkl/ccan/ptr_valid/ptr_valid.c
@@ -246,9 +246,14 @@ static bool check_with_child(struct ptr_valid_batch *batch,
 			return false;
 	}
 
-	write(batch->to_child, &p, sizeof(p));
-	write(batch->to_child, &size, sizeof(size));
-	write(batch->to_child, &is_write, sizeof(is_write));
+	if (write(batch->to_child, &p, sizeof(p))
+	    + write(batch->to_child, &size, sizeof(size))
+	    + write(batch->to_child, &is_write, sizeof(is_write))
+	    != sizeof(p) + sizeof(size) + sizeof(is_write)) {
+		finish_child(batch);
+		errno = EFAULT;
+		return false;
+	}
 
 	if (read(batch->from_child, &ret, sizeof(ret)) != sizeof(ret)) {
 		finish_child(batch);
diff --git a/hkl/ccan/ptrint/ptrint.h b/hkl/ccan/ptrint/ptrint.h
new file mode 100644
index 0000000..020c0ca
--- /dev/null
+++ b/hkl/ccan/ptrint/ptrint.h
@@ -0,0 +1,35 @@
+/* CC0 (Public domain) - see LICENSE file for details */
+#ifndef CCAN_PTRINT_H
+#define CCAN_PTRINT_H
+
+#include <hkl/ccan/ccan_config.h>
+
+#include <stddef.h>
+
+#include <hkl/ccan/build_assert/build_assert.h>
+#include <hkl/ccan/compiler/compiler.h>
+
+/*
+ * This is a deliberately incomplete type, because it should never be
+ * dereferenced - instead it marks pointer values which are actually
+ * encoding integers
+ */
+typedef struct ptrint ptrint_t;
+
+CONST_FUNCTION static inline ptrdiff_t ptr2int(const ptrint_t *p)
+{
+	/*
+	 * ptrdiff_t is the right size by definition, but to avoid
+	 * surprises we want a warning if the user can't fit at least
+	 * a regular int in there
+	 */
+	BUILD_ASSERT(sizeof(int) <= sizeof(ptrdiff_t));
+	return (const char *)p - (const char *)NULL;
+}
+
+CONST_FUNCTION static inline ptrint_t *int2ptr(ptrdiff_t i)
+{
+	return (ptrint_t *)((char *)NULL + i);
+}
+
+#endif /* CCAN_PTRINT_H */
diff --git a/hkl/ccan/str/str.h b/hkl/ccan/str/str.h
index 7778442..2f9a137 100644
--- a/hkl/ccan/str/str.h
+++ b/hkl/ccan/str/str.h
@@ -94,7 +94,7 @@ size_t strcount(const char *haystack, const char *needle);
 #if HAVE_TYPEOF
 /* Only a simple type can have 0 assigned, so test that. */
 #define STR_MAX_CHARS_TCHECK_(type_or_expr)		\
-	({ typeof(type_or_expr) x = 0; (void)x; 0; })
+	(sizeof(({ typeof(type_or_expr) x = 0; x; }))*0)
 #else
 #define STR_MAX_CHARS_TCHECK_(type_or_expr) 0
 #endif
diff --git a/hkl/ccan/typesafe_cb/typesafe_cb.h b/hkl/ccan/typesafe_cb/typesafe_cb.h
new file mode 100644
index 0000000..3fc2c7d
--- /dev/null
+++ b/hkl/ccan/typesafe_cb/typesafe_cb.h
@@ -0,0 +1,134 @@
+/* CC0 (Public domain) - see LICENSE file for details */
+#ifndef CCAN_TYPESAFE_CB_H
+#define CCAN_TYPESAFE_CB_H
+#include <hkl/ccan/ccan_config.h>
+
+#if HAVE_TYPEOF && HAVE_BUILTIN_CHOOSE_EXPR && HAVE_BUILTIN_TYPES_COMPATIBLE_P
+/**
+ * typesafe_cb_cast - only cast an expression if it matches a given type
+ * @desttype: the type to cast to
+ * @oktype: the type we allow
+ * @expr: the expression to cast
+ *
+ * This macro is used to create functions which allow multiple types.
+ * The result of this macro is used somewhere that a @desttype type is
+ * expected: if @expr is exactly of type @oktype, then it will be
+ * cast to @desttype type, otherwise left alone.
+ *
+ * This macro can be used in static initializers.
+ *
+ * This is merely useful for warnings: if the compiler does not
+ * support the primitives required for typesafe_cb_cast(), it becomes an
+ * unconditional cast, and the @oktype argument is not used.  In
+ * particular, this means that @oktype can be a type which uses the
+ * "typeof": it will not be evaluated if typeof is not supported.
+ *
+ * Example:
+ *	// We can take either an unsigned long or a void *.
+ *	void _set_some_value(void *val);
+ *	#define set_some_value(e)			\
+ *		_set_some_value(typesafe_cb_cast(void *, (e), unsigned long))
+ */
+#define typesafe_cb_cast(desttype, oktype, expr)			\
+	__builtin_choose_expr(						\
+		__builtin_types_compatible_p(__typeof__(0?(expr):(expr)), \
+					     oktype),			\
+		(desttype)(expr), (expr))
+#else
+#define typesafe_cb_cast(desttype, oktype, expr) ((desttype)(expr))
+#endif
+
+/**
+ * typesafe_cb_cast3 - only cast an expression if it matches given types
+ * @desttype: the type to cast to
+ * @ok1: the first type we allow
+ * @ok2: the second type we allow
+ * @ok3: the third type we allow
+ * @expr: the expression to cast
+ *
+ * This is a convenient wrapper for multiple typesafe_cb_cast() calls.
+ * You can chain them inside each other (ie. use typesafe_cb_cast()
+ * for expr) if you need more than 3 arguments.
+ *
+ * Example:
+ *	// We can take either a long, unsigned long, void * or a const void *.
+ *	void _set_some_value(void *val);
+ *	#define set_some_value(expr)					\
+ *		_set_some_value(typesafe_cb_cast3(void *,,		\
+ *					    long, unsigned long, const void *,\
+ *					    (expr)))
+ */
+#define typesafe_cb_cast3(desttype, ok1, ok2, ok3, expr)		\
+	typesafe_cb_cast(desttype, ok1,					\
+			 typesafe_cb_cast(desttype, ok2,		\
+					  typesafe_cb_cast(desttype, ok3, \
+							   (expr))))
+
+/**
+ * typesafe_cb - cast a callback function if it matches the arg
+ * @rtype: the return type of the callback function
+ * @atype: the (pointer) type which the callback function expects.
+ * @fn: the callback function to cast
+ * @arg: the (pointer) argument to hand to the callback function.
+ *
+ * If a callback function takes a single argument, this macro does
+ * appropriate casts to a function which takes a single atype argument if the
+ * callback provided matches the @arg.
+ *
+ * It is assumed that @arg is of pointer type: usually @arg is passed
+ * or assigned to a void * elsewhere anyway.
+ *
+ * Example:
+ *	void _register_callback(void (*fn)(void *arg), void *arg);
+ *	#define register_callback(fn, arg) \
+ *		_register_callback(typesafe_cb(void, (fn), void*, (arg)), (arg))
+ */
+#define typesafe_cb(rtype, atype, fn, arg)			\
+	typesafe_cb_cast(rtype (*)(atype),			\
+			 rtype (*)(__typeof__(arg)),		\
+			 (fn))
+
+/**
+ * typesafe_cb_preargs - cast a callback function if it matches the arg
+ * @rtype: the return type of the callback function
+ * @atype: the (pointer) type which the callback function expects.
+ * @fn: the callback function to cast
+ * @arg: the (pointer) argument to hand to the callback function.
+ *
+ * This is a version of typesafe_cb() for callbacks that take other arguments
+ * before the @arg.
+ *
+ * Example:
+ *	void _register_callback(void (*fn)(int, void *arg), void *arg);
+ *	#define register_callback(fn, arg)				   \
+ *		_register_callback(typesafe_cb_preargs(void, void *,	   \
+ *				   (fn), (arg), int),			   \
+ *				   (arg))
+ */
+#define typesafe_cb_preargs(rtype, atype, fn, arg, ...)			\
+	typesafe_cb_cast(rtype (*)(__VA_ARGS__, atype),			\
+			 rtype (*)(__VA_ARGS__, __typeof__(arg)),	\
+			 (fn))
+
+/**
+ * typesafe_cb_postargs - cast a callback function if it matches the arg
+ * @rtype: the return type of the callback function
+ * @atype: the (pointer) type which the callback function expects.
+ * @fn: the callback function to cast
+ * @arg: the (pointer) argument to hand to the callback function.
+ *
+ * This is a version of typesafe_cb() for callbacks that take other arguments
+ * after the @arg.
+ *
+ * Example:
+ *	void _register_callback(void (*fn)(void *arg, int), void *arg);
+ *	#define register_callback(fn, arg) \
+ *		_register_callback(typesafe_cb_postargs(void, (fn), void *, \
+ *				   (arg), int),				    \
+ *				   (arg))
+ */
+#define typesafe_cb_postargs(rtype, atype, fn, arg, ...)		\
+	typesafe_cb_cast(rtype (*)(atype, __VA_ARGS__),			\
+			 rtype (*)(__typeof__(arg), __VA_ARGS__),	\
+			 (fn))
+#endif /* CCAN_CAST_IF_TYPE_H */
diff --git a/hkl/hkl-axis-private.h b/hkl/hkl-axis-private.h
index 83cb684..b808e62 100644
--- a/hkl/hkl-axis-private.h
+++ b/hkl/hkl-axis-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -30,6 +30,8 @@
 G_BEGIN_DECLS
 
 typedef struct _HklAxis HklAxis;
+typedef struct _HklRotationWithOrigin HklRotationWithOrigin;
+typedef struct _HklTranslation HklTranslation;
 
 struct _HklAxis {
 	HklParameter parameter;
@@ -37,7 +39,28 @@ struct _HklAxis {
 	HklQuaternion q; /* internal */
 };
 
-extern HklParameter *hkl_parameter_new_axis(const char* name, HklVector const *axis_v, const HklUnit *punit);
+struct _HklRotationWithOrigin {
+	HklAxis axis;
+	HklVector origin;
+};
+
+struct _HklTranslation {
+	HklParameter parameter;
+	HklVector axis_v;
+};
+
+extern HklParameter *hkl_parameter_new_rotation(const char* name,
+						HklVector const *axis_v,
+						const HklUnit *punit);
+
+extern HklParameter *hkl_parameter_new_rotation_with_origin(const char* name,
+							    const HklVector *axis_v,
+							    const HklVector *origin,
+							    const HklUnit *punit);
+
+extern HklParameter *hkl_parameter_new_translation(const char *name,
+						   const HklVector *axis_v,
+						   const HklUnit *punit);
 
 G_END_DECLS
 
diff --git a/hkl/hkl-axis.c b/hkl/hkl-axis.c
index 8628e8f..0b02342 100644
--- a/hkl/hkl-axis.c
+++ b/hkl/hkl-axis.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -220,22 +220,47 @@ static inline const HklQuaternion *hkl_axis_quaternion_get_real(const HklParamet
 	return &container_of(self, HklAxis, parameter)->q;
 }
 
+static inline int hkl_axis_transformation_cmp_real(const HklParameter *base, const HklParameter *p2)
+{
+	const HklAxis *self = container_of(base, HklAxis, parameter);
+	const HklAxis *axis2 = container_of(p2, HklAxis, parameter);
+
+	return hkl_parameter_transformation_cmp_real(base, p2)
+		|| hkl_vector_cmp(&self->axis_v, &axis2->axis_v);
+}
+
+static inline HklVector hkl_axis_transformation_apply_real(const HklParameter *base,
+							   const HklVector *v)
+{
+	const HklAxis *self = container_of(base, HklAxis, parameter);
+	HklVector res = *v;
+
+	hkl_vector_rotated_quaternion(&res, &self->q);
+
+	return res;
+}
+
+#define HKL_PARAMETER_OPERATIONS_AXIS_DEFAULTS				\
+	HKL_PARAMETER_OPERATIONS_DEFAULTS,				\
+		.copy = hkl_axis_copy_real,				\
+		.free = hkl_axis_free_real,				\
+		.init_copy = hkl_axis_init_copy_real,			\
+		.get_value_closest = hkl_axis_get_value_closest_real,	\
+		.set_value = hkl_axis_set_value_real,			\
+		.set_value_smallest_in_range = hkl_axis_set_value_smallest_in_range_real, \
+		.randomize = hkl_axis_randomize_real,			\
+		.is_valid = hkl_axis_is_valid_real,			\
+		.fprintf = hkl_axis_fprintf_real,			\
+		.axis_v_get = hkl_axis_axis_v_get_real,			\
+		.quaternion_get = hkl_axis_quaternion_get_real,		\
+		.transformation_cmp = hkl_axis_transformation_cmp_real,	\
+		.transformation_apply = hkl_axis_transformation_apply_real
+
 static HklParameterOperations hkl_parameter_operations_axis = {
-	HKL_PARAMETER_OPERATIONS_DEFAULTS,
-	.copy = hkl_axis_copy_real,
-	.free = hkl_axis_free_real,
-	.init_copy = hkl_axis_init_copy_real,
-	.get_value_closest = hkl_axis_get_value_closest_real,
-	.set_value = hkl_axis_set_value_real,
-	.set_value_smallest_in_range = hkl_axis_set_value_smallest_in_range_real,
-	.randomize = hkl_axis_randomize_real,
-	.is_valid = hkl_axis_is_valid_real,
-	.fprintf = hkl_axis_fprintf_real,
-	.axis_v_get = hkl_axis_axis_v_get_real,
-	.quaternion_get = hkl_axis_quaternion_get_real
+	HKL_PARAMETER_OPERATIONS_AXIS_DEFAULTS,
 };
 
-HklParameter *hkl_parameter_new_axis(const char *name, HklVector const *axis_v, const HklUnit *punit)
+HklParameter *hkl_parameter_new_rotation(const char *name, HklVector const *axis_v, const HklUnit *punit)
 {
 	HklAxis axis0 = {
 		.parameter = { HKL_PARAMETER_DEFAULTS_ANGLE,
@@ -253,3 +278,212 @@ HklParameter *hkl_parameter_new_axis(const char *name, HklVector const *axis_v,
 
 	return &self->parameter;
 }
+
+/*************************/
+/* HklRotationWithOrigin */
+/*************************/
+
+static inline HklParameter *hkl_rotation_with_origin_copy_real(const HklParameter *base)
+{
+	HklRotationWithOrigin *self = container_of(container_of(base, HklAxis, parameter),
+						   HklRotationWithOrigin, axis);
+	HklRotationWithOrigin *dup;
+
+	dup = HKL_MALLOC(HklRotationWithOrigin);
+
+	*dup = *self;
+
+	return &dup->axis.parameter;
+}
+
+static inline void hkl_rotation_with_origin_free_real(HklParameter *base)
+{
+	free(container_of(container_of(base, HklAxis, parameter),
+			  HklRotationWithOrigin, axis));
+}
+
+static inline int hkl_rotation_with_origin_init_copy_real(HklParameter *base,
+							  const HklParameter *base_src,
+							  GError **error)
+{
+	HklRotationWithOrigin *self = container_of(container_of(base, HklAxis, parameter),
+						   HklRotationWithOrigin, axis);
+	HklRotationWithOrigin *src = container_of(container_of(base_src, HklAxis, parameter),
+						  HklRotationWithOrigin, axis);
+
+	hkl_error (error == NULL || *error == NULL);
+
+	*self = *src;
+	base->changed = TRUE;
+
+	return TRUE;
+}
+
+static inline int hkl_rotation_with_origin_transformation_cmp_real(const HklParameter *base,
+								   const HklParameter *base_p2)
+{
+	HklRotationWithOrigin *self = container_of(container_of(base, HklAxis, parameter),
+						   HklRotationWithOrigin, axis);
+	HklRotationWithOrigin *p2 = container_of(container_of(base_p2, HklAxis, parameter),
+						 HklRotationWithOrigin, axis);
+
+	return hkl_axis_transformation_cmp_real(base, base_p2)
+		|| hkl_vector_cmp(&self->origin, &p2->origin);
+}
+
+static inline HklVector hkl_rotation_with_origin_transformation_apply_real(const HklParameter *base,
+									   const HklVector *v)
+{
+	const HklAxis *axis = container_of(base, HklAxis, parameter);
+	const HklRotationWithOrigin *self = container_of(axis, HklRotationWithOrigin, axis);
+	HklVector res = *v;
+
+	hkl_vector_minus_vector(&res, &self->origin);
+	hkl_vector_rotated_quaternion(&res, &axis->q);
+	hkl_vector_add_vector(&res, &self->origin);
+
+	return res;
+}
+
+#define HKL_PARAMETER_OPERATIONS_ROTATION_WITH_ORIGIN_DEFAULTS		\
+	HKL_PARAMETER_OPERATIONS_AXIS_DEFAULTS,				\
+		.copy = hkl_rotation_with_origin_copy_real,		\
+		.free = hkl_rotation_with_origin_free_real,		\
+		.init_copy = hkl_rotation_with_origin_init_copy_real,	\
+		.transformation_cmp = hkl_rotation_with_origin_transformation_cmp_real,	\
+		.transformation_apply = hkl_rotation_with_origin_transformation_apply_real
+
+static HklParameterOperations hkl_parameter_operations_rotation_with_origin = {
+	HKL_PARAMETER_OPERATIONS_ROTATION_WITH_ORIGIN_DEFAULTS,
+};
+
+HklParameter *hkl_parameter_new_rotation_with_origin(const char *name,
+						     HklVector const *axis_v,
+						     HklVector const *origin,
+						     const HklUnit *punit)
+{
+	HklRotationWithOrigin rotation0 = {
+		.axis = {
+			.parameter = { HKL_PARAMETER_DEFAULTS_ANGLE,
+				       .name = name,
+				       .punit = punit,
+				       .ops = &hkl_parameter_operations_rotation_with_origin,
+			},
+			.axis_v = *axis_v,
+			.q = {{1., 0., 0., 0.}},
+		},
+		.origin = *origin,
+	};
+
+	HklRotationWithOrigin *self =  HKL_MALLOC(HklRotationWithOrigin);
+
+	*self = rotation0;
+
+	return &self->axis.parameter;
+}
+
+/**********************/
+/* HklTranslation */
+/**********************/
+
+static inline HklParameter *hkl_translation_copy_real(const HklParameter *base)
+{
+	HklTranslation *self = container_of(base, HklTranslation, parameter);
+	HklTranslation *dup;
+
+	dup = HKL_MALLOC(HklTranslation);
+
+	*dup = *self;
+
+	return &dup->parameter;
+}
+
+static inline void hkl_translation_free_real(HklParameter *base)
+{
+	free(container_of(base, HklTranslation, parameter));
+}
+
+static inline int hkl_translation_init_copy_real(HklParameter *base,
+						 const HklParameter *base_src,
+						 GError **error)
+{
+	HklTranslation *self = container_of(base, HklTranslation, parameter);
+	HklTranslation *src = container_of(base_src, HklTranslation, parameter);
+
+	/* need to check that parameters are compatibles */
+	hkl_error (error == NULL || *error == NULL);
+
+	*self = *src;
+	base->changed = TRUE;
+
+	return TRUE;
+}
+
+static inline void hkl_translation_fprintf_real(FILE *f, const HklParameter *base)
+{
+	HklTranslation *self = container_of(base, HklTranslation, parameter);
+
+	hkl_parameter_fprintf_real(f, base);
+	hkl_vector_fprintf(f, &self->axis_v);
+}
+
+static inline const HklVector *hkl_translation_axis_v_get_real(const HklParameter *base)
+{
+	return &container_of(base, HklTranslation, parameter)->axis_v;
+}
+
+static inline int hkl_translation_transformation_cmp_real(const HklParameter *base,
+							  const HklParameter *p2)
+{
+	const HklTranslation *self = container_of(base, HklTranslation, parameter);
+	const HklTranslation *translation2 = container_of(p2, HklTranslation, parameter);
+
+	return hkl_parameter_transformation_cmp_real(base, p2)
+		|| hkl_vector_cmp(&self->axis_v, &translation2->axis_v);
+}
+
+static inline HklVector hkl_translation_transformation_apply_real(const HklParameter *base,
+								  const HklVector *v)
+{
+	const HklTranslation *self = container_of(base, HklTranslation, parameter);
+	HklVector res = self->axis_v;
+
+	hkl_vector_times_double(&res, base->_value);
+	hkl_vector_add_vector(&res, v);
+
+	return res;
+}
+
+#define HKL_PARAMETER_OPERATIONS_TRANSLATION_DEFAULTS			\
+	HKL_PARAMETER_OPERATIONS_DEFAULTS,				\
+		.copy = hkl_translation_copy_real,			\
+		.free = hkl_translation_free_real,			\
+		.init_copy = hkl_translation_init_copy_real,		\
+		.fprintf = hkl_translation_fprintf_real	,		\
+		.axis_v_get = hkl_translation_axis_v_get_real,		\
+		.transformation_cmp = hkl_translation_transformation_cmp_real, \
+		.transformation_apply = hkl_translation_transformation_apply_real
+
+static HklParameterOperations hkl_parameter_operations_translation =
+{
+	HKL_PARAMETER_OPERATIONS_TRANSLATION_DEFAULTS,
+};
+
+HklParameter *hkl_parameter_new_translation(const char *name, HklVector const *axis_v, const HklUnit *punit)
+{
+	HklTranslation translation0 = {
+		.parameter = { HKL_PARAMETER_DEFAULTS,
+			       .name = name,
+			       .unit = &hkl_unit_length_meter,
+			       .punit = punit,
+			       .ops = &hkl_parameter_operations_translation,
+		},
+		.axis_v = *axis_v,
+	};
+
+	HklTranslation *self =  HKL_MALLOC(HklTranslation);
+
+	*self = translation0;
+
+	return &self->parameter;
+}
diff --git a/hkl/hkl-binding-private.h b/hkl/hkl-binding-private.h
index ef1c063..2db6fc8 100644
--- a/hkl/hkl-binding-private.h
+++ b/hkl/hkl-binding-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2012-2016 Synchrotron SOLEIL
+ * Copyright (C) 2012-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-binding.c b/hkl/hkl-binding.c
index 73695c7..641808d 100644
--- a/hkl/hkl-binding.c
+++ b/hkl/hkl-binding.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2012-2016 Synchrotron SOLEIL
+ * Copyright (C) 2012-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-detector-factory.c b/hkl/hkl-detector-factory.c
index fcbbb50..52b3700 100644
--- a/hkl/hkl-detector-factory.c
+++ b/hkl/hkl-detector-factory.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-detector-private.h b/hkl/hkl-detector-private.h
index f4585a5..09cd38e 100644
--- a/hkl/hkl-detector-private.h
+++ b/hkl/hkl-detector-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-detector.c b/hkl/hkl-detector.c
index 2459b47..9d312a4 100644
--- a/hkl/hkl-detector.c
+++ b/hkl/hkl-detector.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -42,7 +42,7 @@ HklDetector *hkl_detector_new(void)
 
 	self = HKL_MALLOC(HklDetector);
 
-	self->idx = 1;
+	self->idx = HKL_HOLDER_DETECTOR_IDX;
 	self->holder = NULL;
 
 	return self;
@@ -107,7 +107,7 @@ int hkl_detector_compute_kf(HklDetector const *self, HklGeometry *g,
 
 	hkl_geometry_update(g);
 
-	holder = darray_item(g->holders, self->idx);
+	holder = hkl_geometry_detector_holder_get(g, self);
 	if (holder) {
 		hkl_vector_init(kf, HKL_TAU / g->source.wave_length, 0, 0);
 		hkl_vector_rotated_quaternion(kf, &holder->q);
diff --git a/hkl/hkl-engine-2c.c b/hkl/hkl-engine-2c.c
index 6713c9d..2bbd011 100644
--- a/hkl/hkl-engine-2c.c
+++ b/hkl/hkl-engine-2c.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -41,14 +41,14 @@ static const char* hkl_geometry_twoC_axes[] = {OMEGA, TTH};
 
 static HklGeometry *hkl_geometry_new_twoC(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, TTH, 0, -1, 0);
+	hkl_holder_add_rotation(h, TTH, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-e4c.c b/hkl/hkl-engine-e4c.c
index e2a1344..c94f013 100644
--- a/hkl/hkl-engine-e4c.c
+++ b/hkl/hkl-engine-e4c.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -62,7 +62,7 @@ static HklMode *bissector(void)
 	};
 
 	return hkl_mode_auto_new(&info,
-				 &hkl_mode_operations,
+				 &hkl_full_mode_operations,
 				 TRUE);
 }
 
@@ -76,7 +76,7 @@ static HklMode *constant_omega(void)
 	};
 
 	return hkl_mode_auto_new(&info,
-				 &hkl_mode_operations,
+				 &hkl_full_mode_operations,
 				 TRUE);
 }
 
@@ -90,7 +90,7 @@ static HklMode *constant_chi(void)
 	};
 
 	return hkl_mode_auto_new(&info,
-				 &hkl_mode_operations,
+				 &hkl_full_mode_operations,
 				 TRUE);
 }
 
@@ -104,7 +104,7 @@ static HklMode *constant_phi(void)
 	};
 
 	return hkl_mode_auto_new(&info,
-				 &hkl_mode_operations,
+				 &hkl_full_mode_operations,
 				 TRUE);
 }
 
@@ -118,7 +118,7 @@ static HklMode *double_diffraction(void)
 	};
 
 	return hkl_mode_auto_new(&info,
-				 &hkl_mode_operations,
+				 &hkl_full_mode_operations,
 				 TRUE);
 }
 
@@ -218,16 +218,16 @@ static const char* hkl_geometry_eulerian4C_vertical_axes[] = {OMEGA, CHI, PHI, T
 
 static HklGeometry *hkl_geometry_new_eulerian4C_vertical(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, CHI, 1, 0, 0);
-	hkl_holder_add_rotation_axis(h, PHI, 0, -1, 0);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, CHI, 1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, PHI, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, TTH, 0, -1, 0);
+	hkl_holder_add_rotation(h, TTH, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
@@ -240,6 +240,7 @@ static HklEngineList *hkl_engine_list_new_eulerian4C_vertical(const HklFactory *
 	hkl_engine_e4c_psi_new(self);
 	hkl_engine_q_new(self);
 	hkl_engine_e4c_incidence_new(self);
+	hkl_engine_e4c_emergence_new(self);
 
 	return self;
 }
@@ -267,16 +268,16 @@ static const char* hkl_geometry_soleil_mars_axes[] = {OMEGA, CHI, PHI, TTH};
 
 static HklGeometry *hkl_geometry_new_soleil_mars(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, CHI, -1, 0, 0);
-	hkl_holder_add_rotation_axis(h, PHI, 0, 0, 1);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, CHI, -1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, PHI, 0, 0, 1, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, TTH, 0, -1, 0);
+	hkl_holder_add_rotation(h, TTH, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
@@ -289,6 +290,7 @@ static HklEngineList *hkl_engine_list_new_soleil_mars(const HklFactory *factory)
 	hkl_engine_e4c_psi_new(self);
 	hkl_engine_q_new(self);
 	hkl_engine_e4c_incidence_new(self);
+	hkl_engine_e4c_emergence_new(self);
 
 	return self;
 }
@@ -315,16 +317,16 @@ static const char* hkl_geometry_eulerian4C_horizontal_axes[] = {OMEGA, CHI, PHI,
 
 static HklGeometry *hkl_geometry_new_eulerian4C_horizontal(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, CHI, 1, 0, 0);
-	hkl_holder_add_rotation_axis(h, PHI, 0, 0, 1);
+	hkl_holder_add_rotation(h, OMEGA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, CHI, 1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, PHI, 0, 0, 1, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, TTH, 0, 0, 1);
+	hkl_holder_add_rotation(h, TTH, 0, 0, 1, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-e6c.c b/hkl/hkl-engine-e6c.c
index d2788d3..1c593d0 100644
--- a/hkl/hkl-engine-e6c.c
+++ b/hkl/hkl-engine-e6c.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -358,18 +358,18 @@ static const char* hkl_geometry_eulerian6C_axes[] = {MU, OMEGA, CHI, PHI, GAMMA,
 
 static HklGeometry *hkl_geometry_new_eulerian6C(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, CHI, 1, 0, 0);
-	hkl_holder_add_rotation_axis(h, PHI, 0, -1, 0);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, CHI, 1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, PHI, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-k4c.c b/hkl/hkl-engine-k4c.c
index 714e6f3..75c6595 100644
--- a/hkl/hkl-engine-k4c.c
+++ b/hkl/hkl-engine-k4c.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -420,17 +420,17 @@ static const char* hkl_geometry_kappa4C_vertical_axes[] = {KOMEGA, KAPPA, KPHI,
 
 static HklGeometry *hkl_geometry_new_kappa4C_vertical(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	double alpha = 50 * HKL_DEGTORAD;
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, KOMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, KAPPA, 0, -cos(alpha), -sin(alpha));
-	hkl_holder_add_rotation_axis(h, KPHI, 0, -1, 0);
+	hkl_holder_add_rotation(h, KOMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KAPPA, 0, -cos(alpha), -sin(alpha), &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KPHI, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, TTH, 0, -1, 0);
+	hkl_holder_add_rotation(h, TTH, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-k6c.c b/hkl/hkl-engine-k6c.c
index f586244..84eaf56 100644
--- a/hkl/hkl-engine-k6c.c
+++ b/hkl/hkl-engine-k6c.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -351,15 +351,16 @@ static int _constant_incidence_func(const gsl_vector *x, void *params, gsl_vecto
 	 * the surface is oriented along the nx, ny, nz axis for all
 	 * diffractometer angles equal to zero */
 	if(mode->geometry){
-		HklQuaternion q0 = darray_item(mode->geometry->holders, 0)->q;
+		HklQuaternion q0 = hkl_geometry_sample_holder_get(mode->geometry, mode->sample)->q;
 
 		hkl_quaternion_conjugate(&q0);
 		hkl_vector_rotated_quaternion(&n, &q0);
 	}
 
-	hkl_vector_rotated_quaternion(&n, &darray_item(engine->geometry->holders, 0)->q);
+	hkl_vector_rotated_quaternion(&n, &hkl_geometry_sample_holder_get(engine->geometry,
+									  mode->sample)->q);
 
-	hkl_source_compute_ki(&engine->geometry->source, &ki);
+	ki = hkl_geometry_ki_get(engine->geometry);
 	incidence = _incidence(&n, &ki);
 
 	hkl_vector_project_on_plan(&n, &ki);
@@ -680,19 +681,19 @@ static const char* hkl_geometry_kappa6C_axes[] = {MU, KOMEGA, KAPPA, KPHI, GAMMA
 
 static HklGeometry *hkl_geometry_new_kappa6C(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	double alpha = 50 * HKL_DEGTORAD;
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, KOMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, KAPPA, 0, -cos(alpha), -sin(alpha));
-	hkl_holder_add_rotation_axis(h, KPHI, 0, -1, 0);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KOMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KAPPA, 0, -cos(alpha), -sin(alpha), &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KPHI, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
@@ -1003,19 +1004,19 @@ static const char* hkl_geometry_soleil_sirius_kappa_axes[] = {MU, KOMEGA, KAPPA,
 
 static HklGeometry *hkl_geometry_new_soleil_sirius_kappa(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	double alpha = 50 * HKL_DEGTORAD;
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, -1);
-	hkl_holder_add_rotation_axis(h, KOMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, KAPPA, 0, -cos(alpha), -sin(alpha));
-	hkl_holder_add_rotation_axis(h, KPHI, 0, -1, 0);
+	hkl_holder_add_rotation(h, MU, 0, 0, -1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KOMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KAPPA, 0, -cos(alpha), -sin(alpha), &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, KPHI, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, 0, -1);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, -1, 0);
+	hkl_holder_add_rotation(h, DELTA, 0, 0, -1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-petra3-p08-lisa.c b/hkl/hkl-engine-petra3-p08-lisa.c
new file mode 100644
index 0000000..160f7d0
--- /dev/null
+++ b/hkl/hkl-engine-petra3-p08-lisa.c
@@ -0,0 +1,693 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ * Copyright (C) 2017      DESY
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ *          Teresa Núñez <tnunez at mail.desy.de>
+ */
+#include "hkl.h"
+#include <gsl/gsl_sys.h>                // for gsl_isnan
+#include "hkl-axis-private.h"
+#include "hkl-factory-private.h"        // for autodata_factories_, etc
+#include "hkl-matrix-private.h"
+#include "hkl-pseudoaxis-common-hkl-private.h"  // for hkl_mode_operations, etc
+#include "hkl-pseudoaxis-common-psi-private.h"  // for hkl_engine_psi_new, etc
+#include "hkl-pseudoaxis-common-q-private.h"  // for hkl_engine_q2_new, etc
+#include "hkl-pseudoaxis-common-tth-private.h"  // for hkl_engine_tth2_new, etc
+#include "hkl-pseudoaxis-common-readonly-private.h"
+#include "hkl-sample-private.h"
+
+/***********************
+
+    Description
+
+There are 5 real motors:
+
+mchi  (monochromator rotation)  -> rotation y axis +1
+sphi  (sample rotation)         -> rotation z axis +1
+dtth  (detector table rotation) -> rotation z axis -1
+dh    (detector height)         -> translation z axis +1
+drot  (detector rotation)       -> rotation x axis +1
+
+There are 4 pseudo motors related to them:
+
+alpha   (incident angle - kin with xy plane)
+beta    (outgoing angle - kout with xy plane)
+sth      (angle between the kin projection and the vector defined via sphi)
+stth     (angle between kin and kout projections in the xy plane)
+
+sth and stth has to be independently as pseudomotors.
+
+For a given energy, E, one can compute mchi, sphi, dtth, dh and drot
+from alpha, beta, th and tth and viceversa. The solutions are not
+unique, for fixing them one has to set:
+
+FRED: reading this and looking at the schema, it seems that you need a
+pseudo motor engine with the four pseudo motors. something which takes
+alpha, beta, sth and stth in order to compute the 5 real motors
+positions. So maybe the right things to do is to create a pm with all
+the pseudo motors and not only stth and sth.
+
+Teresa: I agree. The users told me only about stth and sth, as the manual
+also says, but it is better to have the four ones.
+
+Maybe the right things to do is to create for now, only pseudo motors
+with the read part.  So once we have this setup it will be easier for
+us to understand what is going on.
+
+ - Detector rotation tracking -> the detector table rotation, dtth,
+   follows the monochromator rotation, mchi, so that the position of
+   stth stays constant. For stth = 0 the detector is in diffraction
+   plane.
+
+ - mchi rotation direction -> if set to '+' the mchi angle goes from 0
+   to pi, set to '-' it goes from 0 to -pi.
+
+ - allow rotation sample -> if 'yes' the sample will be rotated with
+   the monochromator, so that sth will stay constant. If 'no' the
+   sample will not be rotated.
+
+The following geometry constants have to be set:
+
+  - distance sample center to detector = 500
+  - distance first crystal (mono1) to sample center = 650
+  - distance first crystal (mono1) to second one (mono2) = 25
+  - first crystal diffraction parameter
+  - second crystal diffraction parameter
+
+lambda = hc_over_e/Energy
+bragg1 = g_tau1 * lambda * 1/(4*pi)
+bragg2 = g_tau2 * lambda * 1/(4*pi)
+
+where
+
+the crystals used are Si111 and Si220.
+
+g_tau1 = 2*PI/d111
+g_tau2 = 2*PI/d220
+
+where d111 and d220 are the lattice plane distances (in Amstrong) of the
+crystals.
+
+d111 = 3.136 A
+d220 = 1.920 A
+
+FRED: Do you want to set these parameters in the code or do you want
+to add these parameters to the geometry dynamiquely ?  So the user can
+change this during the experimenta ? I would prefer a static
+declaration for now in the code.
+
+For a alpha, beta, th and tth set there are different possibilities of
+choosing the position of the real motors for getting a given
+h,k,l. Four possible geometry modes have to be implemented, each mode
+gives an unique solution for the real computers computed from the
+angles. These modes are:
+
+  - mode 0 -> K axis from reciprocal space parallel to incident beam.
+  - mode 1 -> alpha = beta
+  - mode 2 -> th = tth/2
+  - mode 3 -> K axis from reciprocal space parallel to outgoing beam.
+
+There are some corrections (motor movements) that have to be done if
+the energy is changed, in order to correct the shifts in the position
+of the beam on the sample.
+
+*******************/
+
+
+/**************/
+/* Axes names */
+/**************/
+
+#define SPHI "sphi"
+#define DTTH "dtth"
+#define DH   "dh"
+#define DROT "drot"
+#define MCHI "mchi"
+
+#define D_SD 0.5 /* meter */
+#define D_Si111 3.136 /* Si111 of mono1 Angstöm */
+#define D_Si220 1.920 /* Si220 ok mono2 Angstöm */
+
+#define PETRA3_P08_LISA_SOURCE_HOLDER_IDX 0
+#define PETRA3_P08_LISA_SAMPLE_HOLDER_IDX 1
+#define PETRA3_P08_LISA_DETECTOR_HOLDER_IDX 2
+
+#define HKL_GEOMETRY_PETRA3_P08_LISA_DESCRIPTION			\
+	"+ xrays source fix along the :math:`\\vec{x}` direction (1, 0, 0)\n" \
+	"+ 1 axes for the monochromator\n"				\
+	"\n"								\
+	"  + **" MCHI "** : rotation around the :math:`\\vec{x}` direction (1, 0, 0)\n" \
+	"\n"								\
+	"+ 1 axis for the sample\n"					\
+	"\n"								\
+	"  + **" SPHI "** : rotating around the :math:`\\vec{z}` direction (0, 0, 1)\n" \
+	"\n"								\
+	"+ 2 axes for the detector\n"					\
+	"\n"								\
+	"  + **" DTTH "** : rotation around the :math:`-\\vec{z}` direction (0, 0, -1)\n" \
+	"  + **" DH   "** : translation along the :math:`\\vec{z}` direction (0, 0, 1)\n" \
+	"  + **" DROT "** : rotation around the :math:`-\\vec{y}` direction (0, -1, 0)\n"
+
+static double _alpha_max(double wavelength, double d1, double d2)
+{
+	double theta1 = asin(wavelength / (2 * d1));
+	double theta2 = asin(wavelength / (2 * d2));
+	return 2 * (theta2 - theta1);
+}
+
+static int hkl_mode_hkl_petra3_p08_lisa_get_real(HklMode *self,
+						 HklEngine *engine,
+						 HklGeometry *geometry,
+						 HklDetector *detector,
+						 HklSample *sample,
+						 GError **error)
+{
+	HklHolder *holder;
+	HklMatrix RUB;
+	HklVector hkl;
+	HklVector ki;
+	HklVector Q;
+	HklEngineHkl *engine_hkl = container_of(engine, HklEngineHkl, engine);
+
+	/* update the geometry internals */
+	hkl_geometry_update(geometry);
+
+	/* R * UB */
+	/* for the lisa geometry the holder 1 is the sample holder. */
+	holder = hkl_geometry_sample_holder_get(geometry, sample);
+	hkl_quaternion_to_matrix(&holder->q, &RUB);
+	hkl_matrix_times_matrix(&RUB, &sample->UB);
+
+	/* kf - ki = Q */
+	ki = hkl_geometry_ki_get(geometry);
+
+	Q = hkl_geometry_kf_get(geometry, detector);
+
+	hkl_vector_minus_vector(&Q, &ki);
+
+	/* compute hkl */
+
+	hkl_matrix_solve(&RUB, &hkl, &Q);
+
+	engine_hkl->h->_value = hkl.data[0];
+	engine_hkl->k->_value = hkl.data[1];
+	engine_hkl->l->_value = hkl.data[2];
+
+	return TRUE;
+}
+
+int hkl_mode_hkl_petra3_p08_lisa_set_real(HklMode *self,
+					  HklEngine *engine,
+					  HklGeometry *geometry,
+					  HklDetector *detector,
+					  HklSample *sample,
+					  GError **error)
+{
+/* FRED: to implement */
+/*	int last_axis; */
+
+/*	hkl_error (error == NULL || *error == NULL); */
+
+/*	/\* check the input parameters *\/ */
+/*	if(!hkl_is_reachable(engine, geometry->source.wave_length, */
+/*			     error)){ */
+/*		hkl_assert(error == NULL || *error != NULL); */
+/*		return FALSE; */
+/*	} */
+/*	hkl_assert(error == NULL || *error == NULL); */
+
+/*	/\* compute the mode *\/ */
+/*	if(!hkl_mode_auto_set_real(self, engine, */
+/*				   geometry, detector, sample, */
+/*				   error)){ */
+/*		hkl_assert(error == NULL || *error != NULL); */
+/*		//fprintf(stdout, "message :%s\n", (*error)->message); */
+/*		return FALSE; */
+/*	} */
+/*	hkl_assert(error == NULL || *error == NULL); */
+
+/*	/\* check that the mode allow to move a sample axis *\/ */
+/*	/\* FIXME for now the sample holder is the first one *\/ */
+/*	last_axis = get_last_axis_idx(geometry, 0, &self->info->axes_w); */
+/*	if(last_axis >= 0){ */
+/*		uint i; */
+/*		const HklGeometryListItem *item; */
+/*		uint len = engine->engines->geometries->n_items; */
+
+/*		/\* For each solution already found we will generate another one *\/ */
+/*		/\* using the Ewalds construction by rotating Q around the last sample *\/ */
+/*		/\* axis of the mode until it intersect again the Ewald sphere. *\/ */
+/*		/\* FIXME do not work if ki is colinear with the axis. *\/ */
+
+/*		/\* for this we needs : *\/ */
+/*		/\* - the coordinates of the end of the Q vector (q) *\/ */
+/*		/\* - the last sample axis orientation of the mode (axis_v) *\/ */
+/*		/\* - the coordinates of the center of the ewalds sphere (c) *\/ */
+/*		/\* - the coordinates of the center of rotation of the sample (o = 0, 0, 0) *\/ */
+
+/*		/\* then we can : *\/ */
+/*		/\* - project the origin in plane of normal axis_v containing q (o') *\/ */
+/*		/\* - project the center of the ewalds sphere into the same plan (c') *\/ */
+/*		/\* - rotate q around this (o', c') line of 180° to find the (q2) solution *\/ */
+/*		/\* - compute the (kf2) corresponding to this q2 solution *\/ */
+/*		/\* at the end we just need to solve numerically the position of the detector *\/ */
+
+/*		/\* we will add solution to the geometries so save its length before *\/ */
+/*		for(i=0, item=list_top(&engine->engines->geometries->items, HklGeometryListItem, list); */
+/*		    i<len; */
+/*		    ++i, item=list_next(&engine->engines->geometries->items, item, list)){ */
+/*			int j; */
+/*			HklVector ki; */
+/*			HklVector kf2; */
+/*			HklVector q; */
+/*			HklVector axis_v; */
+/*			HklQuaternion qr; */
+/*			HklAxis *axis; */
+/*			HklVector cp = {{0}}; */
+/*			HklVector op = {{0}}; */
+/*			double angle; */
+/*			HklGeometry *geom; */
+
+/*			geom = hkl_geometry_new_copy(item->geometry); */
+
+/*			/\* get the Q vector kf - ki *\/ */
+/*			hkl_detector_compute_kf(detector, geom, &q); */
+/*			hkl_source_compute_ki(&geom->source, &ki); */
+/*			hkl_vector_minus_vector(&q, &ki); */
+
+/*			/\* compute the current orientation of the last axis *\/ */
+/*			axis = container_of(darray_item(geom->axes, */
+/*							darray_item(geom->holders, 0)->config->idx[last_axis]), */
+/*					    HklAxis, parameter); */
+/*			axis_v = axis->axis_v; */
+/*			hkl_quaternion_init(&qr, 1, 0, 0, 0); */
+/*			for(j=0; j<last_axis; ++j) */
+/*				hkl_quaternion_times_quaternion( */
+/*					&qr, */
+/*					&container_of(darray_item(geom->axes, */
+/*								  darray_item(geom->holders, 0)->config->idx[j]), */
+/*						      HklAxis, parameter)->q); */
+/*			hkl_vector_rotated_quaternion(&axis_v, &qr); */
+
+/*			/\* - project the center of the ewalds sphere into the same plan (c') *\/ */
+/*			hkl_vector_minus_vector(&cp, &ki); */
+/*			hkl_vector_project_on_plan_with_point(&cp, &axis_v, &q); */
+/*			hkl_vector_project_on_plan_with_point(&op, &axis_v, &q); */
+
+/*			/\* - rotate q around this (o', c') line of 180° to find the (q2) solution *\/ */
+/*			kf2 = q; */
+/*			hkl_vector_rotated_around_line(&kf2, M_PI, &cp, &op); */
+/*			angle = hkl_vector_oriented_angle_points(&q, &op, &kf2, &axis_v); */
+/*			/\* TODO parameter list for geometry *\/ */
+/*			if(!hkl_parameter_value_set(&axis->parameter, */
+/*						    hkl_parameter_value_get(&axis->parameter, HKL_UNIT_DEFAULT) + angle, */
+/*						    HKL_UNIT_DEFAULT, error)) */
+/*				return FALSE; */
+/*			hkl_geometry_update(geom); */
+/* #ifdef DEBUG */
+/*			fprintf(stdout, "\n- try to add a solution by rotating Q <%f, %f, %f> around the \"%s\" axis <%f, %f, %f> of %f radian", */
+/*				q.data[0], q.data[1], q.data[2], */
+/*				((HklParameter *)axis)->name, */
+/*				axis_v.data[0], axis_v.data[1], axis_v.data[2], */
+/*				angle); */
+/*			fprintf(stdout, "\n   op: <%f, %f, %f>", op.data[0], op.data[1], op.data[2]); */
+/*			fprintf(stdout, "\n   q2: <%f, %f, %f>", kf2.data[0], kf2.data[1], kf2.data[2]); */
+/* #endif */
+/*			hkl_vector_add_vector(&kf2, &ki); */
+
+/*			/\* at the end we just need to solve numerically the position of the detector *\/ */
+/*			if(fit_detector_position(self, geom, detector, &kf2)) */
+/*				hkl_geometry_list_add(engine->engines->geometries, */
+/*						      geom); */
+
+/*			hkl_geometry_free(geom); */
+/*		} */
+/*	} */
+	return TRUE;
+}
+
+#define HKL_MODE_HKL_PETRA3_P08_LISA_OPERATIONS_DEFAULTS	\
+	HKL_MODE_OPERATIONS_AUTO_DEFAULTS,			\
+		.get = hkl_mode_hkl_petra3_p08_lisa_get_real,	\
+		.set = hkl_mode_hkl_petra3_p08_lisa_set_real
+
+static const HklModeOperations hkl_mode_hkl_petra3_p08_lisa_operations = {
+	HKL_MODE_HKL_PETRA3_P08_LISA_OPERATIONS_DEFAULTS,
+};
+
+static const char* hkl_geometry_petra3_p08_lisa_axes[] = {MCHI, SPHI, DTTH, DH, DROT};
+
+static HklHolder *hkl_geometry_petra3_p08_lisa_sample_holder_get_real(const HklGeometry *geometry,
+								      const HklSample *sample)
+{
+	return darray_item(geometry->holders, PETRA3_P08_LISA_SAMPLE_HOLDER_IDX);
+}
+
+static HklHolder *hkl_geometry_petra3_p08_lisa_detector_holder_get_real(const HklGeometry *geometry,
+									const HklDetector *detector)
+{
+	return darray_item(geometry->holders, PETRA3_P08_LISA_DETECTOR_HOLDER_IDX);
+}
+
+static HklVector hkl_geometry_petra3_p08_lisa_ki_get_real(const HklGeometry *geometry)
+{
+	double alpha_max = _alpha_max(geometry->source.wave_length, D_Si111, D_Si220);
+	HklHolder *holder;
+	HklVector ki = {{cos(alpha_max), 0, -sin(alpha_max)}};
+
+	holder = darray_item(geometry->holders, PETRA3_P08_LISA_SOURCE_HOLDER_IDX);
+	ki = hkl_holder_transformation_apply(holder, &ki);
+	hkl_vector_times_double(&ki, HKL_TAU / geometry->source.wave_length);
+
+	return ki;
+}
+
+static HklVector hkl_geometry_petra3_p08_lisa_kf_get_real(const HklGeometry *geometry,
+							  const HklDetector *detector)
+{
+	HklHolder *holder;
+	HklVector kf = {{D_SD, 0, 0}};
+
+	holder = hkl_geometry_detector_holder_get(geometry, detector);
+	kf = hkl_holder_transformation_apply(holder, &kf);
+	hkl_vector_normalize(&kf);
+	hkl_vector_times_double(&kf, HKL_TAU / geometry->source.wave_length);
+
+	return kf;
+}
+
+#define HKL_GEOMETRY_PETRA3_P08_LISA_OPERATIONS_DEFAULTS		\
+	HKL_GEOMETRY_OPERATIONS_DEFAULTS,				\
+		.sample_holder_get = hkl_geometry_petra3_p08_lisa_sample_holder_get_real, \
+		.detector_holder_get = hkl_geometry_petra3_p08_lisa_detector_holder_get_real, \
+		.ki_get = hkl_geometry_petra3_p08_lisa_ki_get_real,	\
+		.kf_get = hkl_geometry_petra3_p08_lisa_kf_get_real
+
+static HklGeometry *hkl_geometry_new_petra3_p08_lisa(const HklFactory *factory)
+{
+	static HklGeometryOperations ops = {HKL_GEOMETRY_PETRA3_P08_LISA_OPERATIONS_DEFAULTS};
+	HklGeometry *self = hkl_geometry_new(factory, &ops);
+	HklHolder *h;
+
+	/* source */
+	h = hkl_geometry_add_holder(self);
+	hkl_holder_add_rotation(h, MCHI, 1, 0, 0, &hkl_unit_angle_deg);
+
+	/* sample */
+	h = hkl_geometry_add_holder(self);
+	hkl_holder_add_rotation(h, SPHI, 0, 0, 1, &hkl_unit_angle_deg);
+
+	/* detector */
+	h = hkl_geometry_add_holder(self);
+	hkl_holder_add_rotation(h, DTTH, 0, 0, -1, &hkl_unit_angle_deg);
+	hkl_holder_add_translation(h, DH, 0, 0, 1, &hkl_unit_length_mm);
+	hkl_holder_add_rotation_with_origin(h, DROT, 0, -1, 0, D_SD, 0, 0, &hkl_unit_angle_deg);
+
+	return self;
+}
+
+/*********/
+/* Modes */
+/********/
+
+/* hkl modes */
+
+static HklMode *k_parallel_incident(void)
+{
+	/* TODO: check if the axes are correct, add the functions and implement them */
+
+	static const char* axes_r[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const char* axes_w[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const HklFunction *functions[] = {};
+
+	/* here just the description of the mode: name, axes_r, axes_w, functions */
+	static const HklModeAutoInfo info = {
+		HKL_MODE_AUTO_INFO(__func__, axes_r, axes_w, functions),
+	};
+
+	/* instantiate a new mode */
+	return hkl_mode_auto_new(&info,
+				 &hkl_mode_hkl_petra3_p08_lisa_operations,
+				 TRUE);
+
+}
+
+static HklMode *alpha_eq_beta(void)
+{
+	/* TODO: check if the axes are correct, add the functions and implement them */
+
+	static const char* axes_r[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const char* axes_w[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const HklFunction *functions[] = {};
+
+	/* here just the description of the mode: name, axes_r, axes_w, functions */
+	static const HklModeAutoInfo info = {
+		HKL_MODE_AUTO_INFO(__func__, axes_r, axes_w, functions),
+	};
+
+	/* instantiate a new mode */
+	return hkl_mode_auto_new(&info,
+				 &hkl_mode_hkl_petra3_p08_lisa_operations,
+				 TRUE);
+}
+static HklMode *th_eq_tth2(void)
+{
+	/* TODO: check if the axes are correct, add the functions and implement them */
+
+	static const char* axes_r[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const char* axes_w[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const HklFunction *functions[] = {};
+
+	/* here just the description of the mode: name, axes_r, axes_w, functions */
+	static const HklModeAutoInfo info = {
+		HKL_MODE_AUTO_INFO(__func__, axes_r, axes_w, functions),
+	};
+
+	/* instantiate a new mode */
+	return hkl_mode_auto_new(&info,
+				 &hkl_mode_hkl_petra3_p08_lisa_operations,
+				 TRUE);
+}
+static HklMode *k_parallel_outgoing(void)
+{
+	/* TODO: check if the axes are correct, add the functions and implement them */
+
+	static const char* axes_r[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const char* axes_w[] = {MCHI, SPHI, DTTH, DROT};
+
+	static const HklFunction *functions[] = {};
+
+	/* here just the description of the mode: name, axes_r, axes_w, functions */
+	static const HklModeAutoInfo info = {
+		HKL_MODE_AUTO_INFO(__func__, axes_r, axes_w, functions),
+	};
+
+	/* instantiate a new mode */
+	return hkl_mode_auto_new(&info,
+				 &hkl_mode_hkl_petra3_p08_lisa_operations,
+				 TRUE);
+}
+
+/* lisapm modes */
+
+
+static const HklParameter mode_lisa_pm_parameters[] = {
+	{
+		HKL_PARAMETER_DEFAULTS, .name = "det_rot_tracking", ._value = 0,
+		.description = "if 1, the detector table will be rotated with the monochromator, so that stth stays constant",
+		.range = { .min=0, .max=1 },
+	},
+	{
+		HKL_PARAMETER_DEFAULTS, .name = "mchi_rot_dir", ._value = 1,
+		.description = "if 1 mchi angle goes from 0 to pi, if -1 from 0 to -pi",
+		.range = { .min=-1, .max=1 },
+	},
+	{
+		HKL_PARAMETER_DEFAULTS, .name = "sample_rot", ._value = 0,
+		.description = "if 1, the sample will be rotated with the monochromator, so that sth stays constant.",
+		.range = { .min=0, .max=1 },
+	},
+};
+
+static int _mode_lisa_pm_m_to_pm_func(const gsl_vector *x, void *params, gsl_vector *f)
+{
+	/* TODO: implement it */
+
+	return  GSL_SUCCESS;
+}
+
+static const HklFunction mode_lisa_pm_m_to_pm_func = {
+	.function = _mode_lisa_pm_m_to_pm_func,
+	.size = 3,
+};
+
+static int _mode_lisa_pm_pm_to_m_func(const gsl_vector *x, void *params, gsl_vector *f)
+{
+	/* TODO: implement it */
+
+	return  GSL_SUCCESS;
+}
+
+static const HklFunction mode_lisa_pm_pm_to_m_func = {
+	.function = _mode_lisa_pm_pm_to_m_func,
+	.size = 3,
+};
+
+static HklMode *mode_lisa_pm(void)
+{
+
+	static const char* axes_r[] = {MCHI, SPHI, DTTH}; /* QUESTION: these are the two motors I need for computing sth and stth positions, is this right ??? */
+
+	static const char* axes_w[] = {MCHI, SPHI, DTTH}; /* QUESTION: these are the motors I move if I write to the pseudomotor sth or stth, is this right ??? */
+
+
+	/* here a list of functions use to solve the mode */ /* QUESTION: which functions should be here ???, I need one for computing motor positions from pseudomotor and one for computing pseudonmotor from motor positions. Why in the other diffractometers there is only one function here ??? */
+	/* FRED this are not the functions in order to do get and set but only to do the set. the get/set is done in the hkl_mode_operations. */
+	static const HklFunction *functions[] = {&mode_lisa_pm_m_to_pm_func, &mode_lisa_pm_pm_to_m_func};
+
+	/* here just the description of the mode: name, axes_r, axes_w, functions */
+	static const HklModeAutoInfo info = {
+		HKL_MODE_AUTO_INFO_WITH_PARAMS(__func__, axes_r, axes_w, functions, mode_lisa_pm_parameters),
+	};
+
+	/* instantiate a new mode */
+	return hkl_mode_auto_new(&info,
+				 &hkl_mode_operations, /* FRED these operation must be specifique to the pseudo motors look at the read_only emergence pseudo in hkl-pseudoaxis-common-readonly code. */
+				 TRUE);
+}
+
+/******************/
+/* LisaPM Engine */
+/*****************/
+
+struct _HklEngineLisaPM
+{
+	HklEngine engine;
+	HklParameter *sth;
+	HklParameter *stth;
+};
+
+typedef struct _HklEngineLisaPM HklEngineLisaPM;
+
+static void hkl_engine_lisapm_free_real(HklEngine *base)
+{
+	HklEngineLisaPM *self = container_of(base, HklEngineLisaPM, engine);
+	hkl_engine_release(&self->engine);
+	free(self);
+}
+
+HklEngine *hkl_engine_lisa_pm_new(HklEngineList *engines)
+{
+	HklEngineLisaPM *self;
+
+	static const HklParameter sth = {
+		HKL_PARAMETER_DEFAULTS_ANGLE, .name="sth",
+		.description = "angle of the projection of $\\vec{ki}$ in the $xy$ and the sample table rotation",
+	};
+
+	static const HklParameter stth = {
+		HKL_PARAMETER_DEFAULTS_ANGLE, .name="stth",
+		.description = "angle of the projection of $\\vec{ki}$ in the $xy$ and the detector arm",
+	};
+
+	static const HklParameter *pseudo_axes[] = {&sth, &stth};
+	static const HklEngineInfo info = {
+		HKL_ENGINE_INFO("LisaPM",
+				pseudo_axes,
+				HKL_ENGINE_DEPENDENCIES_AXES),
+	};
+	static const HklEngineOperations operations = {
+		HKL_ENGINE_OPERATIONS_DEFAULTS,
+		.free=hkl_engine_lisapm_free_real,
+	};
+
+	self = HKL_MALLOC(HklEngineLisaPM);
+
+	hkl_engine_init(&self->engine, &info, &operations, engines);
+	self->sth = register_pseudo_axis(&self->engine, engines, &sth);
+	self->stth = register_pseudo_axis(&self->engine, engines, &stth);
+
+	return &self->engine;
+
+}
+
+
+
+/***********/
+/* Engines */
+/***********/
+
+static HklEngine *hkl_engine_petra3_p08_lisa_hkl_new(HklEngineList *engines)
+{
+	HklEngine *self;
+	HklMode *default_mode;
+
+	self = hkl_engine_hkl_new(engines);
+
+	default_mode = k_parallel_incident();
+	hkl_engine_add_mode(self, default_mode);
+	hkl_engine_mode_set(self, default_mode);
+
+	hkl_engine_add_mode(self, alpha_eq_beta());
+	hkl_engine_add_mode(self, th_eq_tth2());
+	hkl_engine_add_mode(self, k_parallel_outgoing());
+
+	return self;
+}
+
+static HklEngine *hkl_engine_petra3_p08_lisa_pm_new(HklEngineList *engines)
+{
+	HklEngine *self;
+	HklMode *default_mode;
+
+	self = hkl_engine_lisa_pm_new(engines);
+
+	default_mode = mode_lisa_pm();
+	hkl_engine_add_mode(self, default_mode);
+	hkl_engine_mode_set(self, default_mode);
+
+	return self;
+}
+
+
+/***************/
+/* Engine list */
+/***************/
+
+static HklEngineList *hkl_engine_list_new_petra3_p08_lisa(const HklFactory *factory)
+{
+
+	HklEngineList *self = hkl_engine_list_new();
+
+	hkl_engine_petra3_p08_lisa_hkl_new(self);
+	/* hkl_engine_petra3_p08_lisa_pm_new(self); */
+
+	return self;
+}
+
+/* Register the diffractometer into the factory */
+REGISTER_DIFFRACTOMETER(petra3_p08_lisa, "PETRA3 P08 LISA", HKL_GEOMETRY_PETRA3_P08_LISA_DESCRIPTION);
diff --git a/hkl/hkl-engine-petra3-p09-eh2.c b/hkl/hkl-engine-petra3-p09-eh2.c
index 04d286b..8862fd0 100644
--- a/hkl/hkl-engine-petra3-p09-eh2.c
+++ b/hkl/hkl-engine-petra3-p09-eh2.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -281,19 +281,19 @@ static const char* hkl_geometry_petra3_p09_eh2_axes[] = {MU, OMEGA, CHI, PHI, DE
 
 static HklGeometry *hkl_geometry_new_petra3_p09_eh2(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, CHI, 1, 0, 0);
-	hkl_holder_add_rotation_axis(h, PHI, 0, 0, 1);
+	hkl_holder_add_rotation(h, MU, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, OMEGA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, CHI, 1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, PHI, 0, 0, 1, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, -1, 0);
+	hkl_holder_add_rotation(h, MU, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-soleil-sirius-turret.c b/hkl/hkl-engine-soleil-sirius-turret.c
index aa45c4b..65f5edc 100644
--- a/hkl/hkl-engine-soleil-sirius-turret.c
+++ b/hkl/hkl-engine-soleil-sirius-turret.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -99,19 +99,19 @@ static const char* hkl_geometry_soleil_sirius_turret_axes[] = {BASEPITCH, THETAH
 
 static HklGeometry *hkl_geometry_new_soleil_sirius_turret(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis_with_punit(h, BASEPITCH, 0, 1, 0, &hkl_unit_angle_mrad);
-	hkl_holder_add_rotation_axis(h, THETAH, 0, 0, -1);
-	hkl_holder_add_rotation_axis(h, ALPHAY, 0, 1, 0);
-	hkl_holder_add_rotation_axis(h, ALPHAX, 1, 0, 0);
+	hkl_holder_add_rotation(h, BASEPITCH, 0, 1, 0, &hkl_unit_angle_mrad);
+	hkl_holder_add_rotation(h, THETAH, 0, 0, -1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, ALPHAY, 0, 1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, ALPHAX, 1, 0, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis_with_punit(h, BASEPITCH, 0, 1, 0, &hkl_unit_angle_mrad);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, 0, -1);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, -1, 0);
+	hkl_holder_add_rotation(h, BASEPITCH, 0, 1, 0, &hkl_unit_angle_mrad);
+	hkl_holder_add_rotation(h, DELTA, 0, 0, -1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-soleil-sixs-med.c b/hkl/hkl-engine-soleil-sixs-med.c
index b6bb4b6..cbbc1a5 100644
--- a/hkl/hkl-engine-soleil-sixs-med.c
+++ b/hkl/hkl-engine-soleil-sixs-med.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -181,10 +181,6 @@ static HklEngine *hkl_engine_soleil_sixs_med_1_2_hkl_new(HklEngineList *engines)
 
 /* mode incidence */
 
-static const HklParameter surface_parameters[] = {
-	SURFACE_PARAMETERS(0, 0, 1),
-};
-
 REGISTER_READONLY_INCIDENCE(hkl_engine_soleil_sixs_med_1_2_incidence_new,
 			    P99_PROTECT({PITCH, MU}),
 			    surface_parameters_z);
@@ -416,18 +412,18 @@ static const char* hkl_geometry_soleil_sixs_med_2_2_axes[] = {BETA, MU, OMEGA, G
 
 static HklGeometry *hkl_geometry_new_soleil_sixs_med_2_2(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, BETA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
+	hkl_holder_add_rotation(h, BETA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, BETA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
+	hkl_holder_add_rotation(h, BETA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
@@ -469,16 +465,16 @@ static const char* hkl_geometry_soleil_sixs_med_1_2_axes[] = {PITCH, MU, GAMMA,
 
 static HklGeometry *hkl_geometry_new_soleil_sixs_med_1_2(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, PITCH, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
+	hkl_holder_add_rotation(h, PITCH, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, PITCH, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
+	hkl_holder_add_rotation(h, PITCH, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
@@ -523,19 +519,19 @@ static const char* hkl_geometry_soleil_sixs_med_2_3_axes[] = {BETA, MU, OMEGA, G
 
 static HklGeometry *hkl_geometry_new_soleil_sixs_med_2_3(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, BETA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
+	hkl_holder_add_rotation(h, BETA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, BETA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, ETA_A, -1, 0, 0);
+	hkl_holder_add_rotation(h, BETA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, ETA_A, -1, 0, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-template.c b/hkl/hkl-engine-template.c
index 1799e15..6e9a14a 100644
--- a/hkl/hkl-engine-template.c
+++ b/hkl/hkl-engine-template.c
@@ -14,7 +14,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  * Copyright (C) 2014      XXX copyright owner XXX
@@ -63,18 +63,18 @@ static const char* hkl_geometry_eulerian6C_axes[] = {MU, OMEGA, CHI, PHI, GAMMA,
 
 static HklGeometry *hkl_geometry_new_eulerian6C(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, CHI, 1, 0, 0);
-	hkl_holder_add_rotation_axis(h, PHI, 0, -1, 0);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, CHI, 1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, PHI, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-engine-zaxis.c b/hkl/hkl-engine-zaxis.c
index d417d57..8b4b627 100644
--- a/hkl/hkl-engine-zaxis.c
+++ b/hkl/hkl-engine-zaxis.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -135,17 +135,17 @@ static const char* hkl_geometry_zaxis_axes[] = {MU, OMEGA, DELTA, GAMMA};
 
 static HklGeometry *hkl_geometry_new_zaxis(const HklFactory *factory)
 {
-	HklGeometry *self = hkl_geometry_new(factory);
+	HklGeometry *self = hkl_geometry_new(factory, &hkl_geometry_operations_defaults);
 	HklHolder *h;
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, OMEGA, 0, -1, 0);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, OMEGA, 0, -1, 0, &hkl_unit_angle_deg);
 
 	h = hkl_geometry_add_holder(self);
-	hkl_holder_add_rotation_axis(h, MU, 0, 0, 1);
-	hkl_holder_add_rotation_axis(h, DELTA, 0, -1, 0);
-	hkl_holder_add_rotation_axis(h, GAMMA, 0, 0, 1);
+	hkl_holder_add_rotation(h, MU, 0, 0, 1, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, DELTA, 0, -1, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(h, GAMMA, 0, 0, 1, &hkl_unit_angle_deg);
 
 	return self;
 }
diff --git a/hkl/hkl-factory-private.h b/hkl/hkl-factory-private.h
index 366c78e..701724e 100644
--- a/hkl/hkl-factory-private.h
+++ b/hkl/hkl-factory-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-factory.c b/hkl/hkl-factory.c
index 2370753..9b4abaa 100644
--- a/hkl/hkl-factory.c
+++ b/hkl/hkl-factory.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-geometry-private.h b/hkl/hkl-geometry-private.h
index 6f937b8..66701b3 100644
--- a/hkl/hkl-geometry-private.h
+++ b/hkl/hkl-geometry-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -34,6 +34,9 @@
 
 G_BEGIN_DECLS
 
+#define HKL_HOLDER_SAMPLE_IDX 0
+#define HKL_HOLDER_DETECTOR_IDX 1
+
 typedef struct _HklHolder HklHolder;
 
 typedef void (* HklGeometryListMultiplyFunction) (HklGeometryList *self,
@@ -53,14 +56,68 @@ struct _HklHolder {
 	HklQuaternion q;
 };
 
+typedef struct _HklGeometryOperations HklGeometryOperations;
+
+struct _HklGeometryOperations
+{
+	HklHolder* (*sample_holder_get) (const HklGeometry *self, const HklSample *sample);
+
+	HklHolder* (*detector_holder_get) (const HklGeometry *self, const HklDetector *detector);
+
+	HklVector (*ki_get) (const HklGeometry *geometry);
+
+	HklVector (*kf_get) (const HklGeometry *self, const HklDetector *detector);
+};
+
 struct _HklGeometry
 {
 	const HklFactory *factory;
 	HklSource source;
 	darray_parameter axes;
 	darray_holder holders;
+	const HklGeometryOperations *ops;
 };
 
+static inline HklHolder *hkl_geometry_sample_holder_get_real(const HklGeometry *self,
+							     UNUSED const HklSample *sample)
+{
+	return darray_item(self->holders, HKL_HOLDER_SAMPLE_IDX);
+}
+
+static inline HklHolder *hkl_geometry_detector_holder_get_real(const HklGeometry *self,
+							       UNUSED const HklDetector *detector)
+{
+	return darray_item(self->holders, HKL_HOLDER_DETECTOR_IDX);
+}
+
+static inline HklVector hkl_geometry_ki_get_real(const HklGeometry *self)
+{
+	HklVector ki;
+
+	hkl_source_compute_ki(&self->source, &ki);
+
+	return ki;
+}
+
+static inline HklVector hkl_geometry_kf_get_real(const HklGeometry *self,
+						 UNUSED const HklDetector *detector)
+{
+	HklVector kf = {{HKL_TAU / self->source.wave_length, 0, 0}};
+	HklHolder *detector_holder = darray_item(self->holders, HKL_HOLDER_DETECTOR_IDX);
+
+	hkl_vector_rotated_quaternion(&kf, &detector_holder->q);
+
+	return kf;
+}
+
+#define HKL_GEOMETRY_OPERATIONS_DEFAULTS				\
+	.sample_holder_get = hkl_geometry_sample_holder_get_real,	\
+		.detector_holder_get = hkl_geometry_detector_holder_get_real, \
+		.ki_get = hkl_geometry_ki_get_real,			\
+		.kf_get = hkl_geometry_kf_get_real
+
+extern const HklGeometryOperations hkl_geometry_operations_defaults;
+
 #define HKL_GEOMETRY_ERROR hkl_geometry_error_quark ()
 
 static inline GQuark hkl_geometry_error_quark (void)
@@ -90,17 +147,31 @@ struct _HklGeometryListItem
 /* HklHolder */
 /*************/
 
-extern HklParameter *hkl_holder_add_rotation_axis(HklHolder *self,
-						  char const *name, double x, double y, double z);
+extern HklParameter *hkl_holder_add_rotation(HklHolder *self,
+					     char const *name,
+					     double x, double y, double z,
+					     const HklUnit *punit);
+
+extern HklParameter *hkl_holder_add_rotation_with_origin(HklHolder *self,
+							 const char *name,
+							 double x, double y, double z,
+							 double ox, double oy, double oz,
+							 const HklUnit *punit);
+
+extern HklParameter *hkl_holder_add_translation(HklHolder *self,
+						char const *name,
+						double x, double y, double z,
+						const HklUnit *punit);
+
+extern HklVector hkl_holder_transformation_apply(const HklHolder *self,
+						 const HklVector *v);
 
-extern HklParameter *hkl_holder_add_rotation_axis_with_punit(HklHolder *self,
-							     char const *name, double x, double y, double z,
-							     const HklUnit *punit);
 /***************/
 /* HklGeometry */
 /***************/
 
-extern HklGeometry *hkl_geometry_new(const HklFactory *factory);
+extern HklGeometry *hkl_geometry_new(const HklFactory *factory,
+				     const HklGeometryOperations *ops);
 
 extern int hkl_geometry_init_geometry(HklGeometry *self,
 				      const HklGeometry *src);
@@ -129,6 +200,15 @@ extern int hkl_geometry_is_valid(const HklGeometry *self);
 
 extern int hkl_geometry_is_valid_range(const HklGeometry *self);
 
+extern HklHolder *hkl_geometry_sample_holder_get(const HklGeometry *self, const HklSample *sample);
+
+extern HklHolder *hkl_geometry_detector_holder_get(const HklGeometry *self, const HklDetector *detector);
+
+extern HklVector hkl_geometry_ki_get(const HklGeometry *self);
+
+extern HklVector hkl_geometry_kf_get(const HklGeometry *self,
+				     const HklDetector *detector);
+
 /*******************/
 /* HklGeometryList */
 /*******************/
@@ -137,7 +217,7 @@ extern HklGeometryList *hkl_geometry_list_new(void);
 
 extern HklGeometryList *hkl_geometry_list_new_copy(const HklGeometryList *self);
 
-extern void hkl_geometry_list_add(HklGeometryList *self, HklGeometry *geometry);
+extern void hkl_geometry_list_add(HklGeometryList *self, const HklGeometry *geometry);
 
 extern void hkl_geometry_list_reset(HklGeometryList *self);
 
diff --git a/hkl/hkl-geometry.c b/hkl/hkl-geometry.c
index b75ef0b..0064446 100644
--- a/hkl/hkl-geometry.c
+++ b/hkl/hkl-geometry.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -50,23 +50,20 @@
  * else create a new on and add it to the list.
  * die if try to add an axis with the same name but a different axis_v
  */
-static size_t hkl_geometry_add_rotation(HklGeometry *self,
-					const char *name, const HklVector *axis_v,
-					const HklUnit *punit)
+static size_t hkl_geometry_add_axis(HklGeometry *self, const HklParameter *axis)
 {
 	uint i = 0;
 	HklParameter **parameter;
 
 	/* check if an axis with the same name is on the axis list */
 	darray_foreach(parameter, self->axes){
-		HklAxis *axis = container_of(*parameter, HklAxis, parameter);
-		if(!strcmp((*parameter)->name, name)){
-			if (hkl_vector_cmp(&axis->axis_v,
-					   axis_v)){
-				fprintf(stderr, "can not add two axis with the same name \"%s\" but different axes <%f, %f, %f> != <%f, %f, %f> into an HklAxes.",
-					name,
-					axis->axis_v.data[0], axis->axis_v.data[1], axis->axis_v.data[2],
-					axis_v->data[0], axis_v->data[1], axis_v->data[2]);
+		if(!strcmp((*parameter)->name, axis->name)){
+			if (hkl_parameter_transformation_cmp(*parameter, axis)){
+				fprintf(stderr,
+					"can not add two axis with the same name \"%s\" but not compatible transformation",
+					axis->name);
+				hkl_parameter_fprintf(stderr, *parameter);
+				hkl_parameter_fprintf(stderr, axis);
 				exit(128);
 			}else{
 				return i;
@@ -76,7 +73,7 @@ static size_t hkl_geometry_add_rotation(HklGeometry *self,
 	}
 
 	/* no so create and add it to the list */
-	darray_append(self->axes, hkl_parameter_new_axis(name, axis_v, punit));
+	darray_append(self->axes, hkl_parameter_new_copy(axis));
 
 	return darray_size(self->axes) - 1;
 }
@@ -159,49 +156,112 @@ static void hkl_holder_update(HklHolder *self)
 	size_t i;
 
 	self->q = q0;
-	for(i=0; i<self->config->len; ++i)
-		hkl_quaternion_times_quaternion(&self->q,
-						&container_of(darray_item(self->geometry->axes,
-									  self->config->idx[i]),
-							      HklAxis, parameter)->q);
-}
+	/*
+	 * The initial meaning of hkl_holder_update was to compute the
+	 * global rotation of the holder. The first holder contained
+	 * only centered rotations. Now that we have added also
+	 * translation, we stop this computation at the first non
+	 * rotation axis
+	 *
+	 * The right think to do should be to add an
+	 * HklVector hkl_holder_apply_transformation(const Hklholder, const HklVector *vector)
+	 * for every kind of transformation (translation, rotation, etc...)
+	 */
+	for(i=0; i<self->config->len; ++i){
+		const HklParameter *p;
+		const HklQuaternion *q;
 
-HklParameter *hkl_holder_add_rotation_axis(HklHolder *self,
-					   const char *name, double x, double y, double z)
-{
-	return hkl_holder_add_rotation_axis_with_punit(self, name, x, y, z, &hkl_unit_angle_deg);
+		p = darray_item(self->geometry->axes, self->config->idx[i]);
+		q = hkl_parameter_quaternion_get(p);
+		if(NULL == q)
+			break;
+		else
+			hkl_quaternion_times_quaternion(&self->q, q);
+	}
 }
 
-HklParameter *hkl_holder_add_rotation_axis_with_punit(HklHolder *self,
-						      const char *name, double x, double y, double z,
-						      const HklUnit *punit)
+static HklParameter * hkl_holder_add_axis_if_not_present(const HklHolder *self, int idx)
 {
-	HklParameter *axis = NULL;
-	size_t i, idx;
-	HklVector axis_v;
-
-	axis_v.data[0] = x;
-	axis_v.data[1] = y;
-	axis_v.data[2] = z;
-
-	idx = hkl_geometry_add_rotation(self->geometry, name, &axis_v, punit);
+	size_t i;
+	HklParameter *res = NULL;
 
-	/* check that the axis is not already in the holder */
+	/* check if the axis was already in the geometry */
 	for(i=0; i<self->config->len; i++)
 		if (idx == self->config->idx[i])
 			return NULL;
 
-	axis = darray_item(self->geometry->axes, idx);
+	res = darray_item(self->geometry->axes, idx);
 	self->config->idx = realloc(self->config->idx, sizeof(*self->config->idx) * (self->config->len + 1));
 	self->config->idx[self->config->len++] = idx;
 
-	return axis;
+	return res;
+}
+
+HklParameter *hkl_holder_add_rotation(HklHolder *self,
+				      const char *name,
+				      double x, double y, double z,
+				      const HklUnit *punit)
+{
+	HklVector axis_v = {{x, y, z}};
+	HklParameter *axis = hkl_parameter_new_rotation(name, &axis_v, punit);
+	int idx = hkl_geometry_add_axis(self->geometry, axis);
+	hkl_parameter_free(axis);
+
+	return hkl_holder_add_axis_if_not_present(self, idx);
+}
+
+HklParameter *hkl_holder_add_rotation_with_origin(HklHolder *self,
+						  const char *name,
+						  double x, double y, double z,
+						  double ox, double oy, double oz,
+						  const HklUnit *punit)
+{
+	HklVector axis_v = {{x, y, z}};
+	HklVector origin = {{ox, oy, oz}};
+	HklParameter *axis = hkl_parameter_new_rotation_with_origin(name, &axis_v, &origin, punit);
+	int idx = hkl_geometry_add_axis(self->geometry, axis);
+	hkl_parameter_free(axis);
+
+	return hkl_holder_add_axis_if_not_present(self, idx);
+
+}
+
+
+HklParameter *hkl_holder_add_translation(HklHolder *self,
+					 const char *name,
+					 double x, double y, double z,
+					 const HklUnit *punit)
+{
+	HklVector axis_v = {{x, y, z}};
+	HklParameter *axis = hkl_parameter_new_translation(name, &axis_v, punit);
+	int idx = hkl_geometry_add_axis(self->geometry, axis);
+	hkl_parameter_free(axis);
+
+	return hkl_holder_add_axis_if_not_present(self, idx);
+}
+
+HklVector hkl_holder_transformation_apply(const HklHolder *self,
+					  const HklVector *v)
+{
+	size_t i;
+	HklVector res = *v;
+
+	/* for each axis from the end apply the transformation to the vector */
+	for(i=0;i<self->config->len;i++){
+		HklParameter *p = darray_item(self->geometry->axes,
+					      self->config->idx[self->config->len - 1 - i]);
+		res = hkl_parameter_transformation_apply(p, &res);
+	}
+
+	return res;
 }
 
 /***************/
 /* HklGeometry */
 /***************/
 
+const HklGeometryOperations hkl_geometry_operations_defaults = { HKL_GEOMETRY_OPERATIONS_DEFAULTS };
+
 /**
  * hkl_geometry_new: (skip)
  *
@@ -209,11 +269,13 @@ HklParameter *hkl_holder_add_rotation_axis_with_punit(HklHolder *self,
  *
  * Returns:
  **/
-HklGeometry *hkl_geometry_new(const HklFactory *factory)
+HklGeometry *hkl_geometry_new(const HklFactory *factory,
+			      const HklGeometryOperations *ops)
 {
 	HklGeometry *g = NULL;
 
 	g = HKL_MALLOC(HklGeometry);
+	g->ops = ops;
 
 	g->factory = factory;
 	hkl_source_init(&g->source, 1.54, 1, 0, 0);
@@ -237,13 +299,9 @@ HklGeometry *hkl_geometry_new_copy(const HklGeometry *src)
 	HklParameter **axis;
 	HklHolder **holder;
 
-	if(!src)
-		return self;
-
 	self = HKL_MALLOC(HklGeometry);
 
-	self->factory = src->factory;
-	self->source = src->source;
+	*self = *src;
 
 	/* copy the axes */
 	darray_init(self->axes);
@@ -299,6 +357,7 @@ int hkl_geometry_set(HklGeometry *self, const HklGeometry *src)
 	size_t i;
 
 	hkl_error(self->factory == src->factory);
+	hkl_error(self->ops == src->ops);
 
 	self->source = src->source;
 
@@ -812,7 +871,7 @@ int hkl_geometry_closest_from_geometry_with_range(HklGeometry *self,
 HklQuaternion hkl_geometry_sample_rotation_get(const HklGeometry *self,
 					       const HklSample *sample)
 {
-	return darray_item(self->holders, 0)->q;
+	return hkl_geometry_sample_holder_get(self, sample)->q;
 }
 
 /**
@@ -828,7 +887,7 @@ HklQuaternion hkl_geometry_sample_rotation_get(const HklGeometry *self,
 HklQuaternion hkl_geometry_detector_rotation_get(const HklGeometry *self,
 						 const HklDetector *detector)
 {
-	return darray_item(self->holders, detector->idx)->q;
+	return hkl_geometry_detector_holder_get(self, detector)->q;
 }
 
 
@@ -850,6 +909,29 @@ void hkl_geometry_fprintf(FILE *file, const HklGeometry *self)
 	}
 }
 
+HklHolder *hkl_geometry_sample_holder_get(const HklGeometry *self,
+					  const HklSample *sample)
+{
+	return self->ops->sample_holder_get(self, sample);
+}
+
+HklHolder *hkl_geometry_detector_holder_get(const HklGeometry *self,
+					    const HklDetector *detector)
+{
+	return self->ops->detector_holder_get(self, detector);
+}
+
+HklVector hkl_geometry_ki_get(const HklGeometry *self)
+{
+	return self->ops->ki_get(self);
+}
+
+HklVector hkl_geometry_kf_get(const HklGeometry *self,
+			      const HklDetector *detector)
+{
+	return self->ops->kf_get(self, detector);
+}
+
 /*******************/
 /* HklGeometryList */
 /*******************/
@@ -928,7 +1010,7 @@ void hkl_geometry_list_free(HklGeometryList *self)
  * set the geometry axes and copy it to the right geometries. We do
  * not gives the x len as it is equal to the self->axes_len.
  **/
-void hkl_geometry_list_add(HklGeometryList *self, HklGeometry *geometry)
+void hkl_geometry_list_add(HklGeometryList *self, const HklGeometry *geometry)
 {
 	HklGeometryListItem *item;
 
@@ -1079,22 +1161,13 @@ void hkl_geometry_list_fprintf(FILE *f, const HklGeometryList *self)
 			fprintf(f, "\n%d :", i++);
 			darray_foreach(axis, item->geometry->axes){
 				value = hkl_parameter_value_get(*axis, HKL_UNIT_DEFAULT);
-				if ((*axis)->punit)
-					fprintf(f, " % 18.15f %s", value, (*axis)->punit->repr);
-				else
-					fprintf(f, " % 18.15f", value);
+				fprintf(f, " % 18.15f %s", value, (*axis)->unit->repr);
 
 			}
 			fprintf(f, "\n   ");
 			darray_foreach(axis, item->geometry->axes){
-				value = hkl_parameter_value_get(*axis, HKL_UNIT_DEFAULT);
-				value = gsl_sf_angle_restrict_symm(value);
-				value *= hkl_unit_factor((*axis)->unit,
-							 (*axis)->punit);
-				if ((*axis)->punit)
-					fprintf(f, " % 18.15f %s", value, (*axis)->punit->repr);
-				else
-					fprintf(f, " % 18.15f", value);
+				value = hkl_parameter_value_get(*axis, HKL_UNIT_USER);
+				fprintf(f, " % 18.15f %s", value, (*axis)->punit->repr);
 			}
 			fprintf(f, "\n");
 		}
diff --git a/hkl/hkl-interval-private.h b/hkl/hkl-interval-private.h
index b531910..86ebc0c 100644
--- a/hkl/hkl-interval-private.h
+++ b/hkl/hkl-interval-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-interval.c b/hkl/hkl-interval.c
index f293a71..f939f81 100644
--- a/hkl/hkl-interval.c
+++ b/hkl/hkl-interval.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-lattice-private.h b/hkl/hkl-lattice-private.h
index 18e77b4..cfdfe27 100644
--- a/hkl/hkl-lattice-private.h
+++ b/hkl/hkl-lattice-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-lattice.c b/hkl/hkl-lattice.c
index 53ccecc..00a0af7 100644
--- a/hkl/hkl-lattice.c
+++ b/hkl/hkl-lattice.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -442,7 +442,6 @@ int hkl_lattice_set(HklLattice *self,
  * @gamma: (out caller-allocates):
  *
  * get the lattice parameters
- * Return value: all the parameters
  **/
 void hkl_lattice_get(const HklLattice *self,
 		     double *a, double *b, double *c,
@@ -529,9 +528,6 @@ int hkl_lattice_get_1_B(const HklLattice *self, HklMatrix *B)
 	double e;
 	double f;
 
-	if(!self || !B)
-		return FALSE;
-
 	/*
 	 * first compute the B matrix
 	 * | a b c |
diff --git a/hkl/hkl-macros-private.h b/hkl/hkl-macros-private.h
index 228eb27..7e3a44a 100644
--- a/hkl/hkl-macros-private.h
+++ b/hkl/hkl-macros-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-macros.c b/hkl/hkl-macros.c
index b55fd50..b729a1a 100644
--- a/hkl/hkl-macros.c
+++ b/hkl/hkl-macros.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-matrix-private.h b/hkl/hkl-matrix-private.h
index 0d92b17..ce82b4e 100644
--- a/hkl/hkl-matrix-private.h
+++ b/hkl/hkl-matrix-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-matrix.c b/hkl/hkl-matrix.c
index 45ac146..5e12d44 100644
--- a/hkl/hkl-matrix.c
+++ b/hkl/hkl-matrix.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-parameter-private.h b/hkl/hkl-parameter-private.h
index 82aad0a..706a209 100644
--- a/hkl/hkl-parameter-private.h
+++ b/hkl/hkl-parameter-private.h
@@ -14,7 +14,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -48,7 +48,7 @@ struct _HklParameter {
 	const HklParameterOperations *ops;
 };
 
-#define HKL_PARAMETER_DEFAULTS .name="dummy", .description="no description", .range={.min=0, .max=0}, ._value=0, .unit=NULL, .punit=NULL, .fit=TRUE, .changed=TRUE, .ops = &hkl_parameter_operations_defaults
+#define HKL_PARAMETER_DEFAULTS .name="dummy", .description="no description", .range={.min=-DBL_MAX, .max=DBL_MAX}, ._value=0, .unit=NULL, .punit=NULL, .fit=TRUE, .changed=TRUE, .ops = &hkl_parameter_operations_defaults
 
 #define HKL_PARAMETER_DEFAULTS_ANGLE HKL_PARAMETER_DEFAULTS, .range={.min=-M_PI, .max=M_PI}, .unit = &hkl_unit_angle_rad, .punit = &hkl_unit_angle_deg
 
@@ -83,6 +83,8 @@ struct _HklParameterOperations {
 	void                  (*fprintf)(FILE *f, const HklParameter *self);
 	const HklVector *     (*axis_v_get)(const HklParameter *self);
 	const HklQuaternion * (*quaternion_get)(const HklParameter *self);
+	int                   (*transformation_cmp)(const HklParameter *self, const HklParameter *p2);
+	HklVector             (*transformation_apply)(const HklParameter *self, const HklVector *v);
 };
 
 #define HKL_PARAMETER_OPERATIONS_DEFAULTS				\
@@ -97,7 +99,9 @@ struct _HklParameterOperations {
 		.is_valid_range = hkl_parameter_is_valid_real,		\
 		.fprintf = hkl_parameter_fprintf_real,			\
 		.axis_v_get = hkl_parameter_axis_v_get_real,		\
-		.quaternion_get = hkl_parameter_quaternion_get_real
+		.quaternion_get = hkl_parameter_quaternion_get_real,	\
+		.transformation_cmp = hkl_parameter_transformation_cmp_real, \
+		.transformation_apply = hkl_parameter_transformation_apply_real
 
 static inline HklParameter *hkl_parameter_copy_real(const HklParameter *self)
 {
@@ -203,6 +207,17 @@ static inline const HklQuaternion *hkl_parameter_quaternion_get_real(UNUSED cons
 	return NULL;
 }
 
+static inline int hkl_parameter_transformation_cmp_real(const HklParameter *self, const HklParameter *p2)
+{
+	return self->ops != p2->ops;
+}
+
+static inline HklVector hkl_parameter_transformation_apply_real(UNUSED const HklParameter *self,
+								const HklVector *v)
+{
+	return *v;
+}
+
 static NEEDED HklParameterOperations hkl_parameter_operations_defaults = {
 	HKL_PARAMETER_OPERATIONS_DEFAULTS,
 };
@@ -226,7 +241,13 @@ extern int hkl_parameter_is_valid(const HklParameter *self);
 
 extern int hkl_parameter_is_valid_range(const HklParameter *self);
 
-extern void hkl_parameter_fprintf(FILE *f, HklParameter *self);
+extern void hkl_parameter_fprintf(FILE *f, const HklParameter *self);
+
+extern int hkl_parameter_transformation_cmp(const HklParameter *self,
+					    const HklParameter *p2);
+
+extern HklVector hkl_parameter_transformation_apply(const HklParameter *self,
+						    const HklVector *v);
 
 /********************/
 /* HklParameterList */
diff --git a/hkl/hkl-parameter.c b/hkl/hkl-parameter.c
index 3b78239..d6d655e 100644
--- a/hkl/hkl-parameter.c
+++ b/hkl/hkl-parameter.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -373,7 +373,7 @@ int hkl_parameter_is_valid_range(const HklParameter *self)
  *
  * print into the #FILE f an #HklParameter
  **/
-void hkl_parameter_fprintf(FILE *f, HklParameter *self)
+void hkl_parameter_fprintf(FILE *f, const HklParameter *self)
 {
 	double factor = hkl_unit_factor(self->unit, self->punit);
 	if (self->punit)
@@ -425,3 +425,30 @@ const char *hkl_parameter_description_get(const HklParameter *self)
 {
 	return self->description;
 }
+
+/**
+ * hkl_parameter_transformation_cmp: (skip)
+ * @self: the this ptr
+ * @p2: the second parameter to test with
+ *
+ * Returns: if two parameter transformations are compatibles.
+ *          (0) compatible, (!= 0) not-compatible
+ **/
+int hkl_parameter_transformation_cmp(const HklParameter *self,
+				     const HklParameter *p2)
+{
+	return self->ops->transformation_cmp(self, p2);
+}
+
+/**
+ * hkl_parameter_transformation_apply: (skip)
+ * @self: the this ptr
+ * @v: the #HklVector to transform
+ *
+ * Returns: the transformed #HklVector
+ **/
+HklVector hkl_parameter_transformation_apply(const HklParameter *self,
+					     const HklVector *v)
+{
+	return self->ops->transformation_apply(self, v);
+}
diff --git a/hkl/hkl-pseudoaxis-auto-private.h b/hkl/hkl-pseudoaxis-auto-private.h
index c727e80..83f86c1 100644
--- a/hkl/hkl-pseudoaxis-auto-private.h
+++ b/hkl/hkl-pseudoaxis-auto-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-auto.c b/hkl/hkl-pseudoaxis-auto.c
index 3ed6e8a..08e73b7 100644
--- a/hkl/hkl-pseudoaxis-auto.c
+++ b/hkl/hkl-pseudoaxis-auto.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-eulerians-private.h b/hkl/hkl-pseudoaxis-common-eulerians-private.h
index 48493e8..b79abd5 100644
--- a/hkl/hkl-pseudoaxis-common-eulerians-private.h
+++ b/hkl/hkl-pseudoaxis-common-eulerians-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-eulerians.c b/hkl/hkl-pseudoaxis-common-eulerians.c
index 180aa6e..217bde6 100644
--- a/hkl/hkl-pseudoaxis-common-eulerians.c
+++ b/hkl/hkl-pseudoaxis-common-eulerians.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-hkl-private.h b/hkl/hkl-pseudoaxis-common-hkl-private.h
index 429fafc..0adc02c 100644
--- a/hkl/hkl-pseudoaxis-common-hkl-private.h
+++ b/hkl/hkl-pseudoaxis-common-hkl-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -45,6 +45,8 @@ extern int _emergence_fixed_func(const gsl_vector *x, void *params, gsl_vector *
 extern int RUBh_minus_Q(double const x[], void *params, double f[]);
 extern int _double_diffraction(double const x[], void *params, double f[]);
 
+extern int hkl_is_reachable(HklEngine *engine, double wavelength, GError **error);
+
 extern int hkl_mode_get_hkl_real(HklMode *self,
 				 HklEngine *engine,
 				 HklGeometry *geometry,
diff --git a/hkl/hkl-pseudoaxis-common-hkl.c b/hkl/hkl-pseudoaxis-common-hkl.c
index 0bf032d..33abbdc 100644
--- a/hkl/hkl-pseudoaxis-common-hkl.c
+++ b/hkl/hkl-pseudoaxis-common-hkl.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -41,7 +41,6 @@
 #include "hkl-pseudoaxis-private.h"     // for _HklEngine, _HklMode, etc
 #include "hkl-quaternion-private.h"     // for hkl_quaternion_init, etc
 #include "hkl-sample-private.h"         // for _HklSample
-#include "hkl-source-private.h"         // for hkl_source_compute_ki
 #include "hkl-vector-private.h"         // for HklVector, etc
 #include "hkl.h"                        // for HklEngine, HklGeometry, etc
 #include "hkl/ccan/array_size/array_size.h"  // for ARRAY_SIZE
@@ -81,7 +80,7 @@ static int fit_detector_function(const gsl_vector *x, void *params, gsl_vector *
 
 	hkl_geometry_update(fitp->geometry);
 
-	hkl_detector_compute_kf(fitp->detector, fitp->geometry, &kf);
+	kf = hkl_geometry_kf_get(fitp->geometry, fitp->detector);
 
 	f->data[0] = fabs(fitp->kf0->data[0] - kf.data[0])
 		+ fabs(fitp->kf0->data[1] - kf.data[1])
@@ -105,8 +104,11 @@ static int fit_detector_function(const gsl_vector *x, void *params, gsl_vector *
 }
 
 
-static int fit_detector_position(HklMode *mode, HklGeometry *geometry,
-				 HklDetector *detector, HklVector *kf)
+static int fit_detector_position(HklMode *mode,
+				 HklGeometry *geometry,
+				 HklDetector *detector,
+				 const HklSample *sample,
+				 HklVector *kf)
 {
 	const char **axis_name;
 	HklDetectorFit params;
@@ -117,8 +119,8 @@ static int fit_detector_position(HklMode *mode, HklGeometry *geometry,
 	int status;
 	int res = FALSE;
 	int iter;
-	HklHolder *sample_holder = darray_item(geometry->holders, 0);
-	HklHolder *detector_holder = darray_item(geometry->holders, 1);
+	const HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
+	const HklHolder *detector_holder = hkl_geometry_detector_holder_get(geometry, detector);
 
 	/* fit the detector part to find the position of the detector for a given kf */
 	/* FIXME for now the sample and detector holder are respectively the first and the second one */
@@ -230,21 +232,21 @@ static int fit_detector_position(HklMode *mode, HklGeometry *geometry,
 /* BEWARE, NOT the axis index in the geometry->axes */
 /* which is part of the axis_names of the mode */
 /* return -1 if there is no axes of the mode in the sample part of the geometry */
-static int get_last_axis_idx(HklGeometry *geometry, int holder_idx, const darray_string *axes)
+static int get_last_sample_axis_idx(HklGeometry *geometry, const HklSample *sample,
+				    const darray_string *axes)
 {
 	int last = -1;
 	const char **axis_name;
-	HklHolder *holder;
+	HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
 
-	holder = darray_item(geometry->holders, holder_idx);
 	darray_foreach(axis_name, *axes){
 		size_t i;
 		size_t idx;
 
 		/* FIXME for now the sample holder is the first one */
 		idx = hkl_geometry_get_axis_idx_by_name(geometry, *axis_name);
-		for(i=0; i<holder->config->len; ++i)
-			if(idx == holder->config->idx[i]){
+		for(i=0; i<sample_holder->config->len; ++i)
+			if(idx == sample_holder->config->idx[i]){
 				last = last > (int)i ? last : (int)i;
 				break;
 			}
@@ -253,7 +255,7 @@ static int get_last_axis_idx(HklGeometry *geometry, int holder_idx, const darray
 }
 
 
-static int hkl_is_reachable(HklEngine *engine, double wavelength, GError **error)
+int hkl_is_reachable(HklEngine *engine, double wavelength, GError **error)
 {
 	HklEngineHkl *engine_hkl = container_of(engine, HklEngineHkl, engine);
 	HklVector Hkl = {
@@ -315,20 +317,21 @@ int RUBh_minus_Q(double const x[], void *params, double f[])
 		},
 	};
 	HklVector ki, dQ;
-	HklHolder *sample_holder;
+	HklHolder *sample_holder = hkl_geometry_sample_holder_get(engine->geometry,
+								  engine->sample);
 
 	/* update the workspace from x; */
 	set_geometry_axes(engine, x);
 
 	/* R * UB * h = Q */
 	/* for now the 0 holder is the sample holder. */
-	sample_holder = darray_item(engine->geometry->holders, 0);
 	hkl_matrix_times_vector(&engine->sample->UB, &Hkl);
+	/* Hkl = hkl_holder_transformation_apply(sample_holder, &Hkl); */
 	hkl_vector_rotated_quaternion(&Hkl, &sample_holder->q);
 
 	/* kf - ki = Q */
-	hkl_source_compute_ki(&engine->geometry->source, &ki);
-	hkl_detector_compute_kf(engine->detector, engine->geometry, &dQ);
+	ki = hkl_geometry_ki_get(engine->geometry);
+	dQ = hkl_geometry_kf_get(engine->geometry, engine->detector);
 	hkl_vector_minus_vector(&dQ, &ki);
 
 	hkl_vector_minus_vector(&dQ, &Hkl);
@@ -347,23 +350,22 @@ int hkl_mode_get_hkl_real(HklMode *self,
 			  HklSample *sample,
 			  GError **error)
 {
-	HklHolder *sample_holder;
 	HklMatrix RUB;
 	HklVector hkl, ki, Q;
 	HklEngineHkl *engine_hkl = container_of(engine, HklEngineHkl, engine);
+	HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
 
 	/* update the geometry internals */
 	hkl_geometry_update(geometry);
 
 	/* R * UB */
-	/* for now the 0 holder is the sample holder. */
-	sample_holder = darray_item(geometry->holders, 0);
 	hkl_quaternion_to_matrix(&sample_holder->q, &RUB);
 	hkl_matrix_times_matrix(&RUB, &sample->UB);
 
 	/* kf - ki = Q */
-	hkl_source_compute_ki(&geometry->source, &ki);
-	hkl_detector_compute_kf(detector, geometry, &Q);
+	ki = hkl_geometry_ki_get(geometry);
+
+	Q  = hkl_geometry_kf_get(geometry, detector);
 	hkl_vector_minus_vector(&Q, &ki);
 
 	hkl_matrix_solve(&RUB, &hkl, &Q);
@@ -406,7 +408,7 @@ int hkl_mode_set_hkl_real(HklMode *self,
 
 	/* check that the mode allow to move a sample axis */
 	/* FIXME for now the sample holder is the first one */
-	last_axis = get_last_axis_idx(geometry, 0, &self->info->axes_w);
+	last_axis = get_last_sample_axis_idx(geometry, sample, &self->info->axes_w);
 	if(last_axis >= 0){
 		uint i;
 		const HklGeometryListItem *item;
@@ -444,18 +446,19 @@ int hkl_mode_set_hkl_real(HklMode *self,
 			HklVector cp = {{0}};
 			HklVector op = {{0}};
 			double angle;
-			HklGeometry *geom;
+			HklGeometry *geom = hkl_geometry_new_copy(item->geometry);
+			HklHolder *sample_holder = hkl_geometry_sample_holder_get(geom, sample);
 
 			geom = hkl_geometry_new_copy(item->geometry);
 
 			/* get the Q vector kf - ki */
-			hkl_detector_compute_kf(detector, geom, &q);
-			hkl_source_compute_ki(&geom->source, &ki);
+			ki = hkl_geometry_ki_get(geom);
+			q = hkl_geometry_kf_get(geom, detector);
 			hkl_vector_minus_vector(&q, &ki);
 
 			/* compute the current orientation of the last axis */
 			axis = container_of(darray_item(geom->axes,
-							darray_item(geom->holders, 0)->config->idx[last_axis]),
+							sample_holder->config->idx[last_axis]),
 					    HklAxis, parameter);
 			axis_v = axis->axis_v;
 			hkl_quaternion_init(&qr, 1, 0, 0, 0);
@@ -463,7 +466,7 @@ int hkl_mode_set_hkl_real(HklMode *self,
 				hkl_quaternion_times_quaternion(
 					&qr,
 					&container_of(darray_item(geom->axes,
-								  darray_item(geom->holders, 0)->config->idx[j]),
+								  sample_holder->config->idx[j]),
 						      HklAxis, parameter)->q);
 			hkl_vector_rotated_quaternion(&axis_v, &qr);
 
@@ -494,7 +497,7 @@ int hkl_mode_set_hkl_real(HklMode *self,
 			hkl_vector_add_vector(&kf2, &ki);
 
 			/* at the end we just need to solve numerically the position of the detector */
-			if(fit_detector_position(self, geom, detector, &kf2))
+			if(fit_detector_position(self, geom, detector, sample, &kf2))
 				hkl_geometry_list_add(engine->engines->geometries,
 						      geom);
 
@@ -532,7 +535,8 @@ int _double_diffraction(double const x[], void *params, double f[])
 	HklVector kf2;
 	HklVector ki;
 	HklVector dQ;
-	HklHolder *sample_holder;
+	HklHolder *sample_holder = hkl_geometry_sample_holder_get(engine->geometry,
+								  engine->sample);
 
 	/* update the workspace from x; */
 	set_geometry_axes(engine, x);
@@ -545,13 +549,12 @@ int _double_diffraction(double const x[], void *params, double f[])
 
 	/* R * UB * hkl = Q */
 	/* for now the 0 holder is the sample holder. */
-	sample_holder = darray_item(engine->geometry->holders, 0);
 	hkl_matrix_times_vector(&engine->sample->UB, &hkl);
 	hkl_vector_rotated_quaternion(&hkl, &sample_holder->q);
 
 	/* kf - ki = Q */
-	hkl_source_compute_ki(&engine->geometry->source, &ki);
-	hkl_detector_compute_kf(engine->detector, engine->geometry, &dQ);
+	ki = hkl_geometry_ki_get(engine->geometry);
+	dQ = hkl_geometry_kf_get(engine->geometry, engine->detector);
 	hkl_vector_minus_vector(&dQ, &ki);
 	hkl_vector_minus_vector(&dQ, &hkl);
 
@@ -615,8 +618,8 @@ int _psi_constant_vertical_func(gsl_vector const *x, void *params, gsl_vector *f
 	set_geometry_axes(engine, x->data);
 
 	/* kf - ki = Q */
-	hkl_source_compute_ki(&engine->geometry->source, &ki);
-	hkl_detector_compute_kf(engine->detector, engine->geometry, &kf);
+	ki = hkl_geometry_ki_get(engine->geometry);
+	kf = hkl_geometry_kf_get(engine->geometry, engine->detector);
 	Q = kf;
 	hkl_vector_minus_vector(&Q, &ki);
 
@@ -626,6 +629,8 @@ int _psi_constant_vertical_func(gsl_vector const *x, void *params, gsl_vector *f
 	if(hkl_vector_normalize(&Q)){
 		HklVector hkl;
 		HklVector n;
+		HklHolder *sample_holder = hkl_geometry_sample_holder_get(engine->geometry,
+									  engine->sample);
 
 		/* compute n the intersection of the plan P(kf, ki) and PQ (normal Q) */
 		n = kf;
@@ -634,13 +639,11 @@ int _psi_constant_vertical_func(gsl_vector const *x, void *params, gsl_vector *f
 
 		/* compute the hkl ref position in the laboratory */
 		/* referentiel. The geometry was already updated. */
-		/* FIXME for now the 0 holder is the sample holder. */
 		hkl.data[0] = darray_item(engine->mode->parameters, 0)->_value;
 		hkl.data[1] = darray_item(engine->mode->parameters, 1)->_value;
 		hkl.data[2] = darray_item(engine->mode->parameters, 2)->_value;
 		hkl_matrix_times_vector(&engine->sample->UB, &hkl);
-		hkl_vector_rotated_quaternion(&hkl,
-					      &darray_item(engine->geometry->holders, 0)->q);
+		hkl_vector_rotated_quaternion(&hkl, &sample_holder->q);
 
 		/* project hkl on the plan of normal Q */
 		hkl_vector_project_on_plan(&hkl, &Q);
@@ -686,8 +689,8 @@ int hkl_mode_initialized_set_psi_constant_vertical_real(HklMode *self,
 
 	if(initialized){
 		/* kf - ki = Q */
-		hkl_source_compute_ki(&geometry->source, &ki);
-		hkl_detector_compute_kf(detector, geometry, &kf);
+		ki = hkl_geometry_ki_get(geometry);
+		kf = hkl_geometry_kf_get(geometry, detector);
 		Q = kf;
 		hkl_vector_minus_vector(&Q, &ki);
 
@@ -699,6 +702,8 @@ int hkl_mode_initialized_set_psi_constant_vertical_real(HklMode *self,
 				    "\nplease select a non-null hkl", self->info->name);
 			return FALSE;
 		}else{
+			const HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
+
 			/* needed for a problem of precision */
 			hkl_vector_normalize(&Q);
 
@@ -709,13 +714,11 @@ int hkl_mode_initialized_set_psi_constant_vertical_real(HklMode *self,
 
 			/* compute hkl in the laboratory referentiel */
 			/* the geometry was already updated in the detector compute kf */
-			/* for now the 0 holder is the sample holder */
 			hkl.data[0] = darray_item(self->parameters, 0)->_value;
 			hkl.data[1] = darray_item(self->parameters, 1)->_value;
 			hkl.data[2] = darray_item(self->parameters, 2)->_value;
 			hkl_matrix_times_vector(&sample->UB, &hkl);
-			hkl_vector_rotated_quaternion(&hkl,
-						      &darray_item(geometry->holders, 0)->q);
+			hkl_vector_rotated_quaternion(&hkl, &sample_holder->q);
 
 			/* project hkl on the plan of normal Q */
 			hkl_vector_project_on_plan(&hkl, &Q);
@@ -798,6 +801,7 @@ static int hkl_mode_hkl_emergence_fixed_initialized_set_real(HklMode *self,
 	const HklModeAutoHklEmergenceFixed *mode = container_of(self, HklModeAutoHklEmergenceFixed, parent);
 	HklVector kf;
 	HklVector n = surface(mode);
+	const HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
 
 	/* first check the parameters */
 	if (hkl_vector_is_null(&n)){
@@ -809,9 +813,9 @@ static int hkl_mode_hkl_emergence_fixed_initialized_set_real(HklMode *self,
 	}
 
 	/* compute the orientation of the surface */
-	hkl_vector_rotated_quaternion(&n, &darray_item(geometry->holders, 0)->q);
+	hkl_vector_rotated_quaternion(&n, &sample_holder->q);
 
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	kf = hkl_geometry_kf_get(geometry, detector);
 
 	/* compute emergence and keep it */
 	mode->emergence->_value = _emergence(&n, &kf);
@@ -830,16 +834,18 @@ int _emergence_fixed_func(const gsl_vector *x, void *params, gsl_vector *f)
 							  parent);
 	HklGeometry *geometry = engine->geometry;
 	const HklDetector *detector = engine->detector;
+	const HklSample *sample = engine->sample;
 	HklVector n = surface(mode);
 	HklVector kf;
+	const HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
 
 	CHECK_NAN(x->data, x->size);
 
 	RUBh_minus_Q(x->data, params, f->data);
 
 	/* compute the orientation of the surface */
-	hkl_vector_rotated_quaternion(&n, &darray_item(geometry->holders, 0)->q);
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	hkl_vector_rotated_quaternion(&n, &sample_holder->q);
+	kf = hkl_geometry_kf_get(geometry, detector);
 
 	f->data[3] = expected_emergence(mode) - _emergence(&n, &kf);
 
diff --git a/hkl/hkl-pseudoaxis-common-psi-private.h b/hkl/hkl-pseudoaxis-common-psi-private.h
index 3895794..4e46139 100644
--- a/hkl/hkl-pseudoaxis-common-psi-private.h
+++ b/hkl/hkl-pseudoaxis-common-psi-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-psi.c b/hkl/hkl-pseudoaxis-common-psi.c
index 94cabc2..274e49a 100644
--- a/hkl/hkl-pseudoaxis-common-psi.c
+++ b/hkl/hkl-pseudoaxis-common-psi.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -75,8 +75,8 @@ int _psi_func(const gsl_vector *x, void *params, gsl_vector *f)
 	set_geometry_axes(engine, x->data);
 
 	/* kf - ki = Q */
-	hkl_source_compute_ki(&engine->geometry->source, &ki);
-	hkl_detector_compute_kf(engine->detector, engine->geometry, &kf);
+	ki = hkl_geometry_ki_get(engine->geometry);
+	kf = hkl_geometry_kf_get(engine->geometry, engine->detector);
 	Q = kf;
 	hkl_vector_minus_vector(&Q, &ki);
 	if (hkl_vector_is_null(&Q)){
@@ -87,7 +87,8 @@ int _psi_func(const gsl_vector *x, void *params, gsl_vector *f)
 	}else{
 		/* R * UB */
 		/* for now the 0 holder is the sample holder. */
-		sample_holder = darray_item(engine->geometry->holders, 0);
+		sample_holder = hkl_geometry_sample_holder_get(engine->geometry,
+							       engine->sample);
 		hkl_quaternion_to_matrix(&sample_holder->q, &RUB);
 		hkl_matrix_times_matrix(&RUB, &engine->sample->UB);
 
@@ -142,7 +143,7 @@ static int hkl_mode_initialized_set_psi_real(HklMode *self,
 	HklVector ki;
 	HklMatrix RUB;
 	HklModePsi *psi_mode = container_of(self, HklModePsi, parent);
-	HklHolder *sample_holder;
+	HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
 
 	hkl_error (error == NULL || *error == NULL);
 
@@ -152,13 +153,12 @@ static int hkl_mode_initialized_set_psi_real(HklMode *self,
 
 		/* R * UB */
 		/* for now the 0 holder is the sample holder. */
-		sample_holder = darray_item(geometry->holders, 0);
 		hkl_quaternion_to_matrix(&sample_holder->q, &RUB);
 		hkl_matrix_times_matrix(&RUB, &sample->UB);
 
 		/* kf - ki = Q0 */
-		hkl_source_compute_ki(&geometry->source, &ki);
-		hkl_detector_compute_kf(detector, geometry, &psi_mode->Q0);
+		ki = hkl_geometry_ki_get(geometry);
+		psi_mode->Q0 = hkl_geometry_kf_get(geometry, detector);
 		hkl_vector_minus_vector(&psi_mode->Q0, &ki);
 		if (hkl_vector_is_null(&psi_mode->Q0)){
 			g_set_error(error,
@@ -199,8 +199,8 @@ static int hkl_mode_get_psi_real(HklMode *base,
 	}
 
 	/* get kf, ki and Q */
-	hkl_source_compute_ki(&geometry->source, &ki);
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	ki = hkl_geometry_ki_get(geometry);
+	kf = hkl_geometry_kf_get(geometry, detector);
 	Q = kf;
 	hkl_vector_minus_vector(&Q, &ki);
 	if (hkl_vector_is_null(&Q)){
@@ -210,6 +210,8 @@ static int hkl_mode_get_psi_real(HklMode *base,
 			    "can not compute psi when hkl is null (kf == ki)");
 		return FALSE;
 	}else{
+		HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
+
 		/* needed for a problem of precision */
 		hkl_vector_normalize(&Q);
 
@@ -225,7 +227,7 @@ static int hkl_mode_get_psi_real(HklMode *base,
 			hkl1.data[i] = darray_item(base->parameters, i)->_value;
 
 		hkl_matrix_times_vector(&sample->UB, &hkl1);
-		hkl_vector_rotated_quaternion(&hkl1, &darray_item(geometry->holders, 0)->q);
+		hkl_vector_rotated_quaternion(&hkl1, &sample_holder->q);
 
 		/* project hkl1 on the plan of normal Q */
 		hkl_vector_project_on_plan(&hkl1, &Q);
diff --git a/hkl/hkl-pseudoaxis-common-q-private.h b/hkl/hkl-pseudoaxis-common-q-private.h
index f92b775..564f60f 100644
--- a/hkl/hkl-pseudoaxis-common-q-private.h
+++ b/hkl/hkl-pseudoaxis-common-q-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-q.c b/hkl/hkl-pseudoaxis-common-q.c
index d7c0b8c..b229263 100644
--- a/hkl/hkl-pseudoaxis-common-q.c
+++ b/hkl/hkl-pseudoaxis-common-q.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -101,8 +101,8 @@ static int get_q_real(HklMode *self,
 	HklEngineQ *engine = container_of(base, HklEngineQ, engine);
 
 	wavelength = hkl_source_get_wavelength(&geometry->source);
-	hkl_source_compute_ki(&geometry->source, &ki);
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	ki = hkl_geometry_ki_get(geometry);
+	kf = hkl_geometry_kf_get(geometry, detector);
 	theta = hkl_vector_angle(&ki, &kf) / 2.;
 
 	/* we decide of the sign of theta depending on the orientation
@@ -195,8 +195,8 @@ static void _q2(HklGeometry *geometry, HklDetector *detector,
 	};
 
 	wavelength = hkl_source_get_wavelength(&geometry->source);
-	hkl_source_compute_ki(&geometry->source, &ki);
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	ki = hkl_geometry_ki_get(geometry);
+	kf = hkl_geometry_kf_get(geometry, detector);
 	theta = hkl_vector_angle(&ki, &kf) / 2.;
 
 	*q = qmax(wavelength) * sin(theta);
@@ -205,7 +205,6 @@ static void _q2(HklGeometry *geometry, HklDetector *detector,
 	hkl_vector_project_on_plan(&kf, &x);
 
 	*alpha = atan2(kf.data[2], kf.data[1]);
-
 }
 
 static int _q2_func(const gsl_vector *x, void *params, gsl_vector *f)
@@ -317,10 +316,13 @@ struct _HklEngineQperQpar
 };
 
 static void _qper_qpar(HklEngine *engine,
-		       HklGeometry *geometry, HklDetector *detector,
+		       const HklGeometry *geometry,
+		       const HklDetector *detector,
+		       const HklSample *sample,
 		       double *qper, double *qpar)
 {
 	HklModeQperQpar *mode = container_of(engine->mode, HklModeQperQpar, parent);
+	HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
 	HklVector ki;
 	HklVector q;
 	HklVector n = {
@@ -336,12 +338,12 @@ static void _qper_qpar(HklEngine *engine,
 	double norm;
 
 	/* compute q = kf - ki */
-	hkl_source_compute_ki(&geometry->source, &ki);
-	hkl_detector_compute_kf(detector, geometry, &q);
+	ki = hkl_geometry_ki_get(geometry);
+	q = hkl_geometry_kf_get(geometry, detector);
 	hkl_vector_minus_vector(&q, &ki);
 
 	/* compute the real orientation of the surface n */
-	hkl_vector_rotated_quaternion(&n, &darray_item(geometry->holders, 0)->q);
+	hkl_vector_rotated_quaternion(&n, &sample_holder->q);
 	hkl_vector_normalize(&n);
 
 	/* compute the npar used to define the sign of qpar */
@@ -377,7 +379,7 @@ static int _qper_qpar_func(const gsl_vector *x, void *params, gsl_vector *f)
 	/* update the workspace from x */
 	set_geometry_axes(engine, x->data);
 
-	_qper_qpar(engine, engine->geometry, engine->detector,
+	_qper_qpar(engine, engine->geometry, engine->detector, engine->sample,
 		   &qper, &qpar);
 
 	f->data[0] = engine_qper_qpar->qper->_value - qper;
@@ -400,7 +402,7 @@ static int get_qper_qpar_real(HklMode *self,
 {
 	HklEngineQperQpar *engine_qper_qpar = container_of(engine, HklEngineQperQpar, engine);
 
-	_qper_qpar(engine, geometry, detector,
+	_qper_qpar(engine, geometry, detector, sample,
 		   &engine_qper_qpar->qper->_value,
 		   &engine_qper_qpar->qpar->_value);
 
diff --git a/hkl/hkl-pseudoaxis-common-readonly-private.h b/hkl/hkl-pseudoaxis-common-readonly-private.h
index 0fda1ff..1aa9625 100644
--- a/hkl/hkl-pseudoaxis-common-readonly-private.h
+++ b/hkl/hkl-pseudoaxis-common-readonly-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-readonly.c b/hkl/hkl-pseudoaxis-common-readonly.c
index c6d5a7f..a8dcf94 100644
--- a/hkl/hkl-pseudoaxis-common-readonly.c
+++ b/hkl/hkl-pseudoaxis-common-readonly.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -86,9 +86,10 @@ static int hkl_mode_incidence_get_real(HklMode *base,
 	}
 
 	/* compute the orientation of the surface */
-	hkl_vector_rotated_quaternion(&n, &darray_item(geometry->holders, 0)->q);
+	const HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
+	hkl_vector_rotated_quaternion(&n, &sample_holder->q);
 
-	hkl_source_compute_ki(&geometry->source, &ki);
+	ki = hkl_geometry_ki_get(geometry);
 	incidence = _incidence(&n, &ki);
 
 	hkl_vector_project_on_plan(&n, &ki);
@@ -136,6 +137,13 @@ HklMode *hkl_mode_incidence_new(const HklModeInfo *info)
 	return &self->parent;
 }
 
+static void hkl_engine_incidence_free_real(HklEngine *base)
+{
+	HklEngineIncidence *self=container_of(base, HklEngineIncidence, engine);
+	hkl_engine_release(&self->engine);
+	free(self);
+}
+
 HklEngine *hkl_engine_incidence_new(HklEngineList *engines)
 {
 	HklEngineIncidence *self;
@@ -155,6 +163,7 @@ HklEngine *hkl_engine_incidence_new(HklEngineList *engines)
 	};
 	static HklEngineOperations operations = {
 		HKL_ENGINE_OPERATIONS_DEFAULTS,
+		.free=hkl_engine_incidence_free_real,
 	};
 
 	self = HKL_MALLOC(HklEngineIncidence);
@@ -234,9 +243,10 @@ static int hkl_mode_emergence_get_real(HklMode *base,
 	}
 
 	/* compute the orientation of the surface */
-	hkl_vector_rotated_quaternion(&n, &darray_item(geometry->holders, 0)->q);
+	const HklHolder *sample_holder = hkl_geometry_sample_holder_get(geometry, sample);
+	hkl_vector_rotated_quaternion(&n, &sample_holder->q);
 
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	kf = hkl_geometry_kf_get(geometry, detector);
 	emergence = _emergence(&n, &kf);
 
 	hkl_vector_project_on_plan(&n, &X);
@@ -270,6 +280,13 @@ HklMode *hkl_mode_emergence_new(const HklModeInfo *info)
 	return &self->parent;
 }
 
+static void hkl_engine_emergence_free_real(HklEngine *base)
+{
+	HklEngineEmergence *self=container_of(base, HklEngineEmergence, engine);
+	hkl_engine_release(&self->engine);
+	free(self);
+}
+
 HklEngine *hkl_engine_emergence_new(HklEngineList *engines)
 {
 	HklEngineEmergence *self;
@@ -289,6 +306,8 @@ HklEngine *hkl_engine_emergence_new(HklEngineList *engines)
 	};
 	static HklEngineOperations operations = {
 		HKL_ENGINE_OPERATIONS_DEFAULTS,
+		.free=hkl_engine_emergence_free_real,
+
 	};
 
 	self = HKL_MALLOC(HklEngineEmergence);
diff --git a/hkl/hkl-pseudoaxis-common-tth-private.h b/hkl/hkl-pseudoaxis-common-tth-private.h
index 75b0d72..4c9f5a7 100644
--- a/hkl/hkl-pseudoaxis-common-tth-private.h
+++ b/hkl/hkl-pseudoaxis-common-tth-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-pseudoaxis-common-tth.c b/hkl/hkl-pseudoaxis-common-tth.c
index 4429c82..6de7712 100644
--- a/hkl/hkl-pseudoaxis-common-tth.c
+++ b/hkl/hkl-pseudoaxis-common-tth.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -60,8 +60,8 @@ static void _tth2(HklGeometry *geometry, HklDetector *detector,
 		.data = {1, 0, 0},
 	};
 
-	hkl_source_compute_ki(&geometry->source, &ki);
-	hkl_detector_compute_kf(detector, geometry, &kf);
+	ki = hkl_geometry_ki_get(geometry);
+	kf = hkl_geometry_kf_get(geometry, detector);
 	*tth = hkl_vector_angle(&ki, &kf);
 
 	/* project kf on the x plan to compute alpha */
diff --git a/hkl/hkl-pseudoaxis-private.h b/hkl/hkl-pseudoaxis-private.h
index 42cc5f5..5d43bb3 100644
--- a/hkl/hkl-pseudoaxis-private.h
+++ b/hkl/hkl-pseudoaxis-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -136,13 +136,13 @@ static inline int hkl_mode_initialized_get(const HklMode *self)
 }
 
 
-static inline int hkl_mode_initialized_set_real(HklMode *self,
-						HklEngine *engine,
-						HklGeometry *geometry,
-						HklDetector *detector,
-						HklSample *sample,
-						int initialized,
-						GError **error)
+static inline int hkl_mode_initialized_set_real(UNUSED HklMode *self,
+						UNUSED HklEngine *engine,
+						UNUSED HklGeometry *geometry,
+						UNUSED HklDetector *detector,
+						UNUSED HklSample *sample,
+						UNUSED int initialized,
+						UNUSED GError **error)
 {
 	/* by default do nothing and no error */
 	return TRUE;
@@ -163,24 +163,24 @@ static inline int hkl_mode_initialized_set(HklMode *self,
 }
 
 
-static inline int hkl_mode_get_real(HklMode *self,
-				    HklEngine *engine,
-				    HklGeometry *geometry,
-				    HklDetector *detector,
-				    HklSample *sample,
-				    GError **error)
+static inline int hkl_mode_get_real(UNUSED HklMode *self,
+				    UNUSED HklEngine *engine,
+				    UNUSED HklGeometry *geometry,
+				    UNUSED HklDetector *detector,
+				    UNUSED HklSample *sample,
+				    UNUSED GError **error)
 {
 	/* by default do nothing and no error */
 	return FALSE;
 }
 
 
-static inline int hkl_mode_set_real(HklMode *self,
-				    HklEngine *engine,
-				    HklGeometry *geometry,
-				    HklDetector *detector,
-				    HklSample *sample,
-				    GError **error)
+static inline int hkl_mode_set_real(UNUSED HklMode *self,
+				    UNUSED HklEngine *engine,
+				    UNUSED HklGeometry *geometry,
+				    UNUSED HklDetector *detector,
+				    UNUSED HklSample *sample,
+				    UNUSED GError **error)
 {
 	/* by default do nothing and no error */
 	return FALSE;
@@ -352,7 +352,7 @@ struct _HklEngineOperations
 #define HKL_ENGINE_OPERATIONS_DEFAULTS .free=hkl_engine_free_real
 
 
-static inline void hkl_engine_free_real(HklEngine *self)
+static inline void hkl_engine_free_real(UNUSED HklEngine *self)
 {
 }
 
@@ -646,7 +646,7 @@ static inline HklEngineList *hkl_engine_list_new(void)
  *
  * Returns: (transfer none): NULL all the time the structure is non-copyable
  **/
-static inline const HklEngineList *hkl_engine_list_new_copy(const HklEngineList *self)
+static inline const HklEngineList *hkl_engine_list_new_copy(UNUSED const HklEngineList *self)
 {
 	return NULL;
 }
diff --git a/hkl/hkl-pseudoaxis.c b/hkl/hkl-pseudoaxis.c
index f78e40c..d520418 100644
--- a/hkl/hkl-pseudoaxis.c
+++ b/hkl/hkl-pseudoaxis.c
@@ -14,7 +14,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -192,8 +192,8 @@ HklGeometryList *hkl_engine_pseudo_axis_values_set(HklEngine *self,
 		fprintf(stream, " %f", values[i]);
 	fprintf(stream, "], n_values: %d unit_type: %d, error: %p)", n_values, unit_type, error);
 
-	hkl_geometry_fprintf(stream, self->geometry);
-	hkl_sample_fprintf(stream, self->sample);
+	hkl_geometry_fprintf(stream, self->engines->geometry);
+	hkl_sample_fprintf(stream, self->engines->sample);
 	hkl_engine_fprintf(stream, self);
 #endif
 	for(size_t i=0; i<n_values; ++i){
@@ -362,8 +362,6 @@ const darray_string *hkl_engine_parameters_names_get(const HklEngine *self)
  * @unit_type: the unit type (default or user) of the returned value
  *
  * Get the engine parameters values
- *
- * return value: TRUE if succeded or FALSE otherwise.
  **/
 void hkl_engine_parameters_values_get(const HklEngine *self,
 				      double values[], size_t n_values,
diff --git a/hkl/hkl-quaternion-private.h b/hkl/hkl-quaternion-private.h
index 900be6b..0754094 100644
--- a/hkl/hkl-quaternion-private.h
+++ b/hkl/hkl-quaternion-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-quaternion.c b/hkl/hkl-quaternion.c
index 170f712..d24b630 100644
--- a/hkl/hkl-quaternion.c
+++ b/hkl/hkl-quaternion.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-sample-private.h b/hkl/hkl-sample-private.h
index 59c5b64..8409e67 100644
--- a/hkl/hkl-sample-private.h
+++ b/hkl/hkl-sample-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -69,6 +69,7 @@ extern void hkl_sample_fprintf(FILE *f, const HklSample *self);
 struct _HklSampleReflection {
 	HklGeometry *geometry;
 	HklDetector *detector;
+	HklSample *sample;
 	HklVector hkl;
 	HklVector _hkl;
 	int flag;
diff --git a/hkl/hkl-sample.c b/hkl/hkl-sample.c
index 5b93dae..ef9e9cd 100644
--- a/hkl/hkl-sample.c
+++ b/hkl/hkl-sample.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -99,6 +99,10 @@ static void hkl_sample_reflection_update(HklSampleReflection *self)
 {
 	HklVector ki;
 	HklQuaternion q;
+	const HklHolder *sample_holder = hkl_geometry_sample_holder_get(self->geometry,
+									self->sample);
+	const HklHolder *detector_holder = hkl_geometry_detector_holder_get(self->geometry,
+									    self->detector);
 
 	if(!self)
 		return;
@@ -107,11 +111,10 @@ static void hkl_sample_reflection_update(HklSampleReflection *self)
 	/* first Q from angles */
 	hkl_source_compute_ki(&self->geometry->source, &ki);
 	self->_hkl = ki;
-	hkl_vector_rotated_quaternion(&self->_hkl,
-				      &darray_item(self->geometry->holders, self->detector->idx)->q);
+	hkl_vector_rotated_quaternion(&self->_hkl, &detector_holder->q);
 	hkl_vector_minus_vector(&self->_hkl, &ki);
 
-	q = darray_item(self->geometry->holders, 0)->q;
+	q = sample_holder->q;
 	hkl_quaternion_conjugate(&q);
 	hkl_vector_rotated_quaternion(&self->_hkl, &q);
 }
@@ -334,10 +337,6 @@ HklSample* hkl_sample_new(const char *name)
 {
 	HklSample *self = NULL;
 
-	/* check parameters */
-	if(!name)
-		return self;
-
 	self = HKL_MALLOC(HklSample);
 
 	self->name = strdup(name);
@@ -380,10 +379,6 @@ HklSample *hkl_sample_new_copy(const HklSample *self)
 {
 	HklSample *dup = NULL;
 
-	/* check parameters */
-	if(!self)
-		return dup;
-
 	dup = HKL_MALLOC(HklSample);
 
 	dup->name = strdup(self->name);
@@ -407,9 +402,6 @@ HklSample *hkl_sample_new_copy(const HklSample *self)
  **/
 void hkl_sample_free(HklSample *self)
 {
-	if (!self)
-		return;
-
 	free(self->name);
 	hkl_lattice_free(self->lattice);
 	hkl_parameter_free(self->ux);
@@ -705,6 +697,9 @@ void hkl_sample_add_reflection(HklSample *self,
 			return;
 	}
 
+	reflection->sample = self;
+	hkl_sample_reflection_update(reflection);
+
 	list_add_tail(&self->reflections, &reflection->list);
 	self->n_reflections++;
 }
@@ -915,22 +910,18 @@ HklSampleReflection *hkl_sample_reflection_new(const HklGeometry *geometry,
 					       double h, double k, double l,
 					       GError **error)
 {
-	HklSampleReflection *self;
-
-	if (!geometry || !detector)
-		return NULL;
+	HklSampleReflection *self = NULL;
 
 	self = HKL_MALLOC(HklSampleReflection);
 
 	self->geometry = hkl_geometry_new_copy(geometry);
 	self->detector = hkl_detector_new_copy(detector);
+	self->sample = NULL;
 	self->hkl.data[0] = h;
 	self->hkl.data[1] = k;
 	self->hkl.data[2] = l;
 	self->flag = TRUE;
 
-	hkl_sample_reflection_update(self);
-
 	return self;
 }
 
diff --git a/hkl/hkl-source-private.h b/hkl/hkl-source-private.h
index 41723cd..add73b8 100644
--- a/hkl/hkl-source-private.h
+++ b/hkl/hkl-source-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-source.c b/hkl/hkl-source.c
index ace78a3..3d294e8 100644
--- a/hkl/hkl-source.c
+++ b/hkl/hkl-source.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-trajectory-private.h b/hkl/hkl-trajectory-private.h
new file mode 100644
index 0000000..55b3033
--- /dev/null
+++ b/hkl/hkl-trajectory-private.h
@@ -0,0 +1,61 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ */
+#include "hkl.h"
+
+/* HklTrajectoryResult */
+
+typedef darray(HklGeometry *) darray_geometry;
+
+typedef struct _HklTrajectoryResult HklTrajectoryResult;
+
+struct _HklTrajectoryResult {
+	darray_geometry geometries;
+};
+
+extern HklTrajectoryResult * hkl_trajectory_result_new(void);
+
+extern void hkl_trajectory_result_free(HklTrajectoryResult *self);
+
+extern void hkl_trajectory_add_geometry(HklTrajectoryResult *self, const HklGeometry *geometry);
+
+/* HklTrajectoryStats */
+
+typedef darray(double) darray_double;
+typedef darray(size_t) darray_sizet;
+
+typedef struct _HklTrajectoryStats HklTrajectoryStats;
+
+struct _HklTrajectoryStats {
+	size_t n;
+	darray_sizet nb_solutions;
+	darray_double axes_min;
+	darray_double axes_max;
+	darray_double axes_range;
+};
+
+extern HklTrajectoryStats *hkl_trajectory_stats_new(int n);
+
+extern void hkl_trajectory_stats_free(HklTrajectoryStats *self);
+
+extern void hkl_trajectory_stats_add(HklTrajectoryStats *self, const HklGeometryList *geometries);
+
+extern void hkl_trajectory_stats_fprintf(FILE *f, const HklTrajectoryStats *self);
diff --git a/hkl/hkl-trajectory.c b/hkl/hkl-trajectory.c
new file mode 100644
index 0000000..268ac31
--- /dev/null
+++ b/hkl/hkl-trajectory.c
@@ -0,0 +1,139 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ */
+
+#include "hkl-macros-private.h"
+#include "hkl-trajectory-private.h"
+
+HklTrajectoryResult * hkl_trajectory_result_new(void)
+{
+	HklTrajectoryResult *self = HKL_MALLOC(HklTrajectoryResult);
+
+	darray_init(self->geometries);
+
+	return self;
+}
+
+void hkl_trajectory_result_free(HklTrajectoryResult *self)
+{
+	HklGeometry **geometry;
+
+	darray_foreach(geometry, self->geometries){
+		hkl_geometry_free(*geometry);
+	}
+	darray_free(self->geometries);
+}
+
+void hkl_trajectory_add_geometry(HklTrajectoryResult *self, const HklGeometry *geometry)
+{
+	darray_append(self->geometries, hkl_geometry_new_copy(geometry));
+}
+
+/* HklTrajectoryStats */
+
+HklTrajectoryStats *hkl_trajectory_stats_new(int n)
+{
+	HklTrajectoryStats *self = HKL_MALLOC(HklTrajectoryStats);
+
+	self->n = 0;
+	darray_init(self->nb_solutions);
+	darray_init(self->axes_min);
+	darray_init(self->axes_max);
+	darray_init(self->axes_range);
+	darray_resize0(self->axes_range, n);
+
+	return self;
+}
+
+void hkl_trajectory_stats_free(HklTrajectoryStats *self)
+{
+	darray_free(self->axes_range);
+	darray_free(self->axes_max);
+	darray_free(self->axes_min);
+	darray_free(self->nb_solutions);
+	free(self);
+}
+
+void hkl_trajectory_stats_add(HklTrajectoryStats *self, const HklGeometryList *geometries)
+{
+	size_t i;
+
+	const HklGeometryListItem *item = hkl_geometry_list_items_first_get(geometries);
+	const HklGeometry *geometry = hkl_geometry_list_item_geometry_get(item);
+	size_t n = darray_size(*hkl_geometry_axis_names_get(geometry));
+
+	darray_append(self->nb_solutions, hkl_geometry_list_n_items_get(geometries));
+
+	if(self->n == 0){
+		darray_resize(self->axes_min, n);
+		darray_resize(self->axes_max, n);
+		darray_resize(self->axes_range, n);
+
+		hkl_geometry_axis_values_get(geometry,
+					     &darray_item(self->axes_min, 0), n,
+					     HKL_UNIT_USER);
+		hkl_geometry_axis_values_get(geometry,
+					     &darray_item(self->axes_max, 0), n,
+					     HKL_UNIT_USER);
+	}else{
+		double values[n];
+
+		hkl_geometry_axis_values_get(geometry, values, n, HKL_UNIT_USER);
+		for(i=0; i<n; ++i){
+			if (values[i] < darray_item(self->axes_min, i))
+				darray_item(self->axes_min, i) = values[i];
+			else if (values[i] > darray_item(self->axes_max, i))
+				darray_item(self->axes_max, i) = values[i];
+		}
+	}
+	for(i=0;i<n;++i)
+		darray_item(self->axes_range, i) = darray_item(self->axes_max, i) - darray_item(self->axes_min, i);
+
+	self->n += 1;
+}
+
+void hkl_trajectory_stats_fprintf(FILE *f, const HklTrajectoryStats *self)
+{
+	size_t *p;
+	double *v;
+
+	fprintf(f, "Number of points of the trajectory: %d\n", self->n);
+	fprintf(f, "Solutions per points:");
+	darray_foreach(p, self->nb_solutions){
+		fprintf(f, " %d", *p);
+	}
+	fprintf(f, "\n");
+	fprintf(f, "Axes minium:");
+	darray_foreach(v, self->axes_min){
+		fprintf(f, " %f", *v);
+	}
+	fprintf(f, "\n");
+	fprintf(f, "Axes max:");
+	darray_foreach(v, self->axes_max){
+		fprintf(f, " %f", *v);
+	}
+	fprintf(f, "\n");
+	fprintf(f, "Axes range:");
+	darray_foreach(v, self->axes_range){
+		fprintf(f, " %f", *v);
+	}
+	fprintf(f, "\n");
+}
diff --git a/hkl/hkl-type-builtins.c b/hkl/hkl-type-builtins.c
index 2012861..0130e4b 100644
--- a/hkl/hkl-type-builtins.c
+++ b/hkl/hkl-type-builtins.c
@@ -21,7 +21,6 @@ hkl_unit_enum_get_type (void)
     }
     return etype;
 }
-
 GType
 hkl_detector_type_get_type (void)
 {
@@ -35,7 +34,6 @@ hkl_detector_type_get_type (void)
     }
     return etype;
 }
-
 GType
 hkl_engine_capabilities_get_type (void)
 {
@@ -51,7 +49,6 @@ hkl_engine_capabilities_get_type (void)
     }
     return etype;
 }
-
 GType
 hkl_engine_axis_names_get_get_type (void)
 {
@@ -66,7 +63,6 @@ hkl_engine_axis_names_get_get_type (void)
     }
     return etype;
 }
-
 GType
 hkl_engine_dependencies_get_type (void)
 {
@@ -82,7 +78,6 @@ hkl_engine_dependencies_get_type (void)
     }
     return etype;
 }
-
 #define __HKL_TYPE_BUILTINS_C__
 
 /* Generated data ends here */
diff --git a/hkl/hkl-types.c b/hkl/hkl-types.c
index 557ffe7..2fe68e5 100644
--- a/hkl/hkl-types.c
+++ b/hkl/hkl-types.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2011-2016 Synchrotron SOLEIL
+ * Copyright (C) 2011-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-types.h b/hkl/hkl-types.h
index da3e242..cbdea28 100644
--- a/hkl/hkl-types.h
+++ b/hkl/hkl-types.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-unit-private.h b/hkl/hkl-unit-private.h
index 26157df..9fde99a 100644
--- a/hkl/hkl-unit-private.h
+++ b/hkl/hkl-unit-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -26,34 +26,45 @@
 
 G_BEGIN_DECLS
 
-typedef struct _HklUnit HklUnit;
+typedef struct _HklUnitDimension HklUnitDimension;
 
-typedef enum _HklUnitType /*< unit,prefix=HKL >*/
+struct _HklUnitDimension
 {
-	HKL_UNIT_ANGLE_DEG,
-	HKL_UNIT_ANGLE_RAD,
-	HKL_UNIT_LENGTH_NM,
-	HKL_UNIT_ANGLE_MRAD,
-} HklUnitType;
+	int l; /* Length */
+	int m; /* Mass */
+	int t; /* Time */
+	int i; /* Electric current */
+	int th; /* Thermodynamic temperature */
+	int n; /* Amount of substance */
+	int j; /* Luminous intensity */
+};
+
+#define HklDPlaneAngle {0, 0, 0, 0, 0, 0, 0}
+#define HklDLength {1, 0, 0, 0, 0, 0, 0}
+
+typedef struct _HklUnit HklUnit;
 
 struct _HklUnit
 {
-	HklUnitType type;
+	HklUnitDimension dimension;
+	double factor;
 	char const *name;
 	char const *repr;
 };
 
-static HklUnit const hkl_unit_angle_deg = {HKL_UNIT_ANGLE_DEG, "Degree", "°"};
-static HklUnit const hkl_unit_angle_rad = {HKL_UNIT_ANGLE_RAD, "Radian", "rad"};
-static HklUnit const hkl_unit_length_nm = {HKL_UNIT_LENGTH_NM, "NanoMeter", "nm"};
-static HklUnit const hkl_unit_angle_mrad = {HKL_UNIT_ANGLE_MRAD, "Milli Radian", "mrad"};
+static HklUnit const hkl_unit_angle_deg = {HklDPlaneAngle, M_PI/180., "Degree", "°"};
+static HklUnit const hkl_unit_angle_rad = {HklDPlaneAngle, 1., "Radian", "rad"};
+static HklUnit const hkl_unit_length_nm = {HklDLength, 1e-9, "Nano Meter", "nm"};
+static HklUnit const hkl_unit_angle_mrad = {HklDPlaneAngle, 1e-3, "Milli Radian", "mrad"};
+static HklUnit const hkl_unit_length_mm = {HklDLength, 1e-3, "Milli Meter", "mm"};
+static HklUnit const hkl_unit_length_meter = {HklDLength, 1., "Meter", "m"};
 
 extern HklUnit *hkl_unit_dup(const HklUnit *self);
 extern void hkl_unit_free(HklUnit *self);
 
-extern int hkl_unit_compatible(const HklUnit *self, const HklUnit *unit);
+extern int hkl_unit_compatible(const HklUnit *unit1, const HklUnit *unit2);
 
-extern double hkl_unit_factor(const HklUnit *self, const HklUnit *unit);
+extern double hkl_unit_factor(const HklUnit *from, const HklUnit *to);
 
 G_END_DECLS
 
diff --git a/hkl/hkl-unit.c b/hkl/hkl-unit.c
index c2ad01a..f5b0f86 100644
--- a/hkl/hkl-unit.c
+++ b/hkl/hkl-unit.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -67,53 +67,27 @@ void hkl_unit_free(HklUnit *self)
  *
  * Returns: TRUE or FALSE
  **/
-int hkl_unit_compatible(const HklUnit *self, const HklUnit *unit)
+int hkl_unit_compatible(const HklUnit *unit1, const HklUnit *unit2)
 {
-	int res = TRUE;
-	if (self && unit){
-		switch(self->type){
-		case HKL_UNIT_ANGLE_DEG:
-			switch(unit->type){
-			case HKL_UNIT_ANGLE_DEG:
-			case HKL_UNIT_ANGLE_RAD:
-			case HKL_UNIT_ANGLE_MRAD:
-				break;
-			default:
-				res = FALSE;
-				break;
-			}
-			break;
-		case HKL_UNIT_ANGLE_RAD:
-			switch(unit->type){
-			case HKL_UNIT_ANGLE_DEG:
-			case HKL_UNIT_ANGLE_RAD:
-			case HKL_UNIT_ANGLE_MRAD:
-				break;
-			default:
-				res = FALSE;
-				break;
-			}
-			break;
-		case HKL_UNIT_LENGTH_NM:
-			switch(unit->type){
-			case HKL_UNIT_LENGTH_NM:
-				break;
-			default:
-				res = FALSE;
-				break;
-			}
-			break;
-		case HKL_UNIT_ANGLE_MRAD:
-			switch(unit->type){
-			case HKL_UNIT_ANGLE_DEG:
-			case HKL_UNIT_ANGLE_RAD:
-			case HKL_UNIT_ANGLE_MRAD:
-				break;
-			default:
-				res = FALSE;
-				break;
-			}
-			break;
+	int res = FALSE;
+
+	if (unit1 == NULL) {
+		if (unit2 == NULL) {
+			res = TRUE;
+		}else{
+			res = FALSE;
+		}
+	}else{
+		if (unit2 == NULL){
+			res = FALSE;
+		}else{
+			res = ( (unit1->dimension.l == unit2->dimension.l)
+				&& (unit1->dimension.m == unit2->dimension.m)
+				&& (unit1->dimension.t == unit2->dimension.t)
+				&& (unit1->dimension.i == unit2->dimension.i)
+				&& (unit1->dimension.th == unit2->dimension.th)
+				&& (unit1->dimension.n == unit2->dimension.n)
+				&& (unit1->dimension.j == unit2->dimension.j));
 		}
 	}
 	return res;
@@ -129,67 +103,23 @@ int hkl_unit_compatible(const HklUnit *self, const HklUnit *unit)
  *
  * Returns: the factor of the conversion.
  **/
-double hkl_unit_factor(const HklUnit *self, const HklUnit *unit)
+double hkl_unit_factor(const HklUnit *from, const HklUnit *to)
 {
-	double factor = 1.;
+	double res = 1.0;
 
-	if (self && unit){
-		switch(self->type){
-		case HKL_UNIT_ANGLE_DEG:
-			switch(unit->type){
-			case HKL_UNIT_ANGLE_DEG:
-				break;
-			case HKL_UNIT_ANGLE_RAD:
-				factor = HKL_DEGTORAD;
-				break;
-			case HKL_UNIT_ANGLE_MRAD:
-				factor = HKL_DEGTORAD * 1e3;
-				break;
-			default:
-				factor = GSL_NAN;
-				break;
-			}
-			break;
-		case HKL_UNIT_ANGLE_RAD:
-			switch(unit->type){
-			case HKL_UNIT_ANGLE_DEG:
-				factor = HKL_RADTODEG;
-				break;
-			case HKL_UNIT_ANGLE_RAD:
-				break;
-			case HKL_UNIT_ANGLE_MRAD:
-				factor = 1e3;
-				break;
-			default:
-				factor = GSL_NAN;
-				break;
-			}
-			break;
-		case HKL_UNIT_LENGTH_NM:
-			switch(unit->type){
-			case HKL_UNIT_LENGTH_NM:
-				break;
-			default:
-				factor = GSL_NAN;
-				break;
-			}
-			break;
-		case HKL_UNIT_ANGLE_MRAD:
-			switch(unit->type){
-			case HKL_UNIT_ANGLE_DEG:
-				factor = 1e-3 * HKL_RADTODEG;
-				break;
-			case HKL_UNIT_ANGLE_RAD:
-				factor = 1e-3;
-				break;
-			case HKL_UNIT_ANGLE_MRAD:
-				break;
-			default:
-				factor = GSL_NAN;
-				break;
-			}
-			break;
+	if (from == NULL) {
+		if (to == NULL) {
+			res = 1.0;
+		}else{
+			res = 1.0 / to->factor;
+		}
+	}else{
+		if (to == NULL){
+			res = from->factor;
+		}else{
+			res = from->factor / to->factor;
 		}
 	}
-	return factor;
+
+	return res;
 }
diff --git a/hkl/hkl-vector-private.h b/hkl/hkl-vector-private.h
index 736a52a..b9d7dda 100644
--- a/hkl/hkl-vector-private.h
+++ b/hkl/hkl-vector-private.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl/hkl-vector.c b/hkl/hkl-vector.c
index 329a74d..dfe9e8a 100644
--- a/hkl/hkl-vector.c
+++ b/hkl/hkl-vector.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/hkl3d/Makefile.in b/hkl3d/Makefile.in
index 8b6a16f..12d779e 100644
--- a/hkl3d/Makefile.in
+++ b/hkl3d/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -219,6 +219,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/hkl3d/hkl3d.cpp b/hkl3d/hkl3d.cpp
index de0d79e..46fc5b7 100644
--- a/hkl3d/hkl3d.cpp
+++ b/hkl3d/hkl3d.cpp
@@ -51,7 +51,6 @@
 /***************/
 /* static part */
 /***************/
-
 static float identity[] = {1, 0, 0, 0,
 			   0, 1, 0, 0,
 			   0, 0, 1 ,0,
@@ -712,9 +711,6 @@ Hkl3D *hkl3d_new(const char *filename, HklGeometry *geometry)
 
 void hkl3d_free(Hkl3D *self)
 {
-	if(!self)
-		return;
-
 	/* remove all objects from the collision world */
 	for(size_t i=0; i<self->config->len; ++i)
 		for(size_t j=0; j<self->config->models[i]->len; ++j)
@@ -1122,9 +1118,6 @@ void hkl3d_hide_object(Hkl3D *self, Hkl3DObject *object, int hide)
 /* remove an object from the model */
 void hkl3d_remove_object(Hkl3D *self, Hkl3DObject *object)
 {
-	if(!self || !object)
-		return;
-
 	hkl3d_hide_object(self, object, TRUE);
 	hkl3d_axis_detach_object(object->axis, object);
 
@@ -1133,28 +1126,6 @@ void hkl3d_remove_object(Hkl3D *self, Hkl3DObject *object)
 	hkl3d_model_delete_object(object->model, object);
 }
 
-/* use for the transparency of colliding objects */
-struct ContactSensorCallback : public btCollisionWorld::ContactResultCallback
-{
-	ContactSensorCallback(Hkl3DObject *object)
-		: btCollisionWorld::ContactResultCallback(),
-		  collisionObject(object->btObject),
-		  object(object)
-		{ }
-
-	btCollisionObject *collisionObject;
-	Hkl3DObject *object;
-
-	virtual btScalar addSingleResult(btManifoldPoint & cp,
-					 const btCollisionObjectWrapper *colObj0, int partId0, int index0,
-					 const btCollisionObjectWrapper *colObj1, int partId1, int index1)
-		{
-			if(colObj0->m_collisionObject == collisionObject
-			   || colObj1->m_collisionObject == collisionObject)
-				object->is_colliding = TRUE;
-			return 0;
-		}
-};
 
 int hkl3d_is_colliding(Hkl3D *self)
 {
@@ -1173,20 +1144,20 @@ int hkl3d_is_colliding(Hkl3D *self)
 	gettimeofday(&fin, NULL);
 	timersub(&fin, &debut, &self->stats.collision);
 
-	numManifolds = self->_btWorld->getDispatcher()->getNumManifolds();
-
-	/* reset all the collisions */
-	for(size_t i=0; i<self->config->len; i++)
-		for(size_t j=0; j<self->config->models[i]->len; j++)
-			self->config->models[i]->objects[j]->is_colliding = FALSE;
+	numManifolds = self->_btDispatcher->getNumManifolds();
 
-	/* check all the collisions */
-	for(size_t i=0; i<self->config->len; i++)
+	/* update Hkl3DObject collision from manifolds */
+	for(size_t i=0; i<self->config->len; i++){
 		for(size_t j=0; j<self->config->models[i]->len; j++){
 			Hkl3DObject *object = self->config->models[i]->objects[j];
-			ContactSensorCallback callback(object);
-			self->_btWorld->contactTest(object->btObject, callback);
+			object->is_colliding = FALSE;
+			for(int k=0; k<numManifolds; ++k){
+				btPersistentManifold *manifold = self->_btDispatcher->getManifoldByIndexInternal(k);
+				object->is_colliding |= object->btObject == manifold->getBody0();
+				object->is_colliding |= object->btObject == manifold->getBody1();
+			}
 		}
+	}
 
 	return numManifolds != 0;
 }
diff --git a/hkl3d/hkl3d.h b/hkl3d/hkl3d.h
index 62d97b2..c83f3c2 100644
--- a/hkl3d/hkl3d.h
+++ b/hkl3d/hkl3d.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2010-2016 Synchrotron SOLEIL
+ * Copyright (C) 2010-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -155,30 +155,33 @@ extern "C" {
 #endif
 	};
 
-	extern Hkl3D* hkl3d_new(const char *filename, HklGeometry *geometry);
-	extern void hkl3d_free(Hkl3D *self);
-
-	extern int hkl3d_is_colliding(Hkl3D *self);
-	extern void hkl3d_load_config(Hkl3D *self, const char *filename);
-	extern void hkl3d_save_config(Hkl3D *self, const char *filename);
-	extern Hkl3DModel *hkl3d_add_model_from_file(Hkl3D *self,
-						     const char *filename, const char *directory);
-
-	extern void hkl3d_connect_all_axes(Hkl3D *self);
-	extern void hkl3d_hide_object(Hkl3D *self, Hkl3DObject *object, int hide);
-	extern void hkl3d_remove_object(Hkl3D *self, Hkl3DObject *object);
-
-	extern void hkl3d_get_bounding_boxes(Hkl3D *self,
-					     struct btVector3 *min, struct btVector3 *max);
-	extern int hkl3d_get_nb_manifolds(Hkl3D *self);
-	extern int hkl3d_get_nb_contacts(Hkl3D *self, int manifold);
-	extern void hkl3d_get_collision_coordinates(Hkl3D *self, int manifold, int contact,
-						    double *xa, double *ya, double *za,
-						    double *xb, double *yb, double *zb);
-	extern void hkl3d_connect_object_to_axis(Hkl3D *self,
-						 Hkl3DObject *object, const char *name);
-
-	extern void hkl3d_fprintf(FILE *f, const Hkl3D *self);
+	HKLAPI extern Hkl3D* hkl3d_new(const char *filename, HklGeometry *geometry) HKL_ARG_NONNULL(2);
+	HKLAPI extern void hkl3d_free(Hkl3D *self) HKL_ARG_NONNULL(1);
+
+	HKLAPI extern int hkl3d_is_colliding(Hkl3D *self) HKL_ARG_NONNULL(1);
+	HKLAPI extern void hkl3d_load_config(Hkl3D *self, const char *filename) HKL_ARG_NONNULL(1, 2);
+	HKLAPI extern void hkl3d_save_config(Hkl3D *self, const char *filename) HKL_ARG_NONNULL(1, 2);
+	HKLAPI extern Hkl3DModel *hkl3d_add_model_from_file(Hkl3D *self,
+							    const char *filename,
+							    const char *directory) HKL_ARG_NONNULL(1, 2, 3);
+
+	HKLAPI extern void hkl3d_connect_all_axes(Hkl3D *self) HKL_ARG_NONNULL(1);
+	HKLAPI extern void hkl3d_hide_object(Hkl3D *self, Hkl3DObject *object, int hide) HKL_ARG_NONNULL(1, 2);
+	HKLAPI extern void hkl3d_remove_object(Hkl3D *self, Hkl3DObject *object) HKL_ARG_NONNULL(1, 2);
+
+	HKLAPI extern void hkl3d_get_bounding_boxes(Hkl3D *self,
+						    struct btVector3 *min,
+						    struct btVector3 *max) HKL_ARG_NONNULL(1, 2, 3);
+	HKLAPI extern int hkl3d_get_nb_manifolds(Hkl3D *self) HKL_ARG_NONNULL(1);
+	HKLAPI extern int hkl3d_get_nb_contacts(Hkl3D *self, int manifold) HKL_ARG_NONNULL(1);
+	HKLAPI extern void hkl3d_get_collision_coordinates(Hkl3D *self, int manifold, int contact,
+							   double *xa, double *ya, double *za,
+							   double *xb, double *yb, double *zb) HKL_ARG_NONNULL(1);
+	HKLAPI extern void hkl3d_connect_object_to_axis(Hkl3D *self,
+							Hkl3DObject *object,
+							const char *name) HKL_ARG_NONNULL(1, 2, 3);
+
+	HKLAPI extern void hkl3d_fprintf(FILE *f, const Hkl3D *self) HKL_ARG_NONNULL(1, 2);
 
 #ifdef __cplusplus
 }
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 162baa0..fc50e8b 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -7,26 +7,27 @@ all_tests = \
 	hkl-unit-t \
 	hkl-bench-t \
 	hkl-axis-t \
-	hkl-pseudoaxis-t \
 	hkl-quaternion-t \
 	hkl-interval-t \
-	hkl-pseudoaxis-e4cv-t \
-	hkl-pseudoaxis-e4ch-t \
 	hkl-sample-t \
 	hkl-lattice-t \
-	hkl-pseudoaxis-e6c-t \
 	hkl-source-t \
 	hkl-detector-t \
 	hkl-matrix-t \
-	hkl-pseudoaxis-k4cv-t \
 	hkl-vector-t \
 	hkl-geometry-t \
 	hkl-parameter-t \
+	hkl-pseudoaxis-t \
+	hkl-pseudoaxis-e4cv-t \
+	hkl-pseudoaxis-e4ch-t \
+	hkl-pseudoaxis-e6c-t \
+	hkl-pseudoaxis-k4cv-t \
 	hkl-pseudoaxis-k6c-t \
-	hkl-pseudoaxis-zaxis-t \
-	hkl-pseudoaxis-soleil-sixs-med-t
+	hkl-pseudoaxis-soleil-sirius-kappa-t \
+	hkl-pseudoaxis-soleil-sixs-med-t \
+	hkl-pseudoaxis-zaxis-t
 
-AM_CPPFLAGS = -Wextra -D_BSD_SOURCE \
+AM_CPPFLAGS = -Wextra -D_DEFAULT_SOURCE \
 	-I$(top_srcdir) \
 	-I$(top_srcdir)/hkl \
 	-I$(top_srcdir)/tests \
@@ -34,6 +35,7 @@ AM_CPPFLAGS = -Wextra -D_BSD_SOURCE \
 	$(GSL_CFLAGS)
 
 LDADD = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a \
 	$(GLIB_LIBS) \
 	$(GSL_LIBS)
diff --git a/tests/Makefile.in b/tests/Makefile.in
index a389304..8dc1dcb 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -112,16 +112,18 @@ CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 @HKL3D_TRUE at am__EXEEXT_1 = hkl3d-test-t$(EXEEXT)
 am__EXEEXT_2 = hkl-unit-t$(EXEEXT) hkl-bench-t$(EXEEXT) \
-	hkl-axis-t$(EXEEXT) hkl-pseudoaxis-t$(EXEEXT) \
-	hkl-quaternion-t$(EXEEXT) hkl-interval-t$(EXEEXT) \
-	hkl-pseudoaxis-e4cv-t$(EXEEXT) hkl-pseudoaxis-e4ch-t$(EXEEXT) \
-	hkl-sample-t$(EXEEXT) hkl-lattice-t$(EXEEXT) \
-	hkl-pseudoaxis-e6c-t$(EXEEXT) hkl-source-t$(EXEEXT) \
+	hkl-axis-t$(EXEEXT) hkl-quaternion-t$(EXEEXT) \
+	hkl-interval-t$(EXEEXT) hkl-sample-t$(EXEEXT) \
+	hkl-lattice-t$(EXEEXT) hkl-source-t$(EXEEXT) \
 	hkl-detector-t$(EXEEXT) hkl-matrix-t$(EXEEXT) \
-	hkl-pseudoaxis-k4cv-t$(EXEEXT) hkl-vector-t$(EXEEXT) \
-	hkl-geometry-t$(EXEEXT) hkl-parameter-t$(EXEEXT) \
-	hkl-pseudoaxis-k6c-t$(EXEEXT) hkl-pseudoaxis-zaxis-t$(EXEEXT) \
-	hkl-pseudoaxis-soleil-sixs-med-t$(EXEEXT) $(am__EXEEXT_1)
+	hkl-vector-t$(EXEEXT) hkl-geometry-t$(EXEEXT) \
+	hkl-parameter-t$(EXEEXT) hkl-pseudoaxis-t$(EXEEXT) \
+	hkl-pseudoaxis-e4cv-t$(EXEEXT) hkl-pseudoaxis-e4ch-t$(EXEEXT) \
+	hkl-pseudoaxis-e6c-t$(EXEEXT) hkl-pseudoaxis-k4cv-t$(EXEEXT) \
+	hkl-pseudoaxis-k6c-t$(EXEEXT) \
+	hkl-pseudoaxis-soleil-sirius-kappa-t$(EXEEXT) \
+	hkl-pseudoaxis-soleil-sixs-med-t$(EXEEXT) \
+	hkl-pseudoaxis-zaxis-t$(EXEEXT) $(am__EXEEXT_1)
 hkl_axis_t_SOURCES = hkl-axis-t.c
 hkl_axis_t_OBJECTS = hkl-axis-t.$(OBJEXT)
 hkl_axis_t_LDADD = $(LDADD)
@@ -129,6 +131,7 @@ am__DEPENDENCIES_1 =
 @HKL3D_TRUE at am__DEPENDENCIES_2 = $(top_builddir)/hkl3d/libhkl3d.la \
 @HKL3D_TRUE@	$(am__DEPENDENCIES_1)
 hkl_axis_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 AM_V_lt = $(am__v_lt_ at AM_V@)
@@ -139,72 +142,94 @@ hkl_bench_t_SOURCES = hkl-bench-t.c
 hkl_bench_t_OBJECTS = hkl-bench-t.$(OBJEXT)
 hkl_bench_t_LDADD = $(LDADD)
 hkl_bench_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_detector_t_SOURCES = hkl-detector-t.c
 hkl_detector_t_OBJECTS = hkl-detector-t.$(OBJEXT)
 hkl_detector_t_LDADD = $(LDADD)
 hkl_detector_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_geometry_t_SOURCES = hkl-geometry-t.c
 hkl_geometry_t_OBJECTS = hkl-geometry-t.$(OBJEXT)
 hkl_geometry_t_LDADD = $(LDADD)
 hkl_geometry_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_interval_t_SOURCES = hkl-interval-t.c
 hkl_interval_t_OBJECTS = hkl-interval-t.$(OBJEXT)
 hkl_interval_t_LDADD = $(LDADD)
 hkl_interval_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_lattice_t_SOURCES = hkl-lattice-t.c
 hkl_lattice_t_OBJECTS = hkl-lattice-t.$(OBJEXT)
 hkl_lattice_t_LDADD = $(LDADD)
 hkl_lattice_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_matrix_t_SOURCES = hkl-matrix-t.c
 hkl_matrix_t_OBJECTS = hkl-matrix-t.$(OBJEXT)
 hkl_matrix_t_LDADD = $(LDADD)
 hkl_matrix_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_parameter_t_SOURCES = hkl-parameter-t.c
 hkl_parameter_t_OBJECTS = hkl-parameter-t.$(OBJEXT)
 hkl_parameter_t_LDADD = $(LDADD)
 hkl_parameter_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_e4ch_t_SOURCES = hkl-pseudoaxis-e4ch-t.c
 hkl_pseudoaxis_e4ch_t_OBJECTS = hkl-pseudoaxis-e4ch-t.$(OBJEXT)
 hkl_pseudoaxis_e4ch_t_LDADD = $(LDADD)
 hkl_pseudoaxis_e4ch_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_e4cv_t_SOURCES = hkl-pseudoaxis-e4cv-t.c
 hkl_pseudoaxis_e4cv_t_OBJECTS = hkl-pseudoaxis-e4cv-t.$(OBJEXT)
 hkl_pseudoaxis_e4cv_t_LDADD = $(LDADD)
 hkl_pseudoaxis_e4cv_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_e6c_t_SOURCES = hkl-pseudoaxis-e6c-t.c
 hkl_pseudoaxis_e6c_t_OBJECTS = hkl-pseudoaxis-e6c-t.$(OBJEXT)
 hkl_pseudoaxis_e6c_t_LDADD = $(LDADD)
 hkl_pseudoaxis_e6c_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_k4cv_t_SOURCES = hkl-pseudoaxis-k4cv-t.c
 hkl_pseudoaxis_k4cv_t_OBJECTS = hkl-pseudoaxis-k4cv-t.$(OBJEXT)
 hkl_pseudoaxis_k4cv_t_LDADD = $(LDADD)
 hkl_pseudoaxis_k4cv_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_k6c_t_SOURCES = hkl-pseudoaxis-k6c-t.c
 hkl_pseudoaxis_k6c_t_OBJECTS = hkl-pseudoaxis-k6c-t.$(OBJEXT)
 hkl_pseudoaxis_k6c_t_LDADD = $(LDADD)
 hkl_pseudoaxis_k6c_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
+	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
+	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
+hkl_pseudoaxis_soleil_sirius_kappa_t_SOURCES =  \
+	hkl-pseudoaxis-soleil-sirius-kappa-t.c
+hkl_pseudoaxis_soleil_sirius_kappa_t_OBJECTS =  \
+	hkl-pseudoaxis-soleil-sirius-kappa-t.$(OBJEXT)
+hkl_pseudoaxis_soleil_sirius_kappa_t_LDADD = $(LDADD)
+hkl_pseudoaxis_soleil_sirius_kappa_t_DEPENDENCIES =  \
+	$(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_soleil_sixs_med_t_SOURCES =  \
@@ -214,60 +239,70 @@ hkl_pseudoaxis_soleil_sixs_med_t_OBJECTS =  \
 hkl_pseudoaxis_soleil_sixs_med_t_LDADD = $(LDADD)
 hkl_pseudoaxis_soleil_sixs_med_t_DEPENDENCIES =  \
 	$(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_t_SOURCES = hkl-pseudoaxis-t.c
 hkl_pseudoaxis_t_OBJECTS = hkl-pseudoaxis-t.$(OBJEXT)
 hkl_pseudoaxis_t_LDADD = $(LDADD)
 hkl_pseudoaxis_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_pseudoaxis_zaxis_t_SOURCES = hkl-pseudoaxis-zaxis-t.c
 hkl_pseudoaxis_zaxis_t_OBJECTS = hkl-pseudoaxis-zaxis-t.$(OBJEXT)
 hkl_pseudoaxis_zaxis_t_LDADD = $(LDADD)
 hkl_pseudoaxis_zaxis_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_quaternion_t_SOURCES = hkl-quaternion-t.c
 hkl_quaternion_t_OBJECTS = hkl-quaternion-t.$(OBJEXT)
 hkl_quaternion_t_LDADD = $(LDADD)
 hkl_quaternion_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_sample_t_SOURCES = hkl-sample-t.c
 hkl_sample_t_OBJECTS = hkl-sample-t.$(OBJEXT)
 hkl_sample_t_LDADD = $(LDADD)
 hkl_sample_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_source_t_SOURCES = hkl-source-t.c
 hkl_source_t_OBJECTS = hkl-source-t.$(OBJEXT)
 hkl_source_t_LDADD = $(LDADD)
 hkl_source_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_unit_t_SOURCES = hkl-unit-t.c
 hkl_unit_t_OBJECTS = hkl-unit-t.$(OBJEXT)
 hkl_unit_t_LDADD = $(LDADD)
 hkl_unit_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl_vector_t_SOURCES = hkl-vector-t.c
 hkl_vector_t_OBJECTS = hkl-vector-t.$(OBJEXT)
 hkl_vector_t_LDADD = $(LDADD)
 hkl_vector_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 hkl3d_test_t_SOURCES = hkl3d-test-t.c
 hkl3d_test_t_OBJECTS = hkl3d-test-t.$(OBJEXT)
 hkl3d_test_t_LDADD = $(LDADD)
 hkl3d_test_t_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 runtests_SOURCES = runtests.c
 runtests_OBJECTS = runtests.$(OBJEXT)
 runtests_LDADD = $(LDADD)
 runtests_DEPENDENCIES = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(am__DEPENDENCIES_1) \
 	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2)
 AM_V_P = $(am__v_P_ at AM_V@)
@@ -327,6 +362,7 @@ SOURCES = hkl-axis-t.c hkl-bench-t.c hkl-detector-t.c hkl-geometry-t.c \
 	hkl-parameter-t.c hkl-pseudoaxis-e4ch-t.c \
 	hkl-pseudoaxis-e4cv-t.c hkl-pseudoaxis-e6c-t.c \
 	hkl-pseudoaxis-k4cv-t.c hkl-pseudoaxis-k6c-t.c \
+	hkl-pseudoaxis-soleil-sirius-kappa-t.c \
 	hkl-pseudoaxis-soleil-sixs-med-t.c hkl-pseudoaxis-t.c \
 	hkl-pseudoaxis-zaxis-t.c hkl-quaternion-t.c hkl-sample-t.c \
 	hkl-source-t.c hkl-unit-t.c hkl-vector-t.c \
@@ -336,6 +372,7 @@ DIST_SOURCES = hkl-axis-t.c hkl-bench-t.c hkl-detector-t.c \
 	hkl-matrix-t.c hkl-parameter-t.c hkl-pseudoaxis-e4ch-t.c \
 	hkl-pseudoaxis-e4cv-t.c hkl-pseudoaxis-e6c-t.c \
 	hkl-pseudoaxis-k4cv-t.c hkl-pseudoaxis-k6c-t.c \
+	hkl-pseudoaxis-soleil-sirius-kappa-t.c \
 	hkl-pseudoaxis-soleil-sixs-med-t.c hkl-pseudoaxis-t.c \
 	hkl-pseudoaxis-zaxis-t.c hkl-quaternion-t.c hkl-sample-t.c \
 	hkl-source-t.c hkl-unit-t.c hkl-vector-t.c hkl3d-test-t.c \
@@ -451,6 +488,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
@@ -579,17 +617,20 @@ top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 version_info = @version_info@
 SUBDIRS = tap . $(am__append_1)
-all_tests = hkl-unit-t hkl-bench-t hkl-axis-t hkl-pseudoaxis-t \
-	hkl-quaternion-t hkl-interval-t hkl-pseudoaxis-e4cv-t \
-	hkl-pseudoaxis-e4ch-t hkl-sample-t hkl-lattice-t \
-	hkl-pseudoaxis-e6c-t hkl-source-t hkl-detector-t hkl-matrix-t \
-	hkl-pseudoaxis-k4cv-t hkl-vector-t hkl-geometry-t \
-	hkl-parameter-t hkl-pseudoaxis-k6c-t hkl-pseudoaxis-zaxis-t \
-	hkl-pseudoaxis-soleil-sixs-med-t $(am__append_2)
-AM_CPPFLAGS = -Wextra -D_BSD_SOURCE -I$(top_srcdir) \
+all_tests = hkl-unit-t hkl-bench-t hkl-axis-t hkl-quaternion-t \
+	hkl-interval-t hkl-sample-t hkl-lattice-t hkl-source-t \
+	hkl-detector-t hkl-matrix-t hkl-vector-t hkl-geometry-t \
+	hkl-parameter-t hkl-pseudoaxis-t hkl-pseudoaxis-e4cv-t \
+	hkl-pseudoaxis-e4ch-t hkl-pseudoaxis-e6c-t \
+	hkl-pseudoaxis-k4cv-t hkl-pseudoaxis-k6c-t \
+	hkl-pseudoaxis-soleil-sirius-kappa-t \
+	hkl-pseudoaxis-soleil-sixs-med-t hkl-pseudoaxis-zaxis-t \
+	$(am__append_2)
+AM_CPPFLAGS = -Wextra -D_DEFAULT_SOURCE -I$(top_srcdir) \
 	-I$(top_srcdir)/hkl -I$(top_srcdir)/tests $(GLIB_CFLAGS) \
 	$(GSL_CFLAGS) $(am__append_3)
 LDADD = $(top_builddir)/hkl/libhkl.la \
+	$(top_builddir)/hkl/api2/libhkl2.la \
 	$(top_builddir)/tests/tap/libtap.a $(GLIB_LIBS) $(GSL_LIBS) \
 	$(am__append_4)
 
@@ -690,6 +731,10 @@ hkl-pseudoaxis-k6c-t$(EXEEXT): $(hkl_pseudoaxis_k6c_t_OBJECTS) $(hkl_pseudoaxis_
 	@rm -f hkl-pseudoaxis-k6c-t$(EXEEXT)
 	$(AM_V_CCLD)$(LINK) $(hkl_pseudoaxis_k6c_t_OBJECTS) $(hkl_pseudoaxis_k6c_t_LDADD) $(LIBS)
 
+hkl-pseudoaxis-soleil-sirius-kappa-t$(EXEEXT): $(hkl_pseudoaxis_soleil_sirius_kappa_t_OBJECTS) $(hkl_pseudoaxis_soleil_sirius_kappa_t_DEPENDENCIES) $(EXTRA_hkl_pseudoaxis_soleil_sirius_kappa_t_DEPENDENCIES) 
+	@rm -f hkl-pseudoaxis-soleil-sirius-kappa-t$(EXEEXT)
+	$(AM_V_CCLD)$(LINK) $(hkl_pseudoaxis_soleil_sirius_kappa_t_OBJECTS) $(hkl_pseudoaxis_soleil_sirius_kappa_t_LDADD) $(LIBS)
+
 hkl-pseudoaxis-soleil-sixs-med-t$(EXEEXT): $(hkl_pseudoaxis_soleil_sixs_med_t_OBJECTS) $(hkl_pseudoaxis_soleil_sixs_med_t_DEPENDENCIES) $(EXTRA_hkl_pseudoaxis_soleil_sixs_med_t_DEPENDENCIES) 
 	@rm -f hkl-pseudoaxis-soleil-sixs-med-t$(EXEEXT)
 	$(AM_V_CCLD)$(LINK) $(hkl_pseudoaxis_soleil_sixs_med_t_OBJECTS) $(hkl_pseudoaxis_soleil_sixs_med_t_LDADD) $(LIBS)
@@ -750,6 +795,7 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-e6c-t.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-k4cv-t.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-k6c-t.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-soleil-sirius-kappa-t.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-soleil-sixs-med-t.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-t.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hkl-pseudoaxis-zaxis-t.Po at am__quote@
diff --git a/tests/bindings/Makefile.in b/tests/bindings/Makefile.in
index 3824269..e76398d 100644
--- a/tests/bindings/Makefile.in
+++ b/tests/bindings/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -370,6 +370,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/tests/hkl-axis-t.c b/tests/hkl-axis-t.c
index 00629d3..3e453a7 100644
--- a/tests/hkl-axis-t.c
+++ b/tests/hkl-axis-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -31,15 +31,23 @@ static void new(void)
 	HklParameter *axis;
 	static HklVector v = {{1, 0, 0}};
 	double min, max;
-	axis = hkl_parameter_new_axis("omega", &v, &hkl_unit_angle_deg);
 
-	is_string("omega", hkl_parameter_name_get(axis), __func__);
+	axis = hkl_parameter_new_rotation("rotation", &v, &hkl_unit_angle_deg);
+	is_string("rotation", hkl_parameter_name_get(axis), __func__);
 	hkl_parameter_min_max_get(axis, &min, &max, HKL_UNIT_DEFAULT);
 	is_double(-M_PI, min, HKL_EPSILON, __func__);
 	is_double(M_PI, max, HKL_EPSILON, __func__);
 	is_double(0., hkl_parameter_value_get(axis, HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
 	ok(TRUE == hkl_parameter_fit_get(axis), __func__);
+	hkl_parameter_free(axis);
 
+	axis = hkl_parameter_new_translation("translation", &v, &hkl_unit_length_mm);
+	is_string("translation", hkl_parameter_name_get(axis), __func__);
+	hkl_parameter_min_max_get(axis, &min, &max, HKL_UNIT_DEFAULT);
+	is_double(-DBL_MAX, min, HKL_EPSILON, __func__);
+	is_double(DBL_MAX, max, HKL_EPSILON, __func__);
+	is_double(0., hkl_parameter_value_get(axis, HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
+	ok(TRUE == hkl_parameter_fit_get(axis), __func__);
 	hkl_parameter_free(axis);
 }
 
@@ -50,13 +58,14 @@ static void get_quaternions(void)
 	static HklQuaternion q2_ref = {{M_SQRT1_2, -M_SQRT1_2, 0, 0}};
 	HklParameter *axis;
 
-	axis = hkl_parameter_new_axis("omega", &v_ref, &hkl_unit_angle_deg);
-
+	axis = hkl_parameter_new_rotation("rotation", &v_ref, &hkl_unit_angle_deg);
 	is_quaternion(&q1_ref, hkl_parameter_quaternion_get(axis), __func__);
-
 	ok(TRUE == hkl_parameter_value_set(axis, -M_PI_2, HKL_UNIT_DEFAULT, NULL), __func__);
 	is_quaternion(&q2_ref, hkl_parameter_quaternion_get(axis), __func__);
+	hkl_parameter_free(axis);
 
+	axis = hkl_parameter_new_translation("translation", &v_ref, &hkl_unit_length_mm);
+	ok(NULL == hkl_parameter_quaternion_get(axis), __func__);
 	hkl_parameter_free(axis);
 }
 
@@ -69,20 +78,29 @@ static void copy(void)
 	double min, max;
 
 
-	axis = hkl_parameter_new_axis("omega", &v, &hkl_unit_angle_deg);
+	axis = hkl_parameter_new_rotation("rotation", &v, &hkl_unit_angle_deg);
 	ok(TRUE == hkl_parameter_value_set(axis, -M_PI_2, HKL_UNIT_DEFAULT, NULL), __func__);
-
 	copy = hkl_parameter_new_copy(axis);
-
-	is_string("omega", hkl_parameter_name_get(copy), __func__);
+	is_string("rotation", hkl_parameter_name_get(copy), __func__);
 	hkl_parameter_min_max_get(copy, &min, &max, HKL_UNIT_DEFAULT);
 	is_double(-M_PI, min, HKL_EPSILON, __func__);
 	is_double(M_PI, max, HKL_EPSILON, __func__);
 	is_double(-M_PI_2, hkl_parameter_value_get(copy, HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
 	ok(TRUE == hkl_parameter_fit_get(copy), __func__);
-
 	is_quaternion(&q_ref, hkl_parameter_quaternion_get(copy), __func__);
+	hkl_parameter_free(axis);
+	hkl_parameter_free(copy);
 
+	axis = hkl_parameter_new_translation("translation", &v, &hkl_unit_length_mm);
+	ok(TRUE == hkl_parameter_value_set(axis, 100, HKL_UNIT_DEFAULT, NULL), __func__);
+	copy = hkl_parameter_new_copy(axis);
+	is_string("translation", hkl_parameter_name_get(copy), __func__);
+	hkl_parameter_min_max_get(copy, &min, &max, HKL_UNIT_DEFAULT);
+	is_double(-DBL_MAX, min, HKL_EPSILON, __func__);
+	is_double(DBL_MAX, max, HKL_EPSILON, __func__);
+	is_double(100, hkl_parameter_value_get(copy, HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
+	ok(TRUE == hkl_parameter_fit_get(copy), __func__);
+	ok(NULL == hkl_parameter_quaternion_get(copy), __func__);
 	hkl_parameter_free(axis);
 	hkl_parameter_free(copy);
 }
@@ -90,33 +108,36 @@ static void copy(void)
 static void is_valid(void)
 {
 	static HklVector v = {{1, 0, 0}};
-	HklParameter *axis1;
-
-	axis1 = hkl_parameter_new_axis("omega", &v, &hkl_unit_angle_deg);
-
-	ok(TRUE == hkl_parameter_value_set(axis1, 45, HKL_UNIT_USER, NULL), __func__);
-	ok(TRUE == hkl_parameter_is_valid(axis1), __func__);
-
-	/* change the range of axis1 */
-	ok(TRUE == hkl_parameter_min_max_set(axis1, -270, 0, HKL_UNIT_USER, NULL), __func__);
-	ok(FALSE == hkl_parameter_is_valid(axis1), __func__);
-
-	ok(TRUE == hkl_parameter_value_set(axis1, -45, HKL_UNIT_USER, NULL), __func__);
-	ok(TRUE == hkl_parameter_is_valid(axis1), __func__);
-
-	ok(TRUE == hkl_parameter_min_max_set(axis1, 350, 450, HKL_UNIT_USER, NULL), __func__);
-	ok(TRUE == hkl_parameter_value_set(axis1, 45, HKL_UNIT_USER, NULL), __func__);
-	ok(TRUE == hkl_parameter_is_valid(axis1), __func__);
-	ok(TRUE == hkl_parameter_value_set(axis1, -45, HKL_UNIT_USER, NULL), __func__);
-	ok(FALSE == hkl_parameter_is_valid(axis1), __func__);
+	HklParameter *axis;
 
-	ok(TRUE == hkl_parameter_min_max_set(axis1, -10, 90, HKL_UNIT_USER, NULL), __func__);
-	ok(TRUE == hkl_parameter_value_set(axis1, 405, HKL_UNIT_USER, NULL), __func__);
-	ok(TRUE == hkl_parameter_is_valid(axis1), __func__);
-	ok(TRUE == hkl_parameter_value_set(axis1, -405, HKL_UNIT_USER, NULL), __func__);
-	ok(FALSE == hkl_parameter_is_valid(axis1), __func__);
+	axis = hkl_parameter_new_rotation("rotation", &v, &hkl_unit_angle_deg);
+
+	ok(TRUE == hkl_parameter_value_set(axis, 45, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_min_max_set(axis, -270, 0, HKL_UNIT_USER, NULL), __func__);
+	ok(FALSE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_value_set(axis, -45, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_min_max_set(axis, 350, 450, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_value_set(axis, 45, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_value_set(axis, -45, HKL_UNIT_USER, NULL), __func__);
+	ok(FALSE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_min_max_set(axis, -10, 90, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_value_set(axis, 405, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_value_set(axis, -405, HKL_UNIT_USER, NULL), __func__);
+	ok(FALSE == hkl_parameter_is_valid(axis), __func__);
+	hkl_parameter_free(axis);
 
-	hkl_parameter_free(axis1);
+	axis = hkl_parameter_new_translation("translation", &v, &hkl_unit_length_mm);
+	ok(TRUE == hkl_parameter_value_set(axis, 45, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_min_max_set(axis, -270, 0, HKL_UNIT_USER, NULL), __func__);
+	ok(FALSE == hkl_parameter_is_valid(axis), __func__);
+	ok(TRUE == hkl_parameter_value_set(axis, -45, HKL_UNIT_USER, NULL), __func__);
+	ok(TRUE == hkl_parameter_is_valid(axis), __func__);
+	hkl_parameter_free(axis);
 }
 
 static void set_value_smallest_in_range(void)
@@ -124,7 +145,7 @@ static void set_value_smallest_in_range(void)
 	HklParameter *axis;
 	static HklVector v = {{1, 0, 0}};
 
-	axis = hkl_parameter_new_axis("omega", &v, &hkl_unit_angle_deg);
+	axis = hkl_parameter_new_rotation("rotation", &v, &hkl_unit_angle_deg);
 
 	ok(TRUE == hkl_parameter_min_max_set(axis, -190, 190, HKL_UNIT_USER, NULL), __func__);
 
@@ -160,8 +181,8 @@ static void get_value_closest(void)
 	HklParameter *axis1, *axis2;
 	static HklVector v = {{1, 0, 0}};
 
-	axis1 = hkl_parameter_new_axis("omega", &v, &hkl_unit_angle_deg);
-	axis2 = hkl_parameter_new_axis("omega", &v, &hkl_unit_angle_deg);
+	axis1 = hkl_parameter_new_rotation("rotation", &v, &hkl_unit_angle_deg);
+	axis2 = hkl_parameter_new_rotation("rotation", &v, &hkl_unit_angle_deg);
 
 	ok(TRUE == hkl_parameter_value_set(axis1, 0, HKL_UNIT_USER, NULL), __func__);
 	ok(TRUE == hkl_parameter_value_set(axis2, 0, HKL_UNIT_USER, NULL), __func__);
@@ -177,19 +198,50 @@ static void get_value_closest(void)
 	is_double(100 * HKL_DEGTORAD, hkl_parameter_value_get_closest(axis1,
 								      axis2),
 		  HKL_EPSILON, __func__);
-
 	ok(TRUE == hkl_parameter_value_set(axis2, -85, HKL_UNIT_USER, NULL), __func__);
 	is_double(-260 * HKL_DEGTORAD, hkl_parameter_value_get_closest(axis1,
 								       axis2),
 		  HKL_EPSILON, __func__);
 
 	hkl_parameter_free(axis1);
+}
+
+static void transformation_cmp(void)
+{
+	int res = TRUE;
+	HklParameter *axis1, *axis2, *translation1, *translation2;
+	static HklVector v1 = {{1, 0, 0}};
+	static HklVector v2 = {{0, 1, 0}};
+
+	axis1 = hkl_parameter_new_rotation("rotation", &v1, &hkl_unit_angle_deg);
+	axis2 = hkl_parameter_new_rotation("rotation", &v2, &hkl_unit_angle_deg);
+	translation1 = hkl_parameter_new_translation("translation", &v1, &hkl_unit_length_mm);
+	translation2 = hkl_parameter_new_translation("translation", &v2, &hkl_unit_length_mm);
+
+	res &= DIAG(0 == hkl_parameter_transformation_cmp(axis1, axis1));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(axis1, axis2));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(axis1, translation1));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(axis1, translation2));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(axis2, translation1));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(axis2, translation2));
+	res &= DIAG(0 == hkl_parameter_transformation_cmp(translation1, translation1));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(translation1, translation2));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(translation1, axis1));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(translation1, axis2));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(translation2, axis1));
+	res &= DIAG(0 != hkl_parameter_transformation_cmp(translation2, axis2));
+
+	ok(res == TRUE, __func__);
+
+	hkl_parameter_free(translation2);
+	hkl_parameter_free(translation1);
 	hkl_parameter_free(axis2);
+	hkl_parameter_free(axis1);
 }
 
 int main(void)
 {
-	plan(53);
+	plan(73);
 
 	new();
 	get_quaternions();
@@ -197,6 +249,7 @@ int main(void)
 	is_valid();
 	set_value_smallest_in_range();
 	get_value_closest();
+	transformation_cmp();
 
 	return 0;
 }
diff --git a/tests/hkl-bench-t.c b/tests/hkl-bench-t.c
index b033878..39f5dad 100644
--- a/tests/hkl-bench-t.c
+++ b/tests/hkl-bench-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-detector-t.c b/tests/hkl-detector-t.c
index 0e059a1..0764349 100644
--- a/tests/hkl-detector-t.c
+++ b/tests/hkl-detector-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -51,7 +51,7 @@ static void attach_to_holder(void)
 	HklHolder *holder = NULL;
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
-	geometry = hkl_geometry_new(NULL);
+	geometry = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(geometry);
 	hkl_detector_attach_to_holder(detector, holder);
 
@@ -72,15 +72,15 @@ static void compute_kf(void)
 	HklVector kf_ref = {{0, HKL_TAU / HKL_SOURCE_DEFAULT_WAVE_LENGTH, 0}};
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
-	geometry = hkl_geometry_new(NULL);
+	geometry = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	/* add a fake first holder */
 	holder = hkl_geometry_add_holder(geometry);
 	/* for now all detectors MUST be connected to the second
 	 * holder. We will decide about a better API to connect
 	 * geometry and detector */
 	holder = hkl_geometry_add_holder(geometry);
-	hkl_holder_add_rotation_axis(holder, "a", 1, 0, 0);
-	hkl_holder_add_rotation_axis(holder, "b", 0, 1, 0);
+	hkl_holder_add_rotation(holder, "a", 1, 0, 0, &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "b", 0, 1, 0, &hkl_unit_angle_deg);
 
 	res &= DIAG(hkl_parameter_value_set(darray_item(geometry->axes, 0), M_PI_2, HKL_UNIT_DEFAULT, NULL));
 	res &= DIAG(hkl_parameter_value_set(darray_item(geometry->axes, 1), M_PI_2, HKL_UNIT_DEFAULT, NULL));
diff --git a/tests/hkl-geometry-t.c b/tests/hkl-geometry-t.c
index 6b4e74c..e233fe0 100644
--- a/tests/hkl-geometry-t.c
+++ b/tests/hkl-geometry-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -36,17 +36,19 @@ static void add_holder(void)
 	HklGeometry *g = NULL;
 	HklHolder *holder = NULL;
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	is_int(0, darray_size(g->holders), __func__);
 
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_angle_deg);
 	is_int(1, darray_size(g->holders), __func__);
 
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_angle_deg);
 	is_int(2, darray_size(g->holders), __func__);
 
 	ok(holder == darray_item(g->holders, 1), __func__);
@@ -62,30 +64,35 @@ static void get_axis(void)
 	const HklParameter *axis0;
 	GError *error;
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	/* check the private API */
 	res &= DIAG(0 == !hkl_geometry_get_axis_by_name(g, "A"));
 	res &= DIAG(0 == !hkl_geometry_get_axis_by_name(g, "B"));
 	res &= DIAG(0 == !hkl_geometry_get_axis_by_name(g, "C"));
-	res &= DIAG(1 == !hkl_geometry_get_axis_by_name(g, "D"));
+	res &= DIAG(0 == !hkl_geometry_get_axis_by_name(g, "T"));
+	res &= DIAG(1 == !hkl_geometry_get_axis_by_name(g, "DONOTEXIST"));
 
 	/* check the public API */
 	/* get */
 	res &= DIAG(NULL != hkl_geometry_axis_get(g, "A", NULL));
-	res &= DIAG(NULL == hkl_geometry_axis_get(g, "D", NULL));
+	res &= DIAG(NULL == hkl_geometry_axis_get(g, "DONOTEXIST", NULL));
 	error = NULL;
 	res &= DIAG(NULL != hkl_geometry_axis_get(g, "A", &error));
 	res &= DIAG(error == NULL);
-	res &= DIAG(NULL == hkl_geometry_axis_get(g, "D", &error));
+	res &= DIAG(NULL != hkl_geometry_axis_get(g, "T", &error));
+	res &= DIAG(error == NULL);
+	res &= DIAG(NULL == hkl_geometry_axis_get(g, "DONOTEXIST", &error));
 	res &= DIAG(error != NULL);
 	g_clear_error(&error);
 
@@ -93,6 +100,7 @@ static void get_axis(void)
 	axis0 = hkl_geometry_axis_get(g, "A", NULL);
 	res &= DIAG(TRUE == hkl_geometry_axis_set(g, "A", axis0, NULL));
 	res &= DIAG(FALSE == hkl_geometry_axis_set(g, "B", axis0, NULL));
+	res &= DIAG(FALSE == hkl_geometry_axis_set(g, "T", axis0, NULL));
 
 	error = NULL;
 	res &= DIAG(hkl_geometry_axis_set(g, "A", axis0, &error));
@@ -100,11 +108,14 @@ static void get_axis(void)
 
 	res &= DIAG(FALSE == hkl_geometry_axis_set(g, "B", axis0, &error));
 	res &= DIAG(error != NULL);
+	g_clear_error(&error);
 
-	ok(res, __func__);
-
+	res &= DIAG(FALSE == hkl_geometry_axis_set(g, "T", axis0, &error));
+	res &= DIAG(error != NULL);
 	g_clear_error(&error);
 
+	ok(res, __func__);
+
 	hkl_geometry_free(g);
 }
 
@@ -114,16 +125,19 @@ static void update(void)
 	HklGeometry *g = NULL;
 	HklHolder *holder = NULL;
 	HklAxis *axis1;
+	HklQuaternion q_ref = {{1./sqrt(2), 1./sqrt(2), 0.0, 0.0 }};
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T1", 1., 0., 0., &hkl_unit_length_mm);
 
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T2", 1., 0., 0., &hkl_unit_length_mm);
 
 	axis1 = container_of(hkl_geometry_get_axis_by_name(g, "B"), HklAxis, parameter);
 	res &= DIAG(hkl_parameter_value_set(&axis1->parameter, M_PI_2, HKL_UNIT_DEFAULT, NULL));
@@ -132,10 +146,7 @@ static void update(void)
 
 	hkl_geometry_update(g);
 	holder = darray_item(g->holders, 0);
-	is_double(1./sqrt(2), holder->q.data[0], HKL_EPSILON, __func__);
-	is_double(1./sqrt(2), holder->q.data[1], HKL_EPSILON, __func__);
-	is_double(.0, holder->q.data[2], HKL_EPSILON, __func__);
-	is_double(.0, holder->q.data[3], HKL_EPSILON, __func__);
+	is_quaternion(&q_ref, &holder->q, __func__);
 	/* now axis1 is clean */
 	res &= DIAG(FALSE == axis1->parameter.changed);
 
@@ -152,21 +163,22 @@ static void set(void)
 	HklHolder *holder;
 	HklFactory *fake_factory;
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	g1 = hkl_geometry_new_copy(g);
 
 	/* it is required to use a fake factory, with the public API
 	 * geometry contain always a real factory */
 	fake_factory = (HklFactory *)0x1;
-	g2 = hkl_geometry_new(fake_factory);
+	g2 = hkl_geometry_new(fake_factory, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
 
 	ok(hkl_geometry_set(g, g1), __func__);
 
@@ -180,16 +192,17 @@ static void axis_values_get_set(void)
 	unsigned int i;
 	HklGeometry *g;
 	HklHolder *holder;
-	static double set_1[] = {1, 1, 1};
-	static double set_10[] = {10, 10, 10};
-	double values[3];
+	static double set_1[] = {1, 1, 1, 1};
+	static double set_10[] = {10, 10, 10, 10};
+	double values[4];
 	GError *error;
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	/* check set DEFAULT unit */
 	error = NULL;
@@ -200,7 +213,7 @@ static void axis_values_get_set(void)
 		is_double(set_1[i], hkl_parameter_value_get(darray_item(g->axes, i), HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
 
 	/* check get DEFAULT unit */
-	hkl_geometry_axis_values_get(g, values, 3, HKL_UNIT_DEFAULT);
+	hkl_geometry_axis_values_get(g, values, ARRAY_SIZE(values), HKL_UNIT_DEFAULT);
 	for(i=0; i<ARRAY_SIZE(set_1); ++i)
 		is_double(set_1[i], values[i], HKL_EPSILON, __func__);
 
@@ -208,11 +221,9 @@ static void axis_values_get_set(void)
 	ok(TRUE == hkl_geometry_axis_values_set(g, set_10, ARRAY_SIZE(set_10), HKL_UNIT_USER, NULL), __func__);
 	ok(TRUE == hkl_geometry_axis_values_set(g, set_10, ARRAY_SIZE(set_10), HKL_UNIT_USER, &error), __func__);
 	ok(error == NULL, __func__);
-	for(i=0; i<ARRAY_SIZE(set_10); ++i)
-		is_double(set_10[i] * HKL_DEGTORAD, hkl_parameter_value_get(darray_item(g->axes, i), HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
 
 	/* check get USER unit */
-	hkl_geometry_axis_values_get(g, values, 3, HKL_UNIT_USER);
+	hkl_geometry_axis_values_get(g, values, ARRAY_SIZE(values), HKL_UNIT_USER);
 	for(i=0; i<ARRAY_SIZE(set_10); ++i)
 		is_double(set_10[i], values[i], HKL_EPSILON, __func__);
 
@@ -226,17 +237,18 @@ static void distance(void)
 	HklGeometry *g2 = NULL;
 	HklHolder *holder = NULL;
 
-	g1 = hkl_geometry_new(NULL);
+	g1 = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g1);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	g2 = hkl_geometry_new_copy(g1);
 
-	res &= DIAG(hkl_geometry_set_values_v(g1, HKL_UNIT_DEFAULT, NULL, 0., 0., 0.));
-	res &= DIAG(hkl_geometry_set_values_v(g2, HKL_UNIT_DEFAULT, NULL, 1., 1., 1.));
-	is_double(3., hkl_geometry_distance(g1, g2), HKL_EPSILON, __func__);
+	res &= DIAG(hkl_geometry_set_values_v(g1, HKL_UNIT_DEFAULT, NULL, 0., 0., 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(g2, HKL_UNIT_DEFAULT, NULL, 1., 1., 1., 1.));
+	is_double(4., hkl_geometry_distance(g1, g2), HKL_EPSILON, __func__);
 
 	ok(res, __func__);
 
@@ -250,16 +262,17 @@ static void is_valid(void)
 	HklGeometry *geom = NULL;
 	HklHolder *holder = NULL;
 
-	geom = hkl_geometry_new(NULL);
+	geom = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(geom);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_DEFAULT, NULL, 0., 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_DEFAULT, NULL, 0., 0., 0., 0.));
 	res &= DIAG(TRUE == hkl_geometry_is_valid(geom));
 
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_DEFAULT, NULL, -181. * HKL_DEGTORAD, 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_DEFAULT, NULL, -181. * HKL_DEGTORAD, 0., 0., 0.));
 	res &= DIAG(TRUE == hkl_geometry_is_valid(geom));
 
 	res &= DIAG(hkl_parameter_min_max_set(darray_item(geom->axes, 0),
@@ -277,7 +290,7 @@ static void wavelength(void)
 	HklGeometry *geom = NULL;
 	GError *error;
 
-	geom = hkl_geometry_new(NULL);
+	geom = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 
 	is_double(1.54, hkl_geometry_wavelength_get(geom, HKL_UNIT_DEFAULT), HKL_EPSILON, __func__);
 
@@ -330,17 +343,18 @@ static void list(void)
 	HklGeometryList *list;
 	const HklGeometryListItem *item;
 	HklHolder *holder;
-	static double values[] = {0. * HKL_DEGTORAD, 10 * HKL_DEGTORAD, 30 * HKL_DEGTORAD};
+	static double values[] = {0. * HKL_DEGTORAD, 10 * HKL_DEGTORAD, 30 * HKL_DEGTORAD, 100 * HKL_DEGTORAD};
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	list = hkl_geometry_list_new();
 
-	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[0], 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[0], 0., 0., 0.));
 	hkl_geometry_list_add(list, g);
 	is_int(1, hkl_geometry_list_n_items_get(list), __func__);
 
@@ -348,13 +362,13 @@ static void list(void)
 	hkl_geometry_list_add(list, g);
 	is_int(1, hkl_geometry_list_n_items_get(list), __func__);
 
-	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[2], 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[2], 0., 0., 0.));
 	hkl_geometry_list_add(list, g);
-	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[1], 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[1], 0., 0., 0.));
 	hkl_geometry_list_add(list, g);
 	is_int(3, hkl_geometry_list_n_items_get(list), __func__);
 
-	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[0], 0., 0.));
+	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL, values[0], 0., 0., 0.));
 	hkl_geometry_list_sort(list, g);
 
 	HKL_GEOMETRY_LIST_FOREACH(item, list){
@@ -375,30 +389,35 @@ static void  list_multiply_from_range(void)
 	HklGeometry *g;
 	HklGeometryList *list;
 	HklHolder *holder;
-	HklParameter *axisA, *axisB, *axisC;
+	HklParameter *axisA, *axisB, *axisC, *axisT;
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	axisA = hkl_geometry_get_axis_by_name(g, "A");
 	axisB = hkl_geometry_get_axis_by_name(g, "B");
 	axisC = hkl_geometry_get_axis_by_name(g, "C");
+	axisT = hkl_geometry_get_axis_by_name(g, "T");
 
 	res &= DIAG(hkl_parameter_min_max_set(axisA, -190, 190, HKL_UNIT_USER, NULL));
 	res &= DIAG(hkl_parameter_min_max_set(axisB, -190, 190, HKL_UNIT_USER, NULL));
 	res &= DIAG(hkl_parameter_min_max_set(axisC, -190, 190, HKL_UNIT_USER, NULL));
+	res &= DIAG(hkl_parameter_min_max_set(axisT, -190, 190., HKL_UNIT_USER, NULL));
 
 	list = hkl_geometry_list_new();
 
 	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL,
-					      185. * HKL_DEGTORAD, -185. * HKL_DEGTORAD, 190. * HKL_DEGTORAD));
+					      185. * HKL_DEGTORAD, -185. * HKL_DEGTORAD, 190. * HKL_DEGTORAD, 100.));
 	hkl_geometry_list_add(list, g);
 
 	hkl_geometry_list_multiply_from_range(list);
 
+	res &= DIAG(8 == hkl_geometry_list_n_items_get(list));
+
 	ok(res, __func__);
 
 	hkl_geometry_free(g);
@@ -411,40 +430,46 @@ static void  list_remove_invalid(void)
 	HklGeometry *g;
 	HklGeometryList *list;
 	HklHolder *holder;
-	HklParameter *axisA, *axisB, *axisC;
+	HklParameter *axisA, *axisB, *axisC, *axisT;
 
-	g = hkl_geometry_new(NULL);
+	g = hkl_geometry_new(NULL, &hkl_geometry_operations_defaults);
 	holder = hkl_geometry_add_holder(g);
-	hkl_holder_add_rotation_axis(holder, "A", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "B", 1., 0., 0.);
-	hkl_holder_add_rotation_axis(holder, "C", 1., 0., 0.);
+	hkl_holder_add_rotation(holder, "A", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "B", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_rotation(holder, "C", 1., 0., 0., &hkl_unit_angle_deg);
+	hkl_holder_add_translation(holder, "T", 1., 0., 0., &hkl_unit_length_mm);
 
 	axisA = hkl_geometry_get_axis_by_name(g, "A");
 	axisB = hkl_geometry_get_axis_by_name(g, "B");
 	axisC = hkl_geometry_get_axis_by_name(g, "C");
+	axisT = hkl_geometry_get_axis_by_name(g, "T");
 
 	res &= DIAG(hkl_parameter_min_max_set(axisA, -100, 180., HKL_UNIT_USER, NULL));
 	res &= DIAG(hkl_parameter_min_max_set(axisB, -100., 180., HKL_UNIT_USER, NULL));
 	res &= DIAG(hkl_parameter_min_max_set(axisC, -100., 180., HKL_UNIT_USER, NULL));
+	res &= DIAG(hkl_parameter_min_max_set(axisT, 0.0, 179., HKL_UNIT_USER, NULL));
 
 	list = hkl_geometry_list_new();
 
 	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL,
 					      185. * HKL_DEGTORAD,
 					      -185. * HKL_DEGTORAD,
-					      185. * HKL_DEGTORAD));
+					      185. * HKL_DEGTORAD,
+					      0.1));
 	hkl_geometry_list_add(list, g);
 
 	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL,
 					      -190. * HKL_DEGTORAD,
 					      -190. * HKL_DEGTORAD,
-					      -190. * HKL_DEGTORAD));
+					      -190. * HKL_DEGTORAD,
+					      0.1));
 	hkl_geometry_list_add(list, g);
 
 	res &= DIAG(hkl_geometry_set_values_v(g, HKL_UNIT_DEFAULT, NULL,
 					      180. * HKL_DEGTORAD,
 					      180. * HKL_DEGTORAD,
-					      180. * HKL_DEGTORAD));
+					      180. * HKL_DEGTORAD,
+					      0.1));
 	hkl_geometry_list_add(list, g);
 
 	is_int(3, hkl_geometry_list_n_items_get(list), __func__);
@@ -459,7 +484,7 @@ static void  list_remove_invalid(void)
 
 int main(void)
 {
-	plan(51);
+	plan(48);
 
 	add_holder();
 	get_axis();
diff --git a/tests/hkl-interval-t.c b/tests/hkl-interval-t.c
index fe405f4..5dc7765 100644
--- a/tests/hkl-interval-t.c
+++ b/tests/hkl-interval-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-lattice-t.c b/tests/hkl-lattice-t.c
index 6293bae..418c5b2 100644
--- a/tests/hkl-lattice-t.c
+++ b/tests/hkl-lattice-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -51,13 +51,13 @@
 	}while(0)
 \
 #define SET_LATTICE(_lattice, _a, _b, _c, _alpha, _beta, _gamma) do{	\
-								 SET_PARAM(_lattice, a, _a);				\
-								 SET_PARAM(_lattice, b, _b);				\
-								 SET_PARAM(_lattice, c, _c);				\
-								 SET_PARAM(_lattice, alpha, _alpha);			\
-								 SET_PARAM(_lattice, beta, _beta);			\
-								 SET_PARAM(_lattice, gamma, _gamma);			\
-								 }while(0)
+SET_PARAM(_lattice, a, _a);				\
+SET_PARAM(_lattice, b, _b);				\
+SET_PARAM(_lattice, c, _c);				\
+SET_PARAM(_lattice, alpha, _alpha);			\
+SET_PARAM(_lattice, beta, _beta);			\
+SET_PARAM(_lattice, gamma, _gamma);			\
+}while(0)
 
 	static void new(void)
 	{
diff --git a/tests/hkl-matrix-t.c b/tests/hkl-matrix-t.c
index 5bae674..9dc245a 100644
--- a/tests/hkl-matrix-t.c
+++ b/tests/hkl-matrix-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-parameter-t.c b/tests/hkl-parameter-t.c
index 581a293..0dd6958 100644
--- a/tests/hkl-parameter-t.c
+++ b/tests/hkl-parameter-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-pseudoaxis-e4ch-t.c b/tests/hkl-pseudoaxis-e4ch-t.c
index 69c7ef9..328c0af 100644
--- a/tests/hkl-pseudoaxis-e4ch-t.c
+++ b/tests/hkl-pseudoaxis-e4ch-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -24,23 +24,26 @@
 #include <tap/basic.h>
 #include <tap/hkl-tap.h>
 
+#include "hkl/ccan/generator/generator.h"
+#include "hkl-geometry-private.h"
+#include "hkl-trajectory-private.h"
+
 static void getter(void)
 {
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E4ch(1.54, 0., 0., 0., 0.);
 
-	factory = hkl_factory_get_by_name("E4CH", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -76,20 +79,18 @@ static void degenerated(void)
 	HklEngine *engine;
 	const char **mode;
 	const darray_string *modes;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E4ch(1.54, 0., 0., 0., 0.);
 
-	factory = hkl_factory_get_by_name("E4CH", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
-
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
@@ -138,25 +139,23 @@ static void psi_getter(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	double hkl[3];
+	struct Geometry gconf = E4ch(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CH", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "psi", NULL);
 
 	/* the getter part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	hkl[0] = 1, hkl[1] = 0, hkl[2] = 0;
@@ -201,26 +200,24 @@ static void psi_setter(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {1, 0, 0};
+	struct Geometry gconf = E4ch(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CH", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "psi", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_parameters_values_set(engine, hkl, ARRAY_SIZE(hkl),
 						     HKL_UNIT_DEFAULT, NULL));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
@@ -263,25 +260,23 @@ static void q(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E4ch(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CH", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "q", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	darray_foreach(mode, *modes){
@@ -320,21 +315,20 @@ static void hkl_psi_constant_horizontal(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklGeometryList *geometries;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {1, 0, 1};
 	static double hkl2[] = {1, 1, 0};
+	struct Geometry gconf = E4ch(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CH", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -342,7 +336,6 @@ static void hkl_psi_constant_horizontal(void)
 	res &= DIAG(hkl_engine_current_mode_set(engine, "psi_constant", NULL));
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_parameters_values_set(engine, hkl2, ARRAY_SIZE(hkl2),
 						     HKL_UNIT_DEFAULT, NULL));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
@@ -369,9 +362,37 @@ static void hkl_psi_constant_horizontal(void)
 	hkl_geometry_free(geometry);
 }
 
+static void petra3_p01(void)
+{
+	int res = TRUE;
+	HklGeometryList *solutions;
+
+	struct Sample sample = {
+		.name = "Sample",
+		.lattice = Tetragonal(5.4, 11.9),
+		.ux = -90 * HKL_DEGTORAD,
+		.uy = 9 * HKL_DEGTORAD,
+		.uz = -45 * HKL_DEGTORAD,
+	};
+
+	struct Geometry gconfig = E4ch(4.3687,
+				       0., 0., 6., 0.);
+
+	struct Mode mode = ModeHklE4CHConstantPhi;
+
+	/* move between each step */
+	struct Trajectory tconfig1 = TrajectoryHklFromTo(0, 0, 4, 1, 1, 4, 30, mode);
+	solutions = Trajectory_solve(tconfig1, gconfig, sample, TRUE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_fprintf(stdout, solutions);
+	hkl_geometry_list_free(solutions);
+
+	ok(res == TRUE, __func__);
+}
+
 int main(void)
 {
-	plan(6);
+	plan(7);
 
 	getter();
 	degenerated();
@@ -379,6 +400,7 @@ int main(void)
 	psi_setter();
 	q();
 	hkl_psi_constant_horizontal();
+	petra3_p01();
 
 	return 0;
 }
diff --git a/tests/hkl-pseudoaxis-e4cv-t.c b/tests/hkl-pseudoaxis-e4cv-t.c
index 8ff64bc..23691a6 100644
--- a/tests/hkl-pseudoaxis-e4cv-t.c
+++ b/tests/hkl-pseudoaxis-e4cv-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -28,36 +28,35 @@ static void getter(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
-	HklGeometry *geom;
+	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CV", NULL);
-	geom = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
-	hkl_engine_list_init(engines, geom, detector, sample);
+	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
 
 	/* geometry -> pseudo */
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
+	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(check_pseudoaxes_v(engine, 0., 0., 1.));
 
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 30., 0., 90., 60.));
+	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 90., 60.));
 	res &= DIAG(check_pseudoaxes_v(engine, 1., 0., 0.));
 
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 30., 0., -90., 60.));
+	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., -90., 60.));
 	res &= DIAG(check_pseudoaxes_v(engine, -1., 0., 0.));
 
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 30., 0., 180., 60.));
+	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 180., 60.));
 	res &= DIAG(check_pseudoaxes_v(engine, 0., 0., -1.));
 
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 45., 0., 135., 90.));
+	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 45., 0., 135., 90.));
 	res &= DIAG(check_pseudoaxes_v(engine, 1., 0., -1.));
 
 	ok(res == TRUE, "getter");
@@ -65,7 +64,7 @@ static void getter(void)
 	hkl_engine_list_free(engines);
 	hkl_detector_free(detector);
 	hkl_sample_free(sample);
-	hkl_geometry_free(geom);
+	hkl_geometry_free(geometry);
 }
 
 static void degenerated(void)
@@ -75,18 +74,17 @@ static void degenerated(void)
 	HklEngine *engine;
 	const char **mode;
 	const darray_string *modes;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -135,25 +133,23 @@ static void psi_getter(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
-	HklGeometry *geom;
+	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	double hkl[3];
+	struct Geometry gconf = E4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CV", NULL);
-	geom = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
-	hkl_engine_list_init(engines, geom, detector, sample);
+	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "psi", NULL);
 
 	/* the getter part */
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	/* 1 0 0 */
@@ -191,7 +187,7 @@ static void psi_getter(void)
 	hkl_engine_list_free(engines);
 	hkl_detector_free(detector);
 	hkl_sample_free(sample);
-	hkl_geometry_free(geom);
+	hkl_geometry_free(geometry);
 }
 
 static void psi_setter(void)
@@ -201,26 +197,24 @@ static void psi_setter(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {1, 0, 0};
+	struct Geometry gconf = E4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "psi", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_parameters_values_set(engine, hkl, ARRAY_SIZE(hkl), HKL_UNIT_DEFAULT, NULL));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
@@ -261,25 +255,23 @@ static void q(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "q", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	darray_foreach(mode, *modes){
@@ -317,21 +309,20 @@ static void hkl_psi_constant_vertical(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklGeometryList *geometries;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {1, 0, 1};
 	static double hkl2[] = {1, 1, 0};
+	struct Geometry gconf = E4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -339,7 +330,6 @@ static void hkl_psi_constant_vertical(void)
 	res &= DIAG(hkl_engine_current_mode_set(engine, "psi_constant", NULL));
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 30., 0., 0., 60.));
 	res &= DIAG(hkl_engine_parameters_values_set(engine, hkl2, ARRAY_SIZE(hkl2), HKL_UNIT_DEFAULT, NULL));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
diff --git a/tests/hkl-pseudoaxis-e6c-t.c b/tests/hkl-pseudoaxis-e6c-t.c
index 2db88b8..cd97352 100644
--- a/tests/hkl-pseudoaxis-e6c-t.c
+++ b/tests/hkl-pseudoaxis-e6c-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -63,18 +63,17 @@ static void getter(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E6c(1.54, 0., 30., 0., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -110,19 +109,18 @@ static void degenerated(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {0, 0, 1};
+	struct Geometry gconf = E6c(1.54, 0., 30., 0., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -175,25 +173,23 @@ static void q2(void)
 	HklEngine *engine;
 	const char **mode;
 	const darray_string *modes;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = E6c(1.54, 0., 30., 0., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("E6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "q2", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 0., 30., 0., 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	darray_foreach(mode, *modes){
@@ -237,34 +233,25 @@ static void petra3(void)
 	HklEngineList *engines;
 	HklEngine *hkl;
 	HklEngine *psi;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklGeometryList *geometries;
 	HklDetector *detector;
 	HklSample *sample;
-	HklLattice *lattice;
-	HklMatrix *U;
-
-	factory = hkl_factory_get_by_name("E6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	res &= DIAG(hkl_geometry_wavelength_set(geometry, 2.033, HKL_UNIT_DEFAULT, NULL));
-
-	sample = hkl_sample_new("test");
-	lattice = hkl_lattice_new(7.813, 7.813, 7.813,
-				  90*HKL_DEGTORAD, 90*HKL_DEGTORAD, 90*HKL_DEGTORAD,
-				  NULL);
-	hkl_sample_lattice_set(sample, lattice);
-	hkl_lattice_free(lattice);
-
-	U = hkl_matrix_new_euler(-112.5 * HKL_DEGTORAD,
-				 -87.84 * HKL_DEGTORAD,
-				 157.48 * HKL_DEGTORAD);
-	hkl_sample_U_set(sample, U, NULL);
-	hkl_matrix_free(U);
+	struct Sample sconf = {
+		.name = "test",
+		.lattice = Cubic(7.813),
+		.ux = -112.5 * HKL_DEGTORAD,
+		.uy = -87.84 * HKL_DEGTORAD,
+		.uz = 157.48 * HKL_DEGTORAD,
+	};
+	struct Geometry gconf = E6c(2.033, 0., 30., 0., 0., 0., 60.);
+
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(sconf);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	/* set the psi pseudo axis */
@@ -313,17 +300,22 @@ static void petra3_2(void)
 	HklEngineList *engines;
 	HklEngine *hkl;
 	HklEngine *psi;
-	const HklFactory *factory;
 	const HklGeometryListItem *item;
 	HklGeometry *geometry;
 	HklGeometryList *geometries;
 	HklDetector *detector;
 	HklSample *sample;
-	HklLattice *lattice;
-	HklMatrix *U;
 	double PSI;
 	double hkl_p[4];
 	double psi_p[3];
+	struct Sample sconf = {
+		.name = "test",
+		.lattice = Cubic(5.1),
+		.ux = -90.0 * HKL_DEGTORAD,
+		.uy = 0.0 * HKL_DEGTORAD,
+		.uz = -90.0 * HKL_DEGTORAD,
+	};
+	struct Geometry gconf = E6c(1.0332035, 0., 30., 0., 0., 0., 60.);
 
 	/* Wavelength 1.0332035 */
 	/* Mode       psi_constant_vertical */
@@ -334,25 +326,13 @@ static void petra3_2(void)
 	/* A 5.1 B 5.1 C 5.1  */
 	/* Alpha 90 Beta 90 Gamma 90  */
 
-	factory = hkl_factory_get_by_name("E6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	res &= DIAG(hkl_geometry_wavelength_set(geometry, 1.0332035, HKL_UNIT_DEFAULT, NULL));
-
-	sample = hkl_sample_new("test");
-	lattice = hkl_lattice_new(5.1, 5.1, 5.1,
-				  90*HKL_DEGTORAD, 90*HKL_DEGTORAD, 90*HKL_DEGTORAD,
-				  NULL);
-	hkl_sample_lattice_set(sample, lattice);
-	hkl_lattice_free(lattice);
-	U = hkl_matrix_new_euler(-90.0 * HKL_DEGTORAD,
-				 0.0 * HKL_DEGTORAD,
-				 -90.0 * HKL_DEGTORAD);
-	hkl_sample_U_set(sample, U, NULL);
-	hkl_matrix_free(U);
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+
+	sample = newSample(sconf);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	/* set the hkl pseudo axis in psi_constant_vertical */
diff --git a/tests/hkl-pseudoaxis-k4cv-t.c b/tests/hkl-pseudoaxis-k4cv-t.c
index 7c5cf65..41f5e54 100644
--- a/tests/hkl-pseudoaxis-k4cv-t.c
+++ b/tests/hkl-pseudoaxis-k4cv-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -30,19 +30,18 @@ static void degenerated(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {0, 1, 0};
+	struct Geometry gconf = K4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("K4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -95,19 +94,18 @@ static void eulerians(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	static double eulerians[] = {0., 90 * HKL_DEGTORAD, 0.};
+	struct Geometry gconf = K4cv(1.54, 0., 0., 0., 0.);
 
-	factory = hkl_factory_get_by_name("K4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "eulerians", NULL);
@@ -170,18 +168,17 @@ static void q(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = K4cv(1.54, 30., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("K4CV", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "q", NULL);
diff --git a/tests/hkl-pseudoaxis-k6c-t.c b/tests/hkl-pseudoaxis-k6c-t.c
index 9f70d8c..9a230d8 100644
--- a/tests/hkl-pseudoaxis-k6c-t.c
+++ b/tests/hkl-pseudoaxis-k6c-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -30,19 +30,18 @@ static void degenerated(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	static double hkl[] = {0, 1, 0};
+	struct Geometry gconf = K6c(1.54, 0., 0., 0., 0., 0., 0.);
 
-	factory = hkl_factory_get_by_name("K6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
@@ -110,18 +109,17 @@ static void eulerians(void)
 	const darray_string *modes;
 	const char **mode;
 	const HklGeometryListItem *item;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = K6c(1.54, 0., 0., 0., 0., 0., 0.);
 
-	factory = hkl_factory_get_by_name("K6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "eulerians", NULL);
@@ -186,25 +184,23 @@ static void q2(void)
 	HklEngine *engine;
 	const darray_string *modes;
 	const char **mode;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = K6c(1.54, 0., 30., 0., 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("K6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "q2", NULL);
 	modes = hkl_engine_modes_names_get(engine);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 0., 30., 0., 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	darray_foreach(mode, *modes){
@@ -246,24 +242,22 @@ static void m15110(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
+	struct Geometry gconf = K6c(1.54, 0., 62.95, 134.75, 0., 0., 60.);
 
-	factory = hkl_factory_get_by_name("K6C", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	sample = hkl_sample_new("test");
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(cu);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "psi", NULL);
 
 	/* the init part must succed */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 0., 62.95, 134.75, 0., 0., 60.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	hkl_engine_list_free(engines);
diff --git a/tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c b/tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c
new file mode 100644
index 0000000..0b2fdeb
--- /dev/null
+++ b/tests/hkl-pseudoaxis-soleil-sirius-kappa-t.c
@@ -0,0 +1,102 @@
+/* This file is part of the hkl library.
+ *
+ * The hkl library 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.
+ *
+ * The hkl library 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 the hkl library.  If not, see <http://www.gnu.org/licenses/>.
+ *
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
+ *                         L'Orme des Merisiers Saint-Aubin
+ *                         BP 48 91192 GIF-sur-YVETTE CEDEX
+ *
+ * Authors: Picca Frédéric-Emmanuel <picca at synchrotron-soleil.fr>
+ */
+#include <tap/basic.h>
+#include <tap/float.h>
+#include <tap/hkl-tap.h>
+
+#include "hkl/ccan/generator/generator.h"
+#include "hkl-geometry-private.h"
+#include "hkl-trajectory-private.h"
+
+/* tests */
+
+static void stability(void)
+{
+	int res = TRUE;
+	HklGeometryList *solutions;
+
+	struct Sample gaas = {
+		.name = "GaAs",
+		.lattice = Cubic(5.6533),
+		.ux = -90.003382 * HKL_DEGTORAD,
+		.uy = 0.12907 * HKL_DEGTORAD,
+		.uz = -159.91372 * HKL_DEGTORAD,
+	};
+
+	struct Geometry gconfig =		\
+		SoleilSiriusKappa(1.458637,
+				  -0.5193202, 64.7853160, 133.5621380, -80.9690000, -0.0223369, 30.0000299);
+
+	struct Geometry gconfig2 =		\
+		SoleilSiriusKappa(1.458637,
+				  -0.5193202, 64.7853160, 133.5621380, 124.9690000, -0.0223369, 30.0000299);
+
+	struct Mode mode = ModeHklBissectorVertical;
+
+	/* move between each step */
+	struct Trajectory tconfig1 = TrajectoryHklFromTo(0, 0, 1, 0, 0, 6, 11, mode);
+	solutions = Trajectory_solve(tconfig1, gconfig, gaas, TRUE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig1, gconfig, gaas, TRUE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	struct Trajectory tconfig2 = TrajectoryHklFromTo(0, 0, 1, 0, 0, 6, 101, mode);
+	solutions = Trajectory_solve(tconfig2, gconfig, gaas, TRUE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig2, gaas, TRUE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	/* do not move between each steps */
+	solutions = Trajectory_solve(tconfig1, gconfig, gaas, FALSE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig1, gconfig, gaas, FALSE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig, gaas, FALSE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	solutions = Trajectory_solve(tconfig2, gconfig2, gaas, FALSE);
+	res &= DIAG(NULL != solutions);
+	hkl_geometry_list_free(solutions);
+
+	ok(res == TRUE, __func__);
+
+}
+
+int main(void)
+{
+	plan(1);
+
+	stability();
+
+	return 0;
+}
diff --git a/tests/hkl-pseudoaxis-soleil-sixs-med-t.c b/tests/hkl-pseudoaxis-soleil-sixs-med-t.c
index a700c05..f6bb12f 100644
--- a/tests/hkl-pseudoaxis-soleil-sixs-med-t.c
+++ b/tests/hkl-pseudoaxis-soleil-sixs-med-t.c
@@ -32,37 +32,41 @@
 				hkl_geometry_list_items_first_get((geometries))), \
 			"gamma", NULL), HKL_UNIT_USER)
 
+/* tests */
+
 static void qper_qpar(void)
 {
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
-	HklGeometry *geom;
+	HklGeometry *geometry;
 	HklDetector *detector;
 	HklSample *sample;
 	double qper_qpar[2];
 	double gamma;
 	HklGeometryList *geometries;
-	HklMatrix *U;
 
-	factory = hkl_factory_get_by_name("SOLEIL SIXS MED2+3", NULL);
-	geom = hkl_factory_create_new_geometry(factory);
+	static struct Sample gaas = {
+		.name = "test",
+		.lattice=Cubic(1.54),
+		.ux = -90.0 * HKL_DEGTORAD,
+		.uy = 0.0 * HKL_DEGTORAD,
+		.uz = 0.0 * HKL_DEGTORAD,
+	};
 
-	sample = hkl_sample_new("test");
-	U = hkl_matrix_new_euler(-90.0 * HKL_DEGTORAD, 0., 0.);
-	hkl_sample_U_set(sample, U, NULL);
-	hkl_matrix_free(U);
+	struct Geometry gconfig = SoleilSixsMed2_3(1.54, 0., 0.1, 0., 0., 90., 0.);
+
+	geometry = newGeometry(gconfig);
+	engines = newEngines(gconfig);
+	sample = newSample(gaas);
 
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
-	hkl_engine_list_init(engines, geom, detector, sample);
+	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	engine = hkl_engine_list_engine_get_by_name(engines, "qper_qpar", NULL);
 
 	/* the init part */
-	res &= DIAG(hkl_geometry_set_values_v(geom, HKL_UNIT_USER, NULL, 0., 0.1, 0., 0., 90., 0.));
 	res &= DIAG(hkl_engine_initialized_set(engine, TRUE, NULL));
 
 	/* gamma must be positif */
@@ -92,7 +96,7 @@ static void qper_qpar(void)
 	hkl_engine_list_free(engines);
 	hkl_detector_free(detector);
 	hkl_sample_free(sample);
-	hkl_geometry_free(geom);
+	hkl_geometry_free(geometry);
 }
 
 static void med_2_3(void)
@@ -100,45 +104,34 @@ static void med_2_3(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *hkl;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklGeometryList *geometries;
 	HklDetector *detector;
 	HklSample *sample;
-	HklLattice *lattice;
-	HklMatrix *U;
-	static double positions[] = {0, 1, -14.27, 99.62, 60.98, 0};
 	static double hkl_p[] = {1.95, 2, 6};
 
+	static struct Sample gaas = {
+		.name = "GaAs",
+		.lattice = Hexagonal(4.759, 12.992),
+		.ux = -90.59 * HKL_DEGTORAD,
+		.uy = -9.97 * HKL_DEGTORAD,
+		.uz = 176.35 * HKL_DEGTORAD,
+	};
+
+	static struct Geometry gconfig = SoleilSixsMed2_3(1.54980,
+							  0, 1, -14.27, 99.62, 60.98, 0);
+
 	/* Wavelength 1.54980 */
 	/* Mode       mu_fixed */
 	/* Ux -90.59 Uy -9.97 Uz 176.35  */
 	/* A 4.759 B 4.759 C 12.992  */
 	/* Alpha 90 Beta 90 Gamma 120  */
 
-	factory = hkl_factory_get_by_name("SOLEIL SIXS MED2+3", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-
-	res &= DIAG(hkl_geometry_axis_values_set(geometry,
-						 positions, ARRAY_SIZE(positions), HKL_UNIT_USER,
-						 NULL));
-	res &= DIAG(hkl_geometry_wavelength_set(geometry, 1.54980, HKL_UNIT_DEFAULT, NULL));
-
-	sample = hkl_sample_new("test");
-	lattice = hkl_lattice_new(4.759, 4.759, 12.992,
-				  90*HKL_DEGTORAD, 90*HKL_DEGTORAD, 120*HKL_DEGTORAD,
-				  NULL);
-	hkl_sample_lattice_set(sample, lattice);
-	hkl_lattice_free(lattice);
-	U = hkl_matrix_new_euler(-90.59 * HKL_DEGTORAD,
-				 -9.97 * HKL_DEGTORAD,
-				 176.35 * HKL_DEGTORAD);
-	hkl_sample_U_set(sample, U, NULL);
-	hkl_matrix_free(U);
-
+	geometry = newGeometry(gconfig);
+	engines = newEngines(gconfig);
+	sample = newSample(gaas);
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 
 	hkl = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
diff --git a/tests/hkl-pseudoaxis-t.c b/tests/hkl-pseudoaxis-t.c
index a851288..53840f2 100644
--- a/tests/hkl-pseudoaxis-t.c
+++ b/tests/hkl-pseudoaxis-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -36,7 +36,7 @@ static int __test(unsigned int nb_iter, test_func f, int foreach_mode)
 	size_t i, j, n;
 	HklGeometry *geometry = NULL;
 	HklDetector *detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
-	HklSample *sample = hkl_sample_new("test");
+	HklSample *sample = newSample(cu);
 	HklEngineList *engines;
 	int res = TRUE;
 	const char **mode;
diff --git a/tests/hkl-pseudoaxis-zaxis-t.c b/tests/hkl-pseudoaxis-zaxis-t.c
index b0623b6..d397034 100644
--- a/tests/hkl-pseudoaxis-zaxis-t.c
+++ b/tests/hkl-pseudoaxis-zaxis-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -28,44 +28,31 @@ static void solution(void)
 	int res = TRUE;
 	HklEngineList *engines;
 	HklEngine *engine;
-	const HklFactory *factory;
 	HklGeometry *geometry;
 	HklGeometryList *geometries;
 	HklDetector *detector;
 	HklSample *sample;
-	HklLattice *lattice;
 	static double hkl[] = {1, 1, 0};
-	HklMatrix *U;
+	static struct Sample sconf = {
+		.name = "test",
+		.lattice = Cubic(5.432),
+		.ux = -90.0 * HKL_DEGTORAD,
+		.uy = 0.0  * HKL_DEGTORAD,
+		.uz = 0.0  * HKL_DEGTORAD,
+	};
+	struct Geometry gconf = Zaxis(0.842, 1., 0., 0., 0.);
 
-	/* get the geometry and set the source */
-	factory = hkl_factory_get_by_name("ZAXIS", NULL);
-	geometry = hkl_factory_create_new_geometry(factory);
-	res &= DIAG(hkl_geometry_wavelength_set(geometry, 0.842, HKL_UNIT_DEFAULT, NULL));
-
-	/* set up the sample */
-	sample = hkl_sample_new("test");
-	lattice = hkl_lattice_new(5.432, 5.432, 5.432,
-				  90 * HKL_DEGTORAD,
-				  90 * HKL_DEGTORAD,
-				  90 * HKL_DEGTORAD,
-				  NULL);
-	hkl_sample_lattice_set(sample, lattice);
-	U = hkl_matrix_new_euler(-90*HKL_DEGTORAD, 0, 0);
-	hkl_sample_U_set(sample, U, NULL);
-	hkl_lattice_free(lattice);
-	hkl_matrix_free(U);
+	geometry = newGeometry(gconf);
+	engines = newEngines(gconf);
+	sample = newSample(sconf);
 
 	/* use a 0D detector */
 	detector = hkl_detector_factory_new(HKL_DETECTOR_TYPE_0D);
 
 	/* select the hkl pseudo axis */
-	engines = hkl_factory_create_new_engine_list(factory);
 	hkl_engine_list_init(engines, geometry, detector, sample);
 	engine = hkl_engine_list_engine_get_by_name(engines, "hkl", NULL);
 
-	/* the init part must succed */
-	res &= DIAG(hkl_geometry_set_values_v(geometry, HKL_UNIT_USER, NULL, 1., 0., 0., 0.));
-
 	/* compute the 1 1 0 */
 	geometries = hkl_engine_pseudo_axis_values_set(engine, hkl, ARRAY_SIZE(hkl),
 						       HKL_UNIT_DEFAULT, NULL);
diff --git a/tests/hkl-quaternion-t.c b/tests/hkl-quaternion-t.c
index 931400a..ff61583 100644
--- a/tests/hkl-quaternion-t.c
+++ b/tests/hkl-quaternion-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-sample-t.c b/tests/hkl-sample-t.c
index a90883d..c5430d8 100644
--- a/tests/hkl-sample-t.c
+++ b/tests/hkl-sample-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-source-t.c b/tests/hkl-source-t.c
index 50fc3a2..10b2b4c 100644
--- a/tests/hkl-source-t.c
+++ b/tests/hkl-source-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-unit-t.c b/tests/hkl-unit-t.c
index d7f33b5..bf13ebe 100644
--- a/tests/hkl-unit-t.c
+++ b/tests/hkl-unit-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl-vector-t.c b/tests/hkl-vector-t.c
index 64b04de..6f78c25 100644
--- a/tests/hkl-vector-t.c
+++ b/tests/hkl-vector-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
diff --git a/tests/hkl3d-test-t.c b/tests/hkl3d-test-t.c
index 0b9eb78..0fb780c 100644
--- a/tests/hkl3d-test-t.c
+++ b/tests/hkl3d-test-t.c
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2010-2016 Synchrotron SOLEIL
+ * Copyright (C) 2010-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -68,11 +68,12 @@ static void check_collision(Hkl3D *hkl3d)
 {
 	char buffer[1000];
 	int res = TRUE;
+	double values[] = {23, 0., 0., 0., 0., 0.};
 
 	/* check the collision and that the right axes are colliding */
-	res &= DIAG(hkl_geometry_set_values_v(hkl3d->geometry->geometry,
-					      HKL_UNIT_USER, NULL,
-					      23., 0., 0., 0., 0., 0.));
+	res &= DIAG(hkl_geometry_axis_values_set(hkl3d->geometry->geometry,
+						 values, ARRAY_SIZE(values),
+						 HKL_UNIT_USER, NULL));
 
 	res &= DIAG(hkl3d_is_colliding(hkl3d) == TRUE);
 	strcpy(buffer, "");
@@ -101,7 +102,7 @@ static void check_collision(Hkl3D *hkl3d)
 static void check_no_collision(Hkl3D *hkl3d)
 {
 	int res = TRUE;
-	int i;
+	double i;
 
 	/* check that rotating around komega/kappa/kphi do not create collisison */
 	res &= DIAG(hkl_geometry_set_values_v(hkl3d->geometry->geometry,
@@ -109,25 +110,31 @@ static void check_no_collision(Hkl3D *hkl3d)
 					      0., 0., 0., 0., 0., 0.));
 	/* komega */
 	for(i=0; i<=360; i=i+10){
-		res &= DIAG(hkl_geometry_set_values_v(hkl3d->geometry->geometry,
-						      HKL_UNIT_USER, NULL,
-						      0., i, 0., 0., 0., 0.));
+		double values[] = {0., i, 0., 0., 0., 0.};
+
+		res &= DIAG(hkl_geometry_axis_values_set(hkl3d->geometry->geometry,
+							 values, ARRAY_SIZE(values),
+							 HKL_UNIT_USER, NULL));
 		res &= DIAG(hkl3d_is_colliding(hkl3d) == FALSE);
 	}
 
 	/* kappa */
 	for(i=0; i<=360; i=i+10){
-		res &= DIAG(hkl_geometry_set_values_v(hkl3d->geometry->geometry,
-						      HKL_UNIT_USER, NULL,
-						      0., 0., i, 0., 0., 0.));
+		double values[] = {0., 0., i, 0., 0., 0.};
+
+		res &= DIAG(hkl_geometry_axis_values_set(hkl3d->geometry->geometry,
+							 values, ARRAY_SIZE(values),
+							 HKL_UNIT_USER, NULL));
 		res &= DIAG(hkl3d_is_colliding(hkl3d) == FALSE);
 	}
 
 	/* kphi */
 	for(i=0; i<=360; i=i+10){
-		res &= DIAG(hkl_geometry_set_values_v(hkl3d->geometry->geometry,
-						      HKL_UNIT_USER, NULL,
-						      0., 0., 0., i, 0., 0.));
+		double values[] = {0., 0., 0., i, 0., 0.};
+
+		res &= DIAG(hkl_geometry_axis_values_set(hkl3d->geometry->geometry,
+							 values, ARRAY_SIZE(values),
+							 HKL_UNIT_USER, NULL));
 		res &= DIAG(hkl3d_is_colliding(hkl3d) == FALSE);
 	}
 	ok(res == TRUE, "no-collision");
diff --git a/tests/tap/Makefile.in b/tests/tap/Makefile.in
index 22df8e3..df5bf74 100644
--- a/tests/tap/Makefile.in
+++ b/tests/tap/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.15 from Makefile.am.
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2014 Free Software Foundation, Inc.
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -219,6 +219,7 @@ GLIB_LIBS = @GLIB_LIBS@
 GLIB_MKENUMS = @GLIB_MKENUMS@
 GLU_CFLAGS = @GLU_CFLAGS@
 GLU_LIBS = @GLU_LIBS@
+GNUPLOT = @GNUPLOT@
 GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
 GOBJECT_LIBS = @GOBJECT_LIBS@
 GOBJECT_QUERY = @GOBJECT_QUERY@
diff --git a/tests/tap/basic.h b/tests/tap/basic.h
index f76dd13..82098ed 100644
--- a/tests/tap/basic.h
+++ b/tests/tap/basic.h
@@ -124,24 +124,24 @@ void diag_file_remove(const char *file)
 
 /* Allocate memory, reporting a fatal error with bail on failure. */
 void *bcalloc(size_t, size_t)
-__attribute__((__alloc_size__(1, 2), __malloc__, __warn_unused_result__));
+	__attribute__((__alloc_size__(1, 2), __malloc__, __warn_unused_result__));
 void *bmalloc(size_t)
-__attribute__((__alloc_size__(1), __malloc__, __warn_unused_result__));
+	__attribute__((__alloc_size__(1), __malloc__, __warn_unused_result__));
 void *breallocarray(void *, size_t, size_t)
-__attribute__((__alloc_size__(2, 3), __malloc__, __warn_unused_result__));
+	__attribute__((__alloc_size__(2, 3), __malloc__, __warn_unused_result__));
 void *brealloc(void *, size_t)
-__attribute__((__alloc_size__(2), __malloc__, __warn_unused_result__));
+	__attribute__((__alloc_size__(2), __malloc__, __warn_unused_result__));
 char *bstrdup(const char *)
-__attribute__((__malloc__, __nonnull__, __warn_unused_result__));
+	__attribute__((__malloc__, __nonnull__, __warn_unused_result__));
 char *bstrndup(const char *, size_t)
-__attribute__((__malloc__, __nonnull__, __warn_unused_result__));
+	__attribute__((__malloc__, __nonnull__, __warn_unused_result__));
 
 /*
  * Find a test file under BUILD or SOURCE, returning the full path.  The
  * returned path should be freed with test_file_path_free().
  */
 char *test_file_path(const char *file)
-__attribute__((__malloc__, __nonnull__, __warn_unused_result__));
+	__attribute__((__malloc__, __nonnull__, __warn_unused_result__));
 void test_file_path_free(char *path);
 
 /*
@@ -149,7 +149,7 @@ void test_file_path_free(char *path);
  * returned path should be freed with test_tmpdir_free.
  */
 char *test_tmpdir(void)
-__attribute__((__malloc__, __warn_unused_result__));
+	__attribute__((__malloc__, __warn_unused_result__));
 void test_tmpdir_free(char *path);
 
 /*
@@ -164,7 +164,7 @@ void test_tmpdir_free(char *path);
  */
 typedef void (*test_cleanup_func)(int, int);
 void test_cleanup_register(test_cleanup_func)
-__attribute__((__nonnull__));
+	__attribute__((__nonnull__));
 
 END_DECLS
 
diff --git a/tests/tap/hkl-tap.h b/tests/tap/hkl-tap.h
index 4dde2aa..2379e56 100644
--- a/tests/tap/hkl-tap.h
+++ b/tests/tap/hkl-tap.h
@@ -13,7 +13,7 @@
  * You should have received a copy of the GNU General Public License
  * along with the hkl library.  If not, see <http://www.gnu.org/licenses/>.
  *
- * Copyright (C) 2003-2016 Synchrotron SOLEIL
+ * Copyright (C) 2003-2017 Synchrotron SOLEIL
  *                         L'Orme des Merisiers Saint-Aubin
  *                         BP 48 91192 GIF-sur-YVETTE CEDEX
  *
@@ -23,6 +23,7 @@
 #define __HKL_TAP_H__
 
 #include "hkl.h"
+#include "hkl/api2/hkl2.h"
 
 #define STRINGIFY(x) #x
 #define TOSTRING(x) STRINGIFY(x)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/hkl.git



More information about the debian-science-commits mailing list