.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "auto_examples/props/plot_delta_theta.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_auto_examples_props_plot_delta_theta.py: Delta-Theta =========== Plot $\Delta \theta$ surfaces as a function of $w_+$ and $w_-$. .. GENERATED FROM PYTHON SOURCE LINES 7-35 .. rst-class:: sphx-glr-script-out .. code-block:: none /home/docs/checkouts/readthedocs.org/user_builds/pttools/checkouts/main/pttools/models/const_cs.py:681: RuntimeWarning: invalid value encountered in scalar multiply .. raw:: html


| .. code-block:: Python import os.path import numpy as np from examples.utils import FIG_DIR from pttools.analysis.plot_delta_theta import DeltaThetaPlot3D from pttools.models.bag import BagModel from pttools.models.const_cs import ConstCSModel def main(): bag = BagModel(a_s=1.1, a_b=1, V_s=1) css = 1/np.sqrt(3) - 0.01 csb = 1/np.sqrt(3) - 0.02 const_cs = ConstCSModel(a_s=1.5, a_b=1, css2=css**2, csb2=csb**2, V_s=1) plot = DeltaThetaPlot3D() plot.add(bag) plot.add(const_cs) return plot plot = main() plot.save(os.path.join(FIG_DIR, "plot_delta_theta")) if __name__ == "__main__" and "__file__" in globals(): plot.show() plot.fig() .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 1.823 seconds) **Estimated memory usage:** 263 MB .. _sphx_glr_download_auto_examples_props_plot_delta_theta.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_delta_theta.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_delta_theta.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: plot_delta_theta.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_