Data properties (original data)
============================================================

Test data derived from a simple abdomen CT scan.
 - 61 slices numbered 100-160
 - SOP class "CT Image Storage"
 - first slice at -160.671875 -311.671875 -285
 - second slice at -160.671875 -311.671875 -281
 - and so on, always 4mm distance
 - image orientation 1\0\0\0\1\0
 - pixel spacing 5.25\5.25
 
Test data for real life tilted gantry scans:
 - 5 slices numbered 161-165

Data modification for this test set
============================================================

 - downsampled to resolution 64x64 
   (using the helpful dicom2 tool of Sébastien Barré: http://www.barre.nom.fr/medical/dicom2/)
 - anonymized as much as possible by removing or re-inventing patient, institution, protocol data
   (using dcmodify from the DICOM toolkit DCMTK of OFFIS: http://support.dcmtk.org/docs/index.html)
 - files 100 to 119 were changed to be different from the other images:
   - 100-111 have a different orientation (2° change including a little error in string representation of floats)
   - 106-111 have image positions that share a line along the image normal direction (usual CT)
   - 100-105 have image positions that do not share a line along the image normal direction (tilted gantry CT)
   - 117-118 have a spacing of (5\5) (instead of 5.25\5.25)
   - 119 
     - reports (0008,0016) SOPClassUID = MRImageStorage
     - reports (0018,0088) Spacing Between Slices = -0.335
 - files 120 to 122 have variants a/b/c/d with identical positions but later acquisition times. This imitates 3D+t series
 - files 150-156 have variants x (150x, 151x, etc.) that imitated interleaved slice stacks, 
     i.e. when loading e.g. files 140 - 153 including 150x-156x, there should be two 3D blocks
     the x variants are shifted 1mm in z direction

Notes on modifications (to verify or repeat them)

Files 100-111:
  Orientation changed by 2° (rotation along x axis):
   - old Y vector [0,1,0] new Y vector [0, sin(90+2°), cos(90+2°)]: [0, 0.9993908270191, -0.0348994967025]

  Old/normal/tilted origin-to-origin vector: [0,0,4]

Files 106-111:
  Origin-to-origin vector for the rotated slices: 
   - normal of [1,0,0] and [0, 0.9993908270191, -0.0348994967025] : [0, 0.0348994967025, 0.999390827019]
   - times 4 (same z spacing as before): [0, 0.13959798681, 3.9975633080764]

  Position of slice n was calculated like this: 
  {-159.672,-309.97388506595,-69.01218345962} + 4*n* Cross[{1, 0, 0}, {0, 0.9993908270191, -0.0348994967025}]

  Numbers rounded to fit into the 16 bytes of a DS field.

Verifiction of above manipulations:

ALL files:
> dcmdump 10? 110 111 | grep 'Ori' |sort |uniq
(0020,0037) DS [1\0\0\0\0.9993908270141\-0.0348994967035] #  40, 6 ImageOrientationPatient
(0020,0037) DS [1\0\0\0\0.9993908270191\-0.0348994967025] #  40, 6 ImageOrientationPatient

Files 106-111
> dcmdump 10[6789] 110 111 | grep 'ImagePos'
(0020,0032) DS [-159.672\-309.2758951319\-49.02436691924] #  40, 3 ImagePositionPatient
(0020,0032) DS [-159.672\-309.41549311871\-53.021930227314] #  42, 3 ImagePositionPatient
(0020,0032) DS [-159.672\-309.55509110552\-57.019493535391] #  42, 3 ImagePositionPatient
(0020,0032) DS [-159.672\-309.69468909233\-61.017056843467] #  42, 3 ImagePositionPatient
(0020,0032) DS [-159.672\-309.83428707914\-65.014620151544] #  42, 3 ImagePositionPatient
(0020,0032) DS [-159.672\-309.97388506595\-69.01218345962] #  42, 3 ImagePositionPatient

