On Fri, 2016-07-15 at 20:47, Kurolong <twaldm...@gmail.com> wrote: > Hey Guys and Gals ^^ > I'm having trouble with Julia. Maybe one of you can help me out > The program i am writing requires the linear-equation-system-solver(command > "\") in the folder "Julia-0.4.5\share\julia\base\linalg". > Now my problem is that i need the equation solved strictly on integers, an > approximate solution is of no use to me, which is why i tried working with > the "Rational" Type. > Curiously, the solver seems to work for the Rational Type if and only if no > pivoting is required. Otherwise, the following Error is thrown: > > WARNING: pivoting only implemented for Float32, Float64, Complex64 and > Complex128 > ERROR: LoadError: OverflowError() > in * at rational.jl:188 > [inlined code] from linalg/generic.jl:471 > in reflector! at no file:0 > in A_ldiv_B! at linalg/qr.jl:346 > in \ at linalg/qr.jl:398 > in \ at linalg/dense.jl:450 > in include at boot.jl:261 > in include_from_node1 at loading.jl:320 > while loading C:\users\<username > omitted>\documents\julia-0.4.5\sg_project\v0.3\Test02.jl, in expression > starting on line 3 > > Code to reproduce the Error: > > A=[[2//1,0//1] [3//1,3//2] [1//1,3//2]] > v=[2//1,0//1] > A\v > > Now i am under the impression that i could build a relatively simple > workaround if i knew exactly where in the developer's code the actual > problem is, but i am confused by the whole organization of the thing.
This should open the editor in the right place: julia> @edit A\v If that does not work do this to look at it: julia> @less A\v Best probably monkey-patch it to work out the details, this is porgammer speak for overloading the called method Base.(\)(A::StridedMatrix, B::StridedVecOrMat). Once it works insert it back into dense.jl, rebuild, add tests, make a pull request, voila! > Building my own solver could certainly be done, but this will most likely > be ineffecient. Unfortunately, runtime is very important here, as the > method i am currently devising is supposed to be embedded in some very > expensive loops. > > I am a very unexperienced programmer and will likely not understand much > programmertalk, but i am a mathematician and will probably have little > problems in this respect. > > Maybe you have some ideas how to handle this problem. > > Thank you in advance for taking the time to look at my problem :)