<jupyter_start><jupyter_text>Quantitative ComparisonFor a quantitative comparison to the real molecule, let's inspect one period of oscillation.<jupyter_code>period = 215  # fs
r_e_ab = 1.27455  # angstroms
k_ab = 8.15e-4  # N / m
cl = Atom(mass_amu=35, symbol="Cl", pos=np.zeros(3), vel=np.zeros(3), prev_accel=np.zeros(3))
h = Atom(mass_amu=1, symbol="H", pos=np.array([r_e_ab * 0.75, 0.0, 0.0]), vel=np.zeros(3), prev_accel=np.zeros(3))
bond_cl_h = Bond(atom_a=cl, atom_b=h, r_e_ab=r_e_ab, k_ab=k_ab)
bond_h_cl = Bond(atom_a=h, atom_b=cl, r_e_ab=r_e_ab, k_ab=k_ab)
cl.bonds["h"] = bond_h_cl
h.bonds["cl"] = bond_cl_h
molecule = Molecule(atoms={"h": h, "cl": cl})
xs = range(period)
for _ in xs:
    molecule.update_all_atoms()
h_pos_history_x = [pos[0] for pos in h.pos_history]
cl_pos_history_x = [pos[0] for pos in cl.pos_history]
fig, ax = plt.subplots(ncols = 1, nrows = 1, figsize=(10, 5))
ax.plot(xs, h_pos_history_x, label="H")
ax.plot(xs, cl_pos_history_x, label="Cl")
ax.set_xlim(0, max(xs))
ax.set_ylabel("x position (Å)", fontsize=20)
ax.set_xlabel("time (fs)", fontsize=20)
ax.set_title(f"x position, {period} fs", fontsize=30)
plt.xticks(fontsize=15)
plt.yticks(fontsize=15)
ax.legend(fontsize=15)
period = 1000  # fs
r_e_ab = 1.27455  # angstroms
k_ab = 8.15e-4  # N / m
cl = Atom(mass_amu=35, symbol="Cl", pos=np.zeros(3), vel=np.zeros(3), prev_accel=np.zeros(3))
h = Atom(mass_amu=1, symbol="H", pos=np.array([r_e_ab * 0.75, 0.0, 0.0]), vel=np.zeros(3), prev_accel=np.zeros(3))
bond_cl_h = Bond(atom_a=cl, atom_b=h, r_e_ab=r_e_ab, k_ab=k_ab)
bond_h_cl = Bond(atom_a=h, atom_b=cl, r_e_ab=r_e_ab, k_ab=k_ab)
cl.bonds["h"] = bond_h_cl
h.bonds["cl"] = bond_cl_h
molecule = Molecule(atoms={"h": h, "cl": cl})
xs = range(period)
for _ in xs:
    molecule.update_all_atoms()
h_pos_history_x = [pos[0] for pos in h.pos_history]
cl_pos_history_x = [pos[0] for pos in cl.pos_history]
fig, ax = plt.subplots(ncols = 1, nrows = 1, figsize=(10, 5))
ax.plot(xs, h_pos_history_x, label="H")
ax.plot(xs, cl_pos_history_x, label="Cl")
ax.set_xlim(0, max(xs))
ax.set_ylabel("x position (Å)", fontsize=20)
ax.set_xlabel("time (fs)", fontsize=20)
ax.set_title(f"x position, {period} fs", fontsize=30)
plt.xticks(fontsize=15)
plt.yticks(fontsize=15)
ax.legend(fontsize=15)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.18217391304347827, 'fraction_numerical': 0.04217391304347826, 'mean_word_length': 6.304761904761905, 'pattern_counts': {'":': 4, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '277723', 'license': 'BSD-2-Clause', 'n_tokens_mistral': 1162, 'n_tokens_neox': 1088, 'n_words': 200, 'path': 'first_attempt.ipynb', 'repo_name': 'akey7/StretchDyn', 'size': '2300'}