public static string[] GetVariableNames(int numAgents, uint agentIdx) { var numOtherVars = VariableNames.Length; var variableNames = new string[numOtherVars + (numAgents * 8)]; //copies from above VariableNames.CopyTo(variableNames, 0); for (var i = 0u; i < numAgents; i++) { //ignores self agent if (i.Equals(agentIdx)) { continue; } var idxDiff = numOtherVars + (i * numOtherVars); variableNames[SOCIAL_ENCOUNTER_IDX + idxDiff] = string.Format("S{0}", i); variableNames[OTHER_EXTRINSIC_RWD_IDX + idxDiff] = string.Format("Re{0}", i); variableNames[OTHER_ST_ACT_CNT_IDX + idxDiff] = string.Format("Csa{0}", i); variableNames[OTHER_DIST_IDX + idxDiff] = string.Format("D{0}", i); variableNames[OTHER_ST_VAL_IDX + idxDiff] = string.Format("Vs{0}", i); variableNames[OTHER_ST_ACT_VAL_IDX + idxDiff] = string.Format("Qsa{0}", i); variableNames[OTHER_ST_ACT_PRED_ERR_IDX + idxDiff] = string.Format("Esa{0}", i); variableNames[OTHER_TRANS_PROB + idxDiff] = string.Format("Pssa{0}", i); } return(variableNames); }