public class refData extends Object
{
//this class reads and store refrigerent data
public String refrigerantName;
public String openName;
public double R;
public double b;
public double A[];
public double B[];
public double C[];
public double K;
public double u;
public double CP;
public double aVP[];
public double G[];
public double E[];
public double F[];
public double Pc;
public double Vc;
public double Tc;
public double M;
public double X;
public double Y;

public refData(String refrigerantNamei,String openNamei,
 double Ri, double bi,
 double A1,double B1, double C1,
 double A2,double B2, double C2,
 double A3,double B3, double C3,
 double A4,double B4, double C4,
 double A5,double B5, double C5,
 double A6,double B6, double C6,
 double Ki,double ui,double CPi,
 double aVP1,double aVP2,double aVP3,double aVP4, double aVP5, double aVP6, double aVP7,double aVP8,double aVP9,double aVP10,
 double G1,double G2,double G3,double G4, double G5, double G6,
 double E1,double E2,double E3,double E4, double E5,
 double F1,double F2,double F3,double F4, double F5, double F6, double F7,double F8,double F9,double F10,
 double F11,double F12,double F13,double F14, double F15, double F16, double F17,double F18,double F19,double F20,
 double F21,double F22,double F23,double F24, double F25,
 double Pci,double Vci,double Tci,double Mi,double Yi,double Xi)
   {
   refrigerantName=refrigerantNamei;
   openName=openNamei;
   R=Ri;
   b=bi;
   A=new double[6];
   B=new double[6];
   C=new double[6];
   A[0]=A1;A[1]=A2;A[2]=A3;A[3]=A4;A[4]=A5;A[5]=A6;
   B[0]=B1;B[1]=B2;B[2]=B3;B[3]=B4;B[4]=B5;B[5]=B6;
   C[0]=C1;C[1]=C2;C[2]=C3;C[3]=C4;C[4]=C5;C[5]=C6;
   K=Ki;
   u=ui;
   CP=CPi;
   aVP=new double[10];
   aVP[0]=aVP1;aVP[1]=aVP2;aVP[2]=aVP3;aVP[3]=aVP4;aVP[4]=aVP5;
   aVP[5]=aVP6;aVP[6]=aVP7;aVP[7]=aVP8;aVP[8]=aVP9;aVP[9]=aVP10;
   G=new double[6];
   E=new double[5];
   F=new double[25];
   Pc=Pci;
   Vc=Vci;
   Tc=Tci;
   M=Mi;
   X=Xi;
   Y=Yi;
   G[0]=G1;G[1]=G2;G[2]=G3;G[3]=G4;G[4]=G5;G[5]=G6;
   E[0]=E1;E[1]=E2;E[2]=E3;E[3]=E4;E[4]=E5;
   F[0]=F1;F[1]=F2;F[2]=F3;F[3]=F4;F[4]=F5;
   F[5]=F6;F[6]=F7;F[7]=F8;F[8]=F9;F[9]=F10;
   F[10]=F11;F[11]=F12;F[12]=F13;F[13]=F14;F[14]=F15;
   F[15]=F16;F[16]=F17;F[17]=F18;F[18]=F19;F[19]=F20;
   F[20]=F21;F[21]=F22;F[22]=F23;F[23]=F24;F[24]=F25;
   }


   public String toString()
   {
   int i;
   String s="";
   s+="RN = "+refrigerantName+"\n";
   s+="RN = "+openName+"\n";
   s+="EQUATION OF STATE\n";
   s+="R="+R+"\n";
   s+="b="+b+"\n";
   s+=" A B C\n";
   for(i=0;i<A.length;i++)
   {s+=(i+1)+" "+A[i]+"\n";}
   for(i=0;i<B.length;i++)
   {s+=(i+1)+" "+B[i]+"\n";}
   for(i=0;i<C.length;i++)
   {s+=(i+1)+" "+C[i]+"\n";}
   s+="K="+K+"\n";
   s+="u="+u+"\n";
   s+="CP="+CP+"\n";
   s+="Vapor pressure equation aVp\n";
   for(i=0;i<aVP.length;i++)
   {s+=(i+1)+" "+aVP[i]+"\n";}
   s+="Ideal gas heat capacity equation G\n";
   for(i=0;i<G.length;i++)
   {s+=(i+1)+" "+G[i]+"\n";}
   s+="Saturated liquid density equation E\n";
   for(i=0;i<E.length;i++)
   {s+=(i+1)+" "+E[i]+"\n";}
   s+="Saturated vapor density equation E\n";
   for(i=0;i<F.length;i++)
   {s+=(i+1)+" "+F[i]+"\n";}
   s+="critical Parameters \n";
   s+="Pc="+Pc+"\n";
   s+="Vc="+Vc+"\n";
   s+="Tc="+Tc+"\n";
   s+="M="+M+"\n";
   s+="X="+X+"\n";
   s+="Y="+Y+"\n";
   return s;
   }
}
