# Calculate standard transformed Gibbs energy (DeltaG°') for
# glucose + ATP = glucose-6-phosphate + ADP at pH 7, 25 °C
# First add thermodynamic data for sugar phosphates (from Table 3.2 of Alberty, 2003)
mod.OBIGT("glucose-6-phosphate-2", formula = "C6H11O9P-2", G = -1763940)
mod.OBIGT("glucose-6-phosphate-1", formula = "C6H12O9P-", G = -1800590)
# Alberty (2003) doesn't have DeltaG° for neutral glucose-6-phosphate,
# so we calculate it from pKa1 = 1.5 (Degani and Halmann, 1966)
G_G6P <- -1800590 + convert(1.5, "G")
mod.OBIGT("glucose-6-phosphate", formula = "C6H13O9P", G = G_G6P)
# Calculate affinity at pH 7 with unit activities (loga = 0)
result <- phosphorylate("glucose", "ATP", const_pH = 7)
# Extract the overall affinity
A <- result$a12
# Convert affinity to Gibbs energy in kJ/mol
TK <- convert(25, "K")
deltaG_J <- convert(A, "G", T = TK)
deltaG_kJ <- deltaG_J / 1000
print(paste("DeltaG°' at pH 7:", round(deltaG_kJ, 2), "kJ/mol"))
# Example with non-standard activities
# log(a) = -3 for glucose, ATP, and products
result2 <- phosphorylate("glucose", "ATP",
loga_reactant = -5,
loga_product = -4,
loga_P_source = -3,
loga_P_remainder = -2,
const_pH = 7)
A2 <- result2$a12
deltaG2_kJ <- convert(A2, "G", T = convert(25, "K")) / 1000
print(paste("DeltaG at pH 7 with non-unit activities:",
round(deltaG2_kJ, 2), "kJ/mol"))
Run the code above in your browser using DataLab