Menu

Distillation column - Flash calculation error. (NestedLoops.vb, 240)

Mariana
2014-10-29
2014-11-11
  • Mariana

    Mariana - 2014-10-29

    Hi,

    First, thanks for creating this program.

    When running the simulation for a distillation column, I am getting this error: "Flash calculation error. (NestedLoops.vb, 240)".
    Can you please give me an idea of why this is happening?
    I tried with different flash algorithms, but still getting similar errors.

    I have also used the compound creator to add 2,2,5-Trimethylheptane and Hydrogen fluoride. I filled out the "Identification" tab under Compound Properties. Should I fill the other tabs (General Properties, Vapor Pressure, Heat Capacity, etc), or will it be estimated automatically . I can see there are some checkboxes for joback calculation under General Properties tab, will this calculate the properties?

    Thanks,
    Mariana

    Thanks for your help.

     
    • Gustavo León

      Gustavo León - 2014-10-30

      Hello Mariana. Nice to meet you

      Could you send the simulation file? To give it a check :-)

      Thanks

       
      • Mariana

        Mariana - 2014-10-30

        Hi Gustavo,

        I attach the file of the debutanizer.

        Thanks

         
        • Daniel Medeiros

          Daniel Medeiros - 2014-10-30

          The last two compounds are breaking the flash calculation, you'll need to remove them. Also, the condenser and reboiler specs seem to be incorrect since they're both mass flows which will break the mass balance, right Gustavo? It may never converge with these specs, I guess.

           
  • Gregor Reichert

    Gregor Reichert - 2014-10-30

    Hi Mariana,
    your component 2,2,5 Trimethylheptane may be defined via compound creator utility in the standard way. This means that you define UNIFAC (and MODFAC) groups. This groups are automatically split into smaller Joback groups which are used to calculate most of the properties.
    In contrast to that procedure HF is not possible to be defined this way. There are no UNIFAC/MODFAC/Joback groups available to define this component. You rather define it by entering the atoms (1H ; 1F) it's consisting of. As there are no Joback groups available you need to enter all data by yourself. You should go to literature to collect component property and enter it into their fields.
    Sorry there is only the "hard way" for that component.

    Please have a look into Help of DWSIM by pressing F1-key.

    regards
    Gregor

     

    Last edit: Gregor Reichert 2014-10-30
  • Mariana

    Mariana - 2014-10-30

    Hi Gregor, thanks for your answer.

    I made the adjustments for 2,2,5 Trimethylheptane.

    But, after entering some data for HF I got two errors when trying to save this.

    I attach a screenshot that shows the errors when saving the active simulation and the component to database. This time I tried only changing the mole weight and then saving. Same happened when I changed the boiling point under general properties tab.

    Any idea why this is happening?

    Thanks,
    Mariana

     
    • Daniel Medeiros

      Daniel Medeiros - 2014-10-30

      Mariana, see if there isn't any empty textbox where it should have a number in the other tabs, then try saving the data again.

      Regards,
      Daniel

       
    • Gregor Reichert

      Gregor Reichert - 2014-10-31

      Hi Marina,
      please attach your definition files of your new components. I will have a short check whether your definition is set up properly.

      As HF is not possible to be defined by UNIFAC you will not be able to use that kind of property package. Will have to stick to some kind of EOS which utilises the critical constants of that component.

      Regards
      Gregor

       

      Last edit: Gregor Reichert 2014-10-31
      • Mariana

        Mariana - 2014-11-03

        Hi Gregor,
        First file for HF definition.

        Thanks,

        Mariana

         
        • Gregor Reichert

          Gregor Reichert - 2014-11-08

          Hi Mariana,
          this component principally is well defined. As neither Joback groups nor a UNIFAC group is availabel to define this component you defined it by the direct atom definition way. This is ok!

          As no estimation procedures for any property is available in that mode you had to deliver all properties from literature!

          It seems you fetched vapour pressure parameters from NIST database. You introduced a problem here as DWSIM is using a different logarithmic basis in the selected formula and calculated values are to some orders of magnitude wrong! In this case i usually select following work around: Calculate values from literature parameters and formula in Excel and copy them into experimental values table of that property to run a regression.

          You also missed to define vapour heat capacity dependency. You may fetch data from NIST which are available for that component.

          After you edited your component you need to save it to your user database again. Now you need to import new data into your simulation as this is not done automatically. To achieve that you go to pure component viewer, check the box to enable editing component and change a arbitrary parameter. This enables the button "restore component from database". Pressing this button will import all data of that component from database and voila - your new data are imported.

          Inspecting this component i also found a bug in DWSIM as defined atoms are not displayed in the definition table after loading the file. This will be repaired in the next update patch of DWSIM.

          Regards
          Gregor

           

          Last edit: Gregor Reichert 2014-11-08
          • Mariana

            Mariana - 2014-11-10

            Thanks Gregor.
            Trying this right now.

             
      • Mariana

        Mariana - 2014-11-03

        File for 2,2,5 Trimethylheptane definition.

        Mariana

         
        • Gregor Reichert

          Gregor Reichert - 2014-11-08

          Hi Mariana,
          this component is well defined and should work as expected. If you have any "real" data like boiling point, TC, ... available it is recommendet to replace the estimated values.
          I also recommend to enter CAS-number to enable easy jumping to NIST database by clicking the link (= label to that field)

          Gregor

           
          • Mariana

            Mariana - 2014-11-11

            Hi Gregor,

            After recalculating, I got the message of "Calculated succesfully".

            But, I got no data for both outlet streams (mass, molar, volumetric flow, etc..).
            And neither for the energy streams.

            Please refer to the attachment.

            Is this possible?

            Mariana

             

            Last edit: Mariana 2014-11-11
            • Daniel Medeiros

              Daniel Medeiros - 2014-11-11

              Mariana, can you attach the updated simulation?

               
              • Mariana

                Mariana - 2014-11-11

                ALKY3_C1006_DWSIM

                 
                • Daniel Medeiros

                  Daniel Medeiros - 2014-11-11

                  Set the solving method to stop after 5 iterations. It seems to be diverging after that for reasons unknown...

                   
                • Gregor Reichert

                  Gregor Reichert - 2014-11-11

                  Hi Mariana,
                  when i look into conections editor of the column i find streams which are not connected to the column, they even are not existing in your simulation!
                  Also initial temperature profile seems to be very low.

                  Your hydrogen fluoride component still seems to be wrong defined for vapour pressure. Please check the units of the result of the formula. At NIST the parameters are for "K" and "bar". DWSIM uses SI-Units with Pa and K respectively (please regard the hint below parameter list and with * right to the checkbox!). The same holds for heat capacity. You also should check the curve diagram by pressing the diagram button to compare it with Lee Kesler estimation. Lee Kesler usually gives values which are quite good. I did this already with parameters from NIST and got very similar results.

                  Gregor

                   
  • Mariana

    Mariana - 2014-10-30

    Thanks Daniel for your answers.

    I finally entered the data for the last two compounds and changed the condenser spec to Stream Ratio, and the Reboiler spec to Product Molar Flow Rate.
    So, the column converged.

    But, I am not getting any flow data for the product streams and also no data for the energy streams.

    Am I missing something?

    Thanks,

    Mariana

     
  • Daniel Medeiros

    Daniel Medeiros - 2014-10-31

    This worked for me, can you take a look at the differences to your simulation? I changed the specs a little bit and also removed the last two compounds.

     
  • Mariana

    Mariana - 2014-10-31

    Is the stream ratio same to reflux ratio?

     
  • Mariana

    Mariana - 2014-10-31

    The data I used for this case comes from a HYSYS run. With the specs you used, I will get product mass flows that are far away from HYSYS results.

    Also, the mass balance is not met. There are around 12000 lb/h more in the product than in the feed.

    How did you come up with the values for the reboiler and condenser specs?

    If I use those same values in my simulation and keep the last two components, it converges. But I don't get the expected results (or at least close).

    Thanks.

     
  • Daniel Medeiros

    Daniel Medeiros - 2014-10-31

    Stream Ratio is the reflux ratio for the condenser and the boilup ratio for the reboiler.

    It would be nice to compare the same results of DWSIM with HYSYS' without HF at least... I don't know if you can use Peng-Robinson with Hydrogen Fluoride, or any other thermo package... I don't know how HYSYS handles it.

     

Log in to post a comment.