Question: the meaning of _type and conditional

Dear people in mapleprimes,

 

>define(INT, linear, conditional(INT(a::algebraic, X::name) = a*X, _type(a, freeof(X))), INT(X::name, X::name) = (1/2)*X^2);

>INT(2*x+4, x);

x^2 + 4*x

>INT(z+x, z);

(1/2)* z ^2+ x*z

is written in the help page of maple.

This code is to make a function INT.

What it means is that if INT(a::algebraic, x::name) then this is transformed into a*X, where a is independent from x.

And, INT(X::name,X::name) is transformed into (1/2)*X^2.

 

The first of what I want to ask you is the way of use of "_type", which is not in the help page, and as for names with "_" ahead, 

it is written that "_" means internal command for Maple, so not to use it. Is it right to use a name with "_" ahead of it here?

The second of what I want to know is the way to use "conditional."

Please teach me the meaning of this.

Thanks in advance.

 

I hope you will teach me the above questions.

 

Best wishes.

 

taro

 

 

Please Wait...