-
-
Notifications
You must be signed in to change notification settings - Fork 529
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
polish the new symbolic logic code. #545
Comments
comment:1
To do:
Then this might work:
Also, at the top of the file document that vars and vars_order are used
|
comment:2
|
comment:4
I've uploaded a new tarball that addresses all the todo's above. This should be integrated into the SAGE Note that probably sage/logic/all.py and sage/all.py will need to be modified so that the doctests |
comment:5
By the way, this shouldn't definitely stay at milestone 2.9, since it shouldn't be too difficult. |
comment:6
Some comments/ideas on this:
http://www.cs.ubc.ca/~hoos/SATLIB/Benchmarks/SAT/satformat.ps (see also ticket #418 on wrapping minisat) |
comment:7
Another comment: why using OPAREN and CPAREN as tokens? |
comment:8
Comment from the author about the new version
|
comment:9
From Pablo De Napoli:
|
Attachment: logic.hg.gz this is from chris gorecki |
This comment has been minimized.
This comment has been minimized.
comment:14
I think I managed to turn the bundle into a patch against sage-3.0.alpha4. I also tried to fiddle with the patch's header so that Chris Gorecki appears as its author. |
comment:15
While browsing the code I noticed lots of stuff that seemed overly verbose (and inefficient), e.g.
which could be summarized as
Also, the operators are passed around (and compared) as strings everywhere (sometimes '&', sometimes 'and'). I think it would be better to use
rather than having big if-then-else statements. Having a global Sorry it's taken so long to get this in, the boolean formula simplification stuff looks good, I just think some of it could be greatly improved. |
Changed keywords from none to editor_wstein |
Attachment: sekine.pdf.gz This is the referee report |
comment:17
REFEREE REPORT: |
comment:19
Chris is too busy for the next two weeks to work on this, I think. |
comment:40
Urgh. Currently this ticket already has three different patches to be applied from three different guys. I've made my case, please another one step in and review this, thanks! (The long doctests now do pass --- but there is the coverage problem, which is essentially a hen-and-egg problem: the code does not go into Sage because of the coverage, but who would work on code not being in Sage to make the coverage higher?) |
comment:41
In my experience, the motivation to increase coverage is the highest when trying to get something in. How essential is boolopt.py to the rest of the package? Could it be pushed to a separate ticket (enhancement). boolformula.py could probably be brought up to 100% without too much effort. |
comment:42
Ahh, excellent idea, this was just the input needed here. Robert, thank you very much! So now what's to do (if nobody else does it, I'll do it):
Please note that the file "logic.py" which has missing doctests according to the coverage report above is not among the new files, but already a part of Sage! |
comment:43
Georg, thanks for working on this since this is an incredible messy ticket. The main point here is that added functionality must be doctested while it is nice to increase the coverage on existing code that is being worked on. So I agree with the approach here. In addition you should open an enhancement ticket to get coverage of logic.py to 100%, too. Cheers, Michael |
Attachment: trac_545_boolformula-doctests.patch.gz Bring doctest coverage of boolformula.py up to 100% |
comment:44
Replying to @sagetrac-GeorgSWeber:
This is done by |
comment:45
So what happens here is one should apply the following in the specified order as suggested by Georg:
Now |
based on sage-3.4.2.alpha0 |
Attachment: trac_545-logic5.patch.gz based on sage-3.4.2.alpha0 |
Attachment: trac_545-latex2.patch.gz Attachment: trac_545-adjust-simplify.patch.gz based on sage-3.4.2.alpha0 |
comment:46
Apply patches in the following order:
|
comment:47
In the class BooleanFormula there is a spelling mistake in a function name, |
fix spelling mistakes |
Attachment: equivlant.patch.gz Attachment: trac_545-equivlant_rebased.patch.gz apply after the other five patches instead of "equivlant.patch" |
comment:48
Minh, thanks for your good work! Positive review to the sequence of five patches Minh mentioned. And positive review to the changes of Wilfried (I really did nothing but rebase them). The main author here is Chris Gorecki, of course. After this ticket is finally closed (Requiescat In Pacem), the next steps would be to dismiss "logic.py" (I think it becomes mostly obsolete by this patch here), add the "rest" as a logic chapter to the Sphinx documentation (probably this needs some work, but hopefully some scripts will be available to help), and finally work on/solve #5910. Cheers, gsw |
comment:49
Merged
in Sage 3.4.2.rc0. Note that there are some odd whitespace issues in those files, so if someone could take care of that at #5910 it would be splendid :) Cheers, Michael |
This is a single commit bundle, so if somebody could extract the patch and post it here it would be a good idea.
Cheers,
Michael
Component: basic arithmetic
Keywords: editor_wstein
Issue created by migration from https://trac.sagemath.org/ticket/545
The text was updated successfully, but these errors were encountered: