Программа для расчета материального баланса процесса конвертирования медно-никелего штейна, страница 5

writeln(w,'   NiO      ! ',NiO_p:6:3,' ',(NiO_p*100/Sump):6:3,' ! ',Ni_NiO_p:6:3,' ',(Ni_NiO_p*100/Sump):6:3,

' !      -      - ! ',O_NiO_p:6:3,' ',(O_NiO_p*100/Sump):6:3,' !      -      -  ');

writeln(w,'   Ni_met   ! ',Ni_met_p:6:3,' ',(Ni_met_p*100/Sump):6:3,' ! ',Ni_met_p:6:3,' ',(Ni_met_p*100/Sump):6:3,

' !      -      - !      -      - !      -      - ');

writeln(w,'   Cu2S     ! ',Cu2S_p:6:3,' ',(Cu2S_p*100/Sump):6:3,' ! ',Cu_Cu2S_p:6:3,' ',(Cu_Cu2S_p*100/Sump):6:3,

' !      -      - ! ',S_Cu2S_p:6:3,' ',(S_Cu2S_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   Cu_met   !',Cu_met_p:6,(Cu_met_p*100/Sump):6:3,' !',Cu_met_p:6,(Cu_met_p*100/Sump):6:3,

' !      -      - !      -      - !      -      - ');

writeln(w,'   CoS      ! ',CoS_p:6:3,' ',(CoS_p*100/Sump):6:3,' ! ',Co_CoS_p:6:3,' ',(Co_CoS_p*100/Sump):6:3,

' !      -      - ! ',S_CoS_p:6:3,' ',(S_CoS_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   CoO      ! ',CoO_p:6:3,' ',(CoO_p*100/Sump):6:3,' ! ',Co_CoO_p:6:3,' ',(Co_CoO_p*100/Sump):6:3,

' !      -      - ! ',O_CoO_p:6:3,' ',(O_CoO_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   FeS      ! ',FeS_p:6:3,' ',(FeS_p*100/Sump):6:3,' !      -      - ! ',Fe_FeS_p:6:3,' ',

(Fe_FeS_p*100/Sump):6:3,' ! ',S_FeS_p:6:3,' ',(S_FeS_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   Fe3O4    ! ',Fe3O4_p:6:3,' ',(Fe3O4_p*100/Sump):6:3,' !      -      - ! ',Fe_Fe3O4_p:6:3,' ',

(Fe_Fe3O4_p*100/Sump):6:3,' ! ',O_Fe3O4_p:6:3,' ',(O_Fe3O4_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   Fe2O3    ! ',Fe2O3_p:6:3,' ',(Fe2O3_p*100/Sump):6:3,' !      -      - ! ',Fe_Fe2O3_p:6:3,' ',

(Fe_Fe2O3_p*100/Sump):6:3,' ! ',O_Fe2O3_p:6:3,' ',(O_Fe2O3_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   FeO      ! ',FeO_p:6:3,' ',(FeO_p*100/Sump):6:3,' !      -      - ! ',Fe_FeO_p:6:3,' ',

(Fe_FeO_p*100/Sump):6:3,' ! ',O_FeO_p:6:3,' ',(O_FeO_p*100/Sump):6:3,' !      -      - ');

writeln(w,'   Fe_met   ! ',Fe_met_p:6:3,' ',(Fe_met_p*100/Sump):6:3,' !      -      - ! ',Fe_met_p:6:3,' ',

(Fe_met_p*100/Sump):6:3,' !      -      - !      -      - ');

writeln(w,'   SiO2     ! ',SiO2_p:6:3,' ',(SiO2_p*100/Sump):6:3,' !      -      - !      -      - !      -      - ! ',

SiO2_p:6:3,' ',(SiO2_p*100/Sump):6:3);

writeln(w,'   Al2O3    ! ',Al2O3_p:6:3,' ',(Al2O3_p*100/Sump):6:3,' !      -      - !      -      - !      -      - ! ',

Al2O3_p:6:3,' ',(Al2O3_p*100/Sump):6:3);

writeln(w,'   CaO      ! ',CaO_p:6:3,' ',(CaO_p*100/Sump):6:3,' !      -      - !      -      - !      -      - ! ',

CaO_p:6:3,' ',(CaO_p*100/Sump):6:3);

writeln(w,'   MgO      ! ',MgO_p:6:3,' ',(MgO_p*100/Sump):6:3,' !      -      - !      -      - !      -      - ! ',

MgO_p:6:3,' ',(MgO_p*100/Sump):6:3);

writeln(w,'   K2O      ! ',K2O_p:6:3,' ',(K2O_p*100/Sump):6:3,' !      -      - !      -      - !      -      - ! ',

K2O_p:6:3,' ',(K2O_p*100/Sump):6:3);

writeln(w,'   Прочие   ! ',P_p:6:3,' ',(P_p*100/Sump):6:3,' !      -      - !      -      - !      -      - ! ',

P_p:6:3,' ',(P_p*100/Sump):6:3);

writeln(w,'------------+---------------+---------------+---------------+---------------+----------------');

write(w,'   Итого    ! ',Sump:6:3,'  100   ! ',Sump1:6:3,' ',(Sump1*100/Sump):6:3,' ! ',Sump2:6:3,' ');

writeln(w,(Sump2*100/Sump):6:3,' ! ',Sump3:6:3,' ',(Sump3*100/Sump):6:3,' ! ',Sump4:6:3,' ',(Sump4*100/Sump):6:3);

writeln(w,'---------------------------------------------------------------------------------------------');

 end;

  begin

            assign(w,'w.txt'); rewrite(w);

      Sostav_shteina;

      Sostav_flusa;

      Sostav_Kshl_Fain;

      Sostav_Gazov;

      Sostav_pyli;

     { Основная программа }

              { штейн }

      Ni3S2_os := Ni3S2_s + Ni3S2_p_s;

       Cu2S_os := Cu2S_s + Cu2S_p_s;

        CoS_os := CoS_s + CoS_p_s;

        FeS_os := FeS_s + FeS_p_s;

     Fe_met_os := Fe_met_s + Fe_met_p_s;

        FeO_os := FeO_s + FeO_p_s;

          P_os := P_s + P_p_s;

        Ni_os := 0.7331*Ni3S2_os;

        Cu_os := 0.7985*Cu2S_os;

        Co_os := 0.6477*CoS_os;

        Fe_os := 0.6353*FeS_os + Fe_met_os + 0.7773*FeO_os;

         S_os := 0.2670*Ni3S2_os + 0.2015*Cu2S_os + 0.3523*CoS_os +

                 0.3647*FeS_os;

         O_os := 0.2227*FeO_os;

              { флюс }

      z := s;

      SiO2_ofl := SiO2_fl*0.01*z + SiO2_p_fl;

      writeln(w);

      writeln(w,SiO2_p_fl:6:3,'  ', j:6:3,'    ',SiO2_fl:6:3);

     Al2O3_ofl := Al2O3_fl*0.01*z + Al2O3_p_fl;

       CaO_ofl := CaO_fl*0.01*z + CaO_p_fl;

       MgO_ofl := MgO_fl*0.01*z + MgO_p_fl;

     Fe2O3_ofl := 1.6717*Fe_fl*0.01*z + Fe2O3_p_fl;

        Fe_ofl := Fe_fl*0.01*z + Fe_Fe2O3_p;

         O_ofl := 0.3006*Fe2O3_ofl;

         P_ofl := P_fl*0.01*z + P_p_fl;

            { файнштейн }

      Ni3S2_of := Ni3S2_f - Ni3S2_p_f;

     Ni_met_of := Ni_met_f - Ni_met_p_f;

       Cu2S_of := Cu2S_f - Cu2S_p_f;

     Cu_met_of := Cu_met_f - Cu_met_p_f;

        FeS_of := FeS_f - FeS_p_f;

        CoS_of := CoS_f - CoS_p_f;

          P_of := P_f - P_p_f;

         Ni_of := 0.7331*Ni3S2_of + Ni_met_of;

         Cu_of := 0.7985*Cu2S_of + Cu_met_of;

         Co_of := 0.6477*CoS_of;

         Fe_of := 0.6353*FeS_of;

          S_of := 0.2670*Ni3S2_of + 0.2015*Cu2S_of + 0.3647*FeS_of +

                  0.3523*CoS_of;

         { конвертерный шлак }

      Ni3S2_ok := Ni3S2_k - Ni3S2_p_k;

        NiO_ok := NiO_k - NiO_p_k;

       Cu2S_ok := Cu2S_k - Cu2S_p_k;

        CoO_ok := CoO_k - CoO_p_k;