An Asymptote image is a vector graphic, while a JPEG is a raster file. The former is built from mathematical equations while the latter contains pixels. As a result, vector graphics are generally used for illustrations, logos, and charts that need to be scaled to a variety of sizes, while raster files are generally better for photographs and web graphics.