Perfect Competition and Cost Curves