The camssim task generates a set of sinusoidal motions of the Hitomi EOB for both rotational and translational motions. From these simulated motions, camssim calculates the amount by which each of the two CAMS units moves and optionally, the amount by which an HXI unit moves.
The motion is simulated as a combination of six sinusoids, two in each perpendicular linear direction (X and Y) and two in rotation (twist). The amplitudes of the six motions can be set independently, and two different frequencies can be set. The linear motions can also be chosen (using the 'typemotion' parameter) to be in phase, 90 degrees out of phase, or 180 degrees out of phase.
The six independent amplitudes can be set as parameters 'xamp1', 'xamp2', 'yamp1', 'yamp2' (in mm for translation), and 'ramp1', 'ramp2' (in mrad for twist). The two independent frequencies can also be set as parameters 'freq1' and 'freq2'. The output values (in the coordinates of the CAMS units) are 'delta_x', the resulting motion in the X-direction, 'delta_y', the motion in the Y-direction, and 'gamma', the twist angle. Using these definitions, the three possible types of motion are as follows, with time as the independent variable.
It is also possible to add random error to the simulated CAMS measurements. Calling "randn" a normally-distributed random number and "freqerr" the frequency of the time-dependent part, and using the three input parameters 'randerr', 'sinerr', and 'consterr', representing respectively the amplitudes of a random error, a time-varying error, and a constant error. The errors are derived as:
camssim infile1=hxi1_events.fits infile2=hxi2_events.fits outroothxi=outputhxi outrootcams=utputcams clobber=yes
camssim infile1=hxi1_events.fits infile2=hxi2_events.fits outroothxi=outputhxi outrootcams=outputcams freq1=10.0 \ freq2=0.5 xamp1=2.5 xamp2=3.6 yamp1=1.5 yamp2=2.1 ramp1=0.0 ramp2=0.0 typemotion=3 clobber=yes
camssim infile1=hxi1_events.fits infile2=hxi2_events.fits outroothxi=outputhxi outrootcams=outputcams freq1=10.0 \ freq2=0.5 xamp1=2.5 xamp2=3.6 yamp1=1.5 yamp2=2.1 ramp1=0.0 ramp2=0.0 typemotion=3 clobber=yes randerr=0.5 consterr=0.1 \ sinerr=0.95 freqerr=60.0