rem Keywords:
rem matrix D, matrix Dm, matrix Dp, matrix PlaceSet

echo A set of places is a siphon if there exists no transition such that it has
echo at least one input arc feeding any of the places in the set and has no
echo output arcs fed by any of the places in the set.
echo That is, all transitions are such that they either have no input arcs
echo feeding the places in the set or have at least one output arc fed by one
echo of the places in the set.
echo Problem 1.
echo flag should be:
echo flag: 	1	0	0

D 6 4
0		-1	1		-1
0		0		-1	2
0		-1	1		-1	
1		0		-1	2
0		-1	1		-1
0		0		0		2

PlaceSet 6 3
1 0 0
1 0 0
0 1 0
0	1 0
0	0 1
0 0 1

done

echo Problem 2
echo This problem tests issiph with an array as the place set instead of a
echo matrix. The place set should be a siphon.

D 4 3
0		-1	1
1		0		0
0		0		-1
0		1		1

PlaceSet 4 1
1
0
1
1

done

echo Problem 3
echo Final verification - Petri net of problem 2 with a different place set.
echo This time the set should not be a siphon.
D 4 3
0		-1	1
1		0		0
0		0		-1
0		1		1

PlaceSet 4 1
1
1
1
1
done

quit
