From: alex lunax on
I need a symbolic function in mupad like
test(k)=
1 for k<0
2 for k=0
0 for k>0

Where can i find how to define function like this in mupad editor and then reuse it?

Thx for answer.
From: Alan Weiss on
On 6/25/2010 8:01 PM, alex lunax wrote:
> I need a symbolic function in mupad like
> test(k)=
> 1 for k<0
> 2 for k=0
> 0 for k>0
>
> Where can i find how to define function like this in mupad editor and
> then reuse it?
>
> Thx for answer.

Svetlana's approach in this post should solve your problem:
http://www.mathworks.com/matlabcentral/newsreader/view_thread/280848

Alan Weiss
MATLAB mathematical toolbox documentation