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

Backport some bugfixes from SymPy #54

Merged
merged 39 commits into from
Apr 15, 2015
Merged

Backport some bugfixes from SymPy #54

merged 39 commits into from
Apr 15, 2015

Conversation

skirpichev
Copy link
Collaborator

$ git log --oneline --merges cbdd072.. --reverse|sed -n "s/.*Merge pull request #\([0-9]\{4\}\).*/- [ ] sympy\/sympy#\1/p"

last merge: 01400b0

@skirpichev skirpichev added the bug an unexpected problem or unintended behavior label Apr 12, 2015
@skirpichev skirpichev force-pushed the sympy-backports branch 2 times, most recently from 2c29fc1 to 721c94c Compare April 14, 2015 16:24
moorepants and others added 26 commits April 14, 2015 20:43
The appearance of double _ or ^ is ignored since these appear
to be handled as spaces, allowing x_first_loop to become x_{first loop}.
Fixes #2778.  Adds test.
… immediately above.

It does not appear that the direction of the limit should matter once we get a NaN or in the limit of the gamma given.
Previously `ones(3, 0).as_immutable` gave a `0x0` instead of a
`3x0` matrix.  The `0x3` case was already working: add a new test
next to the existing one.
Renames 'l' to a dummy then adds it as an argument to RootOf. This
solves an issue where systems of eqns with symbols as constants throw an
error when solving with dsolve.
Addressed TODOs requiring checks that values are integers or natural
numbers.

// edited by skirpichev
Its "NotImplementedError" rather than "NotImplemented".
Also reformat some docstrings (pep 257) and use more
common heading delimiter for Examples.

// fixed by skirpichev
moble and others added 13 commits April 15, 2015 14:08
Following smichr's advice, I'm replacing the various improperly formatted
"Example" headings to be plural, have no colon, and be underscored by
`=========`.
// is_real -> is_extended_real by skirpichev
Specifically:

Do not hardcode __call__ and __init__ to be the versions from the
'type' metaclass.
ALL metaclasses in SymPy derive from type anyway, so those that want
and need these versions can have them anyway, and those that want to
override them can do so, too.
(Singleton will want to override __call__.)

Do not check for this_bases is None.
It cannot be None anyway, it can only be ().
(Actually not a single with_metaclass makes use of that "you can omit
'object'" featurem, so coding for that case is just potential bugs for
no gain.)

Use type.__new__(metaclass, ...) instead of metaclass(...).
I am not 100% sure about the consequences of this, but I'm simply going
with the wisdom of the six guys.
Might be necessary to avoid endless recursion in some cases.
Previously `trace(MatAdd(X, Y))` was failing with TypeError
"mix of Matrix and Scalar symbols".  This was because
`trace(MatAdd(X, Y))` evaluated to `MatAdd(trace(X), trace(Y))`
but `trace(X)` and `trace(Y)` are scalars, which caused the
exception.

The fix uses `Add(trace(X), trace(Y))` instead.

Fixes #9028.  Adds tests.
Modify an existing test instead of the new one recently introduced.
skirpichev added a commit that referenced this pull request Apr 15, 2015
Backport some bugfixes from SymPy
@skirpichev skirpichev merged commit 6c2b394 into master Apr 15, 2015
@skirpichev skirpichev deleted the sympy-backports branch April 15, 2015 14:43
This was referenced Jul 15, 2016
@skirpichev skirpichev modified the milestone: 0.8.0 Sep 9, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug an unexpected problem or unintended behavior maintainability
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet