Newlines would be a good start, then just tailor the justification to meet the needs of your columns:
Code:
void Pressure(double initial_volume,double CO2, double temp, double volume_increment, double final_volume )
{
double b= 0.0427;
double a= 3.592;
double R= 0.08206;
double pressure = 0;
double index= initial_volume;
printf("Volume (ml)\tPressure (atm)\n");
for (index=initial_volume; index<=final_volume; index+=volume_increment)
{
pressure= (CO2*R*temp/(index)-b*CO2)-(a*(CO2*CO2)/(index*index));
printf("%11.2lf\t%14.2lf\n", initial_volume, pressure);
}
if (initial_volume>final_volume)
pressure= (CO2*R*temp/(final_volume)-b*CO2)-(a*(CO2*CO2)/(final_volume*final_volume));
printf("%11.2lf\t%14.2lf\n", final_volume, pressure);
}
Whenever possible, avoid using spaces as field formatters, they generally cause trouble when mixed with printf's formatting widths. And if you're using C, compile as C. There are times when compiling as C++ (as you're doing with that .cpp file) will result in errors even though the code is valid C.