X-ray Talbot interferometry, differential phase image

Version 1.0.6 (10.1 MB) by Karol Vegso
This m-file calculates the differential phase image measured by X-ray Talbot or grating interferometry
35 Downloads
Updated 12 Dec 2022

View License

The differential phase image is calculated from 5 foreground and 5 background images measured by X-ray Talbot interferomerty. The sample was polypropylene sample. In the X-ray measurement, there were phase and amplitude gratings. The amplitude grating was used for scanning. The amplitiude grating in fringe scanning technique was moved five times. Therefore, M parameter is equal to 5. The measured images have size 1536 x 512 pixels (H x V). In other words, 1536 columns and 512 rows. The foreground and background images are encoded as unsigned 16 bit images with little endian byte order. The logic here is that intensity values for single pixel for different amplitude grating displacements produce sine curve. You could do sinusoidal fitting, but I use here Prof. Atsushi Momose approach. The intensity values in single pixel for 5 amplitude grating displacements are used to calculate complex number for this single pixel. The argumnet of this complex number can be calculated using angle function. You can then calculate argument for every pixel of foreground and background images. The argument of compelx number is actually angular value. The phase values or angles for foreground are stored in phase_image_fg. The phase values or angles for background are stored in phase_image_bg. The subtraction of phase_image_fg and phase_image_bg generates differential phase image. The final differential phase image is stored as double or 64bit real number image with little endian byte order as well. The raw images attached to this contribution were measured by laboratory of Prof. Atsushi Momose from Tohoku University in Sendai, Japan. You can try to calculate absorbtion or visibility (dark field) image from the image data.

Cite As

Karol Vegso (2025). X-ray Talbot interferometry, differential phase image (https://www.mathworks.com/matlabcentral/fileexchange/121862-x-ray-talbot-interferometry-differential-phase-image), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2021b
Compatible with R2021b to R2022b
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

XTI_dph_image_calculator_Momose_approach_CPU

Version Published Release Notes
1.0.6

The raw 16-bit unsigned images as input for calculation differential phase image replaced by correct ones. The background raw images are now correct.

1.0.5

I changed raw 16-bit unsigned encoded images. The new raw images for the background are correct.

1.0.4

I added foreground and background images measured by X-ray Talbot Interferometry so that the person interested in this m-script can try something by himself or herself.

1.0.3

I added raw images fro the foreground and background to allow the user to try analysis by himself.

1.0.2

I added raw images for foreground and background images for calculation.

1.0.1

I try to update the m-script together with raw images.

1.0.0