Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## edu.princeton.repeatedgames.rgsolve.games
Class SymmetricBimatrixGame

    java.lang.Object
      edu.princeton.repeatedgames.rgsolve.games.Game
          edu.princeton.repeatedgames.rgsolve.games.SymmetricBimatrixGame

All Implemented Interfaces:
  java.io.Serializable

    public class SymmetricBimatrixGame

extends Game
implements java.io.Serializable

A class for symmetric matrix games

See Also:
  Serialized Form

Field Summary
`private double[][]` | `G` G is payoff matrix to player 1 G' is payoff matrix to player 2
`private static long` | `serialVersionUID` Serialization ID

Fields inherited from class edu.princeton.repeatedgames.rgsolve.games.Game
`description, extension`

Constructor Summary
`SymmetricBimatrixGame(double[][] G, double delta)` constructor
`SymmetricBimatrixGame(double[][] G, double delta, BitSetFixed usableActions, java.lang.String description)` constructor
`SymmetricBimatrixGame(int m, double delta)` constructor for an empty game

Method Summary
`double` | `payoff1(int a1, int a2)` payoff to player 1
`double` | `payoff2(int a1, int a2)` payoff to player 2
`void` | `setPayoff(int a1, int a2, double g)` Sets the payoff at action (a1,a2) to to payoffs (g1,g2)

Methods inherited from class edu.princeton.repeatedgames.rgsolve.games.Game
`actionUsable, copyUsableActions, delta, m, m1, m2, payoff, payoff, setActionUsable, setDescription, setDiscount, usableActionsDefined`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### serialVersionUID

    private static final long serialVersionUID

  Serialization ID

  See Also:
    Constant Field Values

### G

    private double[][] G

  G is payoff matrix to player 1 G' is payoff matrix to player 2

Constructor Detail

### SymmetricBimatrixGame

    public SymmetricBimatrixGame(int m,
                                 double delta)

  constructor for an empty game

  Parameters:
    `m` - number of actions
    `delta` - discount rate

### SymmetricBimatrixGame

    public SymmetricBimatrixGame(double[][] G,
                                 double delta)

  constructor

  Parameters:
    `G` - payoff matrix
    `delta` - discount rate

### SymmetricBimatrixGame

    public SymmetricBimatrixGame(double[][] G,
                                 double delta,
                                 BitSetFixed usableActions,
                                 java.lang.String description)

  constructor

  Parameters:
    `G` - payoff matrix
    `delta` - discount rate
    `usableActions` - actions that are usable in equilibrium
    `description` - game notes

Method Detail

### payoff1

    public double payoff1(int a1,
                          int a2)

  Description copied from class: `Game`
  payoff to player 1

  Specified by:
    `payoff1` in class `Game`
  Parameters:
    `a1` - player 1 action
    `a2` - player 2 action
  Returns:
    the payoff to player 1

### payoff2

    public double payoff2(int a1,
                          int a2)

  Description copied from class: `Game`
  payoff to player 2

  Specified by:
    `payoff2` in class `Game`
  Parameters:
    `a1` - player 1 action
    `a2` - player 2 action
  Returns:
    the payoff to player 2

### setPayoff

    public void setPayoff(int a1,
                          int a2,
                          double g)

  Sets the payoff at action (a1,a2) to to payoffs (g1,g2)

  Parameters:
    `a1` - action for player 1
    `a2` - action for player 2
    `g` - payoff to player 1 at a=(a1, a2)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD