def run_simulation(self, num_sites): voltages, concentrations, conc_labels = self.simulation_frame.get_run_simulation_settings() if not self.Q_value: self.Q_value = [1] # hack barriers = self.parameter_frame.energy_barriers """ results have the class Results found in numpy_helper_functions and has the attributes voltage, matrix_specs, ion_transport self.fitting, current and steady_state """ results_eig, results_svd, results_qr = eyring_rate_script.eyring_rate_algo(voltages, concentrations, barriers, num_barriers=num_sites, Qs=self.Q_value, Rs=self.R_value) solutes = [] for solute in results_eig[0].ion_transport: solutes.append(solute) result_toplevel.MultiPlotWindows(self, voltages, barriers, results_eig, solutes, conc_labels, "Eig results") result_toplevel.MultiPlotWindows(self, voltages, barriers, results_svd, solutes, conc_labels, "SVD results") result_toplevel.MultiPlotWindows(self, voltages, barriers, results_qr, solutes, conc_labels, "QR results")
'GFe': [10.47, -12.62, 9.68, -12.44, 6.3, -8, 10, -12, 10], 'GBa': [10.47, -12.62, 9.68, -12.44, 6.3, -8, 10, -8, 8]} voltages = range(-150, 110, 10) voltages2 = [-100, 100] dps = range(50, 150, 10) # print voltages num_barriers = 3 # results_eig, ion_conc = {'solute_1i': 0.001, 'solute_1e': 0.001} energy_barriers = {'distance': [0.25, 0.5, 0.75], 'solute_1': [8.0, -10.0, 8.0]} results_eig, results_svd = test.eyring_rate_algo(voltages, ion_conc, energy_barriers, 2, [1], [0.5, 0.9, 1, 0.5, 0.9, 0.5, 1, 0.9, 0.5], 10) print 'test1' """ results has the fields voltage matrix_spec ion_transport fitting current """ print 'test a' result_shelf = shelve.open("Results1")