"The cotton gin made the production of cotton highly profitable."
Yes, it did. And I've read many instances where the North expressed extreme jealously that they didn't receive the profits. Money and power for the North were the main reasons for the Civil War, not slavery as is so widely accepted...
With so much to lose on both sides of the Mason-Dixon Line, economic logic suggests that a peaceful solution to the slave issue would have made far more sense than a bloody war. Yet no solution emerged. One "economic" solution to the slave problem would be for those who objected to slavery to "buy out" the economic interest of Southern slaveholders. Under such a scheme, the federal government would purchase slaves. A major problem here was that the costs of such a scheme would have been enormous. Claudia Goldin estimates that the cost of having the government buy all the slaves in the United States in 1860, would be about $2.7 billion (1973: 85, Table 1). Obviously, such a large sum could not be paid all at once. Yet even if the payments were spread over 25 years, the annual costs of such a scheme would involve a tripling of federal government outlays (Ransom and Sutch 1990: 39-42)! The costs could be reduced substantially if instead of freeing all the slaves at once, children were left in bondage until the age of 18 or 21 (Goldin 1973:85). Yet there would remain the problem of how even those reduced costs could be distributed among various groups in the population. The cost of any "compensated" emancipation scheme was so high that even those who wished to eliminate slavery were unwilling to pay for a "buyout" of those who owned slaves.