Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Writing ε and Γ_c compute funs with new methods #1290

Draft
wants to merge 313 commits into
base: ku/fourier_bounce
Choose a base branch
from

Conversation

unalmis
Copy link
Collaborator

@unalmis unalmis commented Oct 3, 2024

This PR adds new compute functions for Gamma_c and effective ripple using the numerical methods in #1119.

  • Write compute funs (rename old ones by prepnding * to the compute quantity name)
  • Compare results to Effective ripple ε #1003 and Gamma_c (Nemov and Velasco et. al) Γ_c #1042
    • Matches Neo better than DESC's previous than spline implementation, except near axis where both desc implementation agree and differ from neo
  • Write new objectives (rename old as above)

Notes

I won't get to this until next week. If someone needs this before then, feel free to try out. Basically the compute function will no longer have source grid requirement, just grid requirement = meshgrid then use Bounce2D as in the examples in test/integrals on #1119.

unalmis added 30 commits May 27, 2024 00:46
…don't matter

for effective ripple and we save memory and speed, and makes differentiating easier
@unalmis unalmis added the easy Short and simple to code or review label Oct 3, 2024
@unalmis unalmis changed the base branch from master to ku/fourier_bounce October 3, 2024 05:56
@unalmis unalmis changed the title Writing neoclassical functions to use pseudospectral methods Writing ε¹ᐧ⁵ and Γ_c compute funs with new methods Oct 3, 2024
@unalmis unalmis mentioned this pull request Oct 3, 2024
3 tasks
@unalmis unalmis changed the title Writing ε¹ᐧ⁵ and Γ_c compute funs with new methods Writing ε and Γ_c compute funs with new methods Oct 3, 2024
Copy link
Contributor

github-actions bot commented Oct 3, 2024

|             benchmark_name             |         dt(%)          |         dt(s)          |        t_new(s)        |        t_old(s)        | 
| -------------------------------------- | ---------------------- | ---------------------- | ---------------------- | ---------------------- |
 test_build_transform_fft_lowres         |     +7.57 +/- 9.25     | +3.96e-02 +/- 4.84e-02 |  5.63e-01 +/- 4.8e-02  |  5.23e-01 +/- 5.4e-03  |
 test_equilibrium_init_medres            |     -0.67 +/- 1.68     | -2.76e-02 +/- 6.89e-02 |  4.07e+00 +/- 6.4e-02  |  4.10e+00 +/- 2.6e-02  |
 test_equilibrium_init_highres           |     -0.65 +/- 3.02     | -3.58e-02 +/- 1.66e-01 |  5.48e+00 +/- 3.1e-02  |  5.52e+00 +/- 1.6e-01  |
 test_objective_compile_dshape_current   |     +4.35 +/- 5.85     | +1.61e-01 +/- 2.17e-01 |  3.87e+00 +/- 3.6e-02  |  3.70e+00 +/- 2.1e-01  |
 test_objective_compute_dshape_current   |     -0.38 +/- 1.60     | -1.36e-05 +/- 5.78e-05 |  3.60e-03 +/- 5.1e-05  |  3.61e-03 +/- 2.7e-05  |
 test_objective_jac_dshape_current       |     +0.57 +/- 7.26     | +2.26e-04 +/- 2.87e-03 |  3.98e-02 +/- 1.9e-03  |  3.96e-02 +/- 2.1e-03  |
 test_perturb_2                          |     -0.11 +/- 1.99     | -1.88e-02 +/- 3.48e-01 |  1.75e+01 +/- 1.9e-01  |  1.75e+01 +/- 2.9e-01  |
 test_proximal_freeb_jac                 |     +0.01 +/- 0.98     | +8.71e-04 +/- 7.28e-02 |  7.44e+00 +/- 6.5e-02  |  7.44e+00 +/- 3.2e-02  |
 test_solve_fixed_iter                   |     -1.64 +/- 58.27    | -8.39e-02 +/- 2.98e+00 |  5.03e+00 +/- 2.1e+00  |  5.12e+00 +/- 2.1e+00  |
 test_build_transform_fft_midres         |     +1.54 +/- 3.14     | +1.03e-02 +/- 2.10e-02 |  6.77e-01 +/- 1.6e-02  |  6.67e-01 +/- 1.3e-02  |
 test_build_transform_fft_highres        |     +2.40 +/- 2.19     | +2.53e-02 +/- 2.30e-02 |  1.08e+00 +/- 1.9e-02  |  1.05e+00 +/- 1.3e-02  |
 test_equilibrium_init_lowres            |     +4.20 +/- 3.24     | +1.82e-01 +/- 1.40e-01 |  4.52e+00 +/- 1.2e-01  |  4.34e+00 +/- 7.1e-02  |
 test_objective_compile_atf              |     +7.61 +/- 4.45     | +5.98e-01 +/- 3.50e-01 |  8.46e+00 +/- 2.8e-01  |  7.86e+00 +/- 2.1e-01  |
 test_objective_compute_atf              |     +2.77 +/- 2.63     | +2.94e-04 +/- 2.80e-04 |  1.09e-02 +/- 1.9e-04  |  1.06e-02 +/- 2.1e-04  |
 test_objective_jac_atf                  |     +1.97 +/- 2.05     | +3.91e-02 +/- 4.07e-02 |  2.02e+00 +/- 2.9e-02  |  1.98e+00 +/- 2.9e-02  |
-test_perturb_1                          |    +12.59 +/- 3.02     | +1.59e+00 +/- 3.83e-01 |  1.43e+01 +/- 3.4e-01  |  1.27e+01 +/- 1.9e-01  |
 test_proximal_jac_atf                   |     +1.75 +/- 0.93     | +1.42e-01 +/- 7.54e-02 |  8.29e+00 +/- 5.9e-02  |  8.15e+00 +/- 4.7e-02  |
 test_proximal_freeb_compute             |     +2.00 +/- 1.27     | +3.71e-03 +/- 2.36e-03 |  1.89e-01 +/- 2.1e-03  |  1.85e-01 +/- 1.1e-03  |

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
easy Short and simple to code or review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants