Files
WyanMueller d2e409d10f InitalCommit
2025-11-16 10:30:26 +01:00

35 lines
952 B
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BaseCellSimulation.Enzyms.Nucleus
{
public class RNA_Polymerase_II : InternalEnzym
{
private const double EnergyCostATP = 0.3;
public RNA_Polymerase_II()
{
Km = 0.02;
Vmax = 0.8;
}
public override void ApplyChanges(CellRessources res, double dt)
{
double dM = Math.Min(rate * dt, res.Res.Protein.NTP);
dM = res.Res.Energy.ATP >= dM * EnergyCostATP ? dM : res.Res.Energy.ATP / EnergyCostATP;
res.Res.Protein.NTP -= dM;
res.Res.Protein.mRNA += dM;
res.ConsumeATP(dM * EnergyCostATP);
}
public override void ComputeRate(Resources res)
{
Michaelis_Menten(res.Protein.NTP);
rate *= res.Nucleus.ChromatinAccessibility;
}
}
}