windows 2000/XP will set it to 1.5x the ram, but this is a very bad way to do it. The amount of swapfile needs is based on the amount of ram. For example, if you have 1 gig of ram, you don't need a swap[file at all. but winodws would still set it at 1.5 gigs.
1.5 gigs of swapfile is lunacy.
768 swapfile with 512 is also lunacy.
basically, the less ram you have the more swapfile you will need.
For 512 MB ram I would recommend 250-300 megs for the average user. if you use heavy amounts of compressing video and newshgroup binary downloads, then youll need 512 tops.