particles in a box Everything with a Single Particle

particles in a box Everything with a Single Particle preview image

1 collaborator

Default-person Luis Mayorga (Author)

Tags

Visible to everyone | Changeable by the author
Model was written in NetLogo 6.3.0 • Viewed 219 times • Downloaded 17 times • Run 0 times
Download the 'particles in a box Everything with a Single Particle' modelDownload this modelEmbed this model

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)


IMPORTANCE OF SINGLE-MOLECULE ANALYSIS IN CELLULAR BEHAVIOR

Biological systems often operate at the single-molecule level, where stochastic fluctuations play a critical role in function. In cellular environments, understanding how individual molecules transition between states is essential for interpreting key biochemical processes. For example, in patch-clamp experiments, researchers frequently analyze the behavior of a single ion channel, revealing insights into gating dynamics and membrane potential regulation. These single-molecule observations help bridge the gap between macroscopic kinetics and the intricate, probabilistic nature of molecular interactions within cells.


WHAT IS IT?

Analyzing Chemical Equilibrium and Kinetics Using a Single-Molecule Simulation

Chemical reactions occur through the stochastic movement of individual molecules. Unlike bulk kinetics, which averages molecular behavior over thousands of molecules, this simulation focuses on a single molecule to directly observe state occupancy, transition times, and their connection to equilibrium and reaction rates.

This model simulates a single molecule that can switch between two states. The states differ in standard enthalpy (H°) and entropy (S°). The height difference represents ΔH°, while the width of each sector represents ΔS°. The two sectors are separated by a barrer (Ea).


HOW IT WORKS

State Occupancy and Equilibrium

The time a molecule spends in each state reflects the probability of being in that state. Over long periods, this probability corresponds to the equilibrium constant (Keq):

Keq = (residence time in red) / (residence time in green)

Since equilibrium is governed by Gibbs free energy (ΔG), Keq can be used to estimate ΔG:

ΔG = ΔG° + RT ln(Keq)

Thus, tracking residence time in each state provides direct estimates of Keq and ΔG, offering a microscopic understanding of equilibrium.


WAITING TIME AND RATE CONSTANTS

Defining Waiting Time

The waiting time represents how long a molecule remains in a state before transitioning. This waiting time is related to the rate constant (k) for the reaction:

k₁ = 1 / (average waiting time in state 1)
k₋₁ = 1 / (average waiting time in state 2)

Using Rate Constants to Estimate Equilibrium

At equilibrium, forward and reverse transition rates balance:

k₁[A] = k₋₁[B]

Rearranging:

Keq = k₁ / k₋₁

This shows that equilibrium constants can be obtained both from state occupancy and from rate constants derived from waiting times.


ACTIVATION ENERGY (Ea) FROM RATE CONSTANTS

According to the Arrhenius equation, the rate constants follow:

k = A * exp(-Ea / (R * T))

Taking the natural logarithm:

ln(k) = ln(A) - (Ea / R) * (1 / T)

By measuring rate constants across different temperatures and plotting ln(k) vs. 1/T, the slope gives Ea/R, allowing estimation of Ea for both forward and reverse reactions:

Ea₁ = slope forward * R
Ea₋₁ = slope reverse * R

In this single molecule simulation, the estimation of the rate constants by the waiting time at different temperatures can be used to assess the Ea for the forward and reverse reaction


KEY TAKEAWAYS

  1. Time spent in each state determines Keq, which allows the estimation of ΔG.
  2. Waiting time provides rate constants k₁ and k₋₁.
  3. Rate constants can be used to estimate Keq, reinforcing equilibrium calculations.
  4. Arrhenius analysis on rate constants enables Ea estimation.

This single-molecule approach connects stochastic molecular behavior to fundamental kinetic and thermodynamic principles, providing insights into reaction equilibrium and activation energy.


COPYRIGHT AND LICENSE

Copyright 1997 Uri Wilensky.

CC BY-NC-SA 3.0

This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA.

Commercial licenses are also available. To inquire about commercial licenses, please contact Uri Wilensky at uri@northwestern.edu.

This model was created as part of the project: CONNECTED MATHEMATICS: MAKING SENSE OF COMPLEX PHENOMENA THROUGH BUILDING OBJECT-BASED PARALLEL MODELS (OBPML). The project gratefully acknowledges the support of the National Science Foundation (Applications of Advanced Technologies Program) -- grant numbers RED #9552950 and REC #9632612.

This model was converted to NetLogo as part of the projects: PARTICIPATORY SIMULATIONS: NETWORK-BASED DESIGN FOR SYSTEMS LEARNING IN CLASSROOMS and/or INTEGRATED SIMULATION AND MODELING ENVIRONMENT. The project gratefully acknowledges the support of the National Science Foundation (REPP & ROLE programs) -- grant numbers REC #9814682 and REC-0126227. Converted from StarLogoT to NetLogo, 2002.

Comments and Questions

Please start the discussion about this model! (You'll first need to log in.)

Click to Run Model

globals
[
  box-edge1
  box-edge2
  leftbox-edge
  rightbox
  floor1
  floor2
  entropy1
 ; entropy2
 ; temperature
  R
  yboltz
  enthalpy1
  ; enthalpy2
 ; scale
  Eafloor
 initialstate ; particles in initially in state 1
  ΔG
  ΔG0
  ΔG0e
  -ΔG0e
  ΔS
  ΔH
  Kin1
  Kin2
  K
  tracer
  a
  stateLeft
  stateRight
  waitingLeft
  waitingRight
  previous-state
  waitingTimes1to2
  waitingTimes2to1
  logWaitingTimes1to2
  logWaitingTimes2to1
  waitingTime
]

breed [ particles particle ]
breed [ flashes flash ]

flashes-own [birthday]

particles-own
[
  mass energy          ;; particle info
  last-collision
  state
]

to setup
  clear-all
  set waitingTimes1to2 []
  set waitingTimes2to1 []
  set logWaitingTimes1to2 []
  set logWaitingTimes2to1 []

  set-default-shape particles "circle"
  set-default-shape flashes "plane"
  set R 1.9858775 / 1000 ;constante de gases en kcal/mol/K
 ; set entropy1 0.3
  set entropy1 1 - entropy2
  set enthalpy1 0
  ifelse enthalpy1 <= enthalpy2
   [set floor1 0
     set floor2 enthalpy2 * scale] ; scale 1kcal= scale y coordenate
   [set floor2 0
     set floor1 -1 * scale * enthalpy2] ; scale 1kcal=scale y coordinate
  set Eafloor max (list floor1 floor2) + Ea * scale
 ; set initialstate 0.1
  set box-edge2 (max-pxcor)
  set box-edge1 min-pxcor + (entropy1 * max-pxcor * 2)
  set ΔH enthalpy2 - enthalpy1
  set ΔS  R * ln (entropy2 / entropy1) ;calculo entropía
  set ΔG0 ΔH - temperature * ΔS ;calculo Δ G cero teórica
  make-box
  set initialstate 1 - avance
  make-particles
  update-variables
  reset-ticks
  set a 1
end 

to go
  ask particles [ bounce ]
  ask particles [ timeInState ]


    update-variables
    update-plots
    display


    set a a + 1
  if single = true [stop]
;  if a > 1 [stop]
end 

to update-variables
  set ΔG0 ΔH - temperature * ΔS ;calculo Δ G cero teórica
  set Kin1 stateLeft;count turtles with [state = 1]
  set Kin2 stateRight; count turtles with [state = 2]
  set K Kin2 / (Kin1 + 1E-10)
  set ΔG0e (- R * temperature * ln (K + 1E-10))
  set -ΔG0e -1 * ΔG0e
  set ΔG R * temperature * ln (K + 1E-10) + ΔG0
;  set-current-plot "Waiting Time"
;  set-plot-pen-mode 1
  ; set-histogram-num-bars 10
;  histogram waitingTimes1to2  ;; Waiting time for state 1 → state 2
end 

to bounce  ;; particle procedure

 ifelse state = 1
     [
     set yboltz floor1 - scale * ln (random-float 1) * R * temperature
     if yboltz >= Eafloor
     [set xcor min-pxcor + random (max-pxcor - min-pxcor)]
     ]
     [
     set yboltz floor2 - scale * ln (random-float 1) * R * temperature
     if yboltz >= Eafloor
     [set xcor min-pxcor + random (max-pxcor - min-pxcor)]
     ]

  ifelse yboltz > max-pycor
       [set ycor  max-pycor]
       [set ycor yboltz]

  ifelse (xcor >= min-pxcor and xcor < box-edge1)
   [set state 1
    set color green]
  [set state 2
    set color red]
end 

;; Particle Procedure - Track Waiting Time Before Transitions

to timeInState
  ;; Increment time in the current state
  ifelse state = 1 [
    set stateLeft stateLeft + 1
  ]
  [
    set stateRight stateRight + 1
  ]
    ;; Increment  waiting time in the current state
  set waitingTime waitingTime + 1

  ;; Check if transition occurs and store waiting time
  if state != previous-state [
    if previous-state = 1 [
      set waitingTimes1to2 lput waitingTime waitingTimes1to2
      set logWaitingTimes1to2 lput ln waitingTime logWaitingTimes1to2
      set waitingTime 0  ;; Reset waiting time for next cycle
    ]
    if previous-state = 2 [
      set waitingTimes2to1 lput waitingTime waitingTimes2to1
      set logWaitingTimes2to1 lput ln waitingTime logWaitingTimes2to1
      set waitingTime 0  ;; Reset waiting time for next cycle
    ]
  ]

  ;; Update previous-state for next tick comparison
  set previous-state state
end 




;;;
;;; drawing procedures

to make-box

     ; white the part of the  box that is inactive
     ifelse floor1 <= floor2
     [
       ask patches with [ (pxcor > box-edge1) and (pycor < floor2) ]
     [ set pcolor white ]
     ]
     [
       ask patches with [ (pxcor < box-edge1) and (pycor < floor1) ]
     [ set pcolor white ]
     ]

       ; limite superior
    ask patches with [ pycor > max-pycor - 5 ]
    [ set pcolor blue ]

    ; limite inferior
    ask patches with [ (pycor < floor1 + 5 and pycor > floor1 ) and (pxcor <= box-edge1) ]
    [ set pcolor yellow ]

    ask patches with [ (pycor < floor2 + 5 and pycor > floor2) and (pxcor >= box-edge1) ]
    [ set pcolor yellow ]
    ; limite izquierdo
    ask patches with [ (pxcor < min-pxcor + 5) and (pycor >= floor1) ]
    [ set pcolor yellow ]

    ; limite derecho
    ask patches with [ (pxcor > max-pxcor - 5) and (pycor >= floor2) ]
    [ set pcolor yellow ]

    ; limite central
    ask patches with [ (pxcor < box-edge1 + 3 and pxcor > box-edge1 - 3) and (pycor <= Eafloor) ]
    [ set pcolor yellow ]
end 
;;;


;; creates initial particles

to make-particles
  create-particles number-of-particles
  [

    set size 15
    ifelse random-float 1 < initialstate
    [
      set xcor min-pxcor + random (box-edge1 - min-pxcor)
      set yboltz floor1 - scale * ln (random-float 1) * R * temperature
      ifelse yboltz > max-pycor
       [set ycor  max-pycor]
       [set ycor yboltz]
    ]

    [
      set xcor box-edge1 + random (box-edge2 - box-edge1)
      set yboltz floor2 - scale * ln (random-float 1) * R * temperature
      ifelse yboltz > max-pycor
       [set ycor  max-pycor]
       [set ycor yboltz]
    ]


   ifelse (xcor >= min-pxcor and xcor < box-edge1)
  [set state 1
    set color green]
  [set state 2
    set color red]
    ;;random-position

  ]
   set K count turtles with [state = 2] / (count turtles with [state = 1] + 0.00000000000000000000001)
  set ΔG0e (- R * temperature * ln (K + 0.0000000000001))
  set ΔG R * temperature * ln (K + 0.0000000000001) + ΔG0
end 




; Copyright 1997 Uri Wilensky.
; See Info tab for full copyright and license.

There are 2 versions of this model.

Uploaded by When Description Download
Luis Mayorga about 1 month ago To fit with a future paper Download this version
Luis Mayorga 3 months ago Initial upload Download this version

Attached files

File Type Description Last updated
particles in a box Everything with a Single Particle.png preview Preview for 'particles in a box Everything with a Single Particle' 3 months ago, by Luis Mayorga Download

This model does not have any ancestors.

This model does not have any descendants.