Giter VIP home page Giter VIP logo

mfsolve's People

Contributors

byorgey avatar finleymcilwaine avatar kuribas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

mfsolve's Issues

Haddock

It'd be nice if mfsolve were documented more thoroughly. For instance, why are Exp and Log unary operators?

Error building on GHC 7.8

Math/MFSolve.hs:103:8:

    Could not find module ‘Control.Monad.Except’

The problem I think is that it picked mtl-2.1 which does not have Control.Monad.Except.

In order to support both mtl-2.1 and 2.2, you can depend on the mtl-compat package instead of depending on mtl directly: https://hackage.haskell.org/package/mtl-compat

Please add diagnostics for DepError

I sent a pull request, which is a bad implementation, but something is needed to show the user when equations go wrong.

A good improvement on the code I wrote would be to show the most recent equation as submitted---which I think means showing results before substitution (as well as or instead of results after substitution).

Feature request: usability of the Either monad

If addEquation and getKnown used the same error type, they could be used together in the Either monad, which would be convenient. As it is stands, I resort to something like the following.

    where c0 :: Either (DepError SimpleVar Double) Double
          c0 = do d1 <- addEquality noDeps (eqn p1) "c0"
                  d2 <- addEquality d1 (eqn p2)     "c0"
                  soln <- addEquality d2 (eqn p3)   "c0"
                  first (const $ UndefinedVar "c0") $ getKnown "c0" soln

Tests fail to compile for 0.3.2.1

Seems like an instance declaration was left over that has been moved into the library:

Building test suite 'test' for mfsolve-0.3.2.1..
[1 of 1] Compiling Main             ( tests/test.hs, dist/build/test/test-tmp/Main.o )

tests/test.hs:52:10: error:
    Duplicate instance declarations:
      instance (Floating n, Eq n, Ord n, Ord v) => Eq (Expr v n)
        -- Defined at tests/test.hs:52:10
      instance (Eq n, Eq v) => Eq (Expr v n) -- Defined in ‘Math.MFSolve’
   |
52 | instance (Floating n, Eq n, Ord n, Ord v) => Eq (Expr v n) where
   |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.