From e70d0ddf83609c41064ef81ea33dcbb01e34e0df Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 14:54:39 -0500 Subject: [PATCH 01/15] Minor restructuring --- docs/user-guide/gravitational-harmonics/index.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 5f1505677..abc739a48 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -59,13 +59,13 @@ manner. Here we use Chariklo as an example body and refer to Jacobi Ellipsoid mo cb_T_rotation/= 24.0 # converting to julian days (TU) cb_rot = [[0, 0, 360.0 / cb_T_rotation]] # degrees/TU -Once the central body parameters are defined, we can compute the gravitational harmonics coefficients (:math:`C_{lm}`). Here we set the -reference radius flag to `True` and ask the function to return the reference radius. More in the additional capabilities section below. +Once the central body parameters are defined, we can compute the gravitational harmonics coefficients (:math:`C_{lm}`). The output coefficients are already correctly normalized. :: c_lm, cb_radius = swiftest.clm_from_ellipsoid(mass = cb_mass, density = cb_density, a = cb_a, b = cb_b, c = cb_c, lref_radius = True) -*Note: The maximum degree is set to 6 by default to ensure computational efficiency.* +*Note: Here we set the reference radius flag to `True` and ask the function to return the reference radius. More in the +additional capabilities section below. The maximum degree is set to 6 by default to ensure computational efficiency.* Add the central body to the simulation along with the coefficients. :: From cb1827e5a498c18b4eedcdf054da16c4766c17d3 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 14:55:53 -0500 Subject: [PATCH 02/15] Lowered J2 and J4 numbers --- docs/user-guide/gravitational-harmonics/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index abc739a48..cde4b38d8 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -71,7 +71,7 @@ Add the central body to the simulation along with the coefficients. :: sim.add_body(name = 'Chariklo', mass = cb_mass, rot = cb_rot, radius = cb_radius, c_lm = c_lm) -If the :math:`J2` and :math:`J4` terms are passed as well, Swiftest ignores them and uses the :math:`C_{lm}` terms instead. +If the :math:`J_{2}` and :math:`J_{4}` terms are passed as well, Swiftest ignores them and uses the :math:`C_{lm}` terms instead. Now the user can set up the rest of the simulation as usual. :: # add other bodies and set simulation parameters From ee417ddf47449b2ca8c9556c8dd82d787d48cee2 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 14:58:43 -0500 Subject: [PATCH 03/15] Restructing --- .../gravitational-harmonics/index.rst | 46 ++----------------- 1 file changed, 4 insertions(+), 42 deletions(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index cde4b38d8..d1176d71a 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -40,7 +40,7 @@ The coefficients can be computed in a number of ways: - Manually entering the coefficients when adding the central body. (:func:`add_body `) -Computing coefficients from axes measurements +Computing Coefficients from Axes Measurements =============================================== Given the axes measurements of a body, the gravitational harmonics coefficients can be computed in a straightforward @@ -88,11 +88,11 @@ Additional Capabilities of Swiftest's Coefficient Generator Functions The output from :func:`clm_from_ellipsoid ` and :func:`clm_from_relief ` can be customised to the user's needs. Here we show some of the additional capabilities of these functions. -Setting a reference radius for the coefficients +Setting a Reference Radius for the Coefficients ------------------------------------------------- The coefficients are computed with respect to a reference radius. `SHTOOLS `__ calculates it's own radius from -the axes passed, but there are difference ways to calculate the reference radius for non-spherical bodies in the literature. As a result, Swiftest allows +the axes passed, but there are different ways to calculate the reference radius for non-spherical bodies in the literature. As a result, Swiftest allows the user to explicitly set a reference radius (``ref_radius``) which scales the coefficients accordingly. This is particularly useful when a specific radius is desired. @@ -111,7 +111,7 @@ By default, ``lref_radius`` is set to ``False``. In this case, the function only c_lm = swiftest.clm_from_ellipsoid(mass = cb_mass, density = cb_density, a = cb_a, b = cb_b, c = cb_c) -We recommend extracting the ``ref_radius`` from the function output and using it accordingly. +We recommend extracting the ``ref_radius`` from the function output and using it when adding the central body to the simulation. Combinations of Principal Axes ------------------------------- @@ -150,41 +150,3 @@ characteristic wavelength (:math:`\lambda`) of a harmonic degree (:math:`l`) to \lambda = \frac{2\pi R}{\sqrt{l(l+1)}} \lambda = R \Rightarrow l = 6 - -.. Final Steps for Running the Simulation -.. ======================================= - -.. Add other bodies to the simulation. :: - -.. # Add user-defined massive bodies -.. npl = 5 -.. density_pl = cb_density - -.. name_pl = ["SemiBody_01", "SemiBody_02", "SemiBody_03", "SemiBody_04", "SemiBody_05"] -.. a_pl = rng.uniform(250, 400, npl) -.. e_pl = rng.uniform(0.0, 0.05, npl) -.. inc_pl = rng.uniform(0.0, 10, npl) -.. capom_pl = rng.uniform(0.0, 360.0, npl) -.. omega_pl = rng.uniform(0.0, 360.0, npl) -.. capm_pl = rng.uniform(0.0, 360.0, npl) -.. R_pl = np.array([0.5, 1.0, 1.2, 0.75, 0.8]) -.. M_pl = 4.0 / 3 * np.pi * R_pl**3 * density_pl -.. Ip_pl = np.full((npl,3),0.4,) -.. rot_pl = np.zeros((npl,3)) -.. mtiny = 1.1 * np.max(M_pl) - -.. sim.add_body(name=name_pl, a=a_pl, e=e_pl, inc=inc_pl, capom=capom_pl, omega=omega_pl, capm=capm_pl, mass=M_pl, radius=R_pl, Ip=Ip_pl, rot=rot_pl) - -.. Set the parameters for the simulation and run. :: - -.. sim.set_parameter(tstart=0.0, tstop=10.0, dt=0.01, istep_out=10, dump_cadence=0, compute_conservation_values=True, mtiny=mtiny) - -.. # Run the simulation -.. sim.run() - - - - -.. .. toctree:: -.. :maxdepth: 2 -.. :hidden: \ No newline at end of file From 7fa323d1896b381ae9eacaed7134f2845c2c2328 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:00:00 -0500 Subject: [PATCH 04/15] Fixed a typo --- docs/user-guide/gravitational-harmonics/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index d1176d71a..622ed7276 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -64,7 +64,7 @@ The output coefficients are already correctly normalized. :: c_lm, cb_radius = swiftest.clm_from_ellipsoid(mass = cb_mass, density = cb_density, a = cb_a, b = cb_b, c = cb_c, lref_radius = True) -*Note: Here we set the reference radius flag to `True` and ask the function to return the reference radius. More in the +*Note: Here we set the reference radius flag to* `True` *and ask the function to return the reference radius. More in the additional capabilities section below. The maximum degree is set to 6 by default to ensure computational efficiency.* Add the central body to the simulation along with the coefficients. :: From 5743a509b5b841f862e37351ff1e0232af5306ad Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:05:34 -0500 Subject: [PATCH 05/15] Linked functions --- docs/user-guide/detailed-simulation-setup/index.rst | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/user-guide/detailed-simulation-setup/index.rst b/docs/user-guide/detailed-simulation-setup/index.rst index d5212ffbd..a646ec10d 100644 --- a/docs/user-guide/detailed-simulation-setup/index.rst +++ b/docs/user-guide/detailed-simulation-setup/index.rst @@ -31,7 +31,7 @@ The biggest body in the simulation is taken as the central body. Solar System Bodies ========================= -We can add solar system bodies to the simulation using the ``add_solar_system_body`` method. +We can add solar system bodies to the simulation using the :func:`add_solar_system_body ` method. This method uses JPL Horizons to extract the parameters. :: # Add the modern planets and the Sun using the JPL Horizons Database. @@ -51,8 +51,8 @@ We can add other small bodies too. :: User Defined Bodies ========================= -For completeness, let's also add some bodies with user defined parameters using ``sim.add_body()``. -We will randomize the initial conditions and therefore import the ``numpy.random`` module.:: +For completeness, let's also add some bodies with user defined parameters using :func:`sim.add_body `. +We will randomize the initial conditions and therefore import the `numpy.random `__ module.:: from numpy.random import default_rng rng = default_rng(seed=123) @@ -141,7 +141,7 @@ This can be done in multiple ways: sim = swiftest.Simulation(simdir = simdir, integrator = 'symba', init_cond_format = 'EL', tstart=0.0, tstop=1.0e6, dt=0.01, istep_out=100, dump_cadence=0, compute_conservation_values=True, mtiny=mtiny) -- ``sim.set_parameter()``: Set individual parameters in the simulation. The user can set one or multiple at a time. :: +- :func:`sim.set_parameter `: Set individual parameters in the simulation. The user can set one or multiple at a time. :: sim.set_parameter(tstart=0.0, tstop=1.0e6, dt=0.01, istep_out=100, dump_cadence=0, compute_conservation_values=True, mtiny=mtiny) sim.set_parameter(rmin = 0.05) @@ -149,8 +149,8 @@ This can be done in multiple ways: We now set up the simulation parameters. Here we have a simulation starting from `0.0 y` and running for `1 My = 1e6 years` with time steps of `0.01 years`. The timestep should be less than or equal to 1/10 of the orbital period of the innermost body. -The user can then write the parameters to the `param.in` file by using ``sim.write_param()``. -To see the parameters of the simulation, use ``sim.get_parameter()``. +The user can then write the parameters to the `param.in` file by using :func:`write_param `. +To see the parameters of the simulation, use :func:`sim.get_parameter `. Running the Simulation ======================== From 54519f57c09f91910751e86b39a214d66cf3bd6a Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:08:27 -0500 Subject: [PATCH 06/15] Fixed some typos --- docs/user-guide/detailed-simulation-setup/index.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/user-guide/detailed-simulation-setup/index.rst b/docs/user-guide/detailed-simulation-setup/index.rst index a646ec10d..3b0ab0279 100644 --- a/docs/user-guide/detailed-simulation-setup/index.rst +++ b/docs/user-guide/detailed-simulation-setup/index.rst @@ -88,7 +88,7 @@ Initialize orbital elements and then add the bodies. :: Cartesian Coordinates ---------------------- -The process is similar for adding bodies with Cartesian coordinates. However, the parameter `init_cond_format` must be set to `XV` before adding the bodies. +The process is similar for adding bodies with cartesian coordinates. However, the parameter `init_cond_format` must be set to `XV` before adding the bodies. The process of setting parameters is explained in the next section. Start by defining the position and velocity vectors. Here we define the orbital velocities and scale them by a random value. :: @@ -113,7 +113,7 @@ Start by defining the position and velocity vectors. Here we define the orbital sim.add_body(name=name_pl, rh=rh_pl, vh=vh_pl, mass=M_pl, radius=R_pl, Ip=Ip_pl, rot=rot_pl) -The process is similar for **test particles**. The only difference is to exclude ``mass`` and ``radius``. +The process is similar for **test particles**. They only need the orbital elements or the cartesian coordinates. Here is an example with orbital elements: :: # Add 10 user-defined test particles. From 47ad189c63e104a89c2d83f874b8d7fcc05c69c1 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:09:19 -0500 Subject: [PATCH 07/15] Fixed a typo --- docs/user-guide/gravitational-harmonics/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 622ed7276..8c0d21668 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -2,7 +2,7 @@ Gravitational Harmonics ########################## -Here, we show how to use Swiftest's Gravitational Harmonics capabilities. This is based on ``/spherical_harmonics_cb`` +Here, we show how to use Swiftest's Gravitational Harmonics capabilities. This is based on ``spherical_harmonics_cb`` in ``swiftest/examples``. Swiftest uses `SHTOOLS `__ to compute the gravitational harmonics coefficients for a given body and calculate it's associated acceleration kick. The conventions and formulae used to calculate the additional kick are described `here `__. The gravitational From 23c313103a5d24effdf8a4200bef11912e1ee577 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:11:51 -0500 Subject: [PATCH 08/15] Minor restructuring --- docs/user-guide/gravitational-harmonics/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 8c0d21668..9dc191671 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -5,7 +5,7 @@ Gravitational Harmonics Here, we show how to use Swiftest's Gravitational Harmonics capabilities. This is based on ``spherical_harmonics_cb`` in ``swiftest/examples``. Swiftest uses `SHTOOLS `__ to compute the gravitational harmonics coefficients for a given body and calculate it's associated acceleration kick. The conventions and formulae used -to calculate the additional kick are described `here `__. The gravitational +are described `here `__. The gravitational potential is given by the following equation: .. math:: From dbb396db6bcf023667da92666383398a44e1adbe Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:12:45 -0500 Subject: [PATCH 09/15] Minor restructuring --- docs/user-guide/gravitational-harmonics/index.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 9dc191671..67f41f449 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -4,8 +4,8 @@ Gravitational Harmonics Here, we show how to use Swiftest's Gravitational Harmonics capabilities. This is based on ``spherical_harmonics_cb`` in ``swiftest/examples``. Swiftest uses `SHTOOLS `__ to compute the gravitational -harmonics coefficients for a given body and calculate it's associated acceleration kick. The conventions and formulae used -are described `here `__. The gravitational +harmonics coefficients for a given body and calculate it's associated acceleration kick. The conventions and formulae used here +are described in `Weiczorek et al. (2015) `__. The gravitational potential is given by the following equation: .. math:: From 6c7521a1de1ec9ef6f909f76419a47b11964f69e Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:14:49 -0500 Subject: [PATCH 10/15] Added a section for manual addition of clm --- docs/user-guide/gravitational-harmonics/index.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 67f41f449..89a04e9fd 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -82,6 +82,14 @@ Now the user can set up the rest of the simulation as usual. :: # run the simulation sim.run() +Manually Adding the Coefficients +================================ + +If the user already has the coefficients, they can be added to the central body directly. Ensure that they are correctly normalized. :: + + c_lm = ..... # defined by the user + sim.add_body(name = 'Body', mass = cb_mass, rot = cb_rot, radius = cb_radius, c_lm = c_lm) + Additional Capabilities of Swiftest's Coefficient Generator Functions =========================================================================================== From 8468f5e410106217daa1d07a17ace01549dcb551 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:21:05 -0500 Subject: [PATCH 11/15] Added shape of clm array --- docs/user-guide/gravitational-harmonics/index.rst | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 89a04e9fd..463735413 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -85,7 +85,13 @@ Now the user can set up the rest of the simulation as usual. :: Manually Adding the Coefficients ================================ -If the user already has the coefficients, they can be added to the central body directly. Ensure that they are correctly normalized. :: +If the user already has the coefficients, they can be added to the central body directly. Ensure that they are correctly normalized and +the right shape. The dimensions of `c_lm` is `[sign, l, m]` where: +- `sign` indicates coefficients of positive (`[0]`) and negative (`[1]`) `m` and is of length 2. +- The dimension `l` corresponds to the degree of the Spherical Harmonic and is of length :math:`l_{max} + 1`. +- The dimension `m` corresponds to the order of the Spherical Harmonic and is of length :math:`l_{max} + 1`. + +:math:`l_{max}` is the highest order of the coefficients. :: c_lm = ..... # defined by the user sim.add_body(name = 'Body', mass = cb_mass, rot = cb_rot, radius = cb_radius, c_lm = c_lm) From a58ce0bc66df95d75f7c47e1f499f57c036577ce Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:21:34 -0500 Subject: [PATCH 12/15] Fixed table --- docs/user-guide/gravitational-harmonics/index.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 463735413..7110602b5 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -87,6 +87,7 @@ Manually Adding the Coefficients If the user already has the coefficients, they can be added to the central body directly. Ensure that they are correctly normalized and the right shape. The dimensions of `c_lm` is `[sign, l, m]` where: + - `sign` indicates coefficients of positive (`[0]`) and negative (`[1]`) `m` and is of length 2. - The dimension `l` corresponds to the degree of the Spherical Harmonic and is of length :math:`l_{max} + 1`. - The dimension `m` corresponds to the order of the Spherical Harmonic and is of length :math:`l_{max} + 1`. From 8978357b647c03e9a50e3afff4b8b3577138ed01 Mon Sep 17 00:00:00 2001 From: anand43 Date: Fri, 1 Mar 2024 15:22:40 -0500 Subject: [PATCH 13/15] Fixed a typo --- docs/user-guide/gravitational-harmonics/index.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics/index.rst index 7110602b5..1e5dfc4f8 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics/index.rst @@ -86,11 +86,11 @@ Manually Adding the Coefficients ================================ If the user already has the coefficients, they can be added to the central body directly. Ensure that they are correctly normalized and -the right shape. The dimensions of `c_lm` is `[sign, l, m]` where: +the right shape. The dimensions of ``c_lm`` is ``[sign, l, m]`` where: -- `sign` indicates coefficients of positive (`[0]`) and negative (`[1]`) `m` and is of length 2. -- The dimension `l` corresponds to the degree of the Spherical Harmonic and is of length :math:`l_{max} + 1`. -- The dimension `m` corresponds to the order of the Spherical Harmonic and is of length :math:`l_{max} + 1`. +- ``sign`` indicates coefficients of positive (``[0]``) and negative (``[1]``) ``m`` and is of length 2. +- The dimension ``l`` corresponds to the degree of the Spherical Harmonic and is of length :math:`l_{max} + 1`. +- The dimension ``m`` corresponds to the order of the Spherical Harmonic and is of length :math:`l_{max} + 1`. :math:`l_{max}` is the highest order of the coefficients. :: From 0c45d8d2df651b34e222fb2963e9558e2988a0f5 Mon Sep 17 00:00:00 2001 From: David Minton Date: Fri, 1 Mar 2024 19:15:30 -0500 Subject: [PATCH 14/15] Restructured the user guide and added authorship credits to the pages --- .../index.rst => basic-simulation.rst} | 4 +++- .../index.rst => detailed-simulation-setup.rst} | 2 ++ .../index.rst => gravitational-harmonics.rst} | 2 ++ docs/user-guide/index.rst | 12 ++++++------ 4 files changed, 13 insertions(+), 7 deletions(-) rename docs/user-guide/{basic-simulation/index.rst => basic-simulation.rst} (99%) rename docs/user-guide/{detailed-simulation-setup/index.rst => detailed-simulation-setup.rst} (99%) rename docs/user-guide/{gravitational-harmonics/index.rst => gravitational-harmonics.rst} (99%) diff --git a/docs/user-guide/basic-simulation/index.rst b/docs/user-guide/basic-simulation.rst similarity index 99% rename from docs/user-guide/basic-simulation/index.rst rename to docs/user-guide/basic-simulation.rst index 32bd6ffaa..e286035bf 100644 --- a/docs/user-guide/basic-simulation/index.rst +++ b/docs/user-guide/basic-simulation.rst @@ -2,6 +2,8 @@ Basic Simulation ################# +.. rubric:: by David A. Minton + Here, we will walk you through the basic features of Swiftest and using them in Python. Start with importing Swiftest. :: @@ -196,7 +198,7 @@ Here is an example where we can generate a simple plot of the semimajor axis vs. sim.data['a'].where(sim.data.particle_type != 'Central Body', drop=True).plot(x='time',hue='name') -.. image:: ../../_static/basic_simulation_a_vs_t_plot.png +.. image:: ../_static/basic_simulation_a_vs_t_plot.png This is just a simple example of what you can do with the simulation data. Xarray has a large number of built-in plotting and data processing functions. For more information, see the `Xarray documentation `__. diff --git a/docs/user-guide/detailed-simulation-setup/index.rst b/docs/user-guide/detailed-simulation-setup.rst similarity index 99% rename from docs/user-guide/detailed-simulation-setup/index.rst rename to docs/user-guide/detailed-simulation-setup.rst index 3b0ab0279..e10f3ddbe 100644 --- a/docs/user-guide/detailed-simulation-setup/index.rst +++ b/docs/user-guide/detailed-simulation-setup.rst @@ -2,6 +2,8 @@ Detailed Simulation ##################### +.. rubric:: by Kaustub Anand + Here, we will walk you through the basic features of Swiftest and using them in Python. This is based on ``/Basic_Simulation`` in ``swiftest/examples``. diff --git a/docs/user-guide/gravitational-harmonics/index.rst b/docs/user-guide/gravitational-harmonics.rst similarity index 99% rename from docs/user-guide/gravitational-harmonics/index.rst rename to docs/user-guide/gravitational-harmonics.rst index 1e5dfc4f8..2668b939e 100644 --- a/docs/user-guide/gravitational-harmonics/index.rst +++ b/docs/user-guide/gravitational-harmonics.rst @@ -2,6 +2,8 @@ Gravitational Harmonics ########################## +.. rubric:: by Kaustub Anand + Here, we show how to use Swiftest's Gravitational Harmonics capabilities. This is based on ``spherical_harmonics_cb`` in ``swiftest/examples``. Swiftest uses `SHTOOLS `__ to compute the gravitational harmonics coefficients for a given body and calculate it's associated acceleration kick. The conventions and formulae used here diff --git a/docs/user-guide/index.rst b/docs/user-guide/index.rst index faa81fdc3..db5711584 100644 --- a/docs/user-guide/index.rst +++ b/docs/user-guide/index.rst @@ -4,16 +4,16 @@ User Guide In this user guide, you will find detailed descriptions and examples that describe the many capabilities of Swiftest and how to use them. -- Setting up a :doc:`Basic Simulation ` +- Setting up a :doc:`Basic Simulation ` -- A more in-depth :doc:`Detailed Simulation Setup ` +- A more in-depth :doc:`Detailed Simulation Setup ` -- Understanding the :doc:`Gravitational Harmonics capabilities ` +- Understanding the :doc:`Gravitational Harmonics capabilities ` .. toctree:: :maxdepth: 2 :hidden: - Basic Simulation - Detailed Simulation Setup - Gravitational Harmonics \ No newline at end of file + Basic Simulation + Detailed Simulation Setup + Gravitational Harmonics \ No newline at end of file From 27b174ac6e56fc1ccd19f8078fa23471940b00b5 Mon Sep 17 00:00:00 2001 From: David Minton Date: Fri, 1 Mar 2024 19:59:02 -0500 Subject: [PATCH 15/15] Updated the github actions to get pypi upload to happen --- .github/workflows/build_wheels.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_wheels.yml b/.github/workflows/build_wheels.yml index 488180420..a6920a76c 100644 --- a/.github/workflows/build_wheels.yml +++ b/.github/workflows/build_wheels.yml @@ -6,6 +6,9 @@ on: push: branches: - master + release: + types: + - published jobs: build_wheels: @@ -48,7 +51,7 @@ jobs: url: https://pypi.org/p/swiftest permissions: id-token: write - if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') + if: github.event_name == 'release' && github.event.action == 'published' steps: - uses: actions/download-artifact@v4 with: