Ejemplo n.º 1
0
 def setUp(self):
     reactor = aggsim.Reactor(volume_uL=1e-9 * 45, temperature_C=40)
     self.reactor = reactor
     n_monomers = aggsim.numberOfMolecules(1e-15 * 45, 1e-6 * 10)
     monomers = aggsim.ActivatableReactant('monomer', n_monomers)
     self.monomer = monomers
     reactor.addReactant(monomers)
     #print monomer.getProportionActivated(reactor.temperature)
     ensemble = aggsim.SphericalAssemblyEnsemble('ensemble',
                                                 monomers,
                                                 1.0,
                                                 packing_fraction=sp.pi /
                                                 (3 * sp.sqrt(2)))
     self.ens = ensemble
     reactor.addReactant(ensemble)
     # Nucleation
     nuc_reaction = aggsim.EnsembleNucleationReaction(
         'monomer', 'ensemble', 1e-13 * 1e-6)  # convert rate to (uM s)^-1
     reactor.addReaction(nuc_reaction)
     # Nucleation
     denuc_reaction = aggsim.EnsembleDenucleationReaction(
         'monomer', 'ensemble', 1e-3 * 1e-6)  # convert rate to (uM s)^-1
     reactor.addReaction(denuc_reaction)
     # Assembly
     asmb_reaction = aggsim.SphericalAssemblyReaction(
         'monomer', 'ensemble', 1e-8 * 1e-6)  # convert rate to (uM s)^-1
     reactor.addReaction(asmb_reaction)
     # Disassembly
     disasmb_reaction = aggsim.SphericalDisassemblyReaction(
         'monomer', 'ensemble', 1e-6 * 1e-6)  # convert rate to (uM s)^-1
     reactor.addReaction(disasmb_reaction)
Ejemplo n.º 2
0
	def setUp(self):
		reactor = aggsim.Reactor(volume_uL=1e-9*45, temperature_C=40)
		self.reactor = reactor
		n_monomers = aggsim.numberOfMolecules(1e-15 * 45, 1e-6 * 10)
		monomers = aggsim.ActivatableReactant('monomer', n_monomers)
		self.monomer = monomers
		reactor.addReactant(monomers)
		#print monomer.getProportionActivated(reactor.temperature)
		ensemble = aggsim.SphericalAssemblyEnsemble('ensemble', monomers, 1.0, packing_fraction=sp.pi/(3*sp.sqrt(2)))
		self.ens = ensemble
		reactor.addReactant(ensemble)
		# Nucleation
		nuc_reaction = aggsim.EnsembleNucleationReaction('monomer','ensemble', 1e-13 * 1e-6) # convert rate to (uM s)^-1
		reactor.addReaction(nuc_reaction)
		# Nucleation
		denuc_reaction = aggsim.EnsembleDenucleationReaction('monomer','ensemble', 1e-3 * 1e-6) # convert rate to (uM s)^-1
		reactor.addReaction(denuc_reaction)
		# Assembly
		asmb_reaction = aggsim.SphericalAssemblyReaction('monomer','ensemble', 1e-8 * 1e-6) # convert rate to (uM s)^-1
		reactor.addReaction(asmb_reaction)
		# Disassembly
		disasmb_reaction = aggsim.SphericalDisassemblyReaction('monomer','ensemble', 1e-6 * 1e-6) # convert rate to (uM s)^-1
		reactor.addReaction(disasmb_reaction)
Ejemplo n.º 3
0
		data_outs.addStream(sys.stdout)

	# Write out parameters
	data_outs.write("# Run started {}\n".format(util.timestamp()))
	data_outs.write("# Command: {}\n".format(' '.join(sys.argv)))
	data_outs.write("# Parameters:\n")
	optdict = vars(options)
	for (k,v) in optdict.items():
		data_outs.write("#\t{k}: {v}\n".format(k=k, v=v))

	# Set seed
	sp.random.seed(options.random_seed)

	# Set up reaction
	reactor = aggsim.Reactor(volume_uL=1e-9*options.volume_fL, temperature_C=options.initial_temperature_C)
	n_monomers = aggsim.numberOfMolecules(1e-15 * options.volume_fL, 1e-6 * options.initial_concentration_uM)
	monomers = aggsim.ActivatableReactant('monomer', n_monomers)
	reactor.addReactant(monomers)
	#print monomer.getProportionActivated(reactor.temperature)
	ensemble = aggsim.SphericalAssemblyEnsemble('ensemble', monomers, options.monomer_radius_nm, packing_fraction=sp.pi/(3*sp.sqrt(2)))
	reactor.addReactant(ensemble)
	# Nucleation
	nuc_reaction = aggsim.EnsembleNucleationReaction('monomer','ensemble', options.k_nucleation * 1e-6) # convert rate to (uM s)^-1
	reactor.addReaction(nuc_reaction)
	# Nucleation
	denuc_reaction = aggsim.EnsembleDenucleationReaction('monomer','ensemble', options.k_denucleation * 1e-6) # convert rate to (uM s)^-1
	reactor.addReaction(denuc_reaction)
	# Assembly
	asmb_reaction = aggsim.SphericalAssemblyReaction('monomer','ensemble', options.k_assembly * 1e-6) # convert rate to (uM s)^-1
	reactor.addReaction(asmb_reaction)
	# Disassembly
Ejemplo n.º 4
0
    # Write out parameters
    data_outs.write("# Run started {}\n".format(util.timestamp()))
    data_outs.write("# Command: {}\n".format(' '.join(sys.argv)))
    data_outs.write("# Parameters:\n")
    optdict = vars(options)
    for (k, v) in optdict.items():
        data_outs.write("#\t{k}: {v}\n".format(k=k, v=v))

    # Set seed
    sp.random.seed(options.random_seed)

    # Set up reaction
    reactor = aggsim.Reactor(volume_uL=1e-9 * options.volume_fL,
                             temperature_C=options.initial_temperature_C)
    n_monomers = aggsim.numberOfMolecules(
        1e-15 * options.volume_fL, 1e-6 * options.initial_concentration_uM)
    monomers = aggsim.ActivatableReactant('monomer', n_monomers)
    reactor.addReactant(monomers)
    #print monomer.getProportionActivated(reactor.temperature)
    ensemble = aggsim.SphericalAssemblyEnsemble('ensemble',
                                                monomers,
                                                options.monomer_radius_nm,
                                                packing_fraction=sp.pi /
                                                (3 * sp.sqrt(2)))
    reactor.addReactant(ensemble)
    # Nucleation
    nuc_reaction = aggsim.EnsembleNucleationReaction(
        'monomer', 'ensemble',
        options.k_nucleation * 1e-6)  # convert rate to (uM s)^-1
    reactor.addReaction(nuc_reaction)
    # Nucleation