• No results found

Angular Correlations of CsCl Solutions - Simulations of Coherent X-Ray Scattering

N/A
N/A
Protected

Academic year: 2022

Share "Angular Correlations of CsCl Solutions - Simulations of Coherent X-Ray Scattering"

Copied!
72
0
0

Loading.... (view fulltext now)

Full text

(1)

IN DEGREE PROJECT ,

SECOND CYCLE, 30 CREDITS STOCKHOLM SWEDEN 2019 ,

Angular Correlations of CsCl Solutions

Simulations of Coherent X-ray Scattering CAROLINE DAHLQVIST

KTH ROYAL INSTITUTE OF TECHNOLOGY

SCHOOL OF ENGINEERING SCIENCES

(2)
(3)

Angular Correlations of CsCl Solutions

Simulations of Coherent X-ray Scattering

Caroline Dahlqvist

Master’s Thesis (SK202X) School of Engineering Science (SCI)

Department of Applied Physics Supervisor: Jonas Sellberg

Examiner: Ulrich Vogt TRITA-SCI-GRU 2018:430

June 19, 2019

Stockholm

(4)

Abstract

The evolution of brighter and intenser x-ray sources such as free-electron lasers have rekindled the interest in correlation methods, which were limited by the low pho- ton counts reaching the detector, high noise levels, exposure times and consequent radiation damage. By outrunning the radiation damage through ‘diffraction before destruction’ it is possible to take snap-shots of molecules in solution before they explode, without any radiation damage recorded in the diffraction data. These cor- relation methods can reveal hidden information about molecular structures and can also be applied in reconstructions.

In this thesis project, the angular correlations of diffraction patterns, from CsCl

solution in water is generated with the simulation tool Condor, calculated and anal-

ysed. Inside of the water-ring there are indications of structural correlations from

Cs and Cl ions around 1.1 Å

−1

and 1.6 Å

−1

, even with added Poisson and Gaussian

noise. In this limited study, 9 100 diffraction patterns were generated and although

the Fourier coefficients are not completely converged at this number of patterns,

they are converged to at least 97 %, in concurrence with a previous publication

stating a lower limit of 20 000 patterns.

(5)

Sammanfattning

Utvecklingen av ljusare och intensivare röntgenkällor som frielektron lasrar (FEL) har återuppväckt intresset för vinkelkorrelations-metoder, vilka tidigare var begrän- sade av de låga antalet fotoner som nådde fram till detektorn, höga nivåer av brus och exponeringstider med påföljande strålskador. Genom att undgå strålskador genom

‘diffraktion innan destruktion’ är det möjligt att ta ögonblicksbilder av molekyler i vätskelösning innan de exploderar, utan att skador från strålningen har hunnit reg- istrerats i diffraktionsdatan. Dessa korrelationer kan avslöja ny, dold, information om molekylernas struktur och kan även användas för rekonstruktion.

I detta examensarbete beräknas och analyseras korrelationer från diffraktionsmön- ster från simuleringar med programvaran ‘Condor’ av CsCl-lösning i vatten. Innan- för den kända vatten-ringen finns tydliga indikationer på diffraktion från Cs och Cl vid 1.1 Å

−1

samt 1.6 Å

−1

(även vid närvaro av Poisson- och Gaussiskt brus). I denna begränsade studie genererades 9 100 diffraktionsmönster och även om Fourier koefficienterna inte hunnit konvergera helt vid detta antal så har de konvergerat till 97 %, i enlighet med tidigare publikationer som anger en lägre gräns vid 20 000 mönster.

ii

(6)

Contents

Abstract i

Sammanfattning ii

1 Introduction 1

2 Theoretical Background 5

2.1 Angular Cross-Correlation . . . . 5

2.1.1 The Cross-Correlation Function . . . . 5

2.1.2 Intensity Expansion in Local Structures . . . . 8

3 Simulations 10 3.1 Sample . . . 11

3.2 Diffraction Patterns . . . 11

4 Data Analysis 15 4.1 Auto-Correlation or Angular Correlation . . . 15

4.1.1 Calculations of Average Angular Correlations . . . 15

4.1.2 Fourier Coefficients of the Angular Correlations . . . 16

4.2 Cross-Correlation or 3D Angular Correlation . . . 17

4.2.1 Calculation of Cross-Correlations or 3D Angular Correlations . 17 4.2.2 Fourier Coefficients of the 3D Angular Correlations . . . 17

4.2.3 Fourier Quadrant Correlation . . . 19

4.3 Implementation of Noise . . . 19

4.3.1 Poisson Noise . . . 19

4.3.2 Gaussian Noise . . . 19

5 Results 21 5.1 Diffraction Patterns . . . 21

5.2 Auto-Correlation . . . 25

(7)

5.2.1 Fourier Coefficients of the Auto-Correlation . . . 27

5.2.2 Fourier Coefficients of the Auto-Correlation with Added Noise 31 5.3 Cross-Correlation . . . 34

6 Discussion 40 7 Conclusion 44 Acknowledgements 45 Bibliography 45 A Intensity Expansion in Local Structures I B Simulations in Condor IV C Supplementary Figures IX C.1 Amplitude Patterns from Simulations of 6 Molar CsCl with Synchro- nised Arrival at the Beam . . . X C.2 Noise Free Detector - Fourier-Coefficients Normed with the Variance . XI C.3 Poisson Noise in the Detector - Fourier-coefficients Normed with the Variance . . . XII C.4 Fourier Quadrant Correlation Compare 4 Molar and 6 Molar . . . . .XIII List of Figures 2.1 Scattering Vector Components in Reciprocal Space . . . . 6

3.1 A Box of CsCl Solved in Water Simulated with GROMACS . . . 10

3.2 The Detectors Mask from the Experiment at the FEL Facility . . . . 12

3.3 Three shots from Simulations with Condor at Random Orientations of the Sample and with Different Beam Properties . . . 14

4.1 Example if Gaussian Noise per ASIC . . . 20

5.1 Some of the Diffraction Patterns from the Simulations . . . 23

5.2 Average Intensity Patterns for 2 Molar, 4 Molar and 6 Molar . . . 24

iv

(8)

5.3 Radial Profiles for 2, 4 and 6 Molar . . . 24 5.4 Auto-Correlation of the Simulated Intensity Patterns from 6 Molar

of CsCl and of the Mask (from the Experiment) . . . 25 5.5 Auto-Correlation of 2, 4 and 6 Molar of CsCl from Simulated Data

(Normed with the Mask from the Experiment) . . . 26 5.6 Fourier Coefficients for 2, 4 and 6 Molar . . . 28 5.7 Fourier Coefficients for 6 Molar Comparison of Random and Synchro-

nised Arrival of the Sample at the FEL-beam . . . 29 5.8 0

th

Fourier Coefficient for 6 Molar Comparison of Random and Syn-

chronised Arrival of the Sample at the FEL-beam . . . 30 5.9 Even Fourier Coefficients for 6 Molar, Normed with the Variance,

for Detector with Poisson Noise, 10 % and 20 % Gaussian Noise of Average Intensity . . . 32 5.10 Even Fourier Coefficients for 6 Molar, Normed with the Variance,

for Detector with Poisson Noise, 10 % and 20 % Gaussian Noise of Maximum Intensity . . . 33 5.11 Fourier Coefficients for 4 and 6 Molar of Cross-Correlations, Normed

with the Variance . . . 35 5.12 Maps of q

1

vs q

2

for 42 simulations with 100 Shots each for 4 Molar . 36 5.13 Maps of q

1

vs q

2

for 42 simulations with 100 Shots each for 6 Molar . 37 5.14 Maps of q

1

vs q

2

for 42 simulations with 100 Shots each for 6 Molar

with Synchronised Arrival of the Sample at the Beam . . . 38 5.15 FQC for 6 Molar of CsCl solution, Comparison of Random and Syn-

chronised Arrival of the Sample at the FEL-beam . . . 39 C.1 Some of the Diffraction Patterns from the Simulations with Synchro-

nised Arrival . . . X C.2 Fourier Coefficients for 2, 4 and 6 Molar, Normed with the Variance XI C.3 Fourier Coefficients for 2, 4 and 6 Molar Normed with the Variance,

for Detector with Poisson Noise. . . XII C.4 FQC for 4 and 6 Molar Comparison of Random Arrival of the Sample

at the FEL-beam . . . .XIII

List of Tables

3.1 Parameters Used in the Simulation Program Condor . . . 13

(9)

Acronyms

ASIC Application Specific Integrated Circuit CCF Cross-Correlation Function

CDI Coherent Diffractive Imaging

CSPAD Cornell-SLAC Pixel Array Detector CXS Coherent X-ray Scattering

CXI Coherent X-ray Imaging FEL Free-Electron Laser FFT Fast Fourier Transform FQC Fourier Quadrant Correlation FWHM Full-Width at Half-Maximum FXI Flash X-ray Imaging

GFP Green Fluorescent Protein LCLS Linac Coherent Light Source SAXS Small-Angle X-ray Scattering SLAC Stanford Linear Accelerator Center SNR Signal-to-Noise ratio

STED Stimulated Emission Depletion XCCA X-Ray Cross Correlation Analysis

vi

(10)

Chapter 1 Introduction

Ever since the x-rays were discovered by Röntgen in 1895 [1, 2], they have pro- posed an important way of seeing into a material to explore the internal structure or composition. Despite the extensive sequencing of proteins, only 10% have been structurally determined [3] and at the same time many protein functions depend on proper protein folding [4]. Even with the improved techniques in microscopy, these are still limited in terms of imaging a biological sample such as a protein or a molecule in its natural environment, since they often have to be sliced or pre- pared with a fluorophore or marker in the case of fluoroscopy, confocal or Stimulated Emission Depletion (STED) whenever no natural fluorophore, such as Green Fluo- rescent Protein (GFP), is present. There is also a temporal resolution limit of the order of 10

−8

s due to the excitation and de-excitation of the fluorophore [5]. Since x-rays project an electron density map on the detector resulting from the attenu- ation (absorption and scattering) of the photons as they pass through the sample, there is often no sample preparation required. On the down side there is the prob- lem with radiation damage which can be mitigated by imaging frozen (cryogenic) or dead samples. Except for the conventional projection x-ray method there have been several developments in order to increase the contrast and resolution of the imaging object as well as techniques to detect more than just the drop in intensity, such as the phase of the electromagnetic wave as opposed to just its amplitude (the square root of the detected intensity) or the structure of the atomic planes through diffraction. To increase the contrast, vacuum chambers are frequently used in order to remove as much background as possible [6].

Diffractive imaging with x-rays was initially explored in crystallography by the study

of the interference patterns of x-ray beams reflected by a crystal resulting in the

formulation of Bragg’s Law [7], imperative to the study of crystal structures. Since

then, Coherent Diffractive Imaging (CDI) has posed new obstacles, where imaging

of a single molecule instead of a crystal produces a continuous diffraction pattern.

(11)

C. Dahlqvist CHAPTER 1. INTRODUCTION

The difficulty lies in the lack of knowledge of both the phase and the intensity in any plane [8], provided the incident x-ray field is known and preferably coherent.

Where coherent diffraction arises when the irradiated volume is smaller than the coherence length of the (x-ray) beam. For a unique reconstruction to exist in forward scattering CDI, the sample must be finite in the spatial extent [9]. The prospect of diffractive imaging is that instead of the necessity of focusing the beam before and after the sample in order to get a clear image, diffractive imaging is a lensless imaging technique where the diffraction of the focused x-rays are instead collected in the far-field. The diffraction pattern is then converted into a real-space image and the difficulties with lenses and their aberrations are circumvented.

The development of the Free-Electron Laser (FEL) further increased the interest in various possibilities of reconstructing structures at the nano-scale. The FEL produces much more intense x-rays than the synchrotron and like a laser, can be pulsed. The pulse duration can be brought down to tens of femtoseconds. This is the foundation of the imaging modality “diffraction before destruction”, where the x-ray pulse is so intense, with an incident flux of 10

12

photons per shot (or photon bunch) [6, 10], several orders of magnitude above that of a synchrotron, that the sample is destroyed in a flash of plasma from the extreme radiation dose of up to 100 GGy (at 8 keV photon energy). The absorbed dose of x-ray radiation has always posed a problem when studying elements with low atomic number since the low contrast requires longer exposure times and therefore more energy is transferred to the sample giving rise to an increase in temperature, resulting in bond breakage and structural changes of the sample [8]. With a pulse duration of the same order as the electron transitions (10

−15

s), the radiation damage effect can be outrun and the diffraction occurs before the destruction of the sample. The effect is referred to as “freezing” the motion of the sample, at the time scale of atomic vibrations, and produces a snap-shot of the sample. The diffraction pattern from only one such snap-shot is not enough for adequate reconstruction since the Signal-to-Noise ratio (SNR) is too low. However, the sample is destroyed and it is not possible to repeat the procedure with the same sample. Instead the procedure is repeated for several similar or identical samples of unknown orientations and the diffraction patterns are sorted into groups or clusters of similarity. The reconstruction is then performed with a method of choice, for which there are several algorithms used in practice, commonly implementing iterative phase retrieval from the reciprocal Fourier space diffraction patterns [8, 6]. Even with extensive reconstruction processes there is still the problem with collection of low resolution data because of the opening in the detector for the direct FEL beam which would saturate or burn through the detector [6]. Often the FEL-beam hit multiple molecules or structures in the sample as more than one molecule is delivered at the beam line and hit by the x-ray pulse, yielding a diffraction pattern of more than one molecule without the possibility of resolving one from the other. As a consequence, a lot of diffraction data is therefore sorted out and only a fraction is used in the final reconstruction with varying hit-

2

(12)

C. Dahlqvist CHAPTER 1. INTRODUCTION

ratios (single or multiple hits), for example 43% with Cyanobium gracile cells (with sizes around 1000 nm) of which 7.500 single hits were collected [6] compared to 79%

of carboxysomes (ten times smaller, about 100 nm), only 30% of which were bright enough for further processing [11].

A further development for applications on macromolecules was suggested by the study of “scattering correlation” [12] where the fluctuations in intensities, due to the random rotation of particles, from two particles are experimentally enhanced by time averaging. At the time the experimental feasibility was limited because of the weakness of the scattered signal that reached the detector even from a synchrotron x-ray source [13] and too strong background scattering. With the development of more powerful synchrotron sources and more sensitive detectors, the idea of explor- ing the local symmetries related to local bonding and bonding angles of the atoms through correlation was re-investigated [14]. The concept of X-Ray Cross Corre- lation Analysis (XCCA) was developed for disordered matter such as glasses and liquids by relating the measurable cross-correlation of the intensity, which depends on the momentum transfer, unravelling correlations in the angular distribution of the diffraction patterns. A more detailed mathematical description follows in the next chapter. Other names for the same method include Coherent X-ray Scattering (CXS) or Flash X-ray Imaging (FXI) when focusing on the reconstruction processes.

In this thesis, this method shall be referred to as XCCA.

In fluctuation analysis, such as in XCCA, the information about the orientations is lost and what remains is only information that depends on the internal atomic structure of the molecule. However, the recording times need to out-run the proteins’

rotational diffusion and at the same time receive a strong enough signal to overcome the noise (high enough SNR). This is possible with femtosecond FELs for solutions at room temperature [15].

Despite the current limitation in both data collection and reconstruction, there is still new information to be discovered in the currently collected diffraction data.

In particular, the question of what can be interpreted with the aid of XCCA in terms of bond angles and other physical properties of a sample. The advantage lies in circumventing the single-hit problem, since the XCCA of multiple particles will converge to that of a single particle [16].

Furthermore, identifying the possible causes of the deviation of experimentally mea-

sured data from the simulated data. Since a diffraction experiment at a FEL facility

is expensive and generate enormous amount of data to be processed, there are gen-

erally several simulations performed before and after the experiment itself. In the

collected experimental data there will be various types of artefacts and noise. By

simulating the experiment and superimposing different types of noise and artifacts,

the types present in the experimental data can be identified and confirmed and

subsequently removed or compensated for in the reconstruction process.

(13)

C. Dahlqvist CHAPTER 1. INTRODUCTION

This thesis project will focus on what information the angular correlations in coher- ent x-ray scattering of fluids can reveal about the azimuthal average (radial profile).

Moreover, to also investigate how Poisson and Gaussian noise influence the angular correlations. The study of fluids are of high interest since it is not always possible to crystallise proteins. To study their structure and behaviour in a natural environ- ment, in vivo, both crystallisation and cryo-techniques pose limitations in the study of the natural behaviour and dynamics of proteins and molecules.

4

(14)

Chapter 2

Theoretical Background

The fist section relates the mathematical background to the aforementioned XCCA, it is also common to use the fluctuations in the intensities instead of the directly measured intensities. The second section defines a mathematical expression for the intensity of dense and disordered local structures in three dimensions such as in the case of fluids, where there is no translational symmetry. This is of interest for the CsCl solution since, unlike crystals with Bragg peaks, there are only local correlations.

2.1 Angular Cross-Correlation

In subsequent parts h· · · i

x

represents an ensemble average over x, except for when x = ϕ , for which:

hf (ϕ)i

ϕ

= 1 2 π

Z

2 π 0

f (ϕ) dϕ

is the angular average around the ring (ϕ is an angular coordinate around a diffrac- tion ring).

2.1.1 The Cross-Correlation Function

Defining the Cross-Correlation Function (CCF) denoted C(q

1

, q

2

, ∆) for the scat- tered intensities [18], which is dependent on the magnitude momentum transfer vec- tor q and azimuthal angle ∆ between the two correlated intensities (see fig. 2.1b).

The scattered intensity is detected at a two-dimensional detector where it generates

a characteristic concentric ring structure in the case of disordered systems where

(15)

C. Dahlqvist CHAPTER 2. THEORETICAL BACKGROUND

kx

kz

ky

q1

q2

q⊥1

qz1 k1

k2

kin q⊥2

1

2

qz2

a)

q1

q2

Δ

𝝋

kx

ky

b)

Figure 2.1: The geometry of the momentum transfer vectors in reciprocal space, q and the wavenumber k of the incident and scattered beam at the sample and detector plane. a) Orthogonal components of scattering vectors in reciprocal space on the Ewald sphere. b) Diffraction rings corresponding to two different magnitudes of the scattering vectors q (momentum transfers) and their azimuthal angles in the plane of reference. Figure adapted from [17].

the angle ϕ is the azimuthal angle in the detector plane of q

1

. The CCF for two intensities at q

1

and q

2

is defined as:

C(q

1

, q

2

, ∆) = hI(q

1

, ϕ)I(q

2

, ϕ + ∆)i

ϕ

(2.1) By expanding the CCF into a Fourier series (over the angles) in a 2 π interval, any symmetry or periodicity can be investigated:

C(q

1

, q

2

, ∆) =

X

n =− ∞

C

qn1, q2

e

i n ∆

(2.2a)

C

qn1, q2

= 1 2 π

Z

2 π 0

C(q

1

, q

2

, ∆) e

− i n ∆

d∆. (2.2b) Writing C(q

1

, q

2

, ∆) in terms of I(q

j

, ϕ) in eq. (2.2b) and applying the convolution theorem (assuming 2 π periodicity) results in:

C

qn1, q2

= I

n∗

(q

1

) I

n

(q

2

) (2.3) which relates the Fourier coefficients of the CCF with the Fourier coefficients of the intensity which can be calculated first. Because the scattered intensities are real

6

(16)

C. Dahlqvist CHAPTER 2. THEORETICAL BACKGROUND

quantities, it follows that I

−n

(q

j

) = I

n ∗

(q

j

) and consequently the same is true for C

qn

1, q2

. This symmetry conditions implies a cosine behaviour of C(q

1

, q

2

, ∆) : C

q1, q2

(∆) = 2

X

n = 0

Re C

qn1, q2

e

i n ∆

 = 2

X

n = 0

| C

qn1, q2

|

2

· cos(n ∆ + γ

n

) (2.4) where γ

n

= arg[C

qn1, q2

] . Such a strong cosine behaviour can only be observed for those values of q where one of the Fourier coefficients significantly dominates over all the others [17]. The CCF can also be defined as the normed intensity fluctuations, around the mean intensity, where only the fluctuations are of interest. In that case the sums in eq. (2.4) starts at n = 1 and the zeroth term, the angular average, becomes zero [17]. In practice the CCF needs to be averaged over sufficiently many diffraction patterns since statistical fluctuations prevents reliable information [17, 19, 20]. For correlation between diffraction pattern i and j :

hC

in

(q

1

, q

2

, ϕ + ∆)i

i

= 1 M

M

X

i=1

C

in

(q

1

, q

2

) = 1 M

M

X

i=1

I

in∗

(q

1

)I

in

(q

2

) (2.5a)

hC

ijn

(q

1

, q

2

, ϕ + ∆)i

i6=j

= 1 M (M − 1)

M

X

i=1

C

ijn

(q

1

, q

2

) = 1 M (M − 1)

M

X

i,j=1 i6=j

I

in∗

(q

1

)I

jn

(q

2

) (2.5b) For a single momentum transfer, q

1

= q

2

= q the CCF simplifies to the angular correlation (correlation of each q-ring with itself):

C(q, ∆) = hI(q, ϕ)I(q, ϕ + ∆)i

ϕ

(2.6a) hC

i

(q, ∆)i

i

= 1

M

M

X

i=1

C

i

(q, ∆) (2.6b)

with Fourier coefficients C

n

(q) = |I

n

(q)|

2

.

These Fourier coefficients can relate, in a general way, to the arrangement and orientation of bond angles and interatomic distances in the Fraunhofer diffraction (far-field) case. It has previously been shown [21] that for disordered systems there is structural information contained in this Fourier spectra which is not accessible in standard Small-Angle X-ray Scattering (SAXS) experiments. Currently, there are various approaches to relate the additional information from the CCF in reciprocal space to the real space [17, 16, 6, 15], although not included in the span of this thesis.

For the case of large scattering angles in experiments, any angular dependence due

to the linear polarisation of the incident radiation beam must be removed from the

intensity or it will cause faulty results [17].

(17)

C. Dahlqvist CHAPTER 2. THEORETICAL BACKGROUND

2.1.2 Intensity Expansion in Local Structures

The scattered intensities from a disordered sample generates a diffraction pattern on the detector in the far-field regime (Fraunhofer diffraction). In order to form a gen- eral model system, it is assumed that a sample consist of identical three dimensional local structures of arbitrary shape, random orientation and position in space. The general model applies to clusters or molecules in gas phase, ions, protein molecules, viruses or complex biological systems in solution [17].

The following is under the assumption that the sample, in three dimensions, with non negligible thickness, is a disordered (without any preferred alignment) and dense (the average distance between clusters, group of identical molecules, is on the order of the size of a single cluster) system. In addition, for small samples which interacts weakly with the x-rays it is possible to neglect the multiple scattering within the sample [22], this kinematic scattering is referred to as the first Born Approximation (from first-order perturbation theory). The first Born approximation can describe the scattering amplitude A(q) for coherent x-ray scattering:

A(q) = Z

ρ(r) e

i q·r

dr (2.7)

where ρ(r) is the total electron density. In the case of Friedel’s law (inversion symmetry in reciprocal space q = −q), such as in SAXS experiments, the curvature of the Ewald sphere in fig. 2.1a appears flat and the scattering is symmetric. This also means that any odd Fourier coefficients are negligible small and it is believed that there are hidden symmetries as a result of Friedel’s law. This is not the case for wide angle scattering or XCCA where the effects of the Ewald sphere curvature manifests itself, yielding a non-zero scattering vector parallel to the beam-axis and odd Fourier coefficients. To see this, some additional expressions need to be defined, starting with the total electron density of a disordered system:

ρ(r) =

N

X

k = 1

ρ

k

(r − R

k

) (2.8)

where ρ

k

(r) is the electron density of the k

th

local symmetry at position R

k

and N is the number of local symmetries. The intensity scattered at the momentum transfer value q is then (for complete derivation see Appendix A):

I(q) =

N

X

k1, k2= 1

Z Z

ρ

k1

(r

1

) ρ

k2

(r

2

)e

i q·(Rk2, k1+r2,1)

dr

1

dr

2

(2.9) where R

k2, k1

= R

k2

− R

k1

is the interparticle distance and r

2,1

= r

2

− r

1

are local coordinates. The scattering vector can be decomposed into two orthogonal components q = (q

, q

z

) where q

z

is parallel to the direction of the incident beam,

8

(18)

C. Dahlqvist CHAPTER 2. THEORETICAL BACKGROUND

see fig. 2.1a. The perpendicular component can be defined in polar coordinates as q

= (q

, ϕ) . Furthermore, for the radius vectors R

k1, k2

= R

k

2

−R

k

1

, r

2,1

= r

2

−r

1

and their z-components Z

k211, k2

= Z

k1, k2

+ z

21

. The electron density can then be decomposed in its orthogonal components of the scattering vector of the i

th

scatterer inside cluster k to:

˜

ρ

k

(r

, q

zj

) = f (q

j

)

Ns

X

i = 1

δ(r

− r

i

) e

− i qjz·zi

(2.10) where f(q

j

) is the form factor of a scatterer and N

s

is the number of scatterers in the cluster j. With this in mind, the Fourier coefficients in the first sum above in eq. (2.9) can be decomposed into:

I

n

(q

j

, q

zj

) = (i)

n

N

X

k1, k2= 1

e

− i qzj· Zk2, k1

L

kn1, k2

(q

j

, q

jz

) (2.11) with the Spatial Correlations L

kn2, k1

as defined in Appendix A.

Continuing on, the scalar product q·(R

k2, k1

+ r

2,1

) in eq. (2.9) can be written as the product between the vectors modulus and the cosines of the angle between the per- pendicular vector components ϕ−φ

R⊥ m lk2, k1

. Expanding the exponential function with Jacobi-Anger expansion e

i ρ cos ϕ

= P

m = − ∞

(i)

m

J

m

(ρ)e

i m ϕ

yields Bessel functions J

n

(ρ) of the first kind [17].

Integration over ϕ, to cover all angles, yields a Kronecker delta function R

02 π

e

i i(m−n) ϕ dϕ 2 π

= δ

m,n

, which removes the dependency on ϕ. Inserting all this in eq. (2.11) yields the final expression for the Fourier coefficients of the intensity, as seen in eq. (A.7), which can be separated in its odd and even parts:

I

evenn

(q

j

, q

jz

) = 2 (i)

n

|f (q

j

)|

2

N

X

1 ≤ k1≤N k1≤ k2≤N

Ns

X

1 ≤ l ≤Ns

l ≤ m ≤Ns

cos(q

zj

Z

kml2, k1

)J

n

(q

j

| R

⊥ m lk2, k1

|) e

−i n φR⊥ m lk2, k1

(2.12a) I

oddn

(q

j

, q

jz

) =

2 (i)

n+1

|f (q

j

)|

2

N

X

1 ≤ k1≤N k1≤ k2≤N

Ns

X

1 ≤ l ≤Ns

l ≤ m ≤Ns

sin(q

jz

Z

kml2, k1

)J

n

(q

j

| R

⊥ m lk

2, k1

|) e

−i n φR⊥ m lk2, k1

(2.12b) These Fourier coefficients of the intensities contain a nonzero contribution of q

zj

from the Ewald sphere curvature effects which also are present in the CCFs Fourier coefficients yielding nonzero odd Fourier coefficients and additional information.

The odd contribution is negligibly small for conditions corresponding to a flat Ewald

sphere, however this is not the case in XCCA at wide angles [17].

(19)

Chapter 3 Simulations

Pamela Svensson

December 8, 2017 Molecular Dynamics Simulations of CsCl in Water Applied Molecular Physics, 10c

Figure 3: Simulation cell of Cl (green), Cs (purple) and water (red and white)

Multiple calculations was performed with salinity levels ranging from 0.1 % to 19.3 %. A low amount of ions will produce a noisy ion-ion rdf whereas a high concentration of ions will produce some noise of a water-water rdf, this can be noted in Figure 4a. When extracting the water-water distances, Figure 4a, a typical water rdf can be seen for 1 ion pair. This is due to the very low amount of ions in the system and their presence in the solution are therefore almost invisible.

When increasing the concentration, the first peak drops, simply due to a lower amount of water molecules in the system, and the second solvation shell (second peak) appears at higher distances, around 0.6 nm.

5

Figure 3.1: A simulated box with CsCl in water with Cl (green), Cs (purple) and water (red and white) [23]. The sides of the box, although they differ slightly from each other, are around 3.2 ± 0.4 nm. Kindly supplied by Carl Caleman.

A FEL experiment

1

was performed in the autumn of 2018 at the Coherent X-ray Imaging (CXI) instrument of the Linac Coherent Light Source (LCLS) facility, part of SLAC

2

National Accelerator Laboratory in USA. One set of samples in the exper- iment were solvents of caesium chloride (CsCl) in water at different concentrations.

This thesis project focus on simulating the experiment with the same concentrations of CsCl.

1

Experiment Proposal LT14, principal investigator: Dr. Andrew Martin

2

Stanford Linear Accelerator Center (SLAC)

10

(20)

C. Dahlqvist CHAPTER 3. SIMULATIONS

3.1 Sample

Molecular data of a solvent with CsCl in water, the sample, was simulated with GROMACS

3

package and supplied by Carl Caleman

4

as part of another thesis project at Uppsala University [23], an illustration can be seen in fig. 3.1. Three different concentrations were simulated, two of which were of interest for comparison with the experiment, 4 Molar and 6 Molar concentrations. For each concentration there were 91 separate PDB

5

-files simulated [24], each containing a simulation box of the solution but at different instances in time. The boxes are nearly cubic with a side around 3.2 ± 0.4 nm, the exact dimensions of each box is stated in the header of each file in the unit Angstrom.

3.2 Diffraction Patterns

The simulations of diffraction patterns, ‘shots’, from the simulated box with salt solution were performed with Condor

6

. Condor is a FEL simulation program writ- ten in Python 2.7 and can be directly executed from a terminal or instantiated in Python 2.7 [22]. Because the FEL-experiment’s sample is delivered via a jet and the orientation of the sample is completely random, the arrival of the simulated particles from the files were also simulated with random orientation. For each sepa- rate PDB-file there were 100 diffraction patterns, or ‘shots’, simulated with random orientations. Each hit is from a re-load of the same sample file at a random orienta- tion resulting in 100 diffraction patterns of random orientations for each PDB-file, stored in one CXI-file per simulated PDB-file. The resulting 91 CXI-files contains the complex amplitudes Ψ, the intensity patters |Ψ|

2

in number of photons per pixel and the pulse energy of the beam in a dictionary where additional parameters can be added, such as the detector distance or the pixel size of the simulation.

The diffraction patterns were masked post-simulation with an assembled mask from the performed experiment at CXI, representing the collected data from the Cornell- SLAC Pixel Array Detector (CSPAD) detector with ’bad’ and saturated pixels masked out along with the regions where no data can be collected due to the phys- ical limits of the detector, see fig. 3.2. The detector is placed perpendicular to the FEL-beam and has a central hole for the direct beam to pass through. Without the addition of the mask the output from Condor will be in the case of an ideal unsatu- rated detector, however, unrealistic since the intense x-ray beam not only saturates

3

Available at: http://www.gromacs.org, (2019-04-30)

4

Reached via email: carl.caleman@physics.uu.se

5

Available at: http://www.wwpdb.org, (2018-12-21)

6

Available at github: https://github.com/FXIhub/condor or online at http://lmb.icm.uu.

se/condor/, (2018-12-21)

(21)

C. Dahlqvist CHAPTER 3. SIMULATIONS

0 200 400 600 800 1000 1200 1400 1600

0

200

400

600

800

1000

1200

1400

1600

0 1

Figure 3.2: The mask from the experiment performed at CXI with bad pixels masked out. The black 0’s represent that no photons are collected and the white 1’s represent fields where photons are collected.

pixels but also destroys the detector if there is not a central hole for the beam to pass through. In these simulations, the detector’s pixel distribution was loaded into Condor from the assembled mask, but Condor does not subtract the empty space (represented by the value 0) when loading a mask to the detector instance. It ap- pears that the mask is only used to determine the number of pixels in the plane. In addition, it is possible to define a simpler detector structure in terms of central hole coordinates and the gap in vertical and horizontal directions.

For comparison with the experiment, where the sample is injected in the beam- path through a nozzle, the sample arrival in the simulations in Condor were set to random and with random rotation formalism, the default setting is ’synchronised’

where the number of particles in the interaction volume equals the rounded value of ’number’. When the arrival of the particles is set to ’random’ the number of particles is Poissonian and the ’number’ is the expectation value. The ’number’ is a parameter for setting the number of different types of particles as a fraction, since the pdb-files from Gromacs contains the water solution this fraction was set to ’1’, however here the number can represent the fraction of one type of particle against

12

(22)

C. Dahlqvist CHAPTER 3. SIMULATIONS

water in the form spherical particles as in the article [22].

Since the side of the simulated cubic boxes were of the order of 3 nm, the simulation box is recorded along with the solvent when the beam focus is set to 200 nm, as in the experiment. In addition, the photon count was very low in the simulated diffraction patterns. Comparing the sample size to that of the actual experiment which had a nozzle diameter of 1 µm, the beam focus in the experiment was 20 % of the sample depth, while in the simulation it would be 6 700 %, which is clearly much wider than the sample. Therefore, simulations were performed with a narrower beam of 3 nm and 1 nm width of focus, the majority of which with 1 nm to be sure of imaging only the inside of the box at different orientations. Some edge scattering will be more present in some than others due to the orientation of the box, such as when the incident beam hits an edge or corner of the simulation box facing the beam. In addition, the beam energy was increased to 0.1 J instead of 1 mJ to counteract the thickness of the sample for this much narrower beam. Table 3.1 lists the selected parameters for the simulations. Examples of recorded diffraction patterns for the original 200 nm wide beam and an altered 3 nm beam are shown in fig. 3.3.

Table 3.1: Parameters applied in the simulations based on the ex- periment at the CXI instrument of the LCLS facility, part of SLAC in USA. The values in parenthesis is the actual experimental value when this differs from the value set in the simulations.

Source

Photon Energy 9.5 keV

Focus diameter 1 nm, 3 nm (200 nm)

Pulse Energy 0.1 J (1 mJ)

Profile Model Gaussian

Detector

Detector distance 0.15 m

Pixel size 110 × 110 µ m

Large 32 tile CSPAD (active pixels) ∼ 1516 × 1516 pixels Mask from experiment (all pixels) 1738 × 1742 pixels

Sample

Arrival random

Rotation formalism random

Position variation none

Concentration 2 M, 4 M, 6 M

(23)

a)

b)

Figure 3.3: Above is the intensity patterns |Ψ|

2

and below is the amplitude (com-

plex) pattern |Ψ| at the detector. a) Three shots from randomly oriented samples

injected into the beam path with a beam focus width of 200 nm and a pulse energy

of 1 mJ (as in the experiment). The plots are normed such that the lowest of the

three’s maximum intensity is the upper limit. Observe the very low intensity caused

by too few photons reaching the detector after diffraction with the sample, which is

too small compare to the beam’s focus width. Here the grey colour represent masked

out areas from lack of data collection, bad and saturated pixels in the experiment

which is constructed into a detector’s mask and stored separately. b) Three shots

from randomly oriented samples injected into the beam path with a beam focus

width of 3 nm and a pulse energy of 1 mJ (as in the experiment). The white areas

represent a photon count of less than 1.0 and the grey colour is the same as in a),

the masked out pixels.

(24)

Chapter 4

Data Analysis

4.1 Auto-Correlation or Angular Correlation

4.1.1 Calculations of Average Angular Correlations

For consistency with the experiment performed in the autumn of 2018, the same package of Python scripts, called Loki

1

were used to calculate the XCCA. The

’shots’, the intensity diffraction patterns, are first loaded from the datasets stored in Condor’s CXI-file format (Coherent X-ray Imaging), which is based on the format

‘HDF5 ’, whereafter the same mask which was loaded into Condor is multiplied with each shot to yield what data would be collected in the physical experiment. After which both the shot with the mask and the mask itself is converted to polar coordi- nates, separately, with a function in Loki (called ’nearest’ in the InterpSimple-class) and multiplied with each other for each shot. These polar images will then have a three dimensional shape with ’Number of Shots’ × ’Number of qs’ × ’Number of Angles’, where q is the momentum transfer vector magnitudes in reciprocal space.

The subsequent angular correlation defined in eq. (2.6a), or auto-correlation as it is named in Loki, is calculated from these polar images. The function, called ’au- tocorr’ in the ’DiffCorr’-class, calculates the polar image’s Fourier transform along the angles in the polar images, which is the last dimension, or axis, of the three dimensional matrices. These Fourier transformed images are then multiplied with their respective conjugate before returning to the real space with the inverse Fourier transform along the same angular-axis. This yields the correlation of each q-ring, or q-shell, with itself. Where a q-ring is all the qs’ located at the same radial dis-

1

Library of Korrelated Intensity tools, by Derek Mendez (dermendarko@gmail.com) from the Doniach group Stanford Applied Physics. Available at github: https://github.com/dermen/

loki, (2019-04-02)

(25)

C. Dahlqvist CHAPTER 4. DATA ANALYSIS

tance from the center, forming a ring in the detector plane with distances in inverse Ångström (Å

−1

). The correlated images can be directly displayed with ’imshow’

where any radial or angular correlations can be visually observed.

In the physical experiment the difference between two sequential shots are often subtracted to remove correlated pixels in both images before the correlation calcula- tions. In the computer simulations both these ‘pair-wise’ diffraction were correlated in addition to the complete set of shots. The auto-correlation of the mask, in po- lar coordinates, was calculated with the same auto-correlation function as with the polar images of the shots.

4.1.2 Fourier Coefficients of the Angular Correlations

The Fourier coefficients were calculated from the Fourier transform over the angles of the arithmetic mean of the correlations, after normalisation with the correlated mask, with a Fast Fourier Transform (FFT) in Python 2.7 (example shown in List- ing 4.1). Except for normalising with only the correlated detector mask, the sums of the angular correlations were also normalised with the variance (the 0

th

column, representing when the ∆ = 0) and the arithmetic mean of the intensity per row, or radii, before calculating the Fourier coefficients. The 0

th

coefficient was plotted separately as its square root represents the azimuthal average, also referred to as the radial profile. That is, the average over the angles and the number of shots is equal to the 0

th

coefficient of the intensities, C

0

= h|hI

i

(q, ϕ)i

ϕ

|

2

i

i

for average over i shots. With the Fourier coefficients of the correlated data C

n

= h|I

in

(q)|

2

i

i

and for n = 0 the intensities angular average hI

i

(q, ϕ)i

ϕ,i

= hI

i0

(q)i

i

. Since the correlations were summed together from the different simulations of the same concentration, the square root was taken over the average instead of vice versa.

1

i m p o r t numpy a s np

2

from numpy . f f t i m p o r t f f t n , f f t s h i f t , f f t

3

4

## P o l a r Mask : ##

5

qmin_pix , qmax_pix , n p h i = 3 0 0 , 8 0 0 , 360 # t h e p i x e l r a n g e and a n g u l a r b i n s

6

c n t r =np . a s a r r a y ( [ ( mask . s h a p e [ 1 ] − 1 ) / 2 . 0 , ( mask . s h a p e [ 0 ] − 1 ) / 2 . 0 ] ) # (X, Y)

7

I n t e r p = I n t e r p S i m p l e ( c n t r [ 0 ] , c n t r [ 1 ] , qmax_pix , qmin_pix , nphi , mask . s h a p e )

8

mask_polar = I n t e r p . n e a r e s t ( mask , dtype=b o o l )

9

10

## Auto−C o r r e l a t e t h e Mask : ##

11

mask_DC = D i f f C o r r ( mask_polar . a s t y p e ( i n t ) , p r e _ d i f=True )

12

corr_mask = mask_DC . a u t o c o r r ( )

13

16

(26)

C. Dahlqvist CHAPTER 4. DATA ANALYSIS

14

## D i v i d e t h e Auto−C o r r e l a t e ( d a t a ) , ’ corrsum ’ , ##

15

## w i t h t h e Auto−c o r r e l a t e ( Mask ) , ’ corr_mask ’ ##

16

corrsum_m = np . d i v i d e ( corrsum , corr_mask , ou t=None , where=corr_mask ! = 0 )

17

18

## FFT o f Auto−c o r r e l a t i o n N o r m a l i s e d w i t h c o r r e l a t e d Mask and v a r i a n c e : ##

19

s i g = corrsum_m/corrsum_m [ : , 0 ] [ : , None ] / c o r r _ c o u n t

20

s i g _ A f t = f f t ( s i g , a x i s =1)

Listing 4.1: FFT example, where the auto-correlated data ’corrsum’ is the sum of all the aut-correlations from all the 91 simulations, one from each PDB-file.

4.2 Cross-Correlation or 3D Angular Correlation

4.2.1 Calculation of Cross-Correlations or 3D Angular Cor- relations

The Cross-Correlation can be described as an inter-shell correlation where each q- ring is correlated with every other q-ring, including itself. In analogy with the angular correlations, the same polar images described above is utilised in the cross- correlation function in Loki, called ’crosscorr’ in the ’DiffCorr’-class. The function calculates the cross-correlation for a selected index indicating a radial distance which is to be correlated to all the other radial distances by multiplication in the Fourier space of their transforms with one as its conjugate. The inverse Fourier transforma- tion of this multiplication is then the cross-correlation of that q, or radial distance.

This function can be repeatedly called for all the rows, that is q-values, in the polar images alternatively, for a few selected q-vaues.

4.2.2 Fourier Coefficients of the 3D Angular Correlations

Similarly to the 2D Angular Correlation, the Fourier coefficients (example shown in Listing 4.2) were calculated with the FFT over the angles for three different q -rings; 1.3 Å

−1

, 1.45 Å

−1

and 1.6 Å

−1

. The correlated data was normed with the cross-correlation of the detector mask by appending two identical masks together to generate a 3rd dimension for the correlation function. The coefficients were also normed with the variance as the 0

th

angular column before Fourier transformation.

1

i m p o r t numpy a s np

2

from numpy . f f t i m p o r t f f t n , f f t s h i f t , f f t

3

(27)

C. Dahlqvist CHAPTER 4. DATA ANALYSIS

4

p i x 2 i n v a n g = lambda q p i x : np . s i n ( np . a r c t a n ( q p i x ∗ ( ps ∗1E−6)/ d t c _ d i s t )

∗ 0 . 5 ) ∗4∗ np . p i /wl_A

5

6

## The Number o f Angular B i n s and q−r a n g e : ##

7

qmin_pix , qmax_pix , n p h i = 3 0 0 , 8 0 0 , 360 # t h e p i x e l r a n g e and a n g u l a r b i n s

8

9

## The q− v a l u e s [ qmin_pix t o qmin_pix ] : ##

10

qrange_pix = np . a r a n g e ( qmin_pix , qmax_pix )

11

12

## Q−Mapping w i t h 0 : i n d i c e s , 1 : q [ i n v Angstrom ] , 2 : r [ p i x e l s ] ##

13

q_map = np . a r r a y ( [ [ ind , p i x 2 i n v a n g ( q ) , q ] f o r ind , q i n enumerate ( qrange_pix ) ] )

14

15

## Load t h e Mask : ##

16

qmin_pix , qmax_pix = q_map [ 0 , 2 ] , q_map[ − 1 , 2 ]

17

c n t r =np . a s a r r a y ( [ ( mask . s h a p e [ 1 ] − 1 ) / 2 . 0 , ( mask . s h a p e [ 0 ] − 1 ) / 2 . 0 ] ) ## (X ,Y)

18

I n t e r p = I n t e r p S i m p l e ( c n t r [ 0 ] , c n t r [ 1 ] , qmax_pix , qmin_pix , nphi , mask . s h a p e )

19

mask_polar = I n t e r p . n e a r e s t ( mask , dtype=b o o l )

20

21

## C r o s s c o r r e l a t i o n o f e a c h P a i r : ##

22

m a s k _ c r o s s c o r = [ ]

23

mask_polar_w_eXdim = np . z e r o s ( [ 1 , mask_polar . s h a p e [ 0 ] , mask_polar . s h a p e [ 1 ] ] )

24

mask_polar_w_eXdim [ 0 ] =mask_polar

25

mask_DC_w_Xdim = D i f f C o r r ( mask_polar_w_eXdim . a s t y p e ( i n t ) , p r e _ d i f=True )

26

f o r q i n d e x i n r a n g e ( cross_corr_sum . s h a p e [ 1 ] ) : ## Nqx (Nq x Nphi )##

27

mask_crosscor_qindex = mask_DC_w_Xdim . c r o s s c o r r ( q i n d e x )

28

ccorr_sum = np . sum( mask_crosscor_qindex , 0 )

29

m a s k _ c r o s s c o r . append ( ccorr_sum )

30

d e l ccorr_sum

31

m a s k _ c r o s s c o r = np . a s a r r a y ( m a s k _ c r o s s c o r ) ## ( q i n d e x x Nq x Nphi ) ##

32

33

## D i v i d e t h e Cross−C o r r e l a t i o n ( d a t a ) a t Q=i d x w i t h t h e Cross−

C o r r e l a t i o n ( Mask ) : ##

34

cross_sum_m = np . d i v i d e ( c r o s s _ c o r r s u m , mask_crosscor , o u t=None , where=

m a s k _ c r o s s c o r ! = 0 )

35

36

## Average : ##

37

s i g _ c c = cross_sum_m/ c o r r _ c o u n t

38

## FFT o v e r t h e a n g l e s : ##

39

sig_cc_Aft = f f t ( s i g _ c c , a x i s =−1)

40

sig_cc_Aft = sig_cc_Aft . r e a l ## Only t h e Rea l Data , t h i s i s u s e d i n t h e p l o t s ##

Listing 4.2: FFT example, where the cross-correlated data ’cross_corrsum’ is the sum of all the cross-correlations from all the 91 simulations, one from each PDB-file.

18

(28)

C. Dahlqvist CHAPTER 4. DATA ANALYSIS

4.2.3 Fourier Quadrant Correlation

A method for estimating how similar two cross-correlation maps are (from the an- gular Fourier coefficients) was presented in [18] which formulates a function called the Fourier Quadrant Correlation (FQC):

FQC

n

(q) = |CC

1,2n

(q)|

q

CC

1,1n

(q) CC

2,2n

(q)

, (4.1a)

CC

v,wn

(q) = X

q1≤q

C

vn

(q

1

, q) · C

wn

(q

1

, q) + X

q2<q

C

vn

(q, q

2

) · C

wn

(q, q

2

) (4.1b)

where C

vn

(q

1

, q) is the Fourier coefficients of the cross-correlation for map number v = 1, 2 and C

wn

(q

1

, q) is its complex conjugate of the Fourier coefficients of the cross-correlation for map number w = 1, 2.

4.3 Implementation of Noise

4.3.1 Poisson Noise

Poisson noise in the detector was directly implemented in Condor [22] with the parameter ‘noise="Poisson"’.

4.3.2 Gaussian Noise

The Gaussian noise was added post-simulation in Python for each loaded diffraction

pattern. The individual Application Specific Integrated Circuits (ASICs) were iden-

tified with the aid of the ndimage class from the scipy package. The resulting diffrac-

tion patterns were correlated for noise with standard deviation σ as 10 % and 20 %

of the average intensity in the individual ASIC and also for the average of the max-

imum intensity of each shot in the left upper quadrant region x, y = 0 : 500, 0 : 500

(avoiding the edge scattering) with the same percentage. Example of Gaussian noise

added per Application Specific Integrated Circuit over only the binary detector mask

is shown in fig. 4.1.

(29)

C. Dahlqvist CHAPTER 4. DATA ANALYSIS

2019-06-12, 15*01 Add_Gaussian_Noise_per_Tile-ASIC

Page 6 of 6 http://localhost:8888/nbconvert/html/Add_Gaussian_Noise_per_Tile-ASIC.ipynb?download=false

In [ ]:

<type 'numpy.int64'>

Figure 4.1: Example of Gaussian noise added per Application Specific Integrated Circuit to the right, where the standard deviation σ is set to 10 % of the average over the whole mask. On the left is shown the identification of the ASICs with the ndimage class from the scipy package.

20

(30)

Chapter 5 Results

5.1 Diffraction Patterns

The 91 PDB-files, each containing a time instance (snap-shot) of the simulated box of CsCl in pure water (described in chapter 3), were imported into Condor as the sample and simulated with 100 sequential hits from a FEL-beam. Some of the individual amplitude patterns can be seen in fig. 5.1 for three different PDB- files of the same concentration of CsCl run with random arrival statistics (the same pattern for synchronised arrival statistics can be seen in fig. C.1 with more consistent intensity in the colour bar). Several of the diffraction patterns have some edge- scattering from the simulation box (viewed in fig. 3.1) seen as short dashes lined up on both sides of the central hole. The intensity is often higher around the central hole either because of the edge-scattering from the box or from the proximity of the FEL-beam passing through the hole. In these simulations there were no saturation limit set for the detector, however, in an experiment these pixels would be saturated from the direct beam.

The smallest structure in the diffraction pattern, called speckle, is the largest spatial coherent structure in the sample [25]. The size of the coherent speckles can be estimated [26] for the wavelength λ, detector distance d and beam focus s:

w = λ · d

s = 1.3 · 10

−10

· 0.15

1 · 10

−9

≈ 0.0195 m ≈ 178 pixels (5.1)

With the smallest detector unit consisting of 185×194 pixels and a visual estimation

of the amplitude patterns, suggests that the larger speckles have a width of half such

a unit, around 93 to 97 pixels in the patterns with low or no edge-scattering from

the simulation box. The speckle size in eq. (5.1) is defined as the average distance

between two adjacent maxima, therefore the visual observation of intensity maxima

is half this distance, 89 pixels.

(31)

C. Dahlqvist CHAPTER 5. RESULTS

The simulations were run for three different concentrations of CsCl in pure water;

2 M, 4 M and 6 M with the average intensity patterns of all three shown in fig. 5.2 where the intensity is in the number of photons per pixel. The white circles indicate the ranges for the correlation calculations; the inner representing the smallest radial distance from the centre and the outer the largest radial distance. The lower end of the range at 300 pixels (or 1.041 Å

−1

) was selected to avoid any edge-scattering from the simulation box. The upper end of the range was selected to include most of the detector, at 800 pixels (or 2.524 Å

−1

). Here, the so called ‘water-ring’ can clearly be seen, originating from the pure water in the solution. When calculating the radial profile (azimuthal average) of the intensity patterns, after conversion to polar coordinates, it is even more apparent as seen in fig. 5.3 with a broad peak around 650 pixels (2.123 Å

−1

). What is not discernible in the intensity patterns in fig. 5.2 is the smaller peak or ‘hump’ at lower values, 300-425 pixels (1.041-1.449 Å

−1

) which increase with the concentration.

22

(32)

C. Dahlqvist CHAPTER 5. RESULTS

Figure 5.1: Some examples of shots recorded with the simulation package Condor.

All images displays the modulus of the amplitude patterns |Ψ| at different random

orientations of the sample (simulated box of CsCl in water). The mask from the

experiment has been applied and is seen in grey. On the left is shots from PDB-file

number 86, in the center number 69 and on the right number 77 of 6 Molar of

CsCl in solution. A 100 shots were simulated for each PDB-file with random sample

orientation. The top row shows the 1

st

pattern generated in each file, middle the

50

th

and bottom the 100

th

pattern.

(33)

C. Dahlqvist CHAPTER 5. RESULTS

a)

0 250 500 750 1000 1250 1500 x Pixels 0

200 400 600 800 1000 1200 1400 1600

Pixels

Mean Intensit of 9100 Patterns (Log10):

10−1 100 101 102 103

Photons (mean)

b)

0 250 500 750 1000 1250 1500 x Pixels 0

200 400 600 800 1000 1200 1400 1600

Pixels

Mean Intensit of 9100 Patterns (Log10):

10−1 100 101 102 103

Photons (mean)

c)

0 250 500 750 1000 1250 1500 x Pixels 0

200 400 600 800 1000 1200 1400 1600

Pixels

Mean Intensit of 9100 Patterns (Log10):

10−1 100 101 102 103

Photons (mean)

Figure 5.2: The average intensity patterns from 9 100 shots for a) 2 Molar, b) 4 Molar and c) 6 Molar concentration of CsCl in pure water. The white circles indicate start and end radial distance for the correlation calculations from 300 radial pixels (1.041 Å

−1

) to 800 radial pixels (2.524 Å

−1

). The images are in log scale where the photon count is given as the exponent of base 10.

2 M 4 M

N O I S E F R E E

1 N M F O C U S 2 M | 4 M | 6 M

q

1

= q

2

6 M

R A D I A L P R O F I L E

!X

Figure 5.3: Radial profiles or azimuthal averages, for 2, 4 and 6 Molar concentra- tions of CsCl solution in pure water. Average from 9 100 shots.

24

(34)

C. Dahlqvist CHAPTER 5. RESULTS

5.2 Auto-Correlation

The calculated auto-correlations described in section 4.1 can be viewed directly as in fig. 5.4a and is then completely dominated by the mask, for which the auto- correlation can be seen in fig. 5.4b (both and subsequent images of correlations are limited to view µ ± 2σ, where µ is the arithmetic mean and σ the standard devi- ation). To remove this influence, the correlations are normed with the correlation of the detector mask. The resulting normed average angular-correlations (auto- correlations) can be seen in fig. 5.5 for the three different concentrations 2, 4 and 6 Molar of CsCl. The correlations are also normed with the total variance, which is the momentum transfer values at ∆ = 0, at that certain radial distance. Where the total invariance includes un-correlated molecules and noise. As mentioned above, the correlation calculations were limited in a radial range, indicated in fig. 5.2, to 300-800 pixels or 1.041-2.524 Å

−1

. For all concentrations there are some correla- tions seen as horizontal bright lines for ∆ > 0 which could relate to information about local structures. High self-correlations can be seen at the edges (0 and 2π) for all concentrations and has an apparent wedge-shape, becoming narrower at higher radial distances, caused by the FEL-beam’s Gaussian shape. This wedge-shape is approximately 4 % of the entire width in the angular direction for the upper limit at 800 pixels 2.524 Å

−1

and 6 % at 300 pixels or 1.041 Å

−1

. This can be compared to the speckle width in eq. (5.1) of 178 pixels, which compared to the circumference, in number of pixels, of the white rings in fig. 5.2 (at 300 and 800 radial pixels) is 9.4 % and 3.5 %. This indicates that, especially at the outer ring at 800 pixels, the strong correlation around ∆ ≈ 0 is related to the speckle width.

a)

π/2 π 3π/2

Δ 1.041

1.369 1.683 1.981 2.262 2.524 q1]

AverageΔ fΔ91Δc rrsΔ[w_Mask_p lar-all] with limits μ±2σ

0.0036 0.0040 0.0044 0.0048

Cross-correlation of Intensity Difference [a.u.]

b)

π/2 π 3π/2

Δ 1.041

1.369 1.683 1.981 2.262 2.524

q[Å−1]

ACΔofΔMaskΔwithΔlimitsΔμ±2σ

0.64 0.72 0.80 0.88

C oss-correlation of Intensity Difference [a.u.]

Figure 5.4: The auto-correlation of the intensity patterns from a) 6 Molar of CsCl

solution without normalising with the auto-correlation of the mask seen in b). The

correlation of the mask is clearly dominating in the correlations. The figures are limited

to view µ ± 2σ.

(35)

C. Dahlqvist CHAPTER 5. RESULTS

a)

π/2 π 3π/2

Δ 1.041

1.369 1.683 1.981 2.262 2.524 q11]

Average of 91 corrs [w_Mask_polar

-all] (Normalized with Mask) with limits

μ

±2

σ

0.005450 0.005475 0.005500 0.005525 0.005550 Cross-correlation of Intensity Difference [a.u.]

b)

π/2 π 3π/2

Δ 1.041

1.369 1.683 1.981 2.262 2.524 q01]

AverageΔofΔ91ΔcorrsΔ[w_Mas _polar

-all] (Normalized with Mask) with limits

μ

±2

σ

0.00546 0.00548 0.00550 0.00552

Cross-correlation of Intensity Difference [a.u.]

c)

π/2 π 3π/2

Δ 1.041

1.369 1.683 1.981 2.262 2.524 q11]

Average of 91 corrs [w_Mask_polar

-all] (Normalized with Mask) with limits

μ

±2

σ

0.005475 0.005500 0.005525 0.005550

Cross-correlation of Intensity Difference [a.u.]

Figure 5.5: The average auto-correlation of the intensity patterns for 9 100 diffrac- tion patterns from a) 2, b) 4 and c) 6 Molar of CsCl solution after normalising with the auto-correlation of the detector mask and the variance. These simulations were run with random arrival statistics in Condor [22]. The figures are limited to view

µ ± 2σ . 26

References

Related documents

Stöden omfattar statliga lån och kreditgarantier; anstånd med skatter och avgifter; tillfälligt sänkta arbetsgivaravgifter under pandemins första fas; ökat statligt ansvar

Generally, a transition from primary raw materials to recycled materials, along with a change to renewable energy, are the most important actions to reduce greenhouse gas emissions

För att uppskatta den totala effekten av reformerna måste dock hänsyn tas till såväl samt- liga priseffekter som sammansättningseffekter, till följd av ökad försäljningsandel

Regioner med en omfattande varuproduktion hade också en tydlig tendens att ha den starkaste nedgången i bruttoregionproduktionen (BRP) under krisåret 2009. De

Generella styrmedel kan ha varit mindre verksamma än man har trott De generella styrmedlen, till skillnad från de specifika styrmedlen, har kommit att användas i större

Närmare 90 procent av de statliga medlen (intäkter och utgifter) för näringslivets klimatomställning går till generella styrmedel, det vill säga styrmedel som påverkar

Den förbättrade tillgängligheten berör framför allt boende i områden med en mycket hög eller hög tillgänglighet till tätorter, men även antalet personer med längre än

På många små orter i gles- och landsbygder, där varken några nya apotek eller försälj- ningsställen för receptfria läkemedel har tillkommit, är nätet av