Solving two-person zero-sum games

computeIntersection | Find the intersections of two functions |

computeLinearFunction | Compute the function value f(x) of a function |

drawMinOrMaxLine | Draw the line of the max or min of all functions |

generateColors | Generates random colors for the linear functions |

generateFunctionName | Generates name for the linear function |

generateMatrixFromSaddleVector | Generates a mx2 matrix from the saddlepoints vector. |

getAllIntersections | Find all intersections of the functions |

getMaxOfRowMin | Find the maximum of the rows minima. |

getMinOfColMax | Find the minimum of the columns maxima. |

getMinOrMaxFunctionsValueForIntersections | Find the min or max functions value for each intersection |

getSaddlePointsOfGame | Find the saddlepoints of the game. |

isMatrixOfRightDimention | Check if the matrix has the right format of 2xn or mx2 |

plotSolution | Plot the graphical solution of a 2xn or mx2 matrixgame |

solveGame | Solve a two-person zero-sum game. |

solveLinearProgram | Solve the linear program of the gamematrix |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.