asciimath / asciimathml

A new home for asciimathml
http://asciimath.org/
MIT License
958 stars 184 forks source link

Column vectors vs matrices #52

Open Phyks opened 8 years ago

Phyks commented 8 years ago

Hi,

I do not really get the difference between "column vectors" and "matrices" in http://asciimath.org/. For me, it seems both methods and inputs (((a,b),(c,d)) and [[a,b],[c,d]]) give the same result which is to define the

a b
c d

matrix.

However, according to the doc (and especially the "column vector" keyword), I would have expected it to be [[a,b],[c,d]] and ((a,c), (b,d)) (note the input as column vectors) to have the previous matrix. However, I am not sure having two different syntaxes for matrices input is a good idea though, and maybe the best solution is simply to update the doc?

Thanks!

drlippman commented 8 years ago

Yeah, I'm not sure what the docs were intending to show there. Maybe @adius can shed some light on that, as he has primarily maintains those

Phyks commented 8 years ago

Any updates on this? Thanks

adius commented 8 years ago

Mh … yeah that does not make too much sense. I guess the docs should just talk about the visual differences between the syntaxes and not the semantical. After all there are not really any semantical differences. Some authors use them in different ways, but there seems to be no common consensus, right?

Phyks commented 8 years ago

Either that or introduce a semantical difference (which may not break much actually, and would be a great addition in my opinion), as exposed in first comment. Use […] for row and (…) for column input.

It could be a great addition to ease programatically generating ASCIIMath.

adius commented 8 years ago

Yeah, I like the idea, but it's not backwards compatible and might break too much code. I don't think it's feasible…

Phyks commented 8 years ago

The current doc is contradictory between the text ("matrices" and "column vectors") and the examples given.

Thus, breaking depends on the reference. If reference is the JavaScript parser on http://asciimath.org/, then, it will break. But if reference is the text from the doc, it does not break :)

Anyways, I can offer as a solution to this issue: