Skip to content

Diffusion in a speckle field

Brownian particles in a random speckle field, trapped at hotspots for longer as the field grows stronger.

  • Name: diffusion_in_a_speckle_field
  • Field: physics/soft_matter
  • Formalism: stochastic differential equations
  • References: Argun et al. 2021; Volpe, Volpe, and Gigan 2014

Factory

@register_model(
    field='physics/soft_matter',
    tags=('anomalous diffusion', 'sde', 'optical forces', 'disorder'),
    references=('Argun et al. 2021', 'Volpe, Volpe, and Gigan 2014'),
    defaults={'until': 60.0, 'dt': 0.5, 'solver': EulerMaruyamaSolver(dt=0.01)},
)
def diffusion_in_a_speckle_field(
    n_particles: int = 100,
    *,
    n_hotspots: int = 50,
    size: float = 100.0,
    strength: float = 30.0,
    length: float = 10.0,
    D: float = 1.0,
    random_state: int | np.random.Generator | None = 0,
) -> System:
    """Return Brownian particles in a random speckle field, trapped at hotspots for longer as the field grows stronger.

    The hotspots sit at random places in a square, with intensities `r^(-1/2)` and decay lengths `length r^(-1/2)` for
    independent uniform numbers `r`. The particles start at random places in the middle half of the square.

    The default strength 30 draws the particles into the hotspots over the first ten time units and lets them escape
    now and then, so from time 10 to 60 their mean squared displacement grows as `t^0.36`, a tenth of free diffusion.
    A strength of 100 or more traps every particle within the first frames and leaves only the rattling inside one
    hotspot, with a flat mean squared displacement.

    Args:
        n_particles:
            The number of independent particles.

        n_hotspots:
            The number of hotspots.

        size:
            The side of the square of the hotspots.

        strength:
            The product `u I0` of the polarizability constant and the reference intensity.

        length:
            The reference decay length of the hotspots.

        D:
            The diffusion coefficient.

        random_state:
            The seed or generator of the hotspots and the initial positions.

    Returns:
        system:
            The model, with the positions `beads.x`.

    Examples:
        >>> from skcomplex.models.physics.soft_matter import diffusion_in_a_speckle_field
        >>> len(diffusion_in_a_speckle_field(5, n_hotspots=3).interactions[0].centers)
        3
    """
    rng = np.random.default_rng(random_state)
    centers = rng.uniform(0.0, size, (n_hotspots, 2))
    intensities = (1 - rng.random(n_hotspots)) ** -0.5
    lengths = length * (1 - rng.random(n_hotspots)) ** -0.5
    speckle = SpeckleFieldInteraction(
        'speckle',
        target='beads',
        strength=strength,
        centers=tuple((float(x), float(y)) for x, y in centers),
        intensities=tuple(float(item) for item in intensities),
        lengths=tuple(float(item) for item in lengths),
    )
    positions = rng.uniform(size / 4, 3 * size / 4, (n_particles, 2))
    beads = GroupElement(
        'beads',
        element=BrownianParticleElement,
        size=n_particles,
        values={'x': positions, 'gamma': 1.0, 'temperature': D},
    )
    bath = ThermalNoiseInteraction('bath', target='beads')
    return System(elements=[beads], interactions=[speckle, bath], space=ContinuousSpace(n_dim=2))

Components

class BrownianParticleElement(Element):
    """Overdamped Brownian particle at the position `x`, with the friction `gamma` and the thermal energy `temperature`.

    The particle moves by `dx = F / gamma dt + sqrt(2 temperature / gamma) dW`, with the thermal noise of
    `ThermalNoiseInteraction` and the forces of other interactions, which divide by `gamma`.

    Args:
        label:
            The label of the particle or the group.

        visual:
            How the element is drawn, or `None` for `default_visual_`.

        x:
            The initial position.

        gamma:
            The friction coefficient.

        temperature:
            The thermal energy.

    Examples:
        >>> from skcomplex.models.physics.soft_matter import BrownianParticleElement
        >>> BrownianParticleElement('bead', temperature=2.0).temperature
        2.0
    """

    def __init__(
        self,
        label: str,
        visual: VisualSpec | None = POINTS,
        *,
        x: Annotated[npt.ArrayLike, StateSpec(vector=True, role='position')] = 0.0,
        gamma: Annotated[float, ParameterSpec(domain=RealSet.open(0, oo))] = 1.0,
        temperature: Annotated[float, ParameterSpec(domain=RealSet.closed_open(0, oo))] = 1.0,
    ) -> None:
        super().__init__(label, visual=visual)
        self.x = x
        self.gamma = gamma
        self.temperature = temperature

class SpeckleFieldInteraction(GradientInteraction):
    """Random optical speckle field of Gaussian hotspots, which drags particles up its gradient at `u grad(I)`.

    The potential is `-u I(x)`, with the intensity `I(x) = sum_i I_i exp(-|x - c_i|^2 / d_i^2)` of hotspots whose
    centers, intensities relative to `strength`, and decay lengths are fixed when the field is created.

    Args:
        label:
            The label of the interaction.

        target:
            The path of the particle or the group.

        strength:
            The product `u I0` of the polarizability constant and the reference intensity.

        centers:
            The centers of the hotspots.

        intensities:
            The intensities of the hotspots in units of the reference intensity.

        lengths:
            The decay lengths of the hotspots.

    Examples:
        >>> from skcomplex.models.physics.soft_matter import SpeckleFieldInteraction
        >>> SpeckleFieldInteraction(
        ...     'speckle', target='bead', centers=((0.0, 0.0),), intensities=(1.0,), lengths=(1.0,)
        ... ).strength
        1.0
    """

    def __init__(
        self,
        label: str,
        *,
        target: Annotated[str, RoleSpec()],
        strength: Annotated[float, ParameterSpec(domain=RealSet.closed_open(0, oo))] = 1.0,
        centers: tuple[tuple[float, float], ...] = (),
        intensities: tuple[float, ...] = (),
        lengths: tuple[float, ...] = (),
    ) -> None:
        super().__init__(label, target=target, states='x')
        self.strength = strength
        self.centers = centers
        self.intensities = intensities
        self.lengths = lengths

    def _get_potential(self, namespace: SimpleNamespace) -> Expression:
        """Return the potential `-u I(x)` of the speckle field.

        Args:
            namespace:
                The namespace of the symbols the potential can use.

        Returns:
            potential:
                The potential.
        """
        position = namespace.target.x
        intensity = SR(0)
        for center, height, length in zip(self.centers, self.intensities, self.lengths, strict=True):
            offset = position - vector(SR, center)
            intensity += height * exp(-offset.dot_product(offset) / length**2)
        return -namespace.strength * intensity

class ThermalNoiseInteraction(RateInteraction):
    """Thermal noise of overdamped particles, the random force `sqrt(2 gamma temperature) dW` divided by `gamma`.

    The friction `gamma` and the thermal energy `temperature` are parameters of the target, so every component of the
    position diffuses with the coefficient `temperature / gamma`.

    Args:
        label:
            The label of the interaction.

        target:
            The path of the particle or the group.

        state:
            The name of the state that holds the positions.

    Examples:
        >>> from skcomplex.models.physics.soft_matter import ThermalNoiseInteraction
        >>> ThermalNoiseInteraction('bath', target='beads').divisor
        'gamma'
    """

    def __init__(self, label: str, *, target: Annotated[str, RoleSpec()], state: str = 'x') -> None:
        super().__init__(label, target=target, state=state, divisor='gamma')

    def _get_noise(self, namespace: SimpleNamespace) -> object:
        """Return the amplitude `sqrt(2 gamma temperature)` of the random force.

        Args:
            namespace:
                The namespace of the symbols the amplitude can use.

        Returns:
            amplitude:
                The noise amplitude, before the division by the friction.
        """
        target = namespace.target
        return sqrt(2 * target.gamma * target.temperature)

Equations

beads.x[i, 0]: diff(x_beads_0(t), t) == (1.0222549188014547*(-0.0198718223467138*x_beads_0(t) + 0.029224107964841355)*e^(-0.0099359111733569*(x_beads_0(t) - 1.4706304965369288)^2 - 0.0099359111733569*(x_beads_1(t) - 86.36400902455757)^2) + 1.6103357041685684*(-0.012384589833782215*x_beads_0(t) + 0.035072751136415614)*e^(-0.006192294916891107*(x_beads_0(t) - 2.8319671145462966)^2 - 0.006192294916891107*(x_beads_1(t) - 12.428327649956394)^2) + 1.1413658030092055*(-0.012699076844834588*x_beads_0(t) + 0.05203259290694057)*e^(-0.006349538422417294*(x_beads_0(t) - 4.0973523936194685)^2 - 0.006349538422417294*(x_beads_1(t) - 1.6527635528529094)^2) + 1.1615855991192419*(-0.0023980375739186053*x_beads_0(t) + 0.020147195069624018)*e^(-0.0011990187869593027*(x_beads_0(t) - 8.401534358238482)^2 - 0.0011990187869593027*(x_beads_1(t) - 83.26441476533978)^2) + 1.4975338178321778*(-0.015057065193557852*x_beads_0(t) + 0.13664745244010484)*e^(-0.007528532596778926*(x_beads_0(t) - 9.07530456191219)^2 - 0.007528532596778926*(x_beads_1(t) - 58.03323859868507)^2) + 1.2980559742855908*(-0.0003611461374658753*x_beads_0(t) + 0.004150747657818082)*e^(-0.00018057306873293764*(x_beads_0(t) - 11.493263328090519)^2 - 0.00018057306873293764*(x_beads_1(t) - 72.90151170763095)^2) + 3.755690623917113*(-0.014603264289984*x_beads_0(t) + 0.1972849967495422)*e^(-0.007301632144992*(x_beads_0(t) - 13.509650502241122)^2 - 0.007301632144992*(x_beads_1(t) - 72.14883401940817)^2) + 1.3078702629013346*(-0.00043468572319708574*x_beads_0(t) + 0.006466559224298347)*e^(-0.00021734286159854287*(x_beads_0(t) - 14.876401223249792)^2 - 0.00021734286159854287*(x_beads_1(t) - 97.26288138229549)^2) + 1.5083727538963576*(-0.006598763013701279*x_beads_0(t) + 0.1316555132319636)*e^(-0.0032993815068506397*(x_beads_0(t) - 19.95154439682133)^2 - 0.0032993815068506397*(x_beads_1(t) - 94.21131105064978)^2) + 1.5113947718439809*(-0.01634575242146875*x_beads_0(t) + 0.3713061784553256)*e^(-0.008172876210734375*(x_beads_0(t) - 22.715759353337972)^2 - 0.008172876210734375*(x_beads_1(t) - 62.31871446860424)^2) + 1.1853890239112361*(-0.0050350299339649175*x_beads_0(t) + 0.11612904263193108)*e^(-0.0025175149669824587*(x_beads_0(t) - 23.064220899374742)^2 - 0.0025175149669824587*(x_beads_1(t) - 5.202130106440961)^2) + 2.2924132097793057*(-0.017175068861979368*x_beads_0(t) + 0.5130126649971931)*e^(-0.008587534430989684*(x_beads_0(t) - 29.86961328189226)^2 - 0.008587534430989684*(x_beads_1(t) - 67.19948779563593)^2) + 1.931690851876592*(-0.01881071696799323*x_beads_0(t) + 0.5637795544840913)*e^(-0.009405358483996614*(x_beads_0(t) - 29.971189053738478)^2 - 0.009405358483996614*(x_beads_1(t) - 42.26872211976585)^2) + 1.1365613691700822*(-0.0008317273644409616*x_beads_0(t) + 0.027955775691128518)*e^(-0.0004158636822204808*(x_beads_0(t) - 33.611706054566035)^2 - 0.0004158636822204808*(x_beads_1(t) - 15.027946689483906)^2) + 1.1854643661163144*(-0.005707629266904946*x_beads_0(t) + 0.20839134819187724)*e^(-0.002853814633452473*(x_beads_0(t) - 36.51101682448286)^2 - 0.002853814633452473*(x_beads_1(t) - 10.549527957022953)^2) + 5.428219417308108*(-0.013681129092645997*x_beads_0(t) + 0.5357790101358775)*e^(-0.0068405645463229985*(x_beads_0(t) - 39.16190005281612)^2 - 0.0068405645463229985*(x_beads_1(t) - 89.02743520047923)^2) + 1.554405727342162*(-0.002785971809046446*x_beads_0(t) + 0.11270700210406509)*e^(-0.001392985904523223*(x_beads_0(t) - 40.45518398215282)^2 - 0.001392985904523223*(x_beads_1(t) - 19.851304450925532)^2) + 2.5674064342843317*(-0.009531305452101601*x_beads_0(t) + 0.3952211557709525)*e^(-0.004765652726050801*(x_beads_0(t) - 41.46558493556708)^2 - 0.004765652726050801*(x_beads_1(t) - 73.44835717887294)^2) + 2.344815555144572*(-0.01208885453790248*x_beads_0(t) + 0.5323655365174488)*e^(-0.00604442726895124*(x_beads_0(t) - 44.037715471578394)^2 - 0.00604442726895124*(x_beads_1(t) - 95.45904936907372)^2) + 1.0687730488680722*(-0.001485708455711625*x_beads_0(t) + 0.06690730049706634)*e^(-0.0007428542278558125*(x_beads_0(t) - 45.033936664928696)^2 - 0.0007428542278558125*(x_beads_1(t) - 79.63242702872942)^2) + 2.5103552319718747*(-0.002373856545246202*x_beads_0(t) + 0.11533034464748798)*e^(-0.001186928272623101*(x_beads_0(t) - 48.58353588317891)^2 - 0.001186928272623101*(x_beads_1(t) - 88.94878343490002)^2) + 1.636283134728239*(-0.001794884675678905*x_beads_0(t) + 0.08972553354239947)*e^(-0.0008974423378394525*(x_beads_0(t) - 49.9895813687647)^2 - 0.0008974423378394525*(x_beads_1(t) - 42.522862484907556)^2) + 1.0347745588502566*(-0.0027375959162136442*x_beads_0(t) + 0.14382078477747332)*e^(-0.0013687979581068221*(x_beads_0(t) - 52.53543224757259)^2 - 0.0013687979581068221*(x_beads_1(t) - 31.024187555895566)^2) + 1.5692655708354395*(-0.009479555027642495*x_beads_0(t) + 0.5017643749385604)*e^(-0.004739777513821247*(x_beads_0(t) - 52.93121601967704)^2 - 0.004739777513821247*(x_beads_1(t) - 78.57857007138075)^2) + 1.167321577421033*(-0.01452301802800886*x_beads_0(t) + 0.7895075551528499)*e^(-0.00726150901400443*(x_beads_0(t) - 54.362499146542284)^2 - 0.00726150901400443*(x_beads_1(t) - 93.50724237877682)^2) + 1.2349538058247025*(-0.013114085380753492*x_beads_0(t) + 0.7495090997837676)*e^(-0.006557042690376746*(x_beads_0(t) - 57.15298307297609)^2 - 0.006557042690376746*(x_beads_1(t) - 32.18693910759421)^2) + 1.3248795813881042*(-0.00010165303678164371*x_beads_0(t) + 0.006041240282922175)*e^(-(5.082651839082186e-05)*(x_beads_0(t) - 59.43000301996968)^2 - (5.082651839082186e-05)*(x_beads_1(t) - 33.791122550713325)^2) + 3.6162205399849525*(-0.0069477084732672304*x_beads_0(t) + 0.4214728519484675)*e^(-0.0034738542366336152*(x_beads_0(t) - 60.663577576717984)^2 - 0.0034738542366336152*(x_beads_1(t) - 72.94965609839984)^2) + 1.8871948358133463*(-0.010223009063330712*x_beads_0(t) + 0.6291087572111639)*e^(-0.005111504531665356*(x_beads_0(t) - 61.53851114812539)^2 - 0.005111504531665356*(x_beads_1(t) - 38.367755426188346)^2) + 4.943330854264929*(-0.008771984648995543*x_beads_0(t) + 0.5440502880179429)*e^(-0.0043859923244977716*(x_beads_0(t) - 62.021345201537784)^2 - 0.0043859923244977716*(x_beads_1(t) - 99.50965052353241)^2) + 1.3050964462719346*(-0.016658941424354555*x_beads_0(t) + 1.0480275846083984)*e^(-0.008329470712177277*(x_beads_0(t) - 62.91081515397092)^2 - 0.008329470712177277*(x_beads_1(t) - 92.71545530678674)^2) + 1.3867343882806382*(-0.019800908783854158*x_beads_0(t) + 1.261242026946195)*e^(-0.009900454391927079*(x_beads_0(t) - 63.69616873214543)^2 - 0.009900454391927079*(x_beads_1(t) - 26.97867137638703)^2) + 1.0144917190015763*(-0.011404518776428467*x_beads_0(t) + 0.7648148729304859)*e^(-0.005702259388214234*(x_beads_0(t) - 67.06244146936304)^2 - 0.005702259388214234*(x_beads_1(t) - 64.71895115742501)^2) + 2.032583312702043*(-0.004486176237963433*x_beads_0(t) + 0.3075462160903589)*e^(-0.0022430881189817167*(x_beads_0(t) - 68.55419844806947)^2 - 0.0022430881189817167*(x_beads_1(t) - 65.04592762678163)^2) + 1.4326099518843516*(-0.013822852745614775*x_beads_0(t) + 0.9516297779882035)*e^(-0.006911426372807387*(x_beads_0(t) - 68.84467305709401)^2 - 0.006911426372807387*(x_beads_1(t) - 38.892142397910376)^2) + 1.0817757508574255*(-0.018221287195074563*x_beads_0(t) + 1.2957938616583102)*e^(-0.009110643597537282*(x_beads_0(t) - 71.11428779897498)^2 - 0.009110643597537282*(x_beads_1(t) - 93.20596866133782)^2) + 3.8074127151175388*(-0.017463657954775044*x_beads_0(t) + 1.2742453141291228)*e^(-0.008731828977387522*(x_beads_0(t) - 72.9655446429944)^2 - 0.008731828977387522*(x_beads_1(t) - 17.5655620602559)^2) + 1.4950564703232743*(-0.016117404542184133*x_beads_0(t) + 1.2212622333115795)*e^(-0.008058702271092066*(x_beads_0(t) - 75.77288453082915)^2 - 0.008058702271092066*(x_beads_1(t) - 49.7422695487619)^2) + 1.1483453538138098*(-0.0037532920377749196*x_beads_0(t) + 0.29542098104433906)*e^(-0.0018766460188874598*(x_beads_0(t) - 78.70983074886834)^2 - 0.0018766460188874598*(x_beads_1(t) - 23.936944299295217)^2) + 2.2466554556073026*(-0.018427399256687207*x_beads_0(t) + 1.4986455401324927)*e^(-0.009213699628343603*(x_beads_0(t) - 81.32702392002724)^2 - 0.009213699628343603*(x_beads_1(t) - 91.27555772777217)^2) + 1.4727147725743037*(-0.005946958586804274*x_beads_0(t) + 0.48518472992578315)*e^(-0.002973479293402137*(x_beads_0(t) - 81.58535541215322)^2 - 0.002973479293402137*(x_beads_1(t) - 0.2738500170148095)^2) + 1.3396028530319002*(-0.001123971461158184*x_beads_0(t) + 0.0963697937559406)*e^(-0.000561985730579092*(x_beads_0(t) - 85.74042765875693)^2 - 0.000561985730579092*(x_beads_1(t) - 3.3585575305464355)^2) + 1.0208923149556883*(-0.0027044340919845176*x_beads_0(t) + 0.233441050508549)*e^(-0.0013522170459922588*(x_beads_0(t) - 86.31789223498866)^2 - 0.0013522170459922588*(x_beads_1(t) - 54.14612202490917)^2) + 2.9896511258646905*(-0.006642211888572974*x_beads_0(t) + 0.5821793978037595)*e^(-0.003321105944286487*(x_beads_0(t) - 87.64842308107038)^2 - 0.003321105944286487*(x_beads_1(t) - 5.856803480519435)^2) + 2.423959206808311*(-0.00820259943358099*x_beads_0(t) + 0.7299784885276726)*e^(-0.004101299716790495*(x_beads_0(t) - 88.99355557205206)^2 - 0.004101299716790495*(x_beads_1(t) - 82.23738275430705)^2) + 3.3325736239168364*(-0.00857208799088451*x_beads_0(t) + 0.7949959521021523)*e^(-0.004286043995442255*(x_beads_0(t) - 92.74239286245599)^2 - 0.004286043995442255*(x_beads_1(t) - 96.79261899246464)^2) + 1.035111282847064*(-0.009785869889127096*x_beads_0(t) + 0.9140428317930668)*e^(-0.004892934944563548*(x_beads_0(t) - 93.40435159562497)^2 - 0.004892934944563548*(x_beads_1(t) - 35.77951967090702)^2) + 1.2592864656875298*(-0.008433281701474546*x_beads_0(t) + 0.8002709329582666)*e^(-0.004216640850737273*(x_beads_0(t) - 94.89436749377653)^2 - 0.004216640850737273*(x_beads_1(t) - 46.00451393090961)^2) + 2.3749437283328896*(-0.0045470159754922275*x_beads_0(t) + 0.44615095222554035)*e^(-0.0022735079877461138*(x_beads_0(t) - 98.11950400663443)^2 - 0.0022735079877461138*(x_beads_1(t) - 95.72101796109635)^2) + 1.0080930617020192*(-0.0004707535612791092*x_beads_0(t) + 0.04694401286156829)*e^(-0.0002353767806395546*(x_beads_0(t) - 99.7209935789211)^2 - 0.0002353767806395546*(x_beads_1(t) - 98.08353387762301)^2))*strength_speckle
beads.x[i, 1]: diff(x_beads_1(t), t) == (1.0222549188014547*(-0.0198718223467138*x_beads_1(t) + 1.7162102444859957)*e^(-0.0099359111733569*(x_beads_0(t) - 1.4706304965369288)^2 - 0.0099359111733569*(x_beads_1(t) - 86.36400902455757)^2) + 1.6103357041685684*(-0.012384589833782215*x_beads_1(t) + 0.15391974026456437)*e^(-0.006192294916891107*(x_beads_0(t) - 2.8319671145462966)^2 - 0.006192294916891107*(x_beads_1(t) - 12.428327649956394)^2) + 1.1413658030092055*(-0.012699076844834588*x_beads_1(t) + 0.02098857136402093)*e^(-0.006349538422417294*(x_beads_0(t) - 4.0973523936194685)^2 - 0.006349538422417294*(x_beads_1(t) - 1.6527635528529094)^2) + 1.1615855991192419*(-0.0023980375739186053*x_beads_1(t) + 0.1996711951776279)*e^(-0.0011990187869593027*(x_beads_0(t) - 8.401534358238482)^2 - 0.0011990187869593027*(x_beads_1(t) - 83.26441476533978)^2) + 1.4975338178321778*(-0.015057065193557852*x_beads_1(t) + 0.873810256973699)*e^(-0.007528532596778926*(x_beads_0(t) - 9.07530456191219)^2 - 0.007528532596778926*(x_beads_1(t) - 58.03323859868507)^2) + 1.2980559742855908*(-0.0003611461374658753*x_beads_1(t) + 0.0263280993686342)*e^(-0.00018057306873293764*(x_beads_0(t) - 11.493263328090519)^2 - 0.00018057306873293764*(x_beads_1(t) - 72.90151170763095)^2) + 3.755690623917113*(-0.014603264289984*x_beads_1(t) + 1.053608491399606)*e^(-0.007301632144992*(x_beads_0(t) - 13.509650502241122)^2 - 0.007301632144992*(x_beads_1(t) - 72.14883401940817)^2) + 1.3078702629013346*(-0.00043468572319708574*x_beads_1(t) + 0.04227878593389548)*e^(-0.00021734286159854287*(x_beads_0(t) - 14.876401223249792)^2 - 0.00021734286159854287*(x_beads_1(t) - 97.26288138229549)^2) + 1.5083727538963576*(-0.006598763013701279*x_beads_1(t) + 0.6216781148333345)*e^(-0.0032993815068506397*(x_beads_0(t) - 19.95154439682133)^2 - 0.0032993815068506397*(x_beads_1(t) - 94.21131105064978)^2) + 1.5113947718439809*(-0.01634575242146875*x_beads_1(t) + 1.0186462779280074)*e^(-0.008172876210734375*(x_beads_0(t) - 22.715759353337972)^2 - 0.008172876210734375*(x_beads_1(t) - 62.31871446860424)^2) + 1.1853890239112361*(-0.0050350299339649175*x_beads_1(t) + 0.026192880806310343)*e^(-0.0025175149669824587*(x_beads_0(t) - 23.064220899374742)^2 - 0.0025175149669824587*(x_beads_1(t) - 5.202130106440961)^2) + 2.2924132097793057*(-0.017175068861979368*x_beads_1(t) + 1.1541558303797892)*e^(-0.008587534430989684*(x_beads_0(t) - 29.86961328189226)^2 - 0.008587534430989684*(x_beads_1(t) - 67.19948779563593)^2) + 1.931690851876592*(-0.01881071696799323*x_beads_1(t) + 0.7951049683936702)*e^(-0.009405358483996614*(x_beads_0(t) - 29.971189053738478)^2 - 0.009405358483996614*(x_beads_1(t) - 42.26872211976585)^2) + 1.1365613691700822*(-0.0008317273644409616*x_beads_1(t) + 0.012499154493003723)*e^(-0.0004158636822204808*(x_beads_0(t) - 33.611706054566035)^2 - 0.0004158636822204808*(x_beads_1(t) - 15.027946689483906)^2) + 1.1854643661163144*(-0.005707629266904946*x_beads_1(t) + 0.06021279451953614)*e^(-0.002853814633452473*(x_beads_0(t) - 36.51101682448286)^2 - 0.002853814633452473*(x_beads_1(t) - 10.549527957022953)^2) + 5.428219417308108*(-0.013681129092645997*x_beads_1(t) + 1.2179958337649328)*e^(-0.0068405645463229985*(x_beads_0(t) - 39.16190005281612)^2 - 0.0068405645463229985*(x_beads_1(t) - 89.02743520047923)^2) + 1.554405727342162*(-0.002785971809046446*x_beads_1(t) + 0.05530517457307677)*e^(-0.001392985904523223*(x_beads_0(t) - 40.45518398215282)^2 - 0.001392985904523223*(x_beads_1(t) - 19.851304450925532)^2) + 2.5674064342843317*(-0.009531305452101601*x_beads_1(t) + 0.7000587272268974)*e^(-0.004765652726050801*(x_beads_0(t) - 41.46558493556708)^2 - 0.004765652726050801*(x_beads_1(t) - 73.44835717887294)^2) + 2.344815555144572*(-0.01208885453790248*x_beads_1(t) + 1.153990562149184)*e^(-0.00604442726895124*(x_beads_0(t) - 44.037715471578394)^2 - 0.00604442726895124*(x_beads_1(t) - 95.45904936907372)^2) + 1.0687730488680722*(-0.001485708455711625*x_beads_1(t) + 0.11831057018542226)*e^(-0.0007428542278558125*(x_beads_0(t) - 45.033936664928696)^2 - 0.0007428542278558125*(x_beads_1(t) - 79.63242702872942)^2) + 2.5103552319718747*(-0.002373856545246202*x_beads_1(t) + 0.21115165174862438)*e^(-0.001186928272623101*(x_beads_0(t) - 48.58353588317891)^2 - 0.001186928272623101*(x_beads_1(t) - 88.94878343490002)^2) + 1.636283134728239*(-0.001794884675678905*x_beads_1(t) + 0.07632363424016197)*e^(-0.0008974423378394525*(x_beads_0(t) - 49.9895813687647)^2 - 0.0008974423378394525*(x_beads_1(t) - 42.522862484907556)^2) + 1.0347745588502566*(-0.0027375959162136442*x_beads_1(t) + 0.08493168915686586)*e^(-0.0013687979581068221*(x_beads_0(t) - 52.53543224757259)^2 - 0.0013687979581068221*(x_beads_1(t) - 31.024187555895566)^2) + 1.5692655708354395*(-0.009479555027642495*x_beads_1(t) + 0.7448898789851155)*e^(-0.004739777513821247*(x_beads_0(t) - 52.93121601967704)^2 - 0.004739777513821247*(x_beads_1(t) - 78.57857007138075)^2) + 1.167321577421033*(-0.01452301802800886*x_beads_1(t) + 1.35800736681637)*e^(-0.00726150901400443*(x_beads_0(t) - 54.362499146542284)^2 - 0.00726150901400443*(x_beads_1(t) - 93.50724237877682)^2) + 1.2349538058247025*(-0.013114085380753492*x_beads_1(t) + 0.4221022676021041)*e^(-0.006557042690376746*(x_beads_0(t) - 57.15298307297609)^2 - 0.006557042690376746*(x_beads_1(t) - 32.18693910759421)^2) + 1.3248795813881042*(-0.00010165303678164371*x_beads_1(t) + 0.003434970223540692)*e^(-(5.082651839082186e-05)*(x_beads_0(t) - 59.43000301996968)^2 - (5.082651839082186e-05)*(x_beads_1(t) - 33.791122550713325)^2) + 3.6162205399849525*(-0.0069477084732672304*x_beads_1(t) + 0.5068329437967831)*e^(-0.0034738542366336152*(x_beads_0(t) - 60.663577576717984)^2 - 0.0034738542366336152*(x_beads_1(t) - 72.94965609839984)^2) + 1.8871948358133463*(-0.010223009063330712*x_beads_1(t) + 0.39223391146157954)*e^(-0.005111504531665356*(x_beads_0(t) - 61.53851114812539)^2 - 0.005111504531665356*(x_beads_1(t) - 38.367755426188346)^2) + 4.943330854264929*(-0.008771984648995543*x_beads_1(t) + 0.8728971268193376)*e^(-0.0043859923244977716*(x_beads_0(t) - 62.021345201537784)^2 - 0.0043859923244977716*(x_beads_1(t) - 99.50965052353241)^2) + 1.3050964462719346*(-0.016658941424354555*x_beads_1(t) + 1.5445413390881229)*e^(-0.008329470712177277*(x_beads_0(t) - 62.91081515397092)^2 - 0.008329470712177277*(x_beads_1(t) - 92.71545530678674)^2) + 1.3867343882806382*(-0.019800908783854158*x_beads_1(t) + 0.5342022110334167)*e^(-0.009900454391927079*(x_beads_0(t) - 63.69616873214543)^2 - 0.009900454391927079*(x_beads_1(t) - 26.97867137638703)^2) + 1.0144917190015763*(-0.011404518776428467*x_beads_1(t) + 0.7380884936656105)*e^(-0.005702259388214234*(x_beads_0(t) - 67.06244146936304)^2 - 0.005702259388214234*(x_beads_1(t) - 64.71895115742501)^2) + 2.032583312702043*(-0.004486176237963433*x_beads_1(t) + 0.29180749489555696)*e^(-0.0022430881189817167*(x_beads_0(t) - 68.55419844806947)^2 - 0.0022430881189817167*(x_beads_1(t) - 65.04592762678163)^2) + 1.4326099518843516*(-0.013822852745614775*x_beads_1(t) + 0.5376003573277962)*e^(-0.006911426372807387*(x_beads_0(t) - 68.84467305709401)^2 - 0.006911426372807387*(x_beads_1(t) - 38.892142397910376)^2) + 1.0817757508574255*(-0.018221287195074563*x_beads_1(t) + 1.6983327232733558)*e^(-0.009110643597537282*(x_beads_0(t) - 71.11428779897498)^2 - 0.009110643597537282*(x_beads_1(t) - 93.20596866133782)^2) + 3.8074127151175388*(-0.017463657954775044*x_beads_1(t) + 0.30675896760368265)*e^(-0.008731828977387522*(x_beads_0(t) - 72.9655446429944)^2 - 0.008731828977387522*(x_beads_1(t) - 17.5655620602559)^2) + 1.4950564703232743*(-0.016117404542184133*x_beads_1(t) + 0.8017162811637625)*e^(-0.008058702271092066*(x_beads_0(t) - 75.77288453082915)^2 - 0.008058702271092066*(x_beads_1(t) - 49.7422695487619)^2) + 1.1483453538138098*(-0.0037532920377749196*x_beads_1(t) + 0.08984234244720649)*e^(-0.0018766460188874598*(x_beads_0(t) - 78.70983074886834)^2 - 0.0018766460188874598*(x_beads_1(t) - 23.936944299295217)^2) + 2.2466554556073026*(-0.018427399256687207*x_beads_1(t) + 1.6819711446264591)*e^(-0.009213699628343603*(x_beads_0(t) - 81.32702392002724)^2 - 0.009213699628343603*(x_beads_1(t) - 91.27555772777217)^2) + 1.4727147725743037*(-0.005946958586804274*x_beads_1(t) + 0.0016285747101827178)*e^(-0.002973479293402137*(x_beads_0(t) - 81.58535541215322)^2 - 0.002973479293402137*(x_beads_1(t) - 0.2738500170148095)^2) + 1.3396028530319002*(-0.001123971461158184*x_beads_1(t) + 0.0037749228149920994)*e^(-0.000561985730579092*(x_beads_0(t) - 85.74042765875693)^2 - 0.000561985730579092*(x_beads_1(t) - 3.3585575305464355)^2) + 1.0208923149556883*(-0.0027044340919845176*x_beads_1(t) + 0.14643461835291813)*e^(-0.0013522170459922588*(x_beads_0(t) - 86.31789223498866)^2 - 0.0013522170459922588*(x_beads_1(t) - 54.14612202490917)^2) + 2.9896511258646905*(-0.006642211888572974*x_beads_1(t) + 0.03890212970734176)*e^(-0.003321105944286487*(x_beads_0(t) - 87.64842308107038)^2 - 0.003321105944286487*(x_beads_1(t) - 5.856803480519435)^2) + 2.423959206808311*(-0.00820259943358099*x_beads_1(t) + 0.6745603091996621)*e^(-0.004101299716790495*(x_beads_0(t) - 88.99355557205206)^2 - 0.004101299716790495*(x_beads_1(t) - 82.23738275430705)^2) + 3.3325736239168364*(-0.00857208799088451*x_beads_1(t) + 0.8297148468715662)*e^(-0.004286043995442255*(x_beads_0(t) - 92.74239286245599)^2 - 0.004286043995442255*(x_beads_1(t) - 96.79261899246464)^2) + 1.035111282847064*(-0.009785869889127096*x_beads_1(t) + 0.35013372419495964)*e^(-0.004892934944563548*(x_beads_0(t) - 93.40435159562497)^2 - 0.004892934944563548*(x_beads_1(t) - 35.77951967090702)^2) + 1.2592864656875298*(-0.008433281701474546*x_beads_1(t) + 0.3879690255187708)*e^(-0.004216640850737273*(x_beads_0(t) - 94.89436749377653)^2 - 0.004216640850737273*(x_beads_1(t) - 46.00451393090961)^2) + 2.3749437283328896*(-0.0045470159754922275*x_beads_1(t) + 0.43524499785948356)*e^(-0.0022735079877461138*(x_beads_0(t) - 98.11950400663443)^2 - 0.0022735079877461138*(x_beads_1(t) - 95.72101796109635)^2) + 1.0080930617020192*(-0.0004707535612791092*x_beads_1(t) + 0.04617317287573119)*e^(-0.0002353767806395546*(x_beads_0(t) - 99.7209935789211)^2 - 0.0002353767806395546*(x_beads_1(t) - 98.08353387762301)^2))*strength_speckle