Post Reply 
Wronskian
02-24-2015, 12:49 AM
Post: #10
RE: Wronskian
(02-23-2015 10:51 PM)salvomic Wrote:  Another think: wronsk(f) take also the IF in the other function, as I can see, is it right?
IF TYPE(s) THEN ... after the control of s==0 and <>6: controls it if there is another value for s?

If I understand your question correctly, then the answer is no. Only one scenario is allowed: when the input f consists of a list. In CAS-view, the SIZE() command returns a real number if f is a list (whether of the form f1,f2,…,fn or [f1,f2,…,fn] or {f1,f2,…,fn} or any non-matrix type). Otherwise, SIZE() returns a list if f is a matrix. That is, if f is an m x n matrix, then SIZE(f) returns [m n]. So the first IF statement checks to see that an input was actually specified and that it necessarily a list. A symbolic matrix is just a list of lists (or, one can also think of it as a matrix). So after the first IF statement, the only possible scenario is that f is a list, or it is a list of lists. To determine which, we check the TYPE() of the SIZE() result. If the SIZE() command returned a real number, then we have a simple list (or we can think of it as a vector). Otherwise, if SIZE() is not a real number, then it could not be a simple list (likely a list of list, for example) and so we throw an error message.

Quote:EDIT: variables r, c: shouldn't they be in local?

No, they are automatically local, and local to the function (r,c)->diff(f(c), v$(r-1)) because they are simply placeholders (dummy variables).

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


Messages In This Thread
Wronskian - salvomic - 02-22-2015, 11:10 PM
RE: Wronskian - salvomic - 02-23-2015, 06:57 PM
RE: Wronskian - salvomic - 02-23-2015, 07:21 PM
RE: Wronskian - Han - 02-23-2015, 07:29 PM
RE: Wronskian - salvomic - 02-23-2015, 09:46 PM
RE: Wronskian - Han - 02-23-2015, 10:24 PM
RE: Wronskian - salvomic - 02-23-2015, 10:51 PM
RE: Wronskian - Han - 02-23-2015, 10:53 PM
RE: Wronskian - salvomic - 02-23-2015, 11:02 PM
RE: Wronskian - Han - 02-24-2015 12:49 AM
RE: Wronskian - salvomic - 02-24-2015, 06:32 AM



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