Introduction

Suppose that coherent visible-light plane waves normally illuminate a thin lens made of glass that is slightly cloudy. For such a lens, a large percentage of the light will be coherently focused or defocused upon propagation beyond the lens. Conversely, a small percentage of the light will be diffusely scattered by the random cloudy inclusions within the glass. In the hard-x-ray analogue of this experiment, replace the glass lens with a thin semi-transparent sample whose large-scale projected structure locally resembles an aberrated converging or diverging lens (see Fig. 1(a)), and replace the cloudy inclusions with unresolved random micro-structure within the volume of the sample (Fig. 1(b)). For hard x rays we will often have a situation where both coherent and diffuse scatter are narrowly peaked in the forward direction. With reference to Fig. 1(a), consider the “near field” regime where the object-to-detector distance Δ is significantly smaller than the focal length of the “local lenses” of which the sample is considered to be comprised: see e.g. the “local diverging lens” at A, and the “local converging lens” at C, the nominal focal length f for each lens being much larger than Δ. This is the key situation, of combined coherent and diffusive energy transport in a near-field paraxial imaging setting, that we wish to consider in the present paper. While we focus on the case of hard x rays, the methods considered here will also be applicable to paraxial imaging using visible light, electrons, neutrons etc.

Figure 1
figure 1

(a) Specular refraction by a thin object and associated propagation-based phase contrast (local concentration and rarefaction of photon energy density) associated with coherent energy transport downstream of the object. (b) Diffuse scattering by a thin object and associated propagation-based blurring associated with diffusive energy transport downstream of the object. Paraxial coherent energy transport may be modelled using the transport-of-intensity equation (see Eq. (1)), while paraxial diffusive energy transport may be modelled using the diffusion equation (see Eq. (5)). The Fokker–Planck equation can simultaneously model both effects, for small Δ—see Eq. (10), together with the Kramers–Moyal generalisation in Eq. (51).

We make the simplifying assumptions that: (i) magnetic effects such as x-ray circular dichroism in the sample can be ignored; (ii) the sample is non-crystalline, allowing x-ray Bragg-diffraction effects to be ignored; (iii) the sample is sufficiently thin that dynamical x-ray diffraction effects, within the volume of the sample, can also be ignored; (iv) all polarisation-sensitive effects can be ignored. Many well-known means exist, for the quantitative modelling of an x-ray beam interacting with such a sample and subsequently forming a paraxial image as it propagates through space1,2,3. One of the most often-employed, and most elementary, means is to first use the projection approximation to quantify the passage of an incident coherent scalar x-ray beam through the sample, and then use the Fresnel diffraction formalism to propagate the resulting exit-surface wave field to the surface of a detector1,4. The projection approximation assumes that: (i) the radiation is of sufficiently high energy that individual rays within the sample (more precisely, streamlines of the energy-flow vector within the sample) are unchanged within the volume of the said sample in comparison to the streamlines that would have existed in the absence of the sample, and (ii) both phase and amplitude shifts are accumulated continuously and locally, as one traverses any such ray from the entrance surface of the sample to the exit surface–see e.g. Sec. 2.2 of Paganin4. The Fresnel approximation, which is a consequence of the paraxial approximation, assumes that spherical Huygens-type wavelets can be approximated as having parabolic wave fronts. If the sample-to-detector propagation distance is sufficiently small, and if diffuse scattering is negligible, Fresnel diffraction implies that the transport-of-intensity equation5 (TIE) may be used to model the evolution of image intensity with respect to propagation distance downstream of the sample, for a paraxial quasi-monochromatic beam. The TIE, which is the continuity equation for paraxial wave fields, expresses local energy conservation6. It forms a basis for several imaging techniques in coherent x-ray optics1,4,7. Like the formalism of Fresnel diffraction upon which it is based, the TIE models what may be called “coherent energy transport” downstream of a thin sample. That is, at each point in the space downstream of the sample, there is one time-independent energy-flow vector (Poynting vector proportional to the intensity multiplied by the gradient of the wave-field phase8,9,10). However, if there is unresolved spatially random micro-structure within the sample11, then, as hinted in our opening paragraph, small-angle x-ray scatter12 (SAXS) will also be present. This augments the previously mentioned coherent energy-flow vector at each point in space, with an ensemble (“SAXS fan”) of energy-flow vectors associated with diffusive energy transport. How can this additional effect be taken into account, in modelling paraxial hard x-ray imaging of thin objects?

One answer is provided by a more general equation than the TIE, namely the the Fokker–Planck equation13. The latter equation, which can model flows in radiation and matter wave fields that have both a coherent and a diffusive component, may be obtained in a very general setting as a limit case of the still more general Boltzmann equation of classical statistical mechanics14. The Fokker–Planck equation is used in many fields: examples include Brownian motion14, hydrodynamics15, electron and photon transport in biological tissues16,17 and homogeneous media18, high-temperature atomic-level disorder in pre-melting surfaces19, gaseous micro-flows20, droplet nucleation21, dilute polymer dynamics22, hot plasmas23, biaxial fluids24, cold turbulent gas jets25 and quark gluon plasmas26. Notable also is the use of the Fokker–Planck equation in the non-imaging context of x-ray kinematical and dynamical diffraction from imperfect crystals with stochastically distributed defects27,28. An extremely recent application, which is particularly close to that developed in the present paper, uses Fokker–Planck concepts to model the position probability density of a nano-particle in a near-field optical trap29.

The Fokker–Planck equation is also useful for x-ray imaging, since this is a setting where both coherent and diffusive energy flows are present. This equation can simultaneously model four effects, resulting from the illumination of a thin object by normally incident coherent x-ray plane waves:

  • Local absorption by the object (attenuation contrast, known since the 1895 discovery of x rays by Röntgen30);

  • Local lensing by the object which concentrates or rarefies energy density due to local focusing or defocusing (propagation-based Laplacian-type phase contrast31);

  • Local prism-like effects of the object which transversely shift optical energy (propagation-based differential phase contrast31);

  • Local blurring with a position-dependent point spread function, associated with the SAXS fan emerging from each point at the exit of the object.

The first three effects are associated with the “TIE part” of the Fokker–Planck equation, with the fourth effect associated with the “diffusion equation” part. Of particular interest is the use of an x-ray form of the Fokker–Planck equation for modelling forward problems in paraxial x-ray imaging in a simple manner, e.g. by expressions valid in the near field (small propagation distance, Fresnel number32 \({N}_{{\rm{F}}}\gg 1\)) that are of first-order accuracy with respect to the sample-to-detector propagation distance. A Kramers–Moyal13 extension will also be of use when a more detailed treatment of the SAXS, emanating from each point over the exit surface of the object, is required. We anticipate that the resulting formalism will be of use in forward problems related to using x rays to image thin objects, as well as inverse problems such as phase/amplitude/diffusion-tensor recovery in both two and three dimensions (the latter constitutes the field of tensor tomography33,34,35,36,37,38).

We close this introduction by outlining the remainder of the paper. The x-ray Fokker–Planck model is derived in two complementary ways. The first derivation considers the Fokker–Planck equation to be a fusing of (i) the transport-of-intensity equation for coherent energy transport in paraxial monochromatic x-ray beams, with (ii) the diffusion equation for diffusive paraxial energy transport associated with small-angle x-ray scattering within a sample. The second derivation is a microscopic treatment based on first principles, which relies on the crucial assumption that the phase at the exit surface of the object can be written as a sum of (i) a component that varies slowly with respect to the detector pixel size, and (ii) a component that fluctuates many times over one detector pixel and is therefore unresolved. We then give a generalised form of the Fokker–Planck equation, known as the Kramers–Moyal equation, as a means for treating the in-sample SAXS in a more precise manner. Next we sketch some indicative means by which the Fokker–Planck and Kramers–Moyal equations may be used in the forward problem of modelling near-field intensity contrast in coherent x-ray imaging, together with the associated inverse problem of phase retrieval and SAXS determination. We also consider some broader implications of the Fokker–Planck formalism.

Fokker–Planck model for x-ray imaging

Here we give two complementary derivations of the x-ray Fokker–Planck equation. The first is phenomenological, based on local conservation of energy in the presence of both coherent and diffusive paraxial x-ray energy transport. The second is a microscopic first-principles analysis. The former derivation is more general, while the latter is more physically illuminating.

X-ray Fokker–Planck equation: Transport-of-intensity equation with a diffusive term

X-ray beams “flow” in the sense that they stream optical energy as they propagate. As a descriptor of such energy flows, the Fokker–Planck equation may be viewed as a diffusive generalisation of coherent paraxial photon energy transport. Adopting this perspective, below we consider the transport-of-intensity equation5 for coherent paraxial x-ray energy transport and then separately consider the diffusion equation for diffusive paraxial x-ray energy transport. We then show that these two equations may be merged, in a manner that conserves energy both locally and globally, to give the Fokker–Planck equation for paraxial x-ray imaging.

Transport-of-intensity equation for coherent paraxial energy transport

The transport-of-intensity equation5 describes the intensity evolution of a paraxial complex coherent scalar wave field as it propagates. This continuity equation, arising from the parabolic equation of paraxial scalar wave optics, expresses local energy conservation. It states that the negative divergence – which may loosely be spoken of as the “convergence” – of the transverse Poynting vector (energy flow vector) is proportional to the longitudinal rate of change of intensity5:

$$\frac{{\rm{\partial }}}{{\rm{\partial }}z}I(x,y,z)=-\frac{1}{k}{{\rm{\nabla }}}_{\perp }\cdot [I(x,y,z){{\rm{\nabla }}}_{\perp }\varphi (x,y,z)].$$
(1)

Here, I is the intensity of the monochromatic scalar wave field, ϕ is its phase, k is the wave-number and is the gradient in (x, y) planes perpendicular to the optical axis z. Equation (1) quantifies the fact that energy density (and hence intensity) increases with increasing propagation distance for locally-converging waves, and decreases with increasing propagation distance for locally-diverging waves.

As previously mentioned, the TIE is a continuity equation expressing local energy conservation under coherent x-ray energy transport. The conserved (Noether39) current is the transverse Poynting vector, which up to a multiplicative constant is4,8,10

$$I(x,y,z)\,{{\rm{\nabla }}}_{\perp }\varphi (x,y,z)/k\equiv {{\bf{J}}}_{\perp }^{(1)}(x,y,z).$$
(2)

The corresponding constant Noether charge \({\mathfrak{N}}\) is the total integrated intensity over any plane perpendicular to the optical axis:

$${\mathfrak{N}}=\iint I(x,y,z)\,dx\,dy,\hspace{10pt}z\ge 0.$$
(3)

For propagation in vacuo through a distance Δ ≥ 0 that is sufficiently small for the Fresnel number to be much greater than unity, a longitudinal finite-difference approximation to the TIE can be used to model the resulting propagation-based phase contrast4:

$$\begin{array}{ccc}I(x,y,z=\Delta ) & = & I(x,y,z=0)-(\Delta /k){\{{{\rm{\nabla }}}_{\perp }\cdot [I(x,y,z){{\rm{\nabla }}}_{\perp }\varphi (x,y,z)]\}}_{z=0}\\ & = & I(x,y,z=0)-(\Delta /k)\{I(x,y,z){{\rm{\nabla }}}_{\perp }^{2}\varphi (x,y,z)\\ & & +\,{{\rm{\nabla }}}_{\perp }I(x,y,z)\cdot {{\rm{\nabla }}}_{\perp }\varphi (x,y,z){\}}_{z=0}.\end{array}$$
(4)

The underpinning physics is sketched in an imaging context in Fig. 1(a), whereby local specular refraction of x-ray radiation, by a thin object, leads to transverse re-distribution of optical energy upon propagation through a distance Δ that is not too large. Here and henceforth, we use the term “specular refraction” in direct analogy to “specular reflection”, with the former term referring to the refraction associated with a mirror-like refracting surface (i.e. smooth, lacking in the effects of roughness or spatial randomness; cf. Latin speculum). Rays passing through A have a positive divergence, hence the intensity at B is reduced compared to that which would have been registered if the rays passing through A had all been parallel to the optical axis z. Similarly, rays passing through C have a negative divergence (positive “convergence”), hence the intensity at D is increased compared to that which would have been obtained had the rays exiting C been parallel to the optical axis. This phase contrast effect is increased with increased propagation distance Δ, reduced x-ray energy (decreased wave-number k) or faster spatial variations in wave-field phase (larger \(|{\nabla }_{\perp }\varphi (x,y,z=0)|\)). We can also have effects such as a transverse deflection, e.g. with the local maximum of intensity at D being slightly shifted from the point x = x0. Concentration or rarefaction of energy density (and hence intensity) may be thought of as due to the lensing term proportional to \(I(x,y,z){\nabla }_{\perp }^{2}\varphi (x,y,z)\) in Eq. (4), while the transverse shifts in intensity maxima or minima may be viewed as due to the prism term \({\nabla }_{\perp }I(x,y,z)\cdot {\nabla }_{\perp }\varphi (x,y,z)\)31.

Diffusion equation for diffusive paraxial energy transport

If there were only diffusive energy transport on account of unresolved micro-structure in the sample (i.e. SAXS), but no specular refraction, we could instead introduce a diffusion coefficient D(x, y, z) to describe the effects at distance z = Δ downstream of an illuminated thin object in the plane z = 0. The fact that this coefficient depends on x and y reflects the fact that the SAXS fan will in general vary with position over the nominal exit surface z = 0 of the thin sample. Bearing all of this in mind, the intensity evolution of the beam may then be described by the diffusion equation:

$${[\frac{{\rm{\partial }}}{{\rm{\partial }}z}I(x,y,z)]}_{z=0}={{\rm{\nabla }}}_{\perp }^{2}[D(x,y,z=0)I(x,y,z=0)],$$
(5)

with the very important proviso that the above expression is always to be understood in its finite-difference form

$$I(x,y,z=\Delta )=I(x,y,z=0)+\Delta {\{{{\rm{\nabla }}}_{\perp }^{2}[D(x,y,z;\Delta )I(x,y,z)]\}}_{z=0},\,\Delta \ge 0.$$
(6)

Note that a formal dependence on Δ has been added to the diffusion coefficient D, since SAXS-induced diffusive blur has a characteristic transverse width that scales with Δ rather than Δ1/2.

The effect shown in one transverse dimension in Fig. 1(b) can be modelled using the above finite-difference form of the diffusion equation. Here, an x-ray beamlet of width Δx illuminates a slab containing SAXS-inducing unresolved micro-structure. This width Δx is assumed to be large compared to the characteristic length scale of the projected micro-structure, but small compared to the characteristic transverse width associated with the macroscopic projected phase and attenuation coefficients of the object. The illuminated region E of the slab, located at transverse coordinate x = x0, results in a smooth SAXS fan of opening angle θ(x0), which smears the propagated intensity over the plane z = Δ. The characteristic width of this blur, which may be considered as a broadening of the local rocking curve due to the sample40,41, is

$$L({x}_{0};\Delta )\approx \theta ({x}_{0})\Delta \approx \sqrt{D({x}_{0},z=0;\Delta )\,\Delta }.$$
(7)

Thus, local diffuse scattering by a thin object leads to a transverse smearing of intensity upon propagation. This blur increases with increased propagation distance Δ. At the level at which diffusion is here being considered, the opening angle θ(x0) of the SAXS fan is taken to completely characterise its diffusive effects at each location x0; a more sophisticated treatment which replaces the single number θ(x0) (or its associated diffusion coefficient) with a hierarchy of tensors, will be given later.

Like the TIE, the diffusion equation may be viewed as a continuity equation expressing local energy conservation, albeit under diffusive x-ray energy transport. Here, the conserved current is given by Fick’s first law as13,42

$$-{{\rm{\nabla }}}_{\perp }[D(x,y,z=0;\Delta )I(x,y,z=0)]\equiv {{\bf{J}}}_{\perp }^{(2)}(x,y,z=0).$$
(8)

Fokker–Planck equation for combined coherent and diffusive paraxial energy transport

If both specular refraction and local-SAXS effects are present simultaneously, we can add the TIE and diffusion equations together, in an energy-preserving manner. This gives the continuity equation:

$${[\frac{{\rm{\partial }}}{{\rm{\partial }}z}I(x,y,z)]}_{z=0}=-{{\rm{\nabla }}}_{\perp }\cdot {{\bf{J}}}_{\perp }(x,y,z=0),$$
(9)
$${{\bf{J}}}_{\perp }(x,y,z=0)=[1-F(x,y)]\,{{\bf{J}}}_{\perp }^{(1)}(x,y,z=0)+F(x,y)\,{{\bf{J}}}_{\perp }^{(2)}(x,y,z=0),\,0\le F(x,y)\le 1.$$

Here, F(x, y) is the fraction of the optical energy converted to SAXS43 when illuminating a thin sample in the plane z = 0 at the point (x, y). If \(F(x,y)\ll 1\) (as is often the case for both soft11 and hard44 x-rays) one can replace 1 − F(x, y) in the above expression by 1. The resulting convection–diffusion equation (forward Kolmogorov equation13) is the Fokker–Planck equation in two transverse dimensions. It models both effects in Fig. 1, i.e. it models the effects of both local sample-induced specular refraction and local sample-induced SAXS.

If the expressions for the coherent current \({{\bf{J}}}_{\perp }^{(1)}\) and diffusive current \({{\bf{J}}}_{\perp }^{(2)}\) are written explicitly, and the approximations made that (i) \(F(x,y)\ll 1\) and (ii) F(x, y) is slowly varying with x and y, we obtain the 2 + 1-dimensional Fokker–Planck equation:

$$\frac{{\rm{\partial }}}{{\rm{\partial }}z}I(x,y,z)=-\frac{1}{k}{{\rm{\nabla }}}_{\perp }\cdot [I(x,y,z){{\rm{\nabla }}}_{\perp }\varphi (x,y,z)]+F(x,y){{\rm{\nabla }}}_{\perp }^{2}[D(x,y,z=0;\Delta )I(x,y,z)].$$
(10)

In one transverse dimension, this becomes the one-dimensional Fokker–Planck equation:

$$\frac{{\rm{\partial }}}{{\rm{\partial }}z}I(x,z)=-\,\frac{1}{k}\frac{{\rm{\partial }}}{{\rm{\partial }}x}[I(x,z)\frac{{\rm{\partial }}}{{\rm{\partial }}x}\varphi (x,z)]+F(x)\frac{{{\rm{\partial }}}^{2}}{{\rm{\partial }}{x}^{2}}[D(x,z=0;\Delta )I(x,z)].$$
(11)

The corresponding finite-difference forms, which are to be preferred for reasons that have already been outlined, are respectively given by the following pair of equations:

$$\begin{array}{ccc}I(x,y,z=\Delta ) & = & I(x,y,z=0)-(\Delta /k){{\rm{\nabla }}}_{\perp }\cdot {[I(x,y,z){{\rm{\nabla }}}_{\perp }\varphi (x,y,z)]}_{z=0}\\ & & +\,F(x,y)\Delta {{\rm{\nabla }}}_{\perp }^{2}{[D(x,y,z=0;\Delta )I(x,y,z)]}_{z=0},\end{array}$$
(12)
$$\begin{array}{ccc}I(x,z=\Delta ) & = & I(x,z=0)-\frac{\Delta }{k}\frac{{\rm{\partial }}}{{\rm{\partial }}x}{[I(x,z)\frac{{\rm{\partial }}}{{\rm{\partial }}x}\varphi (x,z)]}_{z=0}\\ & & +\,F(x)\Delta \frac{{{\rm{\partial }}}^{2}}{{\rm{\partial }}{x}^{2}}{[D(x,z=0;\Delta )I(x,z)]}_{z=0}.\end{array}$$
(13)

We close this section by noting that, if D may be considered to be sufficiently slowly varying with respect to transverse coordinates that D commutes with the transverse Laplacian, we may instead work with the simpler finite-difference expressions:

$$\begin{array}{ccc}I(x,y,z=\Delta ) & = & I(x,y,z=0)-(\Delta /k){{\rm{\nabla }}}_{\perp }\cdot {[I(x,y,z){{\rm{\nabla }}}_{\perp }\varphi (x,y,z)]}_{z=0}\\ & & +\,F(x,y)D(x,y,z=0;\Delta )\Delta {{\rm{\nabla }}}_{\perp }^{2}I(x,y,z=0),\end{array}$$
(14)
$$\begin{array}{ccc}I(x,z=\Delta ) & = & I(x,z=0)-\frac{\Delta }{k}\frac{{\rm{\partial }}}{{\rm{\partial }}x}{[I(x,z)\frac{{\rm{\partial }}}{{\rm{\partial }}x}\varphi (x,z)]}_{z=0}\\ & & +\,F(x)D(x,z=0;\Delta )\Delta \frac{{{\rm{\partial }}}^{2}}{{\rm{\partial }}{x}^{2}}I(x,z=0).\end{array}$$
(15)

In the above two finite-difference Fokker–Planck equations, FD plays the role of an effective diffusion coefficient

$${D}_{{\rm{e}}{\rm{f}}{\rm{f}}}(x,y;\Delta )=F(x,y)D(x,y,z=0;\Delta )$$
(16)

that also accounts for the fraction of the incident radiation converted to SAXS.

X-ray Fokker–Planck equation: Derived from first principles

Here we derive the x-ray Fokker–Planck equation from first principles. We consider two length scales of sample-induced wave-field variation. The larger scale corresponds to the length scales in the sample that are sufficiently large for their absorptive and refractive effects to lead to detector-resolvable intensity variations. The smaller length scale corresponds to diffuse scattering from unresolved micro-structure resulting in SAXS. This derivation clarifies the physical mechanisms underpinning both coherent and diffusive x-ray energy transport, in a paraxial x-ray imaging context.

We work in one transverse dimension for simplicity, ignore polarisation and assume monochromatic x rays. Let ψ(x, z = 0) be the spatial part of the complex scalar amplitude at the exit surface of a sample. Subsequent Fresnel diffraction gives4

$$\psi (x,z=\Delta )=\int \,{P}_{\Delta }(x{\rm{^{\prime} }})\psi (x-x{\rm{^{\prime} }},z=0)\,dx{\rm{^{\prime} }},$$
(17)

where PΔ(x) is the Fresnel propagator corresponding to free-space diffraction through a distance Δ ≥ 0, and paraxial radiation is assumed throughout. The squared modulus of the above convolution integral gives the propagated intensity as the following linear combination of contributions from every pair of points x′, x″ in the unpropagated wave field45:

$$I(x,z=\Delta )\equiv |\psi (x,z=\Delta ){|}^{2}=\iint \,{P}_{\Delta }(x{\rm{^{\prime} }}){P}_{\varDelta }^{\ast }(x{\rm{^{\prime} }}{\rm{^{\prime} }})\,\psi (x-x{\rm{^{\prime} }},z=0){\psi }^{\ast }(x-x{\rm{^{\prime} }}{\rm{^{\prime} }},z=0)\,dx{\rm{^{\prime} }}dx{\rm{^{\prime} }}{\rm{^{\prime} }}.$$
(18)

The sample is assumed to be thin, normal to the incident plane-wave illumination, and with nominal exit surface z = 0. Many models exist for incorporating unresolved micro-structure into this sample46,47. Follow Voronovich47, Nesterets45 and Yashiro et al.48,49 in decomposing the phase ϕ(x, z = 0) of ψ(x, z = 0) as

$$\varphi (x,z=0)={\varphi }_{{\rm{s}}}(x)+{\varphi }_{{\rm{f}}}(x),$$
(19)

where (i) ϕs(x) is a phase component that varies slowly with respect to the detector pixel size, and (ii) ϕf(x) is a fast-varying spatially random phase due to the sample micro-structure, which fluctuates many times over one detector pixel and is thus unresolved (see also Gureyev et al.31). Further assume a slowly-varying intensity Is(x), together with x-rays that are of sufficiently high energy for the projection approximation to hold for a given sample. Hence

$$\psi (x,z=0)=\sqrt{{I}_{{\rm{s}}}(x)}\,\exp \,\{i[{\varphi }_{{\rm{s}}}(x)+{\varphi }_{{\rm{f}}}(x)]\},$$
(20)

and so Eq. (18) becomes45:

$$\begin{array}{ccc}I(x,z=\Delta ) & = & \iint \,{P}_{\Delta }(x{\rm{^{\prime} }}){P}_{\Delta }^{\ast }(x{\rm{^{\prime} }}{\rm{^{\prime} }})\sqrt{{I}_{{\rm{s}}}(x-x{\rm{^{\prime} }}){I}_{{\rm{s}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})}\exp \{i[{\varphi }_{{\rm{s}}}(x-x{\rm{^{\prime} }})-{\varphi }_{{\rm{s}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})]\}\\ & & \times \,\exp \,\{i[{\varphi }_{{\rm{f}}}(x-x{\rm{^{\prime} }})-{\varphi }_{{\rm{f}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})]\}\,dx{\rm{^{\prime} }}dx{\rm{^{\prime} }}{\rm{^{\prime} }}.\end{array}$$
(21)

Average over an ensemble of realisations of the unresolved fast phase-maps ϕf(x)45,50,51,52. Denoting this average by an over-line,

$$\begin{array}{ccc}\bar{I}(x,z=\Delta ) & = & \iint \,{P}_{\Delta }(x{\rm{^{\prime} }}){P}_{\Delta }^{\ast }(x{\rm{^{\prime} }}{\rm{^{\prime} }})\sqrt{{I}_{{\rm{s}}}(x-x{\rm{^{\prime} }}){I}_{{\rm{s}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})}\exp \,\{i[{\varphi }_{{\rm{s}}}(x-x{\rm{^{\prime} }})-{\varphi }_{{\rm{s}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})]\}\\ & & \times \,\bar{\exp \,\{i[{\varphi }_{{\rm{f}}}(x-x{\rm{^{\prime} }})-{\varphi }_{{\rm{f}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})]\}}\,dx{\rm{^{\prime} }}dx{\rm{^{\prime} }}{\rm{^{\prime} }}.\end{array}$$
(22)

Assuming the fast phase maps ϕf to be spatially statistically stationary over transverse displacements that are small compared to the characteristic length scale over which ϕs fluctuates appreciably, the over-lined expression in Eq. (22) depends only on coordinate differences x′ − x″. Assuming ϕf(x − x′) and ϕf(x − x″) to be Gaussian variables, with zero mean, this correlation function is45,48,49,51,52,53

$$\bar{\exp \,\{i[{\varphi }_{{\rm{f}}}(x\,-\,x{\rm{\text{'}}})\,-\,{\varphi }_{{\rm{f}}}(x\,-\,x{\rm{\text{'}}}{\rm{\text{'}}})]\}}=\exp \,\{-{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)[1\,-\,\gamma (|x{\rm{\text{'}}}\,-\,x{\rm{\text{'}}}{\rm{\text{'}}}|;x)]\},$$
(23)

where \({\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)\) is the x-dependent variance of the ensemble of fast phase maps {ϕf(x)}, and

$$\gamma (\Delta x;x)=\frac{\bar{{\varphi }_{{\rm{f}}}(x){\varphi }_{{\rm{f}}}(x+\Delta x)}}{{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)}$$
(24)

is the normalised fast-phase auto-correlation function54 as a function of coordinate separation Δx and transverse coordinate x.

The quantity \({\sigma }_{{\varphi }_{{\rm{f}}}}(x)\) is called the “phase depth”. If this is not significantly greater than unity, the right side of Eq. (23) does not decay to zero as \(|x^{\prime} -x^{\prime\prime} |\to \infty \). Rather, this correlation function asymptotes to \(\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\): see Fig. 2(a). The physical reason for this decay to a non-zero constant is the phase depth not being sufficiently high for \(\exp \,(i{\varphi }_{{\rm{f}}})\) at two different locations to cross-correlate to zero, irrespective of how widely separated these locations may be (cf. Prade et al.55).

Figure 2
figure 2

(a) Auto-correlation of \(\exp \,[i{\varphi }_{{\rm{f}}}(x)]\) in Eq. (23), with x considered fixed. (b) Re-normalised fast-phase correlation function in Eq. (26), for a given fixed x. (c) Decoherence factor \(\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\) appearing in Eq. (27) and onwards, for a given fixed x. (d) Physical interpretation of Eq. (32). (e) Specular and diffuse scattering for a single x-ray beamlet of width Δx.

To proceed further, follow Goodman51 in separating out the asymptote term from \(\overline{\exp \,\{i[{\varphi }_{{\rm{f}}}(x-x^{\prime} )-{\varphi }_{{\rm{f}}}(x-x^{\prime\prime} )]\}}\) in Eq. (23), and re-normalising the part of the correlation that does decay to zero. Thus:

$$\bar{\exp \,\{i[{\varphi }_{{\rm{f}}}(x-x{\rm{^{\prime} }})-{\varphi }_{{\rm{f}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})]\}}=\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]+\{1-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\}\,C(x{\rm{^{\prime} }}-x{\rm{^{\prime} }}{\rm{^{\prime} }};x),$$
(25)

where C(x′ − x″; x) is a re-normalised correlation function

$$C(x{\rm{^{\prime} }}-x{\rm{^{\prime} }}{\rm{^{\prime} }};x)=\frac{\exp \,\{\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)[1-\gamma (|x{\rm{^{\prime} }}-x{\rm{^{\prime} }}{\rm{^{\prime} }}|;x)]\}-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]}{1-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]}$$
(26)

that does decay to zero for coordinate separations \(\Delta x\equiv |x^{\prime} -x^{\prime\prime} |\gg \tau \), and τ is the transverse correlation length (see Fig. 2(b)).

Substituting Eq. (25) into Eq. (22) gives45

$$\bar{I}(x,z=\Delta )=\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]|{{\mathscr D}}_{\Delta }^{({\rm{F}})}\{\sqrt{{I}_{{\rm{s}}}(x)}\,\exp \,[i{\varphi }_{{\rm{s}}}(x)]\}{|}^{2}+ {\mathcal B} (x,z=\Delta ),$$
(27)
$$\begin{array}{ccc} {\mathcal B} (x,z=\Delta ) & = & \{1-\exp \,[-{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\}\iint \,{P}_{\Delta }(x{\rm{^{\prime} }}){P}_{\Delta }^{\ast }(x{\rm{^{\prime} }}{\rm{^{\prime} }})\sqrt{{I}_{{\rm{s}}}(x-x{\rm{^{\prime} }}){I}_{{\rm{s}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})}\\ & & \times \,\exp \,\{i[{\varphi }_{{\rm{s}}}(x-x{\rm{^{\prime} }})-{\varphi }_{{\rm{s}}}(x-x{\rm{^{\prime} }}{\rm{^{\prime} }})]\}\,C(x{\rm{^{\prime} }}-x{\rm{^{\prime} }}{\rm{^{\prime} }};x)\,dx{\rm{^{\prime} }}dx{\rm{^{\prime} }}{\rm{^{\prime} }},\end{array}$$
(28)

where \({{\mathscr D}}_{\Delta }^{({\rm{F}})}\) is the Fresnel diffraction operator4 acting on the smooth component of the complex amplitude, and \( {\mathcal B} (x,z=\Delta )\) represents small-angle x-ray scattering. Thus a physical consequence of the lack of decay to zero in Eq. (23), is that the diffraction pattern in Eq. (27) contains two components45,51,52,56,57:

  • A “specular diffraction” component that undergoes Fresnel diffraction as if there were no micro-structure present, but with intensity damped by the decoherence factor45 shown in Fig. 2(c);

  • A diffuse component \( {\mathcal B} (x,z=\Delta )\) associated with SAXS.

This splitting of x-ray energy flows – whereby an incident coherent x-ray energy flow upstream of the object bifurcates into superposed coherent and diffusive energy flows downstream of the object – corresponds directly to the factors of F and 1 − F introduced “by hand” in the previous sub-section (see Eq. (9)), if we take

$$F(x)=1-\exp \,[-{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\mathop{\mathop{\longrightarrow }\limits^{{\rm{w}}{\rm{e}}{\rm{a}}{\rm{k}}\,{\rm{S}}{\rm{A}}{\rm{X}}{\rm{S}}}}\limits_{{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)\ll 1}1-[1-{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]={\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x).$$
(29)

Note that a similar bifurcation of energy flows occurs, for similar reasons, in statistical dynamical x-ray diffraction theory58,59 and the frozen-phonon model of electron diffraction theory. Note also that a non-zero specular-diffraction component (which will typically be the dominant component in the present context) indicates the SAXS-induced speckle to be “partially developed”60; this may be contrasted with the case of “fully developed” SAXS speckle, which is not relevant to our context, in which the specular component would be fully extinguished.

Assume Is(x) to be sufficiently slowly varying that the square-root term in Eq. (28) may be replaced by Is(x). For the complex exponent in Eq. (28), make the more sensitive approximation:

$${\varphi }_{{\rm{s}}}(x-{x}^{{\rm{^{\prime} }}})-{\varphi }_{{\rm{s}}}(x-{x}^{{\rm{^{\prime} }}{\rm{^{\prime} }}})\approx ({x}^{{\rm{^{\prime} }}{\rm{^{\prime} }}}-{x}^{{\rm{^{\prime} }}})\,{{\varphi }^{{\rm{^{\prime} }}}}_{{\rm{s}}}(x),$$
(30)

where \({\varphi ^{\prime} }_{{\rm{s}}}(x)\) denotes the derivative of ϕs(x) with respect to x; the above equation makes implicit use of the fact that ϕf varies much more quickly than ϕs. Then write PΔ(x′) in Eq. (28) as a Fourier integral using the notation and convention specified by

$${P}_{\Delta }(x{\rm{^{\prime} }})={(2\pi )}^{-1/2}\int \,{\breve{P}}_{\Delta }({k}_{x})\,\exp \,(i{k}_{x}x{\rm{^{\prime} }})d{k}_{x},$$
(31)

where kx is the Fourier coordinate corresponding to x. Also write \({P}_{\Delta }^{\ast }\) and C in Eq. (28) as Fourier integrals, with C being Fourier transformed with respect to its first argument. With all of these steps, together with the fact that \(|{\breve{P}}_{\Delta }|=1\) for the Fresnel propagator4, one obtains (cf. similar equations in related contexts45,52,61,62, especially those due to Nesterets45):

$$ {\mathcal B} (x,z=\Delta )=\sqrt{2\pi }\,\{1-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\}{I}_{{\rm{s}}}(x)\,\int \,d{k}_{x}\,\breve{C}({{\varphi }^{{\rm{^{\prime} }}}}_{{\rm{s}}}(x)-{k}_{x};x).$$
(32)

Physically, the above equation states that the SAXS contribution, at a given transverse location x, integrates over a fan of rays making angles \([{\varphi ^{\prime} }_{{\rm{s}}}(x)-{k}_{x}]/k\) with respect to the optical axis. This fan of rays is due to scattering from unresolved micro-structure associated with the ensemble of fast phase maps {ϕf(x)}. The whole fan of SAXS rays is rotated by the angle \({\varphi ^{\prime} }_{{\rm{s}}}(x)/k\), due to the specular refraction. All SAXS-scattered x rays, due to illumination of the point at x = x0, are integrated over a single pixel. See Fig. 2(d). The angular spread of the SAXS fan will typically be on the order of a few degrees (50 milli-radians) for hard x rays63, while the fan rotation angle \({\varphi ^{\prime} }_{{\rm{s}}}(x)/k\) will typically be on the order of micro-radians64. The function \(\breve{C}\), being the Fourier transform of a correlation function43, is proportional to the power spectrum of the ensemble of fast-phase fields \(\exp \,\{i{\varphi }_{{\rm{f}}}(x)\}\) (Wiener–Khinchin theorem65); this power spectrum (local differential scattering cross section54,55,66; cf. Eq. (44) below) gives the weights for the diffracted “rays” in the SAXS fan. The fraction \(F(x)=1-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\) of the beam converted to SAXS is complementary to the fraction \(1-F(x)=\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)]\) channelled into the specular Fresnel diffraction (cf. Eq. (29)).

If the object-to-detector distance Δ is large enough that the SAXS-induced fan of rays in Fig. 2(d) spreads over more than one pixel, we have the scenario shown in Fig. 2(e). Equation (32) generalises to the convolution-type integral:

$$ {\mathcal B} (x={x}_{0},z=\Delta )=\sqrt{2\pi }\,\{1-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}({x}_{0})]\}\,[{I}_{{\rm{s}}}(x)\otimes d(x;{x}_{0}){]}_{x={x}_{0}},$$
(33)

where d(x; x0) is a diffusive blur kernel given by

$$d(x;{x}_{0})=\breve{C}{({k}_{x};{x}_{0})}_{{k}_{x}={{\varphi }^{{\rm{^{\prime} }}}}_{{\rm{s}}}(x)-kx/\Delta }\approx \breve{C}{({k}_{x};{x}_{0})}_{{k}_{x}=-kx/\Delta }.$$
(34)

The function d is simply a transverse re-scaling of \(\breve{C}\), from a function of Fourier-space coordinates kx (i.e. angular coordinates kx/k, in the paraxial approximation) to a function of the transverse coordinates x over the detector plane. Stated differently, d(x; x0) is the intensity distribution of SAXS, as a function of position x on the detector, due to x rays incident at position x0. If the object-to-detector distance Δ is sufficiently small, two additional approximations can be made.

  1. (i)

    Small Δ implies d(x; x0) to be sufficiently narrow for its Fourier transform \(\breve{d}({k}_{x};{x}_{0})\) with respect to x to be sufficiently broad that it can be represented by a second-order Taylor expansion in kx. The term in the Taylor series for \(\breve{d}({k}_{x};{x}_{0})\) that is linear in kx will vanish since Cx; x0) is approximately even in Δx (cf. Eq. (47)). Given all of the above, the convolution operator \(\sqrt{2\pi }\,d(x;{x}_{0})\otimes \) in Eq. (33) is well approximated by

    $$\sqrt{2\pi }\,d(x;{x}_{0})\otimes \approx Q+{L}^{2}({x}_{0};\Delta )({d}^{2}/d{x}^{2}),$$
    (35)

    where \(L({x}_{0};\Delta )\) is an x0-dependent blurring width (this blurring being due to SAXS), and Q is a positive constant. Invoke conservation of energy, which implies that the total scattered intensity, due to an incident x-ray pencil beam of intensity Is(x) and with small thickness Δx, will have the same integrated intensity after scattering from the object; see Fig. 2(e). This shows that Q = 1, so that \(\sqrt{2\pi }\,d(x;{x}_{0})\otimes \approx 1+{L}^{2}({x}_{0};\Delta )({d}^{2}/d{x}^{2})\) (cf. Gureyev et al.67). Hence we may approximate Eq. (33) as:

    $$ {\mathcal B} (x={x}_{0},z=\Delta )=\{1-\exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}({x}_{0})]\}\{[1+{L}^{2}(x;\Delta )\frac{{d}^{2}}{d{x}^{2}}]{I}_{{\rm{s}}}(x){\}}_{x={x}_{0}}.$$
    (36)

    Before proceeding, let us back-track a little, and point out that in Eq. (33) we consider \({I}_{{\rm{s}}}(x)\otimes d(x;{x}_{0})\) to be equivalent to \(\int \,{I}_{{\rm{s}}}({x}_{0})d(x-{x}_{0};{x}_{0})\,d{x}_{0}\). Strictly speaking, this linear integral transform is not a convolution integral since the blurring kernel d depends on x0. We use the convolution notation for clarity, however, to denote such smearing with a position dependent point spread function that results from the position-dependent SAXS. See also the next section, for an analysis that considers the same linear integral transform using a more conventional and explicit notation.

  2. (ii)

    A second consequence of small Δ is that the TIE approximation5 may be applied to the first term on the right of Eq. (27):

$$|{{\mathscr D}}_{\Delta }^{({\rm{F}})}\{\sqrt{{I}_{{\rm{s}}}(x)}\,\exp \,[i{\varphi }_{{\rm{s}}}(x{)]\}|}^{2}\approx {I}_{{\rm{s}}}(x)-\frac{\Delta }{k}\frac{d}{dx}[{I}_{{\rm{s}}}(x)\frac{d{\varphi }_{{\rm{s}}}(x)}{dx}].$$
(37)

If Eqs (36) and (37) are substituted into Eq. (27), we obtain

$$\begin{array}{ccc}\frac{\bar{I}(x,z=\Delta )-{I}_{{\rm{s}}}(x)}{\Delta } & = & \exp \,[\,-\,{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)](\frac{-\,1}{k})\frac{d}{dx}[{I}_{{\rm{s}}}(x)\frac{d{\varphi }_{{\rm{s}}}(x)}{dx}]\\ & & +\,\frac{1}{\Delta }\{1-\exp \,[\,-\,{\sigma }_{{\varphi }_{f}}^{2}(x)]\}{L}^{2}(x;\Delta )\frac{{d}^{2}{I}_{{\rm{s}}}(x)}{d{x}^{2}}.\end{array}$$
(38)

Assume only a small fraction of the incident x rays to be converted to SAXS, so that \({\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)\ll 1\). Thus:

$$\frac{\bar{I}(x,z=\Delta )-{I}_{{\rm{s}}}(x)}{\Delta }\approx -\,\frac{1}{k}\frac{d}{dx}[{I}_{{\rm{s}}}(x)\frac{d{\varphi }_{{\rm{s}}}(x)}{dx}]+\frac{{L}^{2}(x;\Delta )}{\Delta }{\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)\frac{{d}^{2}{I}_{{\rm{s}}}(x)}{d{x}^{2}}.$$
(39)

Upon comparing the final term of Eq. (39) with the final term in Eq. (15), and then noting from the far right side of Eq. (29) that \({\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)\approx F(x)\), we obtain:

$$D(x,z=0;\Delta )={L}^{2}(x;\Delta )/\Delta .$$
(40)

The corresponding position-dependent effective diffusion coefficient Deff(x; Δ) obeys Eq. (16), so that

$${D}_{{\rm{e}}{\rm{f}}{\rm{f}}}(x;\Delta )={\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x)D(x,z=0;\Delta )={\sigma }_{{\varphi }_{{\rm{f}}}}^{2}(x){L}^{2}(x;\Delta )/\Delta .$$
(41)

Equation (39) then becomes the 1D form of the finite-difference x-ray Fokker–Planck equation in Eq. (13), provided the diffusion coefficient varies sufficiently slowly with x that it commutes with the transverse Laplacian. Note also that a Kramers–Moyal generalisation of the Fokker–Planck equation would have resulted if all terms had been included in the expansion for \(\sqrt{2\pi }\,d(x;{x}_{0})\otimes \) (see next section). We again emphasise that Eq. (39) is to be considered with Δ being small but finite and fixed. Thus, the simplicity of using diffusion concepts to describe SAXS, must be balanced against the fact that free-space propagation blur-width L scales as Δ rather than \(\sqrt{\Delta }\); formally, this is accounted for by having a Δ-dependent diffusion coefficient for the x-ray Fokker–Planck equation, which is only ever used in its finite-difference form for small nonzero Δ.

We close this section with Fig. 3. This indicates the relation between various key quantities: the divergence angle θ of the SAXS fan, the characteristic transverse length scale \(l\) of the spatially-rapid wave-front fluctuations induced by unresolved micro-structure at the sample exit surface, the phase depth \({\sigma }_{{\varphi }_{{\rm{f}}}}\) of the associated spatially-rapid phase fluctuations, the diffusion coefficient D and the effective diffusion coefficient Deff in the Fokker–Planck equation, and the smear width L associated with the SAXS fan. We make the following remarks on each equation in Fig. 3.

  1. (a)

    The link between L and θ follows from elementary geometry;

  2. (b)

    The link between l and θ follows from the optical uncertainty principle68;

  3. (c)

    The link between l and L follows upon eliminating θ from relations (a) and (b);

  4. (d)

    The link between D and L follows from Eq. (40);

  5. (e)

    The link between D and l follows upon eliminating L from relations (c) and (d);

  6. (f)

    The link between D and θ follows upon eliminating L from relations (a) and (d);

  7. (g)

    The link between D and Deff follows from Eqs (16) and (41); see also Eq. (29).

Figure 3
figure 3

Relations between several key physical quantities used in this paper.

All physical dependencies, for the quantities in Fig. 3, are intuitively reasonable: (a) the blur width L is directly proportional to the angular spread θ of the SAXS fan; the blur width L is directly proportional to the sample-to-detector distance Δ; (b) the angular width θ of the SAXS fan is inversely proportional to the transverse length scale l of the projected unresolved micro-structure, etc.

Kramers–Moyal extension of x-ray Fokker–Planck equation

The preceding analysis gives only a crude treatment of the angular distribution of the local SAXS fan, which is described merely via its angular spread θ(x, y) at each point over the exit surface z = 0 of a thin sample. Here, we show that a less-crude treatment leads to the Kramers–Moyal generalisation of the Fokker–Planck equation, in a form suitable for x-ray near-field imaging of thin objects.

Recall Eq. (29), which links the local phase depth associated with the projected micro-structure of a thin object, to the associated fraction F(x, y) of the x-ray beam which is channelled into SAXS. The two-transverse-dimensional forms of Eqs (27), (33) and (37), upon writing the linear integral transform in Eq. (33) explicitly and setting \(\sqrt{2\pi }d\equiv K\), then become:

$$\begin{array}{ccc}\bar{I}(x,y,z=\Delta ) & = & [1-F(x,y)]\{{I}_{{\rm{s}}}(x,y,z=0)\\ & & -(\Delta /k){{\rm{\nabla }}}_{\perp }\cdot [{I}_{{\rm{s}}}(x,y,z)\,{{\rm{\nabla }}}_{\perp }{\varphi }_{{\rm{s}}}(x,y,z){]}_{z=0}\}+ {\mathscr B} (x,y,z=\Delta ),\end{array}$$
(42)
$$ {\mathscr B} (x,y,z=\Delta )=F(x,y)\,\iint \,{I}_{{\rm{s}}}(x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=0)\,K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }}.$$
(43)

Again, the first term on the right side of Eq. (42) is associated with the coherently-scattered component of the x-ray field downstream of the thin object in the plane z = 0, while the second term \( {\mathscr B} \) is associated with the diffusely scattered component. In the zero-SAXS limit where F(x, y) → 0, Eqs (42) and (43) reduce to Eq. (4).

Recall the usual definition of a differential scattering cross section \([d\sigma /d\Omega ]({\theta }_{x},{\theta }_{y})\), where dΩ is an infinitesimal element of solid angle and θx, θy describe angular deflections (scattering angles) in the x, y transverse directions, respectively69. Hence conclude that \(K=\sqrt{2\pi }d\) in Eq. (43) is proportional to the local differential scattering cross section66 associated with unresolved micro-structure in the sample, namely a differential scattering cross section \([d\sigma /d\Omega ](x^{\prime} ,y^{\prime} ;{\theta }_{x},{\theta }_{y})\) that depends upon an illuminating beamlet’s centre (x′, y′), as well as upon the scattering angles θx, θy. Thus we have the proportionality

$$K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\propto \frac{d\sigma }{d\Omega }(x{\rm{^{\prime} }},y{\rm{^{\prime} }};{\theta }_{x}=\frac{x-x{\rm{^{\prime} }}}{\Delta },{\theta }_{y}=\frac{y-y{\rm{^{\prime} }}}{\Delta }),$$
(44)

where the paraxial approximation has again been assumed in taking \(\tan \,{\theta }_{x,y}\approx {\theta }_{x,y}\). Equations (42) and (43) then have the simple interpretation that the intensity downstream of a sample, which is contained in the plane z = 0, superposes a micro-structure-independent near-field Fresnel diffraction pattern that is damped with a decoherence factor45 1 − F, with a diffusely-scattered signal \( {\mathscr B} \) arising from the superposition of each SAXS fan emerging from each point over the exit surface of the sample. Such a family of SAXS fans is measured e.g. in Schaff et al.36; this amounts to a measurement of \(K(x,y,x^{\prime} ,y^{\prime} ,z=\Delta )\).

In the form given by Eqs (42) and (43), the object-to-detector distance Δ is assumed to be sufficiently small that the detector is in the near-field of the slowly-varying part \(\sqrt{{I}_{{\rm{s}}}(x,y,z=0)}\,\exp \,[i{\varphi }_{{\rm{s}}}(x,y,z=0)]\) of the complex wave field at the sample exit surface z = 0. In these same equations, Δ may be sufficiently large that the SAXS fan \(K(x,y,x^{\prime} ,y^{\prime} ,z=\varDelta )\)—emerging from the point (x′, y′, 0) over the exit surface z = 0 of the thin object, and considered as a function of coordinates (x, y) over the detector in the plane z = Δ—can have a width that is several pixels or more (cf. Fig. 2(e)). If these SAXS fans are highly structured, e.g. if they exhibit SAXS satellite peaks from highly directional unresolved structures such as collagen fibres70, then Eqs (42) and (43) can be used without any need for further approximation, to model image contrast in a regime where the detector plane is in the near-field of the resolved structure in the sample, but in the far-field of the unresolved micro-structure.

However if Δ is indeed small enough that the SAXS fan spreads over no more than a few pixels, and if the SAXS fans are not too highly structured, an intermediate simplification is possible, with a domain of validity between that of the less-general Fokker–Planck equation and the more general expression in Eqs (42) and (43). This intermediate model arises from a more precise consideration of the angular scattering distribution in the local SAXS differential cross sections, compared to that given in the preceding section. With this end in mind, assume that the angular widths θ(x′, y′) of all differential scattering cross sections contained in \(K(x,y,x^{\prime} ,y^{\prime} ,z=\Delta )\) obey \(\theta (x^{\prime} ,y^{\prime} )\ll 1\), with all such narrow SAXS fans being strongly peaked in the forward direction. If this is the case, we are justified in Taylor expanding \({I}_{{\rm{s}}}(x{\rm{^{\prime} }},y{\rm{^{\prime} }},z\,=\,0)\) about (x, y), so that Eq. (43) becomes:

$$\begin{array}{ccc} {\mathscr B} (x,y,z=\Delta ) & \approx & F(x,y)[{I}_{{\rm{s}}}(x,y,z=0)+\mathop{\sum }\limits_{m=0}^{2}\,{D}_{m,2-m}^{(2)}(x,y;\Delta )\frac{{{\rm{\partial }}}^{2}{I}_{{\rm{s}}}(x,y,z=0)}{{\rm{\partial }}{x}^{m}{\rm{\partial }}{y}^{2-m}}\\ & & -\,\mathop{\sum }\limits_{m=0}^{3}\,{D}_{m,3-m}^{(3)}(x,y;\Delta )\frac{{{\rm{\partial }}}^{3}{I}_{{\rm{s}}}(x,y,z=0)}{{\rm{\partial }}{x}^{m}{\rm{\partial }}{y}^{3-m}}+\cdots ].\end{array}$$
(45)

In obtaining the above expression, we have made use of the following three points:

  • We have assumed that each SAXS fan \(K(x,y,x^{\prime} ,y^{\prime} ,z=\Delta )\)—emanating from the point (x′, y′) over the exit surface of the sample to produce an intensity distribution that is a function of detector coordinates (x, y) in the plane z = Δ—obeys:

    $$\iint \,K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }}=1.$$
    (46)

    This normalisation condition is appropriate since the multiplicative factor of F is a scattering fraction which accounts for the fact that only a certain percentage of the incident beam is converted to SAXS upon passage through the sample.

  • We have assumed that

    $$\iint \,(x{\rm{^{\prime} }}-x)K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }}=\iint \,(y{\rm{^{\prime} }}-y)K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }}=0,$$
    (47)

    consistent with the fact that any transverse shift in the centroid of the SAXS fan may be interpreted as a local gradient in \({\varphi }_{{\rm{s}}}(x,y)\) that has already been accounted for in Eq. (42). This eliminates the terms \({D}_{01}^{(1)}(x,y;\Delta )\) and \({D}_{10}^{(1)}(x,y;\Delta )\) that would otherwise have appeared in Eq. (45). There is an intrinsic ambiguity here: it is a question of semantics whether we consider \({\varphi }_{{\rm{s}}}(x,y)\) to possess a linear phase gradient and assume the SAXS fan to have a centre-of-mass that is undeflected, or whether we instead consider there to be no local gradient in \({\varphi }_{{\rm{s}}}(x,y)\) but view the centre-of-mass of the SAXS fan to be transversely shifted on account of correlations that are present in the sample’s unresolved micro-structure. In writing Eq. (47) we take the former of these two equivalent points of view.

  • We have defined the following hierarchy of diffusion tensors (SAXS-fan moments, cf. Gureyev et al.67), which arise from terms of progressively higher order in the Taylor expansion of Is(x′, y′, z = 0) about (x, y):

$${D}_{m,2-m}^{(2)}(x,y;\Delta )=\frac{1}{2!}(\begin{array}{c}2\\ m\end{array})\,\iint \,{(x{\rm{^{\prime} }}-x)}^{m}{(y{\rm{^{\prime} }}-y)}^{2-m}\,K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }},\,m=0,1,2,$$
(48)
$${D}_{m,3-m}^{(3)}(x,y;\Delta )=\frac{1}{3!}(\begin{array}{c}3\\ m\end{array})\,\iint \,{(x{\rm{^{\prime} }}-x)}^{m}{(y{\rm{^{\prime} }}-y)}^{3-m}\,K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }},\,\hspace{4pt}m=0,1,2,3,$$
(49)
$$\begin{array}{ccc}{D}_{m,M-m}^{(M)}(x,y;\Delta ) & = & \frac{1}{M!}(\begin{array}{c}M\\ m\end{array})\,\iint \,{(x{\rm{^{\prime} }}-x)}^{m}{(y{\rm{^{\prime} }}-y)}^{M-m}K(x,y,x{\rm{^{\prime} }},y{\rm{^{\prime} }},z=\Delta )\\ & & \times \,dx{\rm{^{\prime} }}dy{\rm{^{\prime} }},\,\,\,\,m=0,1,2,\cdots ,M.\end{array}$$
(50)

Here, \((\begin{array}{c}M\\ m\end{array})\) denotes a binomial coefficient \(M!/[m!(M-m)!]\). The moments in Eq. (48) quantify the ellipticity of the SAXS fan, via the three independent diffusion-tensor components \({D}_{02}^{(2)}(x,y;\Delta ),{D}_{11}^{(2)}(x,y;\Delta ),\) \({D}_{20}^{(2)}(x,y;\Delta )\), which may be mapped to the semi-major axis of the SAXS ellipse, the semi-minor axis and a rotation angle42. The higher-order diffusion tensors in Eqs (49) and (50) have an analogous interpretation.

Finally, if we insert Eq. (45) into Eq. (42), we obtain the following finite-difference form of a Kramers–Moyal equation13:

$$\begin{array}{ccc}\bar{I}(x,y,z=\Delta ) & = & {I}_{{\rm{s}}}(x,y,z=0)-(\Delta /k)[1-F(x,y)]{{\rm{\nabla }}}_{\perp }\\ & & \cdot \,{[{I}_{{\rm{s}}}(x,y,z){{\rm{\nabla }}}_{\perp }{\varphi }_{{\rm{s}}}(x,y,z)]}_{z=0}\\ & & +\,F(x,y)\,[\mathop{\sum }\limits_{m=0}^{2}\,{D}_{m,2-m}^{(2)}(x,y;\Delta )\frac{{{\rm{\partial }}}^{2}{I}_{{\rm{s}}}(x,y,z=0)}{{\rm{\partial }}{x}^{m}{\rm{\partial }}{y}^{2-m}}\\ & & -\mathop{\sum }\limits_{m=0}^{3}\,{D}_{m,3-m}^{(3)}(x,y;\Delta )\frac{{{\rm{\partial }}}^{3}{I}_{{\rm{s}}}(x,y,z=0)}{{\rm{\partial }}{x}^{m}{\rm{\partial }}{y}^{3-m}}+\cdots ].\end{array}$$
(51)

The F(x, y) = 0 case of Eq. (51) is the commonly-employed first-order finite-difference form of the transport-of-intensity equation5 (see Eq. (4)). The final lines of this equation incorporate  SAXS-induced blurring, in a manner which takes the anisotropy of the local SAXS fans into account. Pawula71 has shown that such Kramers–Moyal expansions may be either truncated at most to second or lower orders in spatial derivatives, or not truncated at all. In our context, this amounts to working with one of five possibilities, with increasing order of generality:

  • Keeping only the first two terms on the right-hand side of Eq. (51) (TIE approximation), with F = 0, which ignores SAXS altogether;

  • Setting D(3) and all higher-order diffusion tensors to zero, and assuming rotationally-invariant SAXS fans via

$${D}_{02}^{(2)}(x,y;\Delta )={D}_{20}^{(2)}(x,y;\Delta )\equiv D(x,y;\Delta ),\,{D}_{11}^{(2)}(x,y;\Delta )=0,$$
(52)

leaving us with the Fokker–Planck form given in Eq. (14) if we can also assume that \(F\ll 1\);

  • Setting D(3) and all higher-order diffusion tensors to zero, thereby reducing Eq. (51) to an anisotropic Fokker–Planck equation incorporating the diffusion tensor \({D}_{mn}^{(2)}(x,y;\Delta )\) (assumption of an elliptic SAXS fan);

  • Keeping all orders in Eq. (51), which contains all SAXS-fan moments. Note that this hierarchy of SAXS-fan moments may be measured, e.g. by raster scanning a focused beam through a thin sample to obtain a family of SAXS patterns36,72 from which each component of each diffusion tensor at each location (x, y) may be obtained using Eqs (48)–(50);

  • Eschewing the Kramers–Moyal and Fokker–Planck approximations and instead working with Eqs (42) and (43) directly.

Discussion

The primary goal of this paper is to give several means by which the Fokker–Planck equation (and its extension to the Kramers–Moyal equation) may be used to model forward and inverse problems of near-field x-ray imaging, in the presence of both phase–amplitude shifts and non-negligible small-angle x-ray scattering from unresolved micro-structure in a thin sample.

A detailed study of any particular application or applications is beyond the scope of this paper. One such application, grating-based x-ray phase contrast imaging73,74,75,76, is studied in detail in a companion paper77 that gives a number of analytical expressions based on the finite-difference expression in Eq. (11). More generally, Eqs (11) and (10) may be used to calculate, in one and two transverse dimensions respectively, the near-field paraxial image corresponding to a thin sample with known position-dependent exit-surface intensity, phase and diffusion coefficient. As we have already seen, a sufficiently slowly varying fraction F(x, y), this being the fraction of the incident radiation that is converted to SAXS, may be brought into the second square brackets on the right hand side of Eqs (10) and (11), and thereby incorporated into an effective diffusion coefficient. See Eqs (16), (29) and (41), in addition to Eq. (g) in Fig. 3. These expressions can be used for calculating propagation-based phase contrast x-ray images78,79,80 and speckle-tracking phase contrast images81,82,83, as well as the previously mentioned grating-based phase-contrast images. Note, also, that if one is in the intermediate-field rather than the near-field regime for \(\sqrt{{I}_{{\rm{s}}}}\,\exp \,(i{\varphi }_{{\rm{s}}})\), expressions such as (i) Eqs (27) and (36); or (ii) Eqs (27) and (43); or (iii) Eqs (27) and (45) may instead be used. All of these expressions are amenable to analytical implementation if the functional forms of intensity, phase and diffusion coefficients are known, or to computational implementation if the intensity, phase and diffusion are numerically modelled e.g. using Geant484.

The above indications, of the forward problem of near-field and intermediate-field x-ray imaging for a thin sample in the presence of both coherent and diffusive scattering, set up Fokker–Planck and Kramers–Moyal equations that can be used to consider the associated inverse problem of reconstructing intensity, phase and diffusion from measured intensity data. It is again beyond the scope of our paper to explore this point further, beyond the indicative suggestions given in the three examples below.

Example #1

As a first example of inverse problems that may be tackled based on the formalism of this paper, observe that the diffusion-tensor moments may be measured e.g. using the previously-mentioned technique of raster scanning a focused quasi-monochromatic x-ray probe over a lattice of points at the entrance surface of a thin object36,72, and the scattering fractions F(x, y) obtained using the same data. Since both \(\overline{I}(x,y,z=\Delta )\) and \({I}_{{\rm{s}}}(x,y,z=0)\) can be measured using quasi-monochromatic x rays, and since both the object-to-detector distance Δ and the radiation wave number k are known, the only remaining unknown in Eq. (51) would be the phase ϕs. This phase could then be obtained using existing techniques for numerically solving the transport-of-intensity equation (e.g. a full multi-grid method85 or a method using four Fourier transforms86).

Example #2

A second application of the formalism of the present paper, is to the field of x-ray speckle tracking81,82. The technique of x-ray speckle tracking illuminates an object with a known resolved reference speckle field, and then measures one or more distorted forms of that speckle field which arise when a sample is placed in the illuminating speckle beam. The diffuse-scatter signal, considered in the present paper, arises naturally in x-ray speckle tracking – via unresolved sample-induced speckles that should be carefully distinguished from the titular illuminating speckles – and gives useful information that may be extracted using a variety of techniques. These techniques are typically based on the reduction in illuminating-speckle visibility due to SAXS-induced diffusion: see e.g. the review by Zdora83, and references therein. The geometric-flow approach to speckle tracking, which has recently been developed for x-rays87 but has also been very recently applied to visible-light imaging88, takes as a starting-point the following equation:

$${I}_{{\rm{R}}}(x,y)-{I}_{{\rm{S}}}(x,y)={{\rm{\nabla }}}_{\perp }\cdot [{I}_{{\rm{R}}}(x,y)\,{{\bf{D}}}_{\perp }(x,y)].$$
(53)

This relates the intensity IR(x, y) of a reference speckle image obtained in the absence of a sample, to the distorted/coded/encrypted form of that speckle image, denoted IS(x, y), obtained in the presence of a pure-phase-object sample; D(x, y) is a transverse displacement-vector field, which distorts the reference speckle image IR(x, y) into the speckle image IS(x, y) obtained in the presence of the sample. The above equation, modelled on the continuity equation that has played such a dominant role in the present paper, conserves photon energy both globally and locally. It may be used to reconstruct the speckle displacement D(x, y) induced by the phase object, and hence a map of the phase shift ϕ(x, y) due to the object, in a simple and efficient manner that implicitly rather than explicitly tracks speckles87. Note that the displacement field is related to the phase shift of the object, via

$${{\bf{D}}}_{\perp }(x,y)=(\Delta /k){{\rm{\nabla }}}_{\perp }\varphi (x,y),$$
(54)

where Δ is the sample-to-detector distance and k is the wave-number of the x-rays. A Fokker–Planck form of Eq. (53), suitable for a phase object described by both its phase shift ϕ(x, y) and effective diffusion coefficient Deff(x, y; Δ), is:

$${I}_{{\rm{R}}}(x,y)-{I}_{{\rm{S}}}(x,y)={{\rm{\nabla }}}_{\perp }\cdot [{I}_{{\rm{R}}}(x,y)\,{{\bf{D}}}_{\perp }(x,y)]-\varDelta {{\rm{\nabla }}}_{\perp }^{2}[{D}_{{\rm{e}}{\rm{f}}{\rm{f}}}(x,y;\Delta ){I}_{{\rm{R}}}(x,y)].$$
(55)

This incorporates both coherent flow and diffuse flow, into the geometric-flow method for x-ray speckle tracking. It would be interesting to investigate an augmented form of the geometric-flow x-ray speckle-tracking method, which takes Eq. (55) rather than Eq. (53) as a starting point, and seeks to reconstruct both ϕ(x, y) and Deff(x, y; Δ) rather than just ϕ(x, y). Of possible relevance in such a context – namely, of separating out the signal due to coherent versus diffusive energy flow – is the fact that Deff(x, y; Δ) will transform as a scalar upon rotation of the sample through 180 degrees (about a rotation axis that is perpendicular to the optical axis, e.g. in a computed-tomography setting), whereas D(x, y) will transform as a vector under the same rotation.

Example #3

As a third and somewhat more detailed example of inverse problems that may be tackled using the formalism outlined in the present paper, consider a static non-magnetic non-crystalline sample that is made of a single material. This sample may and in general will have varying spatial density, with complex refractive index4

$$n(x,y,z)=1-\delta (x,y,z)+i\beta (x,y,z)$$
(56)

which is such that the ratio \(\delta (x,y,z)/\beta (x,y,z)\) is independent of position at all points within the sample7,89. The associated unresolved micro-structure is left arbitrary, and the exit surface of the sample is assumed to correspond to the plane z = 0. Further assume normally-incident unit-intensity illumination by z-directed quasi-monochromatic x-ray plane waves. This single-material approximation, together with the projection approximation4, implies that the x rays at the exit surface of the sample have an intensity \(I(x,y,z=0)\) and phase \(\varphi (x,y,z=0)\) given by

$$I(x,y,z=0)=\exp \,[\,-\,\mu T(x,y)],\,\varphi (x,y,z=0)=-\,k\delta T(x,y).$$
(57)

Here μ = 2 is the linear attenuation coefficient of the material from which the sample is composed, and T(x, y) is the projected thickness of the sample along the z direction. The fact that7

$$\begin{array}{ccc}{{\rm{\nabla }}}_{\perp }\cdot [I(x,y,z=0){{\rm{\nabla }}}_{\perp }\varphi (x,y,z=0)] & = & {{\rm{\nabla }}}_{\perp }\cdot \{\exp \,[\,-\,\mu T(x,y)]{{\rm{\nabla }}}_{\perp }[\,-\,k\delta T(x,y)]\}\\ & = & \frac{k\delta }{\mu }{{\rm{\nabla }}}_{\perp }^{2}\,\exp \,[\,-\,\mu T(x,y)]\end{array}$$
(58)

enables the 2 + 1-dimensional finite-difference Fokker–Planck equation in Eq. (14) to be transformed to:

$$I(x,y,z=\Delta )=\{1-\Delta [\frac{\delta }{\mu }-{D}_{{\rm{e}}{\rm{f}}{\rm{f}}}(x,y;\Delta )]{{\rm{\nabla }}}_{\perp }^{2}\}\,\exp \,[\,-\,\mu T(x,y)],\,F(x,y)\ll 1.$$
(59)

Here, we have used Eq. (16) to incorporate the effective diffusion coefficient Deff(x, y; Δ). Equation (59) is a linear elliptic partial differential equation for the unknown exponentiated projected thickness exp[−μT(x, y)] of the single-material sample with projected thickness T(x, y), and is an algebraic equation for the unknown effective diffusion coefficient (SAXS term, or so-called “dark-field” signal11,44,76) Deff(x, y; Δ). Note that the Deff(x, y; Δ) → 0 limit of Eq. (59) is the basis of a commonly-used single-image method for x-ray phase retrieval7. When we cannot assume Deff(x, y; Δ) to vanish, we may solve Eq. (59) for both Deff(x, y; Δ) and T(x, y), as follows. Suppose propagation-based phase contrast images are obtained at two different propagation distances, Δ1 and Δ2. From Eq. (f) in Fig. 3, we can write down the scaling relation:

$$\frac{{D}_{{\rm{e}}{\rm{f}}{\rm{f}}}(x,y;{\Delta }_{1})}{{\Delta }_{1}}=\frac{{D}_{{\rm{e}}{\rm{f}}{\rm{f}}}(x,y;{\Delta }_{2})}{{\Delta }_{2}}.$$
(60)

This scaling results from the already-mentioned fact that the slab of vacuum, in between the exit surface z = 0 of the object and the entrance surface z = Δ of the detector, is not a diffusive medium. Thus the width of the SAXS fans scales linearly with Δ, rather than being proportional to Δ1/2 (as would be the case for true diffusion). Setting D Δ ensures that the final term on the right side of Eq. (6) is proportional to Δ2, ensuring the width of the SAXS fan scales as (Δ1/2)2 = Δ, as required. As is the case throughout the paper, the artifice of a Δ-dependent diffusion coefficient is a price to be paid for the simplicity of being able to work simultaneously with both diffusion concepts and free-space coherent propagation concepts, in the context of the Fokker–Planck and Kramers–Moyal equations for x-ray imaging. To proceed we write the z = Δ1 and the z = Δ2 cases of Eq. (59), and then use Eq. (60) to eliminate Deff(x, y; Δ1,2). Hence:

$$\frac{{\Delta }_{2}^{2}\,I(x,y,z={\Delta }_{1})-{\Delta }_{1}^{2}\,I(x,y,z={\Delta }_{2})}{{\Delta }_{2}^{2}-{\Delta }_{1}^{2}}=(1-\frac{\delta }{\mu }\frac{{\Delta }_{1}{\Delta }_{2}}{{\Delta }_{1}+{\Delta }_{2}}{{\rm{\nabla }}}_{\perp }^{2})\,\exp \,[\,-\,\mu T(x,y)].$$
(61)

Equation (61) is mathematically identical in form to Eq. (7) of Paganin et al.7, and may therefore be solved using the same Fourier-transform method. This gives:

$$\begin{array}{ccl}T(x,y) & = & -\,\frac{1}{\mu }{\log }_{{\rm{e}}}\{{{\mathscr{F}}}^{-1}[\frac{{\mathscr{F}}[{\Delta }_{2}^{2}\,I(x,y,z={\Delta }_{1})-{\Delta }_{1}^{2}\,I(x,y,z={\Delta }_{2})]}{1+\frac{\delta }{\mu }\frac{{\Delta }_{1}{\Delta }_{2}}{{\Delta }_{1}+{\Delta }_{2}}({k}_{x}^{2}+{k}_{y}^{2})}]\}\\ & & +\,\frac{1}{\mu }{\log }_{{\rm{e}}}({\Delta }_{2}^{2}-{\Delta }_{1}^{2}),\,{\Delta }_{1}\ne {\Delta }_{2}.\end{array}$$
(62)

Here, \({\mathscr{F}}\) denotes Fourier transformation with respect to x and y, in any convention that transforms ∂/∂x into ikx and ∂/∂y into iky; (kx, ky) are Fourier coordinates corresponding to (x, y), and \({ {\mathcal F} }^{-1}\) is the inverse of \( {\mathcal F} \). Equation (62) shows how a linear combination of two images, taken at two different distances Δ1 and Δ2, may be combined to yield the projected thickness T(x, y) of a thin single-material sample, in a manner that is independent of SAXS scattering by the sample (cf. Pagot et al.40). Once T(x, y) has been so obtained, Eq. (59) can then be solved algebraically for Deff(x, y;Δ). Such a phase/dark-field retrieval approach that incorporates dark-field effects might benefit samples from a range of fields including materials development (e.g. micro-crack detection in high-strength materials90) and biomedical imaging (e.g. diagnostic imaging of the lungs91).

In the third example above, and indeed throughout the paper, the effective diffusion coefficient (and, more generally, the diffusion tensors as defined in Eqs (48)–(50)) will have at least three independent contributions:

  • The first contributor to the hierarchy of diffusion tensors is the sample-induced scatter due to unresolved micro-structure, that has been a main theme of the present paper.

  • The second contributor to the diffusion tensors is an edge-scattering signal11,44 that is now known to be due to unresolved sharp edges92, and which may be viewed as a Young–Maggi–Rubinowicz type boundary wave65,93,94,95,96,97 or a Keller-type98 diffracted ray. This is examined in further detail in the previously mentioned companion paper77.

  • The third contribution to the diffusion tensors is associated with incoherent aberrations (including the modulation transfer function of the detector, and penumbral blurring effects due to finite source size) of the imaging system that is used to measure images of the sample. As an example: take Eq. (59), set Deff(x, y; Δ) to a constant Deff(Δ) that is independent of x, y so as to model penumbral blur due to finite source size in a linear shift-invariant imaging system, and then note that the resulting equation has a solution identical to that recently published by Beltran et al.99.

All three effects will in general be present simultaneously, so that e.g. the SAXS fans associated with sample-induced blurring will need to be convolved with the intensity point-spread function of a given optical imaging system, and similarly with the signal associated with unresolved sharp edges. These interesting complications, which may be summarised in the statement that “partial coherence can come from the source, or the object itself”, are beyond the scope of the present paper.

There is some relation between the differential form of the diffusion operators employed in this paper, and the idea of Laplacian-based unsharp-mask image sharpening100,101. From an unsharp-mask image processing perspective, the linear differential operator102

$${\mathscr{L}}=1-{w}^{2}(x,y){{\rm{\nabla }}}_{\perp }^{2}$$
(63)

locally sharpens an image I(x, y) to which it is applied, with a characteristic position-dependent partial-deconvolution transverse length scale equal to w(x, y); cf. Eq. (59). The approximate inverse of this operator, which locally blurs an image over the same transverse length scale w(x, y), is (cf. Eqs (6) and (35))102:

$${{\mathscr{L}}}^{-1}\approx 1+{w}^{2}(x,y){{\rm{\nabla }}}_{\perp }^{2}.$$
(64)

This blurring is rotationally symmetric. If this rotational symmetry is not present, we can use a Kramers–Moyal type linear differential operator to effect local blurring with a position-dependent point-spread function, namely

$${\mathscr{K}}=1+\mathop{\sum }\limits_{m=0}^{2}\,{w}_{m,2-m}^{(2)}(x,y){{\rm{\partial }}}_{x}^{m}{{\rm{\partial }}}_{y}^{2-m}-\mathop{\sum }\limits_{m=0}^{3}\,{w}_{m,3-m}^{(3)}(x,y){{\rm{\partial }}}_{x}^{m}{{\rm{\partial }}}_{y}^{3-m}+\cdots .$$
(65)

The notation above is analogous to the diffusive terms in Eq. (51), and we have set ∂/∂x ≡ ∂x, ∂/∂y ≡∂y. This gives another perspective on the use of derivative operators to effect blurring associated with a position-dependent point spread function. Similar ideas are used in image sharpening via coherent defocus67 and image blurring operations of the convolution type103.

The two derivations of the Fokker–Planck equation for paraxial imaging, given in the present paper, may be augmented by other approaches. An approach based on Wigner functions104 would be an interesting avenue for future research, since Wigner functions naturally capture the idea that there can be a distribution of energy flow vectors at each point in space105. See e.g. Eq. (19) of Nugent and Paganin106, which was obtained via a Wigner-function formulation of paraxial optics, and which may be readily manipulated into a Fokker–Planck form given by Eq. (14). From a different perspective again, the intensity transport equations associated with arbitrary aberrated linear shift-invariant optical imaging systems107 may be rendered into Fokker–Planck and Kramers–Moyal forms via the slight generalisation of replacing shift-invariant local differential operators with their corresponding shift-variant forms, along very similar lines to those indicated in the preceding paragraph.

Unresolved speckle lies at the heart of many phenomena observed in imaging using partially coherent optical fields4,108. Here, “speckle” is used in the general sense of optical fields whose spatial and/or temporal intensity fluctuations have a random component; this differs from the more usual usage which equates “speckle” with “fully developed speckle”. Unresolved speckles have two distinct origins: (i) the partial coherence of the illuminating beam and its associated spatio-temporal speckles, and (ii) unresolved speckle associated with sample micro-structure. In the present paper, the spatial width w of the point-spread function (PSF) of the position-sensitive detector—a lower limit on which is given by the pixel size—defines a natural transverse length scale. Speckles much smaller in size than w will be spatially averaged when registering an image. If ergodicity of the associated stochastic process can be assumed, over the area of each pixel, then by definition the spatially-averaged intensity at each pixel location can be replaced with a corresponding ensemble average over many realisations of the ensemble of fields illuminating each pixel. Physically, and as has been used in the present paper, this corresponds to a statistical ensemble of objects, each of which has the same coarse-grained projected complex refractive index distribution, but differing spatially-random micro-structure. This construct permits us to approximate the resulting measured intensity map, with a probability distribution obeying the 2 + 1-dimensional Kramers–Moyal equation, including the special case of the 2 + 1-dimensional Fokker–Planck equation. Refraction and prism terms are associated with the resolved coarse-grained structure of the ensemble of objects and the ensemble of illuminations, with the diffusion term being associated with the unresolved speckles. What is deemed SAXS is a detector-resolution-dependent construct associated with unresolved sample-induced speckles. Thus, the component of the scattered radiation attributed to SAXS is dependent on w, and thereby detector dependent. This last statement ties in with the broader idea that there is a close link between partial coherence and the spatio-temporal resolution of one’s detector—see e.g. Sec. 3.6.3 of Paganin4. It is also closely related to what component of the x-ray energy flow is classed as “coherent energy transport”, and what is classed as “diffusive energy transport”, in the Fokker–Planck and Kramers–Moyal constructions: the finer the spatio-temporal resolution of the intensity detection, the smaller the fraction of the x-ray energy flow that will be classed as diffusive. Both the TIE-type and SAXS-type scattering (resolved and unresolved structures) arise from the same fundamental physics, as is clear in the first-principles derivation of the x-ray Fokker–Planck equation. Again, what length scales ultimately fall into either category is determined by the resolution of the detector.

We close this discussion by emphasising the broader applicability, beyond the margins delineated in the present paper, of the Fokker–Planck and Kramers–Moyal equations to (i) partially coherent paraxial x-ray imaging in particular, and (ii) partially-coherent paraxial imaging more generally. Context may be given to this claim, by the huge domain of applicability of Fokker–Planck and Kramers–Moyal concepts. Of equal relevance is the likelihood that the domain of validity of the paraxial-imaging Fokker–Planck and Kramers–Moyal equations is at least as broad at that of the transport-of-intensity equation which they generalise; and, since the transport-of-intensity equation has been applied to visible light109, electrons110, neutrons111 and x-rays7, there is every expectation that the formalism of the present paper may be utilised for paraxial-imaging scenarios using all of the just-listed radiation and matter wave fields. Extensions of the present paper, to imaging applications beyond those listed previously, include a Fokker–Planck approach to neutron phase contrast imaging111,112, x-ray magnetic circular dichroism imaging113, x-ray edge-illumination imaging114, x-ray Zernike phase contrast imaging115, neutron grating imaging116, electron out-of-focus contrast imaging (Fresnel contrast imaging)117 and visible-light out-of-focus contrast imaging109. As with the present study, a core motivation for such an approach is its potential simultaneously to model, under the aegis of a single powerful formalism, both deterministic and stochastic aspects of paraxial thin-object imaging using partially coherent radiation and matter wave fields.

Conclusion

Fokker–Planck and Kramers–Moyal equations were obtained, to model near-field and intermediate-field paraxial quasi-monochromatic x-ray imaging of thin samples exhibiting both phase–amplitude and small-angle-scattering contrast. Two complementary derivations were given. Possible applications, to both forward and inverse imaging problems, were discussed.