Git Product home page Git Product logo

Comments (5)

davidedc avatar davidedc commented on July 22, 2024

let's stick to 2D as you mention - get/set of a row is trivial, as matrixes are stored by rows. Get/Set of a column is less trivial. In the meantime we have a function, just transpose, get/set, then transpose again.

from algebrite.

Jean-MarieL avatar Jean-MarieL commented on July 22, 2024

Does not seems trivial to me at API level (how to set a matrix in JS ?)
BTW I hope I am not too stupid but I cannot figure out why
Algebrite.eval('[[1,2],[3,4]]').toString() gives me "[[-1,-2],[-3,-4]]" .ful CAS
Many thanks for helping me with this wonderfull CAS

from algebrite.

davidedc avatar davidedc commented on July 22, 2024

Other points I didn't think about:

  • setting a row/column should trigger a check so the number of elements in the row/column is correct
  • getting a row/column: should we get a row/column by reference or by value? (to be checked what similar sw does).

from algebrite.

Jean-MarieL avatar Jean-MarieL commented on July 22, 2024

from algebrite.

davidedc avatar davidedc commented on July 22, 2024

Hi @Jean-MarieL sorry I got confused in a previous comment. Indeed matrices are stored by row, meaning:

a=[[1,2],[3,4]]
a[1]
> [1,2]
a[2] = [5,6]
a
> [[1,2],[5,6]]

so it should be easy to get/set a row.

As for why you'd get Algebrite.eval('[[1,2],[3,4]]').toString() gives me "[[-1,-2],[-3,-4]]" that's indeed very strange. If you keep getting that result please open another issue and we'll look into that further.

from algebrite.

Related Issues (20)

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.