## 2 Materials and Methods
### Computer-Based Model  
For mathematical analysis and visualization of the processes that occur in the surface layer of the membrane, a computer model was developed. The model consists of N (value declared as a simulation parameter) electric dipoles that can move on the surface of the membrane and rotate around its own axis perpendicular to the surface of the membrane. The mobility of the dipoles is declared as a simulation parameter. The energy of the surface layer of the membrane is described by the Hamiltonian:  
\[H=\sum_{(i)}\frac{p_{i}^{2}}{2m}+\sum_{(i)}\frac{L_{i}^{2}}{2I}+\sum_{(i<j)}U_{ ij} \tag{1}\]  
where \(m\)--dipole mass, \(I\)--moment of inertia, \(p_{i}\)--dipole momentum, and \(L_{i}\)--dipole angular momentum. The first two terms of the equation refer to the kinetic energy of the dipoles associated with translational and rotational motion. The third term of the equation represents the Coulomb and Lennard-Jones interactions between all dipoles:  
\[ \begin{split} U_{ij}=\frac{e^{2}}{4\pi e_{0}e_{r}}\left(\frac{1}{ \left|\overrightarrow{a_{ij}+\overrightarrow{a_{j}}-\overrightarrow{a_{i}}} \right|}-\frac{1}{\left|\overrightarrow{a_{ij}-\overrightarrow{a_{j}}- \overrightarrow{a_{i}}}\right|}+\frac{1}{\left|\overrightarrow{a_{ij}- \overrightarrow{a_{j}}+\overrightarrow{a_{i}}}\right|}-\frac{1}{\left| \overrightarrow{a_{ij}+\overrightarrow{a_{j}}+\overrightarrow{a_{i}}} \right|}\right)+\\ 4e\left[\left(\left(\frac{\sigma}{\left|\overrightarrow{a_{ij}} \right|}\right)^{12}-\left(\frac{\sigma}{\left|\overrightarrow{a_{ij}} \right|}\right)^{6}\right]\right]\end{split}  \tag{2}\]  
The meanings of vectors \(a\) and \(d\) are described in Figure 6.  
Figure 5: The location of probes in the lipid bilayer of liposome. The model represents a system of dipoles arranged on a round cork floating in a sea of lipids. The system defined in this way has three degrees of freedom. Two of them relate to the translational motion of the dipole, and one corresponds to its rotation. In real lipid membranes, the polar head group (dipoles) forming the surface layer is anchored on hydrocarbon chains that limit their mobility. The presence of these chains also prevents the heads (dipoles) from getting closer to one another. In the mathematical model, this property is represented by the Lennard-Jones potential. The degree of this limitation is set by the depth of the potential described by the \(\varepsilon\) parameter. Increasing the value of \(\varepsilon\) makes the simulated membrane stiffer. The \(\sigma\) parameter determines the average distance between the dipoles. It is determined on the basis of literature data. In the case of EYL and DPPC lecithin, it is about 1 nm. The dynamics of the chains connected to the heads indirectly affects the dynamics of the heads. However, this is not a strict correlation because the mobility of the polar head group is significantly lower than the mobility of the hydrocarbon chains. The rotation time of the polar heads is around \(10^{-9}\) s, while the oscillation times of the chains are estimated at \(10^{-14}\) s. The model assumes that this effect is purely stochastic and uncorrelated, which is a simplification compared to the real membrane. The simulation algorithm is based on the Monte Carlo Metropolis algorithm in the statistical canonical ensemble. In this algorithm, the part coming from the kinetic energy is calculated analytically, while the part coming from the potential energy is the basis for the simulation and determines the probability (\(w\)) of accepting a randomly selected new state. \[w=\exp\left(-\frac{\Delta E_{p}}{k_{B}T}\right) \tag{3}\]  
where k\({}_{B}\) is the Boltzmann constant, T is the temperature, and \(\Delta\)Ep is the change in the potential energy of the system between the previous state and the new state. If the new state leads to a lower energy of the system (\(-\Delta\)Ep), the \(w\) parameter is greater than 1. This means that the state is always accepted. It represents the current state of the system.