-
Notifications
You must be signed in to change notification settings - Fork 13
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
Monster PR - vectors, matrices, number theory bindings #12
Open
bollu
wants to merge
40
commits into
symengine:master
Choose a base branch
from
bollu:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…convert from Int -> <various C types>
…hould happen at both interfaces
… inside a newtype
…foriegn pointers to leak memory, still crashes
…ot (Q \ {0}, (*))
…ode as well to do the same
Thanks! I'll try to review soon.
Sent from my mobile phone.
…On Dec 16, 2016 2:50 AM, "Siddharth" ***@***.***> wrote:
Sorry for the absolutely *huge* commit
Things Implemented
- Dense matrices
- some Spare matrix functions
- Vector
- some of Number Theory
TODO
- split dense matrices into a "non strictly typed" part (matrix size
not being part of the type)
- finish binding number theory, sparse matrices
- write documentation
------------------------------
You can view, comment on, or merge this pull request online at:
#12
Commit Summary
- started binding CVec
- started writing code to use Symengine exceptions, simplified code to
convert from Int -> <various C types>
- add a list of things you learnt along the way
- added error handling code so vectors dont crash on out of bounds
- implement vector with foreign pointer, started binding dense matrix
- started binding dense matrices
- added test for dense matrices
- added checks to bounds in basicvec, as isuruf said that such checks
should happen at both interfaces
- touched README so travis build is triggered
- made versions of cabal to be newer
- changed a bunch of definitions to make the code simpler
- added a typeclass called Wrapped that represents ForeignPtr's
wrapped inside a newtype
- implemented getter for matrix
- added getter for CDenseMatrix
- added dimensions access to dense matrix
- fixed get_size
- changed travis file to use the correct cabal, GHC version. BUMP
- added more dense matrix code
- bound dense matrix solves, need to write test cases
- rewrote modules to be split into separate code
- no longer allow a densematrix_new and vecbasic_new. Should be IO
- dependant typing is matrix. DenseMatrix size is now dependant typed
- made eye into typed function
- changed densematrix_get to be type level
- fully typed densematrix API
- made code referentially transparent
- add comment about debacle with densematrix_set
- continue building number theory
- implemented number theory bindings
- changed the way basicsym, densematrix is constructed to now abuse
mkForeignPtr
- edited VecBasic as well to prevent weird memory races. Hope this is
correct
- edited basic_unaryop to do the construction thing
- identity of + is crashing
- DOES NOT COMPILE: turns out memory is _not_ the problem. changed all
foriegn pointers to leak memory, still crashes
- minimal test case: create and do nothing. crashes
- found the error. divide by 0. I was assuming Q, (*) is a group, and
not (Q \ {0}, (*))
- crash fixed: removed test case that tried to invert 0. Need to
actually fix it now
- changed basicsym_binaryop to deal with exceptions. TODO: edit other
code as well to do the same
- added algebra-based test cases. Implemented det, inv, etc.
- expose transpose
File Changes
- *M* .travis.yml
<https://github.com/symengine/symengine.hs/pull/12/files#diff-0> (33)
- *M* README.md
<https://github.com/symengine/symengine.hs/pull/12/files#diff-1> (60)
- *M* src/Symengine.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-2> (265)
- *A* src/Symengine/BasicSym.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-3> (267)
- *A* src/Symengine/DenseMatrix.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-4> (346)
- *A* src/Symengine/Internal.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-5> (94)
- *A* src/Symengine/NumberTheory.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-6> (223)
- *A* src/Symengine/VecBasic.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-7> (112)
- *M* stack.yaml
<https://github.com/symengine/symengine.hs/pull/12/files#diff-8> (32)
- *M* symengine.cabal
<https://github.com/symengine/symengine.hs/pull/12/files#diff-9> (26)
- *M* test/Spec.hs
<https://github.com/symengine/symengine.hs/pull/12/files#diff-10>
(202)
Patch Links:
- https://github.com/symengine/symengine.hs/pull/12.patch
- https://github.com/symengine/symengine.hs/pull/12.diff
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#12>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABQWOk5tKUEiWAHsDZ8Da9teUFaCmhgks5rIl7agaJpZM4LPA5d>
.
|
@bollu, can you fix the travis-ci errors? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Sorry for the absolutely huge commit
Things Implemented
TODO