Post Reply 
problems with MAKEMAT
12-26-2016, 10:59 PM
Post: #1
problems with MAKEMAT
Hello

CAS MODE

MAKEMAT(0,10); -> Error: Bad Argument Type" Why?
makemat(0,10); -> [[]] Why?
makeMat(0,10); -> [0,0,0,0,0,0,0,0,0,0]; // ok =)
Find all posts by this user
Quote this message in a reply
12-28-2016, 02:41 AM (This post was last modified: 12-28-2016 02:44 AM by Han.)
Post: #2
RE: problems with MAKEMAT
This was discussed in depth in another thread a long while back. There are two versions: MAKEMAT and makemat and they take different arguments since 'makemat' is a CAS-only command (with the only exception being a "constant" function). makemat( cas-function, width, height )

Example: makemat( (x,y)->x+2*y, 3, 4 )

Creates a 3x4 matrix whose \( i,j \)-th entry is \( i+2j \)

EDIT: While we are at it, MAKELIST and makelist are similarly different.

Graph 3D | QPI | SolveSys
Find all posts by this user
Quote this message in a reply
12-28-2016, 01:29 PM
Post: #3
RE: problems with MAKEMAT
I hope that google translator is correct

It is a fact that there are two versions of several commands, but in my first post I show that there are 3 versions, this complicates the coding, Do you agree?

Or at least this should be shown in HELP, if the development group does not incorporate user contributions, we are wasting time.

I hope that in a future version complete functions and commands on catalog help.

CAS MODE
makemat(0,1,10) -> [[0,0,0,0,0,0,0,0,0,0]] // Two Dimensional (i,j) // ok
makeMat(0,10) -> [0,0,0,0,0,0,0,0,0,0] // One-dimensional (i) // ok
makemat(0,10); -> [[]] // I think I should throw [0,0,0,0,0,0,0,0,0,0], To remove the third option command with M middle capital, at let's wait and see what the Mr Bernard says.

makemat(x->0,10) -> "Error: Bad Argument Value" -> [0,0,0,0,0,0,0,0,0,0]
makemat(x->0,1,10) -> [[0,0,0,0,0,0,0,0,0,0]] // ok

HOME MODE
MAKEMAT(0,1,10) -> [0,0,0,0,0,0,0,0,0,0] // ok
MAKEMAT(0,10) -> [0,0,0,0,0,0,0,0,0,0] // ok
CAS MODE
MAKEMAT(0,1,10) -> [[0,0,0,0,0,0,0,0,0,0]]
MAKEMAT(0,10) -> "Error: Bad Argument Type" -> [0,0,0,0,0,0,0,0,0,0]

Now with MAKELIST

HOME MODE
MAKELIST(X,X,5,10); ->{5,6,7,8,9,10} // ok
MAKELIST(0,X,1,10); -> {0,0,0,0,0,0,0,0,0,0} // ok
MAKELIST(0,X,10); -> "Error:" -> {0,0,0,0,0,0,0,0,0,0} // ok
CAS MODE
MAKELIST(0,X,1,10); -> {0,0,0,0,0,0,0,0,0,0} // ok
makelist(0,X,10); -> [0,0,0,0,0,0,0,0,0,0,0] // ok
makelist(0,X,1,10); -> [0] // ??? -> [[0,0,0,0,0,0,0,0,0,0]]

Project Emu48 Skins for android ► https://www.hpmuseum.org/forum/thread-14...25336.html
Find all posts by this user
Quote this message in a reply
12-28-2016, 02:42 PM
Post: #4
RE: problems with MAKEMAT
I don't think there are three versions. There is either makemat, or MAKEMAT. Anything else is automatically converted to MAKEMAT. So makeMat, MaKeMaT, etc. are all the same as MAKEMAT. Only makemat is different.

I believe Tim already responded with their intentions to remedy this issue in a different post of yours (on essentially the same topic).

Graph 3D | QPI | SolveSys
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)