arg() crashes the emulator
|
02-20-2015, 11:49 AM
(This post was last modified: 02-20-2015 12:16 PM by Angus.)
Post: #3
|
|||
|
|||
RE: arg() crashes the emulator
What I tried to do is find out what are the variables of a cas function.
Say fun(a,b):=a^2/b; Arguments(fun) should give {a,b}. Initially the idea was to be able to subst() a varible to 'X' for compatibility with built in apps. Now I am just wondering if it is possible. Final goal is to get a plot() function that can be called as my_plot(fun, a) which then plots a fun(X) from the Function app. No special requirements for fun. fun may be a function of some variable or an expression. As far as I understand I would need the independant var as X because that kind of plotting is not intended. (Maybe the geometry app suits better what made me open the other thread). Edit: The need to distinguish between calling a function for an expression foo(expr) or a function foo(expr(indep)) should dimish. A program is able to find out if an argument is a function (DOM_FUNC) or an expression (DOM_SYMBOLIC) so it would be nice if it knew what variables are used by the function by itself. P.S. btw is there a reason for glueing the app (like function app) to the build in fixed variables F1..9 with indepandant X? I'm under the impression that introducing the fixed type-bound variables was a bad idea. Cutting down flexibility and causing many of the known issues and questions that arise when home/cas interact. I see that that approach was economically seductive (code-reuse) and leads to an easy to introduce calculator for the first few hours. But I consider the scenario when you have defined or calculated a function in cas and then want to use exact that thing inside am app like Function the most natural approach. Straightforward and no workarounds needed. If there are major benefits of the design the prime has I would be happy to learn. Many times I ask myself 'why did they do it this way'? Other than needing a quick solution. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 3 Guest(s)