It would be great to have the REPL.jl fork submitted as a PR. Even if it is not accepted, something good will certainly come out of it.
-viral > On 20-Apr-2015, at 11:34 pm, Marcus Appelros <marcus.appel...@gmail.com> > wrote: > > Currently some modifications to REPL.jl are needed, there is a fork > made which does exactly that. > > Am trying to test some of the examples in the SJulia readme, keep in > mind that this is on a old sourcebuilt 0.4 master. > > ``` > julia> m= @ex Expand((a+b)^10) > Expand((a + b) ^ 10) > > julia> m[2] > ERROR: BoundsError() > in getindex at /home/quin/SJulia/src/mxpr_type.jl:267 > ``` > > Apparently the only method found is: > > ``` > julia> t= @ex (a+b)^10 > (a + b) ^ 10 > > julia> typeof(t) > Mxpr{Power} > > julia> tt=SJulia.mxpr(:Expand,t) > Expand((a + b) ^ 10) > > julia> ttt=typeof(tt) > Mxpr{Expand} > > julia> methods(SJulia.apprules,(ttt,)) > 1-element Array{Any,1}: > apprules(x) at /home/quin/SJulia/src/apprules.jl:9 > ``` > > Which is set to equal x. Also there's this: > > ``` > julia> function f(n);@ex Expand((a+b)^n);end > f (generic function with 1 method) > > julia> f(3) > Expand((a + b) ^ n) > ``` > > The Fibbonacci example does work. > > On 20 April 2015 at 19:14, Viral Shah <vi...@mayin.org> wrote: >> Would it be possible to install SJulia as a Julia package, and switch >> between SJulia and Julia - kind of like how we have the help> and the shell> >> prompts, which can be activated with ? and ; >> >> -viral >> >> >> On Monday, April 20, 2015 at 5:46:08 PM UTC+5:30, lapeyre....@gmail.com >> wrote: >>> >>> Here is SJulia >>> >>> https://github.com/jlapeyre/SJulia >>> >>> sjulia> f = (x^y + y^z + z^x)^3 >>> (x ^ y + y ^ z + z ^ x) ^ 3 >>> >>> sjulia> f = (x^y + y^z)^3 >>> (x ^ y + y ^ z) ^ 3 >>> >>> sjulia> g = Expand(f) >>> x ^ (3 * y) + 3 * (x ^ (2 * y)) * (y ^ z) + 3 * (x ^ y) * (y ^ (2 * z)) + >>> y ^ (3 * z) >>> >>> SJulia is very close in spirit to Mathematica (Wolfram). This is more or >>> less a language written in Julia, >>> although it can be made to communicate well with Julia. From the user's >>> perspective, there are advantages and disadvantages to >>> implementing symbolic capability as an extension to languages like Julia >>> or Python rather than as >>> another language. I think it is possible to have a language that supports >>> both. >>> >>> Also, CAS can describe various software tools that are designed to do very >>> different things. For instance, a CAS may be intended to implement more or >>> less mathematical rigor. It may have a hierarchy of computer language types >>> meant to represent mathematical objects. Or >>> it may (like Mathematica, Maple, and Maxima) be based on 'expressions' >>> that are essentially devoid of meaning. All of these distinctions, >>> particularly the latter, regarding purpose, are typically confused in >>> discussions on internet fora. >>> >>> I think that Julia is a great language for symbolic computation. Have fun! >>> --John >>> >>> >>> On Sunday, April 19, 2015 at 7:47:34 PM UTC+2, Marcus Appelros wrote: >>>> >>>> Hi Kevin, thanks for the link! From the end of that thread: >>>> >>>> "Has anybody written pure Julia symbolic math for things like: >>>> >>>> f = (x**y + y**z + z**x)**100 >>>> g = f.expand()" >>>> >>>> "As far as I know there is no Julia package which supports such symbolic >>>> expressions and manipulation." >>>> >>>> Now there is! >>>> >>>> Saw a more recent dev discussion calling for someone to write a package >>>> like this. Have looked through the package list many times and never found >>>> anything that appeared alike the vision of Equations, SymPy has some common >>>> functionality however certainly didn't start developing in Julia to use >>>> Python. >>>> >>>> Developing this code is indeed very enjoying and as more of the planned >>>> features become released a solid user base will be established, have >>>> expanded the todolist with an impelling to read the discussion in your link >>>> so as to hasten the construction of such a foundation, as per your >>>> recommendation. >>>> >>>> With love. <3