%mathpiper,def="IsPositiveInteger"

IsPositiveInteger(x):= IsInteger(x) And x > 0;

%/mathpiper



%mathpiper_docs,name="IsPositiveInteger",categories="User Functions;Predicates"
*CMD IsPositiveInteger --- test for a positive integer
*STD
*CALL
	IsPositiveInteger(n)

*PARMS

{n} -- integer to test

*DESC

This function tests whether the integer {n} is (strictly) positive. The
positive integers are 1, 2, 3, 4, 5, etc. If {n} is not a integer, the
function returns {False}.

*E.G.

In> IsPositiveInteger(31);
Result: True;
In> IsPositiveInteger(-2);
Result: False;

*SEE IsNegativeInteger, IsNonZeroInteger, IsPositiveNumber
%/mathpiper_docs