| The example data contain measurement data files: | |
| "GaAs ref cell closer 20ms 16repeat 100mAbiasLED 800mV bias 256x256 +390+330.txt" | |
| An example of the corresponding reconstructed image is given in: | |
| "output.txt" | |
| Measurement data files contain tab delimited text data with one line per measurement comprising a pattern index followed by a measured current. | |
| Data are generated by illuminating a sample with split Hadamard patterns while simultaneously measuring the sample's output current. | |
| *** Measurement theory *** | |
| In principle, the measured current corresponds to the sum of photocurrent generated by the measurement pattern plus a constant background current. In vector form this is written: | |
| y = Phi*x + y_0 | |
| where y (vector) is the measured current, x (vector) is the photocurrent response of the sample (the measurand) and Phi is a matrix containing all of the measurement patterns as rows. | |
| *** Pattern generation *** | |
| Split Hadamard patterns are 2D binary patterns with 2^oRow rows and 2^oCol columns. Each one is generated by mapping a row of a 2^(oRow+oCol) x 2^(oRow+oCol) Hadamard matrix onto a 2D array. The pattern index tells us which row of the Hadamard matrix is used for each Split Hadamard pattern. Elements of Hadamard matrices are -1 or +1, whereas the measurement system uses binary arrays of 0, +1. Each row of the Hadamard array is split into a pair of binary patterns: a positive pattern and a negative pattern. In the positive pattern the -1 elements of the Hadamard vector are replaced with 0, but the +1 elements remain the same. The negative pattern is generated by taking the positive pattern and swapping 1s and 0s. | |
| For example, if the ith row of the 4x4 Hadamard matrix is | |
| Phi_i = [+1 +1 -1 -1]; | |
| Then the positive 2D pattern mapped into a 2x2 2D array is: | |
| H+_i = [1 1] | |
| [0 0] | |
| and the negative pattern is: | |
| H-_i = [0 0] | |
| [1 1] | |
| The rows of the Hadamard matrix are ordered such that the pattern resolution increases with increasing index. | |
| *** Image reconstruction *** | |
| Images can be reconstructed using the inverse Hadamard transform. To do this, the measurements must be sorted into natural Hadamard order and the differential between measurements of positive and negative patterns should be taken. An example of this is given in the accompanying MATLAB Live Script "partialReconstruction.mlx". | |