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

[GSoC] Added support for Min, Max, Bra, and Ket #25552

Merged
merged 5 commits into from
Aug 19, 2023

Conversation

wermos
Copy link
Contributor

@wermos wermos commented Aug 18, 2023

References to other Issues or PRs

Addresses #19127 for the Lark-based LaTeX parser.

Brief description of what is fixed or changed

I added support for Min and Max in the Lark-based LaTeX parser. I also took this opportunity to add support for Bra and Ket notation.

Other comments

cc @sylee957 and @Upabjojr for review.

Release Notes

  • parsing
    • The Lark-based parser now supports Min, Max, and Bra and Ket.

@sympy-bot
Copy link

sympy-bot commented Aug 18, 2023

Hi, I am the SymPy bot. I'm here to help you write a release notes entry. Please read the guide on how to write release notes.

Your release notes are in good order.

Here is what the release notes will look like:

  • parsing
    • The Lark-based parser now supports Min, Max, and Bra and Ket. (#25552 by @wermos)

This will be added to https://github.com/sympy/sympy/wiki/Release-Notes-for-1.13.

Click here to see the pull request description that was parsed.
<!-- Your title above should be a short description of what
was changed. Do not include the issue number in the title. -->

#### References to other Issues or PRs
<!-- If this pull request fixes an issue, write "Fixes #NNNN" in that exact
format, e.g. "Fixes #1234" (see
https://tinyurl.com/auto-closing for more information). Also, please
write a comment on that issue linking back to this pull request once it is
open. -->
Addresses #19127 for the Lark-based LaTeX parser.

#### Brief description of what is fixed or changed
I added support for Min and Max in the Lark-based LaTeX parser. I also took this opportunity to add support for Bra and Ket notation.

#### Other comments
cc @sylee957 and @Upabjojr for review.

#### Release Notes

<!-- Write the release notes for this release below between the BEGIN and END
statements. The basic format is a bulleted list with the name of the subpackage
and the release note for this PR. For example:

* solvers
  * Added a new solver for logarithmic equations.

* functions
  * Fixed a bug with log of integers. Formerly, `log(-x)` incorrectly gave `-log(x)`.

* physics.units
  * Corrected a semantical error in the conversion between volt and statvolt which
    reported the volt as being larger than the statvolt.

or if no release note(s) should be included use:

NO ENTRY

See https://github.com/sympy/sympy/wiki/Writing-Release-Notes for more
information on how to write release notes. The bot will check your release
notes automatically to see if they are formatted correctly. -->

<!-- BEGIN RELEASE NOTES -->
* parsing
  * The Lark-based parser now supports Min, Max, and Bra and Ket.
<!-- END RELEASE NOTES -->

Update

The release notes on the wiki have been updated.

@wermos wermos changed the title Added support for min, max, bra, and ket Added support for Min, Max, Bra, and Ket Aug 18, 2023
@wermos wermos changed the title Added support for Min, Max, Bra, and Ket [GSoC] Added support for Min, Max, Bra, and Ket Aug 18, 2023
@github-actions
Copy link

github-actions bot commented Aug 18, 2023

Benchmark results from GitHub Actions

Lower numbers are good, higher numbers are bad. A ratio less than 1
means a speed up and greater than 1 means a slowdown. Green lines
beginning with + are slowdowns (the PR is slower then master or
master is slower than the previous release). Red lines beginning
with - are speedups.

Significantly changed benchmark results (PR vs master)

Significantly changed benchmark results (master vs previous release)

       before           after         ratio
     [8059df73]       [73484029]
     <sympy-1.12^0>                 
-      86.8±0.7ms       57.4±0.4ms     0.66  integrate.TimeIntegrationRisch02.time_doit(10)
-      86.7±0.8ms       56.0±0.3ms     0.65  integrate.TimeIntegrationRisch02.time_doit_risch(10)
-     7.02±0.02ms         3.77±0ms     0.54  logic.LogicSuite.time_load_file
-        2.11±0ms          653±3μs     0.31  polys.TimePREM_LinearDenseQuadraticGCD.time_op(3, 'sparse')
-     10.3±0.02ms      1.96±0.01ms     0.19  polys.TimePREM_LinearDenseQuadraticGCD.time_op(5, 'sparse')
-       372±0.8μs       82.4±0.3μs     0.22  polys.TimePREM_QuadraticNonMonicGCD.time_op(1, 'sparse')
-        4.81±0ms        361±0.5μs     0.08  polys.TimePREM_QuadraticNonMonicGCD.time_op(3, 'sparse')
-     10.6±0.05ms      1.09±0.01ms     0.10  polys.TimePREM_QuadraticNonMonicGCD.time_op(5, 'sparse')
-     6.29±0.01ms      3.95±0.02ms     0.63  polys.TimeSUBRESULTANTS_LinearDenseQuadraticGCD.time_op(2, 'sparse')
-     27.3±0.06ms      12.0±0.02ms     0.44  polys.TimeSUBRESULTANTS_LinearDenseQuadraticGCD.time_op(3, 'sparse')
-     7.04±0.01ms         1.17±0ms     0.17  polys.TimeSUBRESULTANTS_QuadraticNonMonicGCD.time_op(1, 'sparse')
-     16.3±0.01ms      9.22±0.03ms     0.57  polys.TimeSUBRESULTANTS_QuadraticNonMonicGCD.time_op(2, 'sparse')
-       211±0.3ms       70.5±0.1ms     0.33  polys.TimeSUBRESULTANTS_QuadraticNonMonicGCD.time_op(3, 'sparse')
-     6.42±0.05ms          532±1μs     0.08  polys.TimeSUBRESULTANTS_SparseGCDHighDegree.time_op(3, 'sparse')
-     27.4±0.04ms          853±1μs     0.03  polys.TimeSUBRESULTANTS_SparseGCDHighDegree.time_op(5, 'sparse')
-       618±0.9μs          196±1μs     0.32  polys.TimeSUBRESULTANTS_SparseNonMonicQuadratic.time_op(1, 'sparse')
-     6.45±0.01ms        202±0.6μs     0.03  polys.TimeSUBRESULTANTS_SparseNonMonicQuadratic.time_op(3, 'sparse')
-     16.9±0.03ms        206±0.8μs     0.01  polys.TimeSUBRESULTANTS_SparseNonMonicQuadratic.time_op(5, 'sparse')
-       168±0.8μs      88.7±0.09μs     0.53  solve.TimeMatrixOperations.time_rref(3, 0)
-       323±0.5μs        107±0.4μs     0.33  solve.TimeMatrixOperations.time_rref(4, 0)
-      31.7±0.2ms      13.7±0.04ms     0.43  solve.TimeSolveLinSys189x49.time_solve_lin_sys

Full benchmark results can be found as artifacts in GitHub Actions
(click on checks at the top of the PR).

@wermos
Copy link
Contributor Author

wermos commented Aug 19, 2023

@sylee957 I think this PR is ready to be merged now.

@sylee957 sylee957 merged commit 3fa17f2 into sympy:master Aug 19, 2023
57 checks passed
@wermos wermos deleted the latex-min-max branch September 2, 2023 12:31
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.

None yet

4 participants