function oops(f,x,y, nx,ny,vx,vy,fx) { nx = Factors2Numbers[cachedSlot(f,x)]; ny = Factors2Numbers[cachedSlot(f,y)]; vx = value(f,x); vy = value(f,y); fx = Fx[x , y,nx,ny] return vx * vy * fx } function Product_risk(f) { return \ oops(f,"rely","acap") + oops(f,"rely","pcap") + oops(f,"cplx","acap") + \ oops(f,"cplx","pcap") + oops(f,"cplx","tool") + oops(f,"rely","pmat") + \ oops(f,"sced","cplx") + oops(f,"sced","rely") + oops(f,"sced","time") + \ oops(f,"ruse","apex") + oops(f,"ruse","ltex"); } function Schedule_risk(f) { return \ oops(f,"sced","rely") + oops(f,"sced","time") + oops(f,"sced","pvol") + \ oops(f,"sced","tool") + oops(f,"sced","acap") + oops(f,"sced","apex") + \ oops(f,"sced","pcap") + oops(f,"sced","plex") + oops(f,"sced","ltex") + \ oops(f,"sced","pmat"); } function Personnel_risk(f) { return \ oops(f,"pmat","acap") + oops(f,"stor","acap") + oops(f,"time","acap") + \ oops(f,"tool","acap") + oops(f,"tool","pcap") + oops(f,"ruse","apex") + \ oops(f,"ruse","ltex") + oops(f,"pmat","pcap") + oops(f,"stor","pcap") + \ oops(f,"time","pcap") + oops(f,"ltex","pcap") + oops(f,"pvol","plex") + \ oops(f,"sced","acap") + oops(f,"sced","apex") + oops(f,"sced","pcap") + \ oops(f,"sced","plex") + oops(f,"sced","ltex") + oops(f,"rely","acap") + \ oops(f,"rely","pcap") + oops(f,"cplx","acap") + oops(f,"cplx","pcap") + \ oops(f,"team","apex"); } function Process_risk(f) { return \ oops(f,"tool","pmat") + oops(f,"time","tool") + oops(f,"tool","pmat") + \ oops(f,"team","apex") + oops(f,"team","sced") + oops(f,"team","site") + \ oops(f,"sced","tool") + oops(f,"sced","pmat") + oops(f,"cplx","tool") + \ oops(f,"pmat","acap") + oops(f,"tool","acap") + oops(f,"tool","pcap") + \ oops(f,"pmat","pcap"); } function Platform_risk(f) { return \ oops(f,"sced","time") + oops(f,"sced","pvol") + oops(f,"stor","acap") + \ oops(f,"time","acap") + oops(f,"stor","pcap") + oops(f,"pvol","plex") + \ oops(f,"time","tool"); } function Reuse_risk(f) { return oops(f,"ruse","apex") + oops(f,"ruse","ltex"); } function Total_risk(f) { return (Schedule_risk(f) + Product_risk(f) + Personnel_risk(f) + \ Process_risk(f) + Platform_risk(f) + Reuse_risk(f))/3.73; }