Skip to content
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

Matrix problem #807

Open
MagicHacker opened this issue Apr 10, 2018 · 11 comments
Open

Matrix problem #807

MagicHacker opened this issue Apr 10, 2018 · 11 comments

Comments

@MagicHacker
Copy link

Does mathquill support matrix features?

@tmilev
Copy link

tmilev commented Jun 24, 2018

From what I understand, not the main project. However, the developers at learnosity have added support here:

https://github.com/Learnosity/mathquill/tree/matrix

The learnosity build had a tiny issue (I informed them of it, I suspect they will fix it soon). Until then, I've fixed the issue in my fork (master branch):

https://github.com/tmilev/mathquill

In case you have no experience with the npm build system (as was the case with me when I first started using mathquill), you can download the built files here:

https://github.com/tmilev/mathquill/tree/master/build

Many thanks to the wonderful mathquill project!

@kavibvaidya
Copy link

@tmilev Sorry for asking this late, but I am not able to expand the matrix to other dimensions. I can not find any documentation for that either. Can you please advise?

@tmilev
Copy link

tmilev commented Mar 18, 2019

What do you mean by expand, do you want your users to be able to dynamically expand the matrices they type?

@kavibvaidya
Copy link

TL;DR: Yes.

So when I make the matrix, (say using \bmatrix), I get a 2x2 matrix. I was wondering how I can increase the dimensions of this matrix (increase cols and rows). Currently, I have a hacky way:

`
_.createBlocks = function() {

var content = prompt("Please provide the dimensions of the matrix");

dimensions = content.split("x");

num_rows = parseInt(dimensions[0]);

num_col = parseInt(dimensions[1]);

this.blocks = [];

for (var i = 0; i < num_rows; i++){

  for (var j = 0; j < num_col; j++) {

    this.blocks.push(MatrixCell(i, this));

  }

}

// this.blocks = [

//   MatrixCell(0, this),

//   MatrixCell(0, this),

//   MatrixCell(1, this),

//   MatrixCell(1, this)

// ];

};`

Note that I have some of your code in here to give you a context where I made changes. I got the idea from symbolab.

I was hoping to find a way to addCell directly as a user after I have made the matrix.

@tmilev
Copy link

tmilev commented Mar 18, 2019

The only way I know how to do this is also hacky. I am not the original author of the code: to talk to the code's creator, try talking to the guys from this branch:

[]https://github.com/Learnosity/mathquill/tree/matrix

The one way I know to modify the matrix size is by doing:

currentMathField.write('\begin{pmatrix}&& \\& &\end{pmatrix}'); //creates a 2x3 matrix, all cells empty

currentMathField.write('\begin{pmatrix}&& \\& & \\ & & \end{pmatrix}'); //creates a 3x3 matrix, all cells empty

@kavibvaidya
Copy link

kavibvaidya commented Mar 18, 2019 via email

@kallikak
Copy link

Shift-space adds a new column, shift-enter a new row.

@tmilev
Copy link

tmilev commented Mar 25, 2019

Many thanks for the information!

@ultrainstinct1987
Copy link

Is there any plan for matrix support for the official mathquill?

@kavibvaidya
Copy link

kavibvaidya commented Apr 11, 2022 via email

@ultrainstinct1987
Copy link

Sure. Thank you. Is there a way to contact you?
i have some other questions to ask

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants