Using Experimentally Calibrated Regularized Stokeslets to Assess Bacterial Flagellar Motility Near a Surface

The presence of a nearby boundary is likely to be important in the life cycle and evolution of motile flagellate bacteria. This has led many authors to employ numerical simulations to model near-surface bacterial motion and compute hydrodynamic boundary effects. A common choice has been the method of images for regularized Stokeslets (MIRS); however, the method requires discretization sizes and regularization parameters that are not specified by any theory. To determine appropriate regularization parameters for given discretization choices in MIRS, we conducted dynamically similar macroscopic experiments and fit the simulations to the data. In the experiments, we measured the torque on cylinders and helices of different wavelengths as they rotated in a viscous fluid at various distances to a boundary. We found that differences between experiments and optimized simulations were less than 5\% when using surface discretizations for cylinders and centerline discretizations for helices. Having determined optimal regularization parameters, we used MIRS to simulate an idealized free-swimming bacterium constructed of a cylindrical cell body and a helical flagellum moving near a boundary. We assessed the swimming performance of many bacterial morphologies by computing swimming speed, motor rotation rate, Purcell's propulsive efficiency, energy cost per distance, and a new metabolic energy cost defined to be the energy cost per body mass per distance. All five measures predicted the same optimal flagellar wavelength independently of body size and surface proximity. Although the measures disagreed on the optimal body size, they all predicted that body size is an important factor in the energy cost of bacterial motility near and far from a surface.


I. INTRODUCTION
Living organisms emerge, evolve, and reside within habitats, and the physical interactions among organisms and their environments impose selective forces on their evolution. In their low Reynolds number surroundings, bacteria such as Escherichia coli and Pseudomonas aeruginosa have evolved a mechanical motility system to propel themselves through fluids.
This system consists of one or more helical flagella, and these flagellar organelles are attached to the cell body by rotary nanomotors. Flagellar motor rotation is driven by an ion flow through the motor, causing the flagellum and the bacterial cell body to rotate in opposite directions [1]. A bacterium swimming through a fluid can be described as a non-inertial system in which the mechanical power output by the motor is instantaneously dissipated by fluid drag on the body and flagellar filaments. The interaction between the bacterium and the fluid generates a flow that results in the net motion of the bacterium. Different flows can be more or less favorable to the survival of an organism [2]; and the presence of a surface introduces boundary effects that modify how a swimming cell interacts with the fluid. We consider here the example of a unicellular motile flagellate bacterium swimming through a fluid near to a surface and how the conformation of the bacterial cell body and the flagellar organelle may be optimized for such an environment.
The efficiency of the bacterial motility system has been the focus of numerous theoretical [3][4][5], computational [6][7][8][9][10][11], and experimental works [12][13][14]. In an early paper on swimming efficiency, E. Purcell discussed two measures: the propulsive efficiency (Purcell efficiency) and the energy consumed during bacterial motion per body mass [3]. The Purcell efficiency-a specialized form of the Lighthill efficiency [15] for rotary motor-driven bacterial propulsionis defined as the ratio of the least power needed to translate a bacterial body against fluid drag to the total power output by the motor during motion of the bacterium. Most work has focused on the Purcell efficiency because it is a scale-independent function of the geometries of the cell body and flagellum. One shortcoming of this measure, however, is that it is independent of the motor's response to an external load imposed by the environment and therefore cannot assess the biological fitness of the bacterial motor. Another measure of bacterial performance used by a few authors is the distance traveled by a bacterium per energy input by the motor [13,16], which provides a different means of evaluating fitness, as explained below.
In this work, we investigate and compare predictions of the optimal bacterial motility system made by five measures. The first two measures are related directly to the motion of a bacterium: the swimming speed and the motor rotation frequency. Bacteria live in an environment where nutrients diffuse on time and length scales comparable to bacterial motion. To effectively achieve chemotaxis, bacteria must move quickly enough to sample their chemical environment before it is randomized by diffusion [3,11]. The bacterial motor has a characteristic frequency response that depends on the external torque load [17][18][19][20].
At low frequencies, small changes in applied load correspond to large changes in operating frequency, whereas at high frequencies, small changes in load correspond smaller changes in frequency. In the low speed regime, the motion may be unreliable because small changes in applied load that occur, for example, by approaching a boundary could lead to the motor stalling. However, the low speed regime is more thermodynamically efficient than the high speed regime. These two competing effects must be balanced to achieve a strong swimming performance.
The other three performance measures we studied are based on the mechanical energy cost to achieve motility: the Purcell inefficiency (or the inverse of the Purcell efficiency), the inverse of distance traveled per energy input, and the metabolic energy cost, which we define to be the energy output by the motor per body mass per distance traveled.
Each of these measures compares the ratio of the power output of the bacterial motor to the performance of a particular task. The rationale for introducing the metabolic cost function is that it measures the actual energetic cost to the organism to perform a specific biologically relevant task, i.e., translation through the fluid. Moreover, the metabolic energy cost depends upon the rotation speed of the motor and, because the bacterial motor has a different responses to different external conditions, predicts different optimal morphologies based on the environment than the other measures.
To determine the values of performance measures attained by different bacterial geometries, we employed the method of regularized Stokeslets [21] and the method of images for regularized Stokeslets (MIRS) [22], which includes the effect of a solid boundary. Employing MRS and MIRS requires determining values for two kinds of free parameters: those associated with computation and those associated with the biological system. As with any computational method, the bacterial structure in the simulation is represented as a set of discrete points. The body forces acting at those points are expressed as a vector force multi-plied by a regularized distribution function, whose width is specified by a regularization, or "blob" parameter. Though other simulations have produced numerical values for dynamical quantities like torque [23] that are within a reasonable range for bacteria, precise numbers are not possible without an accurately calibrated method.
There is no known theory that predicts the relationship between the discretization and regularization parameters, though one benchmarking study showed that MRS simulations could be made to match the results of other numerical methods [24]. To determine the optimal regularization parameter for chosen discretization sizes, we performed dynamically similar macroscopic experiments using the two objects from our model bacterium: a cylinder and a helix, see Fig. 1. Such an approach was previously used to evaluate the accuracy of various computational and theoretical methods for a helix [25]. By measuring values of the fluid torque acting on rotating cylinders near a boundary, we verified the theory of Jeffery and Onishi [26], which in turn we used to calibrate the ratio of discretization to regularization size in MRS and MIRS simulations of rotating cylindrical cell bodies. For helices there are no exact analytical results. To determine regularization parameters for helices we descretized them along their centerlines and fit simulation results directly to experimental measurements. Calibrating our simulations of rotating cylinders and helices with the experiments allowed us to build a bacterial model with a cylindrical cell body and a helical flagellum whose discretization and regularization parameter are optimized for each part.
To impose motion on the bacterial model, we needed only to specify the motor rotation -a consequence of there being no body forces acting on the bacterium [23]. The motor rotation rate, however, depends upon the external load [13,[17][18][19]. In our simulations, we ensured the motor rotation rate and the total torque acting on the motor match a point on the experimentally determined torque-speed response curve reported in the literature [17,20]. The dynamical quantities output from the simulations were then used to compute performance measures for different bacterial geometries at various distances from the boundary.
Our paper is organized as follows: Sec. II discusses our implementation of the MRS and the MIRS, our use of dynamically similar experiments to calibrate the simulations, and our determination of the torque-speed response curve for the motor; Sec. III compares our five fitness measures: free swimming speed, motor frequency, inverse Purcell efficiency, energy per distance and metabolic cost per distance; and Sec. IV discusses the predictions made by each fitness measure and comments on future directions of our work.

A. Numerical Methods
Bacterial motility using a helical flagellum often involves multiple flagella, and bodies may be spherical, cylindrical, or helical [27]. We reduced the complexity by considering a simpler biomechanical system of a regular cylindrical body to which a single, uniform flagellum is attached, as shown in Fig. 1. This simple system, however, contains the same essential geometric factors as some real bacteria such as E. coli, which have a long rod-shaped body and helical flagella that bundle together, forming a single helix. Our goal was to assess how the performance of our model organism changes when its geometrical parameters and distance to an infinite plane wall are varied in numerical simulations. We quantified the performance of different models by computing speed, motor rotation rate, and the three energy cost measures. We composed our model of a bacterium with a cylindrical cell body and a tapered lefthanded helical flagellum as shown in Fig. 1 and Fig. 2. The flagellar centerline is described by where 0 ≤ s ≤ L and L is the axial length in the z-direction. k is the wavenumber 2π/λ where λ is the wavelength. θ is the phase angle of the helical flagellum at 16 evenly spaced phases.
The parameter values used for the bacterium models shown in Fig. 2 are given in Table   I. and filament radius a. The body of the bacterium was modeled as a cylinder with radius r and length . Each flagellum was modeled as a regular helix that tapers to zero radius at the point it attaches to the body. Our simulations used a surface discretization of regularized Stokeslets to represent the cylinder and a string of regularized Stokeslets along the centerline of the flagellum.
The inset represents a radially symmetric blob function described in Sec. II A 1 that is used to spread the force at a given point on the flagellar centerline. For the purpose of illustration, we show the blob function of two variables whose width is controlled by the regularization parameter f .

Method of regularized Stokeslets
The microscopic length and velocity scales of bacteria ensure that fluid motion at that scale can be described using the incompressible Stokes equations. We used the MRS in three dimensions [21] to compute the fluid-bacterium interactions due to the rotating flagellum in free space at steady state: u is the fluid velocity, p is the fluid pressure, and µ is the dynamic viscosity. F is the body force represented as f k φ (x − x k ) where f k is a point force at a discretized point x k of the bacterium model. In our simulations, we used the blob function φ (x − x k ) = Our model bacterium had a cylindrical cell body and a helical flagellum, and 25 different cell body sizes and eighteen different flagellar wavelengths were used, as described in Table I parameter which controls the spread of the point force f k . Given N such forces, the resulting velocity at any point x in the fluid can be computed as Evaluating Eq. 3 N times, once for each x k , yields a 3N × 3N linear system of equations for the velocities of the model points. In the limit as approaches 0, the resulting velocity u approaches the classical singular Stokeslet solution. In practice, the specific choice of may depend on the discretization or the physical thickness of the structure.
In our bacterium model, we discretized the cell body as N c points on the surface of a cylinder, and we modeled the flagellum as N f points distributed uniformly along the arclength of the centerline. In Sec. III, we present the optimal regularization parameter

Method of images for regularized Stokeslets
We used the method of images for regularized Stokeslets (MIRS) [22] to solve the incompressible Stokes equations (Eq. 2) and simulate bacterial motility near a surface. In the method, the no-slip boundary condition on an infinite plane wall is satisfied by imposing a combination of a Stokeslet, a Stokeslet doublet, a potential dipole, and rotlets at the image point x * k of each discretized point x k . The image point x * k is the point obtained by reflecting x k across the planar surface. The resulting velocity at any point x in the fluid bounded by a plane can be found in Ref. [22] and written in the compact form similar to Eq. 3: 3. Force-free and torque-free models On a free-swimming bacterium, the only external forces acting are due to the fluidstructure interaction. A bacterium is a non-inertial system so the net external force and net external torque acting on it must vanish. This means that F c + F f = 0 and τ c + τ f = 0, where F c / τ c and F f / τ f represent, respectively, the net fluid forces and torques acting on the cell body and flagellum. These force-free and torque-free constraints require the cell body and flagellum to counterrotate relative to each other. In our simulations, the point connecting the cell body and the flagellum x r represented the motor location, and was used as the reference point for computing torque and angular velocity.
Given an angular velocity Ω m of the motor, the relationship between the lab frame angular velocities of the flagellum and the cell body is Ω f = Ω c + Ω m [23]. Since Ω m is the relative rotational velocity of the flagellum with respect to the cell body, the resulting velocityũ(x k ) at a discretized point x k on the flagellum (k = 1, ..., N f ) can be computed as Ω m × x k (this velocity is set to zero at a discretized point on the cell body). Using the MRS (or MIRS) and the six added constraints from the force-free and torque-free conditions, we formed a (3N + 6) × (3N + 6) linear system of equations to solve for the translational velocity U and angular velocity Ω c of the cell body and the internal force f k acting at the discretized point x k of the model: where G is S from Eq. 3 for swimming in a free space or S * from Eq. 4 for swimming near a plane wall. Each f k represents a point force acting at point x k , which is in principle an internal contact force due to interactions with the points on the bacterium that neighbor x k . Each f k is balanced by the hydrodynamic drag that arises from a combination of viscous forces and pressure forces exerted on the point x k by the fluid (Eq. 2).
By computing each f k , we were able to deduce the fluid interaction with each point of the bacterial model. Eq. 5 shows that the calculated quantities U, Ω c , F c , and τ c depend linearly on the angular velocity Ω m sinceũ(x j ) = Ω m × x j .

B. Torque-speed motor response curve
The singly-flagellated bacteria we simulated move through their environment by rotating their motor, which causes their body and flagellum to counter-rotate accordingly. Drag force from the fluid exerts equal magnitude torques on the body and the flagellum, and the value of the torque equals the torque load applied to the motor. The relationship between the motor rotation rate and the torque load is characterized by a torque-speed curve, which has been measured experimentally in several organisms [13,[17][18][19][20]. In the context of motor response characteristics, speed refers to frequency of rotation. We estimated the torquespeed curve for E. coli with typical values taken from the literature [17,20] to match the body and flagellum parameters also taken from measurements on E. coli [20].  The torque-speed curve of the E. coli motor has been determined experimentally by measuring the rotation rate of a bead attached to a flagellar stub and then computing the torque on the bead due to fluid drag. By performing the measurement in fluids of different viscosities, many points on the torque-speed curve were assembled. It was found that the torque-speed curve of the E. coli bacterial motor decreases monotonically from a maximum stall torque (i.e. the zero-speed torque) of about 1300 pN·nm to zero torque, which occurs at a maximum speed of 350 Hz [17,19,20]. There are two linear operating regimes, a low speed regime from 0-175 Hz and a high speed regime 175-350 Hz. In the low speed regime below 175 Hz, the torque is a relatively flat function of the motor rotation rate, falling to 0.92 of the stall torque at 175 Hz. In the high speed regime above 175 Hz, the torque falls steeply to zero at 350 Hz. The torque-speed curve is thus expressed as a piecewise linear function of the motor rotation rate, Ω m : ≤ 300 Hz very slowly over a two-year period, so we determined the modified viscosity by measuring the torque on rotating cylinders at the center of the tank and recorded data within two months of that measurement.
The theoretical value for torque per unit length on an infinite rotating cylinder in Stokes flow is σ = 4πµΩr 2 , where µ is the dynamic viscosity of the fluid, Ω is the angular rotation rate, and r is the cylindrical radius. We measured the torque τ on a rotating cylinder with radius r = 6.35 ± 0.2 mm and length = 149 ± 1 mm and, by assuming τ = σ, used the data to solve for the viscosity of the fluid. We also assumed that the finite size of the tank did not affect the torque value in the middle, which was more than 20r from the nearest boundary. Before each data collection run, we measured the temperature of the oil with a NIST-traceable calibrated thermistor (Cole-Parmer Digi-Sense-AO-37804-04 Calibrated Digital Thermometer) and adjusted the previously determined viscosity using the manufacturer's temperature coefficient of viscosity 1.00 × 10 −6 kg/(m·s)/ • C. See Sec.
II C 2 for a detailed description of the torque measurements.

Fabricating helices
We fabricated helices of varying wavelengths (2.26 < λ/R < 11.88) by wrapping straight stainless steel welding wire around cylindrical aluminum mandrels with different helical Vgrooves precisely machined using a CNC lathe. The V-grooves transition to a flat face with a straight groove, to which the remaining straight section can be clamped; see Fig. 4.  Table II.
Mandrels were held on a lathe, and the wire was hand-spun into the V-groove. The straight sections were secured to the flat faces, which left straight stems aligned with the axes of the helices to be attached to the motor via a rigid shaft adapter. Residual tension in the wires caused the wavelengths and radii to vary after they were removed from the mandrels.
The helices were forced onto a precision stainless steel rod with radius R = 6.350±0.013 mm for annealing. The helices on the rod were then placed into a tube furnace (MTI GSL-1500X) and annealed at 900 degrees Celsius for two hours, which removed most of the variation in the radii of the helices and fixed the helical wavelength.
The helix parameters used in the experiments are listed Table II: The helical wavelength λ and axial length L are expressed in terms of the helical radius R; R = 6.35 ± 0.10 mm in all cases. The filament radius was a/R = 0.111 for all helices.

Axial torque measurements
To measure the dependence of torque on boundary distance, we secured the tank onto a horizontal stage that allowed for motion in the x-direction, as shown in Fig. 5. The motion of the stage was controlled by a linear guide with a worm gear screw that advanced the stage 0.3 mm per revolution. The screw was turned using a computer-controlled NEMA 23 stepper motor with a resolution of 400 steps/rev. This gave better than 100 µm precision in controlling the boundary distance, which was necessary: the step size near the boundary was as small as 0.5 mm.
Torque measurements were made for both cylinders and helices using similar methods.
The objects were held in a rigid shaft adapter and then lowered until centered in the tank using a vertical translation stage built from 80-20 ® extruded aluminum.
At the beginning of each data set, we first adjusted the vertical tilt of the object until it was parallel to the boundary. Next, we manually adjusted the horizontal stage so that the cylinder or helix touched the front vertical boundary of the tank. We used total internal reflection to form an image of the object that could be used as a reference to find where the edge of the object just made contact with the boundary, which occurs when the image appears to touch the object.
The torque was measured using a FUTEK TFF400, 10 in-oz, Reaction Torque Sensor.
The cylinder and helices were driven by a variable speed DC motor with a magnetic encoder (Pololu 298:1 Micro Metal Gear Motor with Magnetic Encoder) and housed inside of a 3Dprinted enclosure that included sleeve bearings to minimize frictional torque. The power and signal wires were fed through a 6.32 mm opening at the center of the torque sensor.
The wires were then fixed to the outside structure so that they did not create a torque when measurements were taken. The encoder output was read by the counter input on a National Instruments USB6211 M series multifunction DAQ. The torque signal was amplified using an amplifier/driver (Omega DP25B-E-A 1/8 DIN Process Meter and Controller) and its output fed into the same National Instruments data acquisition board's analog to digital input with a resolution of 250 thousand samples per second, which is much faster than any time scales in the experiment.
Data were taken with the DC motor rotating at varying speeds and with the objects located at a distance from the boundary set by the horizontal stage. The torque and motor frequency were simultaneously recorded using MATLAB to acquire and plot them. We used MATLAB and a motor controller (ARDUINO MEGA 2560 with an ADAFRUIT Motor Shield v.2) to control the motor. However, the motor rotation varied depending on the axial load, so we divided the signal from the torque sensor by the frequency data from the counter input to get the torque per unit frequency at each boundary distance, see Fig. 6.
A MATLAB data acquisition GUI included the temperature and distance values, ensuring that the acquisition parameters were stored with the raw data.
Data were taken for approximately 60 rotation periods for both CW and CCW rotation at each boundary location. The frequency signal occasionally showed large spikes that affected the average torque-per-frequency value because the torque signal did not show a corresponding jump. We considered this to be the result of the encoder miscounting the rotation rate or the counter input in the DAQ misreading the signal from the encoder. We used MATLAB's outliers function to remove such frequency spikes that were more than nine median absolute deviations from the median calculated in a moving window ten data points wide, and replaced them with the average of the adjoining data points. The number of outliers was less than 1% of the data points, so this frequency smoothing should not have biased the averaging significantly.
The difference between mean CW and CCW rotation values, which should have been the same, was used to establish the uncertainty in the experimental measurements. An analysis script read the geometric parameters and data files for a given set of measurements (cylinder or helix) and plotted the data versus boundary distance. We scaled the torque using a unit of [µΩr 2 ] (cylinder) or [µΩR 2 L] (helix), where µ is the fluid viscosity, Ω is the angular speed, r is cylindrical radius, is the cylindrical length, R is the helical radius, and L is the helical axial length. Plots of the dimensionless torque for cylinders and helices are shown in Fig. 7 and Fig. 9. Using these units for the torque allowed for easy comparison between experiments, numerical simulations, and theory.

D. Summary of algorithms and data analysis
Two separate sets of simulations are presented in this paper. For those with a helix model or a bacterium model, the results were averaged over 16 evenly spaced phases as described in Eq. 1 of the flagellar centerline.
(i) The goal of the first set of simulations was to calibrate the MRS and MIRS methods by finding the optimal factors (γ c for a cylindrical cell body and γ f for a helical flagellum) and the optimal regularization parameters ( c and f ), as reported in Table I. Eq. 3 was used to solve for the force f k at each discretized point x k in a free space, whereas Eq. 4 was used for simulations near a plane wall. The resulting net torque of each rotating structure was then compared with the results from theory for a cylinder or from experiments for a helix, as described in Sec. III A.
(ii) The goal of the second set of simulations was to assess the motility performance of the force-free and torque-free bacterium models with boundary effects incorporated.
Step 1 : Eq. 5 was used with S (for simulations in a free space) or with S * (for simulations with a plane wall). Different combinations of the cell body size, flagellar wavelength, and distance to the wall were simulated. We used five values for the length and five values for the radius r shown in Table I. These values are within the range of normal E. coli [20]. We Step 2 : The torque value τ was output from each simulation in Step 1 with the motor frequency set to 154 Hz. That torque-frequency pair was then used to determine the load line and its intersection with the torque-speed, as discussed in Sec. II B and shown in Fig.   3. Each motor frequency Ω m /2π on the torque-speed curve was given as some multiple q of 154 Hz. The simulation outputs were scaled by q, since they were all linear with motor frequency; i.e., (U, F, τ ) → q (U, F, τ ). These scaled quantities were then used calculate the performance measures. Results are presented in Sec. III B and Sec. III C.

III. RESULTS
A. Verifying the numerical model and determining the optimal regularization parameters When using MRS or MIRS, the choice of the regularization parameter for a given discretization (cylinder) or filament radius (helix) of the immersed structure has generally been made without precise connection to real-world experiments, because there are large uncertainties in biological and other small-scale measurements. We therefore used theory, as described below, and dynamically similar experiments, as described in Sec. II C, to determine the optimal regularization parameters for the two geometries used in our bacterial model: a cylinder and a helix.
1. Finding the optimal regularization parameter for a rotating cylinder Jeffrey and Onishi (1981) derived a theory for the torque per length on an infinite cylinder rotating near an infinite plane wall [28] that was used previously to calibrate numerical simulations of helical flagella [23]. The torque per unit length σ on an infinite cylinder is given as where µ is the dynamic viscosity of the fluid, Ω is the angular rotation speed, r is the cylindrical radius, and d is the distance from the axis of symmetry to the plane wall.
We used this theoretical value as a common reference point between the experiments and simulations to establish optimal computational parameters, but note that this theory has not been experimentally tested outside of the present work. We assumed Eq. 7 is valid for our experiments and simulations, though this assumption as applied to experiments ignored the finite size of the tank. To control for end effects in the experiments, we measured the torque with only the first 3 cm inserted into the fluid and with the full cylinder inserted at the same boundary locations. We subtracted the torque found for the short section from the torque found for the full insertion of the cylinder. In simulations, we controlled for finitelength effects by measuring the torque on a middle subsection of the simulated cylinder, as discussed below.
Our experimental data are shown in Fig. 7, with the torque made dimensionless using the quantity µΩr 2 , where µ is the fluid viscosity, Ω is the rotation rate, r is the cylindrical radius, and is the cylindrical length. The mean squared error (MSE) between experiments and theory is MSE ≤ 6% when calculated for the boundary distances where d/r > 1.1 (i.e. the distance from the boundary to the edge of the flagellum is ≥ 1 mm). The theory asymptotically approaches infinity as the boundary distance approaches d/r = 1, which skewed the MSE unrealistically. For the data where d/r ≥ 2, the mean squared error is less than 1%.
In numerical simulations of the cylinder, the computed torque value depended on both the discretization and regularization parameter. Having found good correspondence with the experiments, we used Eq. (7) to find an optimal regularization parameter for a given discretization of the cylinder (see Table I: cylinder part). The discretization size of the cylindrical model ds c was varied among 0.192 µm, 0.144 µm, and 0.096 µm. For each ds c , an optimal discretization factor γ c was found by minimizing the MSE between the numerical simulations and the theoretical values using the computed torque in the middle two-thirds of the cylinder to avoid end effects. The optimal factor was found to be γ c = 6.4 for all the discretization sizes. We used the finest discretization size for our model bacterium as reported in Table I since it returned the smallest MSE value of 0.36%.

Finding the optimal regularization parameter for a rotating helix far from a boundary
Simulated helical torque values also depend on the discretization and regularization parameter, but there is no theory for a helix to provide a reference. Other researchers have determined the regularization parameter using complementary numerical simulations, but the reference simulations also have free parameters that may have affected their results [24].
Thus, we used dynamically similar experiments, as described in Sec. II C, to determine the optimal filament factor, γ f = 2.139, for a helix filament radius a/R = 0.111. Torque were measured for the six helical wavelengths given in Table II when the helix was far from the boundary. The optimal filament factor γ f = 2.139 was found by the following steps (i) varying f for each helix until the percent difference between the experiment and simulation was under 5%; and (ii) averaging the f values found in Step (i). In these simulations, the regularization parameter and discretization size are both equal to γ f a. The results are shown in Fig. 8, with the torque values non-dimensionalized by the value µΩR 2 L, where µ is the fluid viscosity, Ω is the rotation rate, R is the helical radius, and L is the axial length.
The optimized simulations returned an average percent difference of 2.4 ± 1.7% compared to the experimental values.
We checked whether helices with different filament radii could be accurately simulated 3.6 ± 3.4%. The percent difference between our MRS and theirs is 1.8±3.7%. Thus, within the range we tested our MRS with a centerline distribution, the optimal filament factor γ f worked very well for another filament radius and other helical wavelengths when compared to both the experiments and the surfaced discretized MRS in Rodenborn et al. (2013) [25] for torques far from the boundary.

Torque on rotating helices near a boundary
To determine how boundaries affect bacterial motility, we used our optimized value for γ f in our MIRS simulations to compute the torque as a function of boundary distance, as shown in Fig. 9. The computed torque values and measured torque values also show excellent agreement at most boundary distances, except for the shortest wavelength λ/R = 2.26.
We note that this helix had the largest variation in wavelength, as reported in Table II.
Furthermore, the torque for short wavelengths is more sensitive to variation in wavelength as compared to variation at longer wavelengths, which likely explains the difference between simulation and experiment for this geometry, whereas for the other wavelengths the simulated values are generally within the uncertainty in the experiments for all boundary distances.

B. Speed Measurements to Assess Performance
The motion of bacteria through their environment enables them to find nutrients. Indeed, it has been suggested that the purpose of bacterial motility is primarily to perform chemotaxis [3]. Living in a microscopic environment where thermal effects are significant, bacteria must be able to sample chemical concentrations faster than diffusion causes those concentrations to change [3,11], so moving faster may confer a survival advantage.
The low speed operating regime of the bacterial motor (below 175 Hz) is thermodynamically more efficient than the high speed regime. A simple model gives the fraction of energy lost to friction in the motor as (τ 0 − τ )/τ 0 , where τ 0 is the stall torque and τ is the operating torque at a given frequency [13]. In the low speed regime τ ≥ 0.92τ 0 , so that the power output of the motor is greater than 92% of the power input. However, the low speed regime may be less operationally reliable for motility; the flatness of the torque-speed curve implies that small increases in load correspond to large decreases in motor rotation rate, so the bacterium risks stalling and may be unable to restart its motor. Using our simulations, we determined the swimming speed and motor rotation rate for different bacterial geometries at different distances to a solid boundary and assessed. the performance of bacterial geometries typically associated with swimming. Interestingly, the center point of the heat maps shown in Fig. 11 corresponds to the mean size of the E. coli cell body.

C. Energy Cost Measures to Assess Performance
The energy cost required to move is another way to assess the performance of the bacterial motility system. Here we present simulation results of three different energy cost measures.
The first measure we consider is what we term the Purcell inefficiency E −1 P urcell given by, where τ is the motor torque (or the torque on the cell body or the flagellum), Ω m is the motor rotation rate, F is the drag force on the cell body (or on the flagellum), and U is the swimming speed of the bacterium.
Thus, the Purcell inefficiency measures the mechanical energy (T Ω m ) required to swim at speed U relative to the least amount of energy (F U ) needed to translate the cell body at speed U . The Purcell inefficiency is useful because, under certain simplifying assumptions [34], it can be expressed as a function of the geometry of the cell body and the flagellum alone. The difficulty with this measures is that it does not depend on the rotation rate of the motor because all four quantities appearing in Eq. 8 scale with the motor frequency (see Eq. 5). Therefore, the Purcell inefficiency cannot assess how swimming performance depends on the torque-speed characteristics of the motor, and thus omits an important element of the bacterial motility system that is subject to selective forces.
The second measure is the energy cost E to travel a unit distance d given by Several authors [13,16] have considered the distance traveled per energy output by the motor, which is the inverse of the measure we consider here. The merit of the energy cost per distance measure is that it expresses the amount of energy used by the bacterium to perform a biologically relevant task; namely, to swim one unit distance. Another advantage is that it depends on the motor rotation rate and thus can probe the effect of the torquespeed characteristics of the motor. However, it does not account for the size of the bacterium, and thus does not measure the energy cost relative to the overall metabolic budget of the organism.
To account for the metabolic energy cost required to swim a unit distance, we introduce a third measure, The mass m associated with each bacterial model is m = 1.1 × 10 −15 (πr 2 l) kg, where r is the body radius and is the body length, both measured in µm. Though this energy cost measure has not been considered in the literature, it was suggested earlier by Purcell [3].

Optimal wavelength
We first consider the optimal flagellar wavelength predicted by the three energy cost We assessed swimming performance using multiple measures: swimming speed, motor rotation rate, the Purcell inefficiency, energy cost per distance, and metabolic energy cost per distance. As a important and novel addition to our simulations, we incorporated the experimentally measured torque-speed response curve [17] by ensuring that the torque and motor rotation rate matched a point on the curve in all our calculated measures.
Using our MIRS calibration method, we found that the optimal discretization factor for a cylinder is γ c = 6.4 for the surface discretizations we used, which may be used as a reference value for other researchers who simulate rotating cylinders using MRS or MIRS.
We also found an optimal filament factor γ f = 2.139 when using MRS and MIRS with each helix modeled as a string of regularized Stokeslets along the helix centerline. Selecting an appropriate regularization parameter for a center-line discretization of helices MIRS has been considered by other researchers. Martindale et al. (2016) [24] benchmarked their center-line discretization of a helix with a surface discretization model. They reported that the optimal filament factor should be in the range 1 ≤ γ f ≤ 3 to keep the percent difference less than about 10% in their simulations, which is consistent with our results.
In our work, we calibrated simulations that used a centerline discretization of helices by fitting the regularization parameter directly with experimentally measured values of torque.
These MIRS computations showed excellent agreement with the experimental torque values at most boundary distances (Fig. 9).
In MRS/MIRS, using a centerline distribution for a model helix (or flagellum) with a calibrated regularization parameter is more useful than a surface discretization for several reasons: (i) the computational cost is significantly reduced because the matrix system for the centerline distribution is much smaller than for a surface discretization; Further analysis showed that the swimming speed is optimal (i.e. fastest) for bodies that are short and thin, both near and far from the surface. The structure of the torque-speed curve imposes two competing conditions that need to be balanced to achieve optimality: at low speeds the torque-speed curve is flat and therefore thermodynamically efficient, but in that regime small increases in applied load result in large decreases in motor rotation rate that could cause the motor to stall. We therefore suggest that the optimal speed is higher than the 175 Hz knee speed (see Fig. 3) so that the motor operates in the reliable regime, but not much higher so that it remains thermodynamically efficient. The lowest motor speed that is still above the knee speed for typical bacterial wavelengths occurs for long and thick bacterial bodies, both near and far from the surface. It is tempting to suggest that balancing the short, thin bodies needed for optimal speed and long, thick bodies needed for optimal motor operation yields the average body size. However, we do not infer too much from this result because we do not have a principled way of performing the balancing needed to draw a definitive conclusion.
The three energy cost measures also make different predictions about body shape. The Purcell inefficiency is relatively insensitive to differences in body shape, especially far from the wall. However, based on the small differences (≈ 8%), the optimal body far from the boundary is short and thick, whereas the optimal body near the wall is short and thin. The Purcell inefficiency is the only quantity that makes different predictions about the optimal body near and far from the boundary. The Purcell inefficiency also predicts that bacterial motility systems become generally more efficient near the boundary, which would suggest a natural benefit for all bacteria to move near boundaries that are independent of any other biologically relevant activities.
Unlike the Purcell inefficiency, the energy cost per distance traveled and the energy cost per body mass per distance traveled (metabolic energy cost) both predict larger energy costs for moving near a surface. However, they make opposite predictions about the optimal body size. The energy cost per distance suggests short and thin cell bodies are most efficient, and the metabolic energy cost suggests long and thick cell bodies are most efficient. Though increasing body size results in a greater energy cost for moving a given distance, the increase in body size results in a smaller relative energy expenditure. The energy per distance predicts the same optimal body as predicted by the fastest swimming speed, and metabolic energy cost predicts the same optimal body as predicted by motor rotation rate. Only the Purcell efficiency predicts a short, thick body is optimal, and this occurs only far from the boundary.
Although the Purcell efficiency has been a popular quantity of analysis, we believe it has several important shortcomings that warrant discussion, at least one of which was anticipated by Purcell. First, the Purcell efficiency is dependent only on the geometry of the body and flagellum and not on the motor's torque-speed response characteristics. From a physical standpoint, it is interesting to find such an invariant quantity, but from a biological standpoint, it does not assess the bacterial motility system's thermodynamic efficiency because it ignores motor mechanics.
Second, the Purcell efficiency is defined to be the ratio between the minimum power required to translate the cell body and the power actually dissipated during the bacterial motion. In our simulations, we find the maximal efficiency is in the range of 1-2%, similar to what others have found [3,9,12]. These two quantities (the minimum power vs the actual power) are clearly of very different orders, which suggests that least power needed may not be an appropriate reference quantity.To give a biophysical interpretation to the least power needed to translate the cell body, some authors have suggested that it represents the "useful" portion of the power dissipated during motion, [8,12] but we believe this is a misconception.
The bacterium is non-inertial; therefore, the force acting on the cell body by the fluid is exactly balanced by the force acting on the flagellum by the fluid (assuming no net body forces). Both the bacterial body and the flagellum have the same axial velocity (in a rigid model); therefore the power dissipated due to the axial fluid drag on the body is exactly compensated by the power input by the axial fluid force exerted on the flagellum.
Finally, as Purcell noted in 1977, the efficiency of the bacterial motility system is probably best characterized by the energy consumption relative to the overall metabolic budget of the organism [3]. This suggestion led us to consider the metabolic energy cost introduced in this paper. The actual amount of that metabolic budget used for motility is a small fraction, which led Purcell [3] to suggest that bacterial motility is not really subject to strong selective forces toward optimal efficiency. Our data do not say whether evolutionary processes tend to minimize the energy cost of bacterial motility, but a plausible counterargument is that the bacterium needs to consume most of its energy for other biological functions and has only a small fraction available for motility. Thus, small absolute changes in energy consumption correspond to large relative changes in the energy available for motility, resulting in a significant selective pressure to make the motility system as efficient

ACKNOWLEDGMENTS
We wish to thank undergraduate students Asha Ari, Alexandra Boardman, Tanner May and Mackenzie Conkling and Prof. Philip Lockett for their assistance in collecting experimental data at Centre College. We also acknowledge the contributions of Mica Jarocki and David Clark at Trinity University to the initial implementation of the model bacterium. We would also like to thank Deon Lee for her support by editing the manuscript.