Skip to content

Commit

Permalink
DOC: add 1D projections of the Dalitz plot
Browse files Browse the repository at this point in the history
  • Loading branch information
redeboer committed Oct 10, 2022
1 parent 5242a73 commit 3316d30
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@
"nansum",
"nbconvert",
"nbformat",
"ncols",
"noreply",
"pandoc",
"pbar",
Expand All @@ -77,9 +78,11 @@
"prereleased",
"pygments",
"redeboer",
"sharey",
"startswith",
"textwrap",
"toctree",
"wspace",
"xlabel",
"xreplace",
"xrightarrow",
Expand Down
52 changes: 52 additions & 0 deletions docs/jpsi2ksp.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -676,6 +676,19 @@
"func = create_function(dalitz_expression, backend=\"jax\")"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"tags": [
"remove-input"
]
},
"outputs": [],
"source": [
"%config InlineBackend.figure_formats = ['png']"
]
},
{
"cell_type": "code",
"execution_count": null,
Expand Down Expand Up @@ -711,6 +724,45 @@
"ax.set_ylabel(R\"$M^2\\left(K^0\\bar{p}\\right)$\")\n",
"plt.show()"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"tags": [
"remove-input"
]
},
"outputs": [],
"source": [
"%config InlineBackend.figure_formats = ['svg']"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"jupyter": {
"source_hidden": true
},
"tags": [
"hide-input",
"full-width"
]
},
"outputs": [],
"source": [
"plt.rc(\"font\", size=16)\n",
"fig, axes = plt.subplots(figsize=(18, 6), ncols=2, sharey=True)\n",
"fig.subplots_adjust(wspace=0.02)\n",
"ax1, ax2 = axes\n",
"ax1.fill_between(jnp.sqrt(X[0]), jnp.nansum(normalized_intensities, axis=0))\n",
"ax2.fill_between(jnp.sqrt(Y[:, 0]), jnp.nansum(normalized_intensities, axis=1))\n",
"ax1.set_ylabel(\"Normalized intensity (a.u.)\")\n",
"ax1.set_xlabel(R\"$M\\left(K^0\\Sigma^+\\right)$\")\n",
"ax2.set_xlabel(R\"$M\\left(K^0\\bar{p}\\right)$\")\n",
"plt.show()"
]
}
],
"metadata": {
Expand Down

0 comments on commit 3316d30

Please sign in to comment.