Relationship between specialization and trade