<< lightsimulationext MaxPlusAndPetrinet maxplusaplus >>

MaxPlusAndPetrinet >> MaxPlusAndPetrinet > maxplusaltlinsol

maxplusaltlinsol

Max-plus algebra alternating linear solution to A⊗x=B⊗y.

Calling Sequence

[x,y,x0,r] = maxplusaltlinsol(A,B)

Parameters

A
: an input matrix of size m × p.
B
: an input matrix of size p × n .

Description

Function returns a non unique solution x and y to equation A⊗x=B⊗y,

a random initial x0 and the number of iterating r.

If there exists solution then r is finite and no solution; function returns r=1000, x=[], y=[]. For detailed, see : Cunninghame-Green, R.A., Butkovic, P.. (2003), "The equation A⊗x=B⊗y over (max,+)" , Theoretical Computer Science, vol.293, 3-12.

Examples

A=[3 -%inf 0;1 1 0;-%inf 1 2]; 
B=[1 1;3 2;3 1]; 
[x,y,x0,r]=maxplusaltlinsol(A,B) 
// Check that x and y solutions to A⊗x=B⊗y
maxplusotimes(A,x)==maxplusotimes(B,y) 
// Another solutions of x and y to A⊗x=B⊗y
[x,y,x0,r]=maxplusaltlinsol(A,B)
// Check that x and y solutions to A⊗x=B⊗y
maxplusotimes(A,x)==maxplusotimes(B,y)

Author

"Max-Plus Algebra And Petrinet Toolbox", ver. 1.1.0, February, 2013.

See Also


Report an issue
<< lightsimulationext MaxPlusAndPetrinet maxplusaplus >>