.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "api/gallery/astro/galactic_dynamics/plot_04_rubin_flat_rotation_curves.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr_api_gallery_astro_galactic_dynamics_plot_04_rubin_flat_rotation_curves.py: Rubin and Ford: flat galaxy rotation curves =============================================== Rubin and Ford (1970) measured the Doppler shifts of emission regions across the Andromeda galaxy, and through the 1970s they, Roberts, Whitehurst and Bosma extended such curves far past the visible disk. If the visible stars and gas were all the mass, the circular speed :math:`v_c(r)=\sqrt{GM( 4 * R_d print(f"outer-curve slope d ln v / d ln r = {np.polyfit(np.log(r_obs[outer]), np.log(v_obs[outer]), 1)[0]:+.3f} (Keplerian: -0.5)") for ri, Mi, q in zip(r_obs[::6], M_dyn[::6], ratio[::6]): print(f"r = {ri:5.1f}: M_dyn = {Mi:7.1f}, M_dyn / M_visible = {q:5.2f}") fig2, ax2 = plt.subplots(figsize=(5.5, 3.8)) ax2.plot(r_obs, M_dyn, "o", color="black", ms=4, label=r"dynamical $r v_c^2/G$") ax2.plot(r, disk_mass(r), "--", color="firebrick", label="visible disk") ax2.set_xlabel("radius r") ax2.set_ylabel("enclosed mass") ax2.set_title("Mass keeps rising where light stops") ax2.legend(fontsize=8) fig2.tight_layout() plt.show() .. image-sg:: /api/gallery/astro/galactic_dynamics/images/sphx_glr_plot_04_rubin_flat_rotation_curves_002.png :alt: Mass keeps rising where light stops :srcset: /api/gallery/astro/galactic_dynamics/images/sphx_glr_plot_04_rubin_flat_rotation_curves_002.png :class: sphx-glr-single-img .. rst-class:: sphx-glr-script-out .. code-block:: none outer-curve slope d ln v / d ln r = -0.014 (Keplerian: -0.5) r = 1.0: M_dyn = 4.5, M_dyn / M_visible = 1.69 r = 8.2: M_dyn = 114.0, M_dyn / M_visible = 2.50 r = 15.5: M_dyn = 232.9, M_dyn / M_visible = 4.02 r = 22.8: M_dyn = 346.1, M_dyn / M_visible = 5.79 r = 30.0: M_dyn = 398.6, M_dyn / M_visible = 6.65 .. GENERATED FROM PYTHON SOURCE LINES 103-107 Check ----- Beyond the optical disk the curve stays flat (slope ~0, not Keplerian -1/2), so the dynamical mass keeps growing past the visible mass. .. GENERATED FROM PYTHON SOURCE LINES 107-110 .. code-block:: Python outer_slope = np.polyfit(np.log(r_obs[outer]), np.log(v_obs[outer]), 1)[0] assert abs(outer_slope) < 0.1 assert ratio[-1] > 5 and ratio[-1] > 3 * ratio[0] .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 0.065 seconds) .. _sphx_glr_download_api_gallery_astro_galactic_dynamics_plot_04_rubin_flat_rotation_curves.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_04_rubin_flat_rotation_curves.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_04_rubin_flat_rotation_curves.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: plot_04_rubin_flat_rotation_curves.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_