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

Implementation of Bessel functions of second kind (yn) #4234

Merged
merged 6 commits into from
Nov 18, 2024

Conversation

aliciaroblesp
Copy link
Contributor

Summary

This merge request adds support for the Bessel function of the second kind (Yn) to the AMReX parser. The implementation allows users to evaluate the Yn(x) function directly in runtime expressions, enhancing the mathematical capabilities of AMReX.

Additional background

The Bessel function of the second kind is widely used in solving partial differential equations, particularly in problems involving cylindrical or spherical symmetry. Adding this function expands the parser's usability in scientific and engineering applications where such functions are essential. The implementation leverages standard mathematical libraries for accurate computation.

Checklist

The proposed changes:

  • fix a bug or incorrect behavior in AMReX
  • add new capabilities to AMReX
  • changes answers in the test suite to more than roundoff level
  • are likely to significantly affect the results of downstream AMReX users
  • include documentation in the code and/or rst files, if appropriate

@WeiqunZhang
Copy link
Member

Could you please revert the changes on comp_ellint_1 and comp_ellint_2? Could you also update the Parser section in amrex/Docs/sphinx_documentation/source/Basics.rst?

@WeiqunZhang
Copy link
Member

If I run make in amrex/Src/Base/Parser, git diff shows

$ git diff
diff --git a/Src/Base/Parser/amrex_parser.lex.nolint.H b/Src/Base/Parser/amrex_parser.lex.nolint.H
index a77f870ee1..904c5c6547 100644
--- a/Src/Base/Parser/amrex_parser.lex.nolint.H
+++ b/Src/Base/Parser/amrex_parser.lex.nolint.H
@@ -674,7 +674,7 @@ static const YY_CHAR yy_ec[256] =
 static const YY_CHAR yy_meta[49] =
     {   0,
         1,    1,    2,    1,    1,    1,    1,    1,    1,    1,
-        1,    1,    3,    3,    3,    3,    1,    1,    1,    1,
+        3,    1,    3,    3,    3,    3,    1,    1,    1,    1,
         3,    3,    1,    1,    3,    3,    3,    3,    3,    3,
         3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
         3,    3,    3,    3,    3,    3,    3,    3

So it seems that you need to run to regenerate the files.

@WeiqunZhang WeiqunZhang merged commit 4210fe0 into AMReX-Codes:development Nov 18, 2024
75 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants