You also have to include packaging costs as well, and as the pin counts go up, this gets more expensive. In some case the packaging and bonding cost more than the die! I can't really give away too much information, but I can give you some equations on figuring costs.
Total cost = (Cost of die+Cost of testing die+Cost of packaging and final test)/Final test yield
Cost of die = Cost of wafer/(Dies per wafer * Die yield)
Dies per wafer = [(pi*Wafer radius)^2/Die area] - [(pi*wafer diameter)/sqrt(2*die area)]
Die yield = wafer yield*[1+((Defects per unit area*Die area)/alpha)]^-alpha
alpha is the measure of manufacturing complexity
These are all just for straight up material and testing costs, do not include marketing, design, etc...
Total cost = (Cost of die+Cost of testing die+Cost of packaging and final test)/Final test yield
Cost of die = Cost of wafer/(Dies per wafer * Die yield)
Dies per wafer = [(pi*Wafer radius)^2/Die area] - [(pi*wafer diameter)/sqrt(2*die area)]
Die yield = wafer yield*[1+((Defects per unit area*Die area)/alpha)]^-alpha
alpha is the measure of manufacturing complexity
These are all just for straight up material and testing costs, do not include marketing, design, etc...
