import java.io.*;
import javax.swing.*;

class cubicTest
{
 public static void main(String s[]) throws IOException
 {
   //Text cin=new Text();
   String isim;
   //System.out.print("isim = ");
   isim=JOptionPane.showInputDialog("isim = ");
   //cin.readString();
   cubicEquationofState x=new cubicEquationofState(isim,1,"Peng Robinson");
   System.out.println("equation of state name   = "+x.GasEquation);
   System.out.println("gas name   = "+x.Name);
   System.out.println("formula = "+x.Formula);
   System.out.println("Mole Weight  = "+x.MolWt);
   System.out.println("M      = "+x.M);
   System.out.println("Tfp    = "+x.Tfp);
   System.out.println("Tb     = "+x.Tb);
   System.out.println("Tc     = "+x.Tc);
   System.out.println("Pc     = "+x.Pc);
   System.out.println("Vc     = "+x.Vc);
   System.out.println("Zc     = "+x.Zc);
   System.out.println("Omega  = "+x.Omega);
   System.out.println("Dipm   = "+x.Dipm);
   System.out.println("CPVAPA = "+x.CPVAPA);
   System.out.println("CPVAPB = "+x.CPVAPB);
   System.out.println("CPVAPC = "+x.CPVAPC);
   System.out.println("CPVAPD = "+x.CPVAPD);
   System.out.println("DELHF  = "+x.DELHF);
   System.out.println("DELGF  = "+x.DELGF);
   System.out.println("VPEq   = "+x.VPEq);
   System.out.println("VPA    = "+x.VPA);
   System.out.println("VPB    = "+x.VPB);
   System.out.println("VPC    = "+x.VPC);
   System.out.println("VPD    = "+x.VPD);
   System.out.println("Tmin   = "+x.Tmin);
   System.out.println("Tmax   = "+x.Tmax);
   System.out.println("LDEN   = "+x.LDEN);
   System.out.println("TDEN   = "+x.TDEN);
   double T,P;
   //System.out.print("P = ");
   //P=cin.readDouble();
   P=Double.parseDouble(JOptionPane.showInputDialog("P = "));
   //System.out.print("T = ");
   T=Double.parseDouble(JOptionPane.showInputDialog("T = "));
   //T=cin.readDouble();
   System.out.println("V   = "+x.V(T,P));
   System.out.println("Z   = "+x.Z(T,P));
   System.out.println("P   = "+x.P(T,x.V(T,P)));
   //System.out.println("Pvc   = "+x.Pvp(T));
 }
}
