|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.princeton.repeatedgames.rgsolve.games.Game
edu.princeton.repeatedgames.rgsolve.games.BimatrixGame
public class BimatrixGame
This class extends Game and stores a
repeated game where the stage game payoffs are
stored as 2D arrays
| Field Summary | |
|---|---|
private double[][] |
G1
payoff matrix to player 1 |
private double[][] |
G2
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 | |
|---|---|
BimatrixGame(double[][] G1,
double[][] G2,
double delta)
constructor |
|
BimatrixGame(double[][] G1,
double[][] G2,
double delta,
BitSetFixed usableActions,
java.lang.String description)
constructor |
|
BimatrixGame(int m1,
int m2,
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 g1,
double g2)
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, setActionUsable, setDescription, setDiscount, usableActionsDefined |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final long serialVersionUID
private double[][] G1
private double[][] G2
| Constructor Detail |
|---|
public BimatrixGame(int m1,
int m2,
double delta)
m1 - number of actions to 1m2 - number of actions to 2delta - discount rate
public BimatrixGame(double[][] G1,
double[][] G2,
double delta)
G1 - payoff matrix for 1G2 - payoff matrix for 2delta - discount rate
public BimatrixGame(double[][] G1,
double[][] G2,
double delta,
BitSetFixed usableActions,
java.lang.String description)
G1 - payoff matrix for 1G2 - payoff matrix for 2delta - discount rateusableActions - actions that are usable in equilibriumdescription - game notes| Method Detail |
|---|
public double payoff1(int a1,
int a2)
Game
payoff1 in class Gamea1 - player 1 actiona2 - player 2 action
public double payoff2(int a1,
int a2)
Game
payoff2 in class Gamea1 - player 1 actiona2 - player 2 action
public void setPayoff(int a1,
int a2,
double g1,
double g2)
a1 - action for player 1a2 - action for player 2g1 - payoff to 1g2 - payoff to 2
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||