phen_hiv {qvirus} | R Documentation |
This function calculates the final quantum state and expected payoffs for two players in a quantum game based on their strategies. The function uses quantum gates and unitary transformations to simulate the game dynamics.
phen_hiv(strategy1, strategy2, alpha, beta, gamma, theta)
strategy1 |
A 2x2 matrix representing the strategy of player 1. |
strategy2 |
A 2x2 matrix representing the strategy of player 2. |
alpha |
A numeric value representing the payoff for outcome |00>. |
beta |
A numeric value representing the payoff for outcome |01>. |
gamma |
A numeric value representing the payoff for outcome |10>. |
theta |
A numeric value representing the payoff for outcome |11>. |
A list containing the final quantum state (final_state
), the payoffs
for each basis state (payoffs
), and the expected payoffs for player 1 (pi_v
)
and player 2 (pi_V
).
Özlüer Başer, B. (2022). "Analyzing the competition of HIV-1 phenotypes with quantum game theory". Gazi University Journal of Science, 35(3), 1190–1198. doi:10.35378/gujs.772616
library(qsimulatR)
strategy1 <- diag(2) # Identity matrix for strategy 1
strategy2 <- diag(2) # Identity matrix for strategy 2
alpha <- 1
beta <- 0.5
gamma <- 2
theta <- 0.1
result <- phen_hiv(strategy1, strategy2, alpha, beta, gamma, theta)
print(result)