Changeset 574
- Timestamp:
- Jul 25, 2008, 11:18:50 AM (15 years ago)
- Location:
- branches/gui
- Files:
-
- 36 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/gui/eml/heat_exchangers/DoublePipeIncr.mso
r482 r574 346 346 end 347 347 348 for i in [1:N] 348 for i in [1:N] do 349 349 350 350 if InletInner.v equal 0 … … 499 499 Lincr(1) = 0*'m'; 500 500 501 for i in [1:N] 501 for i in [1:N] do 502 502 503 503 "Incremental Length" … … 506 506 end 507 507 508 for i in [1:N] 508 for i in [1:N] do 509 509 510 510 switch innerFlowRegime … … 536 536 end 537 537 538 for i in [1:N] 538 for i in [1:N] do 539 539 540 540 switch outerFlowRegime … … 566 566 end 567 567 568 for i in [1:N] 568 for i in [1:N] do 569 569 570 570 switch innerFlowRegime … … 641 641 end 642 642 643 for i in [1:N] 643 for i in [1:N] do 644 644 645 645 switch outerFlowRegime … … 794 794 end 795 795 796 for i in [2:N] 796 for i in [2:N] do 797 797 798 798 "Incremental Enthalpy Inner Stream" … … 879 879 Outer.PressureDrop.Pd_fric(1) = 0*'kPa'; 880 880 881 for i in [1:N] 881 for i in [1:N] do 882 882 883 883 "Outer Pipe Local Pressure"# FIXME: NOZZLE PRESSURE DROP MUST BE ADDED … … 892 892 893 893 894 for i in [1:N] 894 for i in [1:N] do 895 895 896 896 "Outer Pipe Pressure Drop for friction" … … 902 902 Outer.PressureDrop.Pd_fric(Npoints) = 0*'kPa'; 903 903 904 for i in [1:N] 904 for i in [1:N] do 905 905 906 906 "Outer Pipe Local Pressure"# FIXME: NOZZLE PRESSURE DROP MUST BE ADDED … … 920 920 Inner.PressureDrop.Pd_fric(1) = 0*'kPa'; 921 921 922 for i in [1:N] 922 for i in [1:N] do 923 923 924 924 "Inner Pipe Local Pressure"# FIXME: NOZZLE PRESSURE DROP MUST BE ADDED -
branches/gui/eml/heat_exchangers/HairpinIncr.mso
r452 r574 354 354 end 355 355 356 for i in [1:N] 356 for i in [1:N] do 357 357 358 358 if InletInner.v equal 0 … … 465 465 Lincr(1) = 0*'m'; 466 466 467 for i in [1:N] 467 for i in [1:N] do 468 468 469 469 "Incremental Length" … … 472 472 end 473 473 474 for i in [1:N] 474 for i in [1:N] do 475 475 476 476 switch innerFlowRegime … … 502 502 end 503 503 504 for i in [1:N] 504 for i in [1:N] do 505 505 506 506 switch outerFlowRegime … … 532 532 end 533 533 534 for i in [1:N] 534 for i in [1:N] do 535 535 536 536 switch innerFlowRegime … … 607 607 end 608 608 609 for i in [1:N] 609 for i in [1:N] do 610 610 611 611 switch outerFlowRegime … … 685 685 end 686 686 687 for i in [2:N] 687 for i in [2:N] do 688 688 689 689 "Incremental Enthalpy Inner Stream" … … 835 835 Outer.PressureDrop.Plocal(1) = OutletOuter.P; 836 836 837 for i in [1:N] 837 for i in [1:N] do 838 838 839 839 "Outer Pipe Pressure Drop for friction" … … 948 948 Inner.PressureDrop.Plocal(1) = OutletInner.P; 949 949 950 for i in [1:N] 950 for i in [1:N] do 951 951 952 952 "Inner Pipe Pressure Drop for friction" … … 1040 1040 +UpperPipe.Outer.PressureDrop.Pd_fric(1); 1041 1041 1042 for i in [1:N] 1042 for i in [1:N] do 1043 1043 1044 1044 "Outer Pipe Local Pressure"# FIXME: NOZZLE PRESSURE DROP MUST BE ADDED -
branches/gui/eml/heat_exchangers/HeatExchangerDetailed.mso
r492 r574 470 470 471 471 "Shell Side Pressure Drop Friction Factor" 472 Shell.PressureDrop.FricFactor=48*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -1;472 Shell.PressureDrop.FricFactor=48*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-1); 473 473 474 474 when Shell.HeatTransfer.Re > 10 switchto "range2"; … … 477 477 478 478 "Ji Factor" 479 Ji =1.36*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.657;479 Ji =1.36*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.657); 480 480 481 481 "Shell Side Pressure Drop Friction Factor" 482 Shell.PressureDrop.FricFactor=45.10*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.973;482 Shell.PressureDrop.FricFactor=45.10*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.973); 483 483 484 484 when Shell.HeatTransfer.Re > 100 switchto "range3"; … … 487 487 488 488 "Ji Factor" 489 Ji =0.593*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.477;489 Ji =0.593*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.477); 490 490 491 491 "Shell Side Pressure Drop Friction Factor" 492 Shell.PressureDrop.FricFactor=4.570*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.476;492 Shell.PressureDrop.FricFactor=4.570*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.476); 493 493 494 494 when Shell.HeatTransfer.Re > 1000 switchto "range4"; … … 497 497 498 498 "Ji Factor" 499 Ji =0.321*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.388;499 Ji =0.321*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.388); 500 500 501 501 "Shell Side Pressure Drop Friction Factor" 502 Shell.PressureDrop.FricFactor=0.486*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.152;502 Shell.PressureDrop.FricFactor=0.486*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.152); 503 503 504 504 when Shell.HeatTransfer.Re > 10000 switchto "range5"; … … 507 507 508 508 "Ji Factor" 509 Ji =0.321*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.388;509 Ji =0.321*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.388); 510 510 511 511 "Shell Side Pressure Drop Friction Factor" 512 Shell.PressureDrop.FricFactor=0.372*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.123;512 Shell.PressureDrop.FricFactor=0.372*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.123); 513 513 514 514 when Shell.HeatTransfer.Re < 10000 switchto "range4"; … … 550 550 551 551 "Shell Side Pressure Drop Friction Factor" 552 Shell.PressureDrop.FricFactor=32*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -1;552 Shell.PressureDrop.FricFactor=32*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-1); 553 553 554 554 when Shell.HeatTransfer.Re > 10 switchto "range2"; … … 560 560 561 561 "Shell Side Pressure Drop Friction Factor" 562 Shell.PressureDrop.FricFactor=26.20*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.913;562 Shell.PressureDrop.FricFactor=26.20*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.913); 563 563 564 564 when Shell.HeatTransfer.Re > 100 switchto "range3"; … … 570 570 571 571 "Shell Side Pressure Drop Friction Factor" 572 Shell.PressureDrop.FricFactor=3.50*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.476;572 Shell.PressureDrop.FricFactor=3.50*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.476); 573 573 574 574 when Shell.HeatTransfer.Re > 1000 switchto "range4"; … … 577 577 578 578 "Ji Factor" 579 Ji =0.370*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.396;579 Ji =0.370*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.396); 580 580 581 581 "Shell Side Pressure Drop Friction Factor" 582 Shell.PressureDrop.FricFactor=0.333*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.136;582 Shell.PressureDrop.FricFactor=0.333*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.136); 583 583 584 584 when Shell.HeatTransfer.Re > 10000 switchto "range5"; … … 587 587 588 588 "Ji Factor" 589 Ji =0.370*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.396;589 Ji =0.370*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.396); 590 590 591 591 "Shell Side Pressure Drop Friction Factor" 592 Shell.PressureDrop.FricFactor=0.303*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.126;592 Shell.PressureDrop.FricFactor=0.303*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.126); 593 593 594 594 when Shell.HeatTransfer.Re < 10000 switchto "range4"; … … 627 627 628 628 "Ji Factor" 629 Ji =0.970*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.667;629 Ji =0.970*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.667); 630 630 631 631 "Shell Side Pressure Drop Friction Factor" 632 Shell.PressureDrop.FricFactor=35*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -1;632 Shell.PressureDrop.FricFactor=35*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-1); 633 633 634 634 when Shell.HeatTransfer.Re > 10 switchto "range2"; … … 637 637 638 638 "Ji Factor" 639 Ji =0.900*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.631;639 Ji =0.900*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.631); 640 640 641 641 "Shell Side Pressure Drop Friction Factor" 642 Shell.PressureDrop.FricFactor=32.10*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.963;642 Shell.PressureDrop.FricFactor=32.10*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.963); 643 643 644 644 when Shell.HeatTransfer.Re > 100 switchto "range3"; … … 647 647 648 648 "Ji Factor" 649 Ji =0.408*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.460;649 Ji =0.408*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.460); 650 650 651 651 "Shell Side Pressure Drop Friction Factor" 652 Shell.PressureDrop.FricFactor=6.090*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.602;652 Shell.PressureDrop.FricFactor=6.090*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.602); 653 653 654 654 when Shell.HeatTransfer.Re > 1000 switchto "range4"; … … 657 657 658 658 "Ji Factor" 659 Ji =0.107*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.266;659 Ji =0.107*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.266); 660 660 661 661 "Shell Side Pressure Drop Friction Factor" … … 667 667 668 668 "Ji Factor" 669 Ji =0.370*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^ -0.395;669 Ji =0.370*((1.33*Tubes.TubeOD/Tubes.TubePitch)^a)*Shell.HeatTransfer.Re^(-0.395); 670 670 671 671 "Shell Side Pressure Drop Friction Factor" 672 Shell.PressureDrop.FricFactor=0.391*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^ -0.148;672 Shell.PressureDrop.FricFactor=0.391*((1.33*Tubes.TubeOD/Tubes.TubePitch)^b)*Shell.HeatTransfer.Re^(-0.148); 673 673 674 674 when Shell.HeatTransfer.Re < 10000 switchto "range4"; … … 900 900 901 901 "Effectiveness Correction for 2 pass shell side" 902 Method.Eft1 = 2*(1+Method.Cr+sqrt(1+Method.Cr^2)*((1+exp(-Method.NTU*sqrt(1+Method.Cr^2)))/(1-exp(-Method.NTU*sqrt(1+Method.Cr^2)))) )^ -1;902 Method.Eft1 = 2*(1+Method.Cr+sqrt(1+Method.Cr^2)*((1+exp(-Method.NTU*sqrt(1+Method.Cr^2)))/(1-exp(-Method.NTU*sqrt(1+Method.Cr^2)))) )^(-1); 903 903 904 904 "TEMA F Shell Effectiveness" 905 Method.Eft = ( ((1-Method.Eft1*Method.Cr)/(1-Method.Eft1))^2 -1 )*( ((1-Method.Eft1*Method.Cr)/(1-Method.Eft1))^2 - Method.Cr )^ -1;905 Method.Eft = ( ((1-Method.Eft1*Method.Cr)/(1-Method.Eft1))^2 -1 )*( ((1-Method.Eft1*Method.Cr)/(1-Method.Eft1))^2 - Method.Cr )^(-1); 906 906 907 907 case "Eshell": 908 908 909 909 "TEMA E Shell Effectiveness" 910 Method.Eft = 2*(1+Method.Cr+sqrt(1+Method.Cr^2)*((1+exp(-Method.NTU*sqrt(1+Method.Cr^2)))/(1-exp(-Method.NTU*sqrt(1+Method.Cr^2)))) )^ -1;910 Method.Eft = 2*(1+Method.Cr+sqrt(1+Method.Cr^2)*((1+exp(-Method.NTU*sqrt(1+Method.Cr^2)))/(1-exp(-Method.NTU*sqrt(1+Method.Cr^2)))) )^(-1); 911 911 # Method.Eft = 1; 912 912 -
branches/gui/eml/heat_exchangers/Heatex.mso
r566 r574 362 362 363 363 "TEMA E Shell Effectiveness" 364 Method.Eft = 2*(1+Method.Cr+sqrt(1+Method.Cr^2)*((1+exp(-Method.NTU*sqrt(1+Method.Cr^2)))/(1-exp(-Method.NTU*sqrt(1+Method.Cr^2)))) )^ -1;365 366 end 367 368 369 end 370 371 end 364 Method.Eft = 2*(1+Method.Cr+sqrt(1+Method.Cr^2)*((1+exp(-Method.NTU*sqrt(1+Method.Cr^2)))/(1-exp(-Method.NTU*sqrt(1+Method.Cr^2)))) )^(-1); 365 366 end 367 368 369 end 370 371 end -
branches/gui/eml/heat_exchangers/heater.mso
r561 r574 49 49 Outlet.F = sum(Inlet.F); 50 50 51 for j in [1 : NComp] 51 for j in [1 : NComp] do 52 52 53 53 "Composition" -
branches/gui/eml/mixers_splitters/mixer.mso
r554 r574 80 80 Outlet.F = sum(Inlet.F); 81 81 82 for i in [1:NComp] 82 for i in [1:NComp] do 83 83 84 84 "Composition" -
branches/gui/eml/mixers_splitters/sepComp.mso
r364 r574 69 69 70 70 71 for i in [1:NOutlet-1] 71 for i in [1:NOutlet-1] do 72 72 73 73 "Mol fraction normalisation" … … 77 77 78 78 79 for i in [1:NComp] 79 for i in [1:NComp] do 80 80 81 81 "Composition" … … 85 85 86 86 87 for i in [1:NOutlet] 87 for i in [1:NOutlet] do 88 88 89 89 "Flow" … … 152 152 sum(Outlet1.z) = 1; 153 153 154 for i in [1:NComp] 154 for i in [1:NComp] do 155 155 156 156 "Composition" -
branches/gui/eml/mixers_splitters/splitter.mso
r354 r574 52 52 sum(frac) = 1; 53 53 54 for i in [1:NOutlet] 54 for i in [1:NOutlet] do 55 55 56 56 "Flow" -
branches/gui/eml/reactors/equil.mso
r530 r574 97 97 # + PP.IdealGasEnthalpyOfFormationAt25C()*(1 - Outlet.T/To); 98 98 99 for j in [1:NReac] 99 for j in [1:NReac] do 100 100 "Gibbs free energy of reaction" 101 101 sumt(G*stoic(:,j)) = -Rg*Outlet.T*ln(K(j)); … … 106 106 end 107 107 108 for i in [1:NComp] 108 for i in [1:NComp] do 109 109 "Outlet molar fraction" 110 110 Outlet.F*Outlet.z(i) = (Inlet.F*Inlet.z(i) + sumt(stoic(i,:)*extent)); 111 111 end 112 112 113 for i in [1:NComp] 113 for i in [1:NComp] do 114 114 if (Outletm.z(i) > 1e-16) then 115 115 "Molar conversion" … … 192 192 # K = exp(-sumt(G*stoic)/(Rg*Outlet.T)); 193 193 194 for j in [1:NReac] 194 for j in [1:NReac] do 195 195 "Equilibrium constant" 196 196 K(j) = prod(activ^stoic(:,j)); 197 197 end 198 198 199 for i in [1:NComp] 199 for i in [1:NComp] do 200 200 "Outlet molar fraction" 201 201 Outlet.F*Outlet.z(i) = (Inlet.F*Inlet.z(i) + sumt(stoic(i,:)*extent)); 202 202 end 203 203 204 for i in [1:NComp] 204 for i in [1:NComp] do 205 205 if (Outletm.z(i) > 1e-16) then 206 206 "Molar conversion" -
branches/gui/eml/reactors/gibbs.mso
r530 r574 104 104 # + PP.IdealGasEnthalpyOfFormationAt25C()*(1 - Outlet.T/To); 105 105 106 for i in [1:NComp] 106 for i in [1:NComp] do 107 107 "Lagrangian multiplier" 108 108 G(i) + sumt(lambda*na(:,i)) = -Rg*Outlet.T*ln(activ(i)); … … 191 191 # + PP.IdealGasEnthalpyOfFormationAt25C()*(1 - Outlet.T/To); 192 192 193 for i in [1:NComp] 193 for i in [1:NComp] do 194 194 "Lagrangian multiplier" 195 195 G(i) + sumt(lambda*na(:,i)) = -Rg*Outlet.T*ln(activ(i)); -
branches/gui/eml/reactors/pfr.mso
r354 r574 82 82 Outlet.v = str(NDisc+1).v; 83 83 84 for z in [1:NDisc] 85 for c in [1:NComp-1] 84 for z in [1:NDisc] do 85 for c in [1:NComp-1] do 86 86 "Component Molar Balance" 87 87 diff(M(c,z)) = (str(z).F*str(z).z(c) - str(z+1).F*str(z+1).z(c)) … … 113 113 end 114 114 115 for z in [1:NDisc+1] 115 for z in [1:NDisc+1] do 116 116 "Specific Volume" 117 117 vol(z) = PP.VapourVolume(str(z).T, str(z).P, str(z).z); -
branches/gui/eml/reactors/stoic.mso
r530 r574 72 72 Outlet.F = Outletm.F; 73 73 74 for i in [1:NComp] 74 for i in [1:NComp] do 75 75 if (Outletm.z(i) > 1e-16) then 76 76 "Molar conversion" … … 123 123 Outlet.F = Outletm.F; 124 124 125 for i in [1:NComp] 125 for i in [1:NComp] do 126 126 if (Outletm.z(i) > 1e-16) then 127 127 "Molar conversion" -
branches/gui/eml/reactors/vol_tank.mso
r427 r574 90 90 Vt = pi/4*(D^2)*L; 91 91 "Level tank volume" 92 V = ((D^2)*acos((D - 2*Level)/D)/4/ "rad"-92 V = ((D^2)*acos((D - 2*Level)/D)/4/'r' - 93 93 (D - 2*Level)*sqrt(D*Level - Level^2)/2)*L; 94 94 -
branches/gui/eml/reactors/yield.mso
r530 r574 84 84 Outlet.F*Outlet.h = Outletm.F*Outletm.h; 85 85 86 for i in [1:NComp] 86 for i in [1:NComp] do 87 87 if (Outletm.z(i) > 1e-16) then 88 88 "Molar conversion" … … 147 147 Outlet.F*Outlet.h = Outletm.F*Outletm.h; 148 148 149 for i in [1:NComp] 149 for i in [1:NComp] do 150 150 if (Outletm.z(i) > 0) then 151 151 "Molar conversion" -
branches/gui/sample/miscellaneous/sample_arrays.mso
r176 r574 30 30 31 31 EQUATIONS 32 for i in [1 : Dimension] 32 for i in [1 : Dimension] do 33 33 diff(Var1(1,i)) = Var2(1,i)/'s'; 34 34 end -
branches/gui/sample/miscellaneous/sample_arrays2.mso
r176 r574 32 32 diff(Var1(1,1))*'s' = Var2(1,2); 33 33 34 for i in [2 : Dimension-1] 34 for i in [2 : Dimension-1] do 35 35 diff(Var1(1,i))*'s' = Var2(1,i-1)+Var2(1,i+1); 36 36 end -
branches/gui/sample/miscellaneous/sample_galvanic.mso
r535 r574 27 27 *--------------------------------------------------------------------*# 28 28 29 include "types"; 30 29 using "types"; 31 30 32 31 FlowSheet cell -
branches/gui/sample/miscellaneous/sample_tanks.mso
r313 r574 35 35 36 36 SPECIFY 37 "Vazao de entrada"38 37 Fin = 10 * 'm^3/h'; 39 38 … … 65 64 66 65 SPECIFY 67 "Vazao de entrada"68 66 Fin = 10 * 'm^3/h'; 69 67 -
branches/gui/sample/miscellaneous/tenprobs/prob07.mso
r228 r574 71 71 dz = (z(N+2) - z(1))/(N+1); 72 72 73 for i in [2:(N+1)] 73 for i in [2:(N+1)] do 74 74 "Concentration of reactant" 75 75 (C(i+1) - 2*C(i)+ C(i-1))/(z(i) - z(i-1))^2 … … 111 111 112 112 SPECIFY 113 "Lower boundary"114 113 reac.z(1) = 0*'m'; 115 114 116 "Upper boundary"117 115 reac.z(N+2) = reac.L; 118 119 116 120 117 OPTIONS … … 162 159 163 160 SPECIFY 164 "Lower boundary"165 161 reac.z(1) = 0*'m'; 166 162 167 "Upper boundary"168 163 reac.z(N+2) = reac.L; 169 170 164 171 165 OPTIONS -
branches/gui/sample/optimization/ammonia.mso
r313 r574 94 94 Outlet.F = Inlet.F * (1 - sum(Outletz)); 95 95 96 for i in [1:NComp] 96 for i in [1:NComp] do 97 97 "Component Molar Balance" 98 98 Outletz(i) = Inlet.z(i) + sum(stoic(i,:)*X*Inlet.z(comp)); … … 169 169 170 170 F102.OutletV.P = 10 * 'atm'; 171 F102.InletQ .Q= 0 * 'kJ/h';171 F102.InletQ = 0 * 'kJ/h'; 172 172 173 173 # We can choose between one of the following specs -
branches/gui/sample/processes/Sample_Process.mso
r564 r574 78 78 EQUATIONS 79 79 80 for z in [1:Reac.NDisc] 80 for z in [1:Reac.NDisc] do 81 81 82 82 "Reaction Rate = k*C(1)" … … 125 125 INITIAL 126 126 127 for z in [2:Reac.NDisc+1] 127 for z in [2:Reac.NDisc+1] do 128 128 129 129 Reac.str(z).T = Reac.Inlet.T; -
branches/gui/sample/reactors/fogler/chap2/series_reactors.mso
r446 r574 239 239 V(1) = 0.0*'l'; 240 240 241 for i in [2:N] 241 for i in [2:N] do 242 242 "Molar balance" 243 243 V(i) - V(i-1) = -0.5*Inlet.F*dx*(1/r(i-1) + 1/r(i)); # second order … … 250 250 Outlet.F = Inlet.F; 251 251 252 for i in [1:N] 252 for i in [1:N] do 253 253 "Rate of reaction" 254 254 (-r(i)) = sum(a*X(i)^[0:(NT-1)]); … … 293 293 294 294 SPECIFY 295 "Inlet conversion"296 295 Inlet.X = 0.0; 297 "Required conversion"298 296 R1.Outlet.X = 0.8; 299 297 … … 316 314 317 315 SPECIFY 318 "Inlet molar flow"319 316 Inlet.F = 0.866541*'mol/s'; 320 "Inlet conversion"321 317 Inlet.X = 0.0; 322 318 … … 350 346 351 347 SPECIFY 352 "Inlet molar flow"353 348 Inlet.F = 0.866541*'mol/s'; 354 "Inlet conversion"355 349 Inlet.X = 0.0; 356 350 357 "Required conversion"358 351 R1.Outlet.X = 0.8; 359 352 … … 392 385 393 386 SPECIFY 394 "Inlet molar flow"395 387 Inlet.F = 5.0*'mol/s'; 396 "Inlet conversion"397 388 Inlet.X = 0.0; 398 389 399 "Required CSTR conversion"400 390 CSTR.Outlet.X = 0.6; 401 "Required PFR conversion"402 391 PFR.Outlet.X = 0.6; 403 392 … … 435 424 436 425 SPECIFY 437 "Inlet molar flow"438 426 Inlet.F = 0.866541*'mol/s'; 439 "Inlet conversion"440 427 Inlet.X = 0.0; 441 428 442 "Required 1st reactor conversion"443 429 R1.Outlet.X = 0.4; 444 "Required 2nd reactor conversion"445 430 R2.Outlet.X = 0.8; 446 431 … … 478 463 479 464 SPECIFY 480 "Inlet molar flow"481 465 Inlet.F = 0.866541*'mol/s'; 482 "Inlet conversion"483 466 Inlet.X = 0.0; 484 467 485 "Required 1st reactor conversion"486 468 R1.Outlet.X = 0.4; 487 "Required 2nd reactor conversion"488 469 R2.Outlet.X = 0.8; 489 470 … … 524 505 525 506 SPECIFY 526 "Inlet molar flow"527 507 Inlet.F = 0.866541*'mol/s'; 528 "Inlet conversion"529 508 Inlet.X = 0.0; 530 509 531 "Required 1st reactor conversion"532 510 R1.Outlet.X = 0.5; 533 "Required 2nd reactor conversion"534 511 R2.Outlet.X = 0.8; 535 512 … … 570 547 571 548 SPECIFY 572 "Inlet molar flow"573 549 Inlet.F = 0.866541*'mol/s'; 574 "Inlet conversion"575 550 Inlet.X = 0.0; 576 551 577 "Required 1st reactor conversion"578 552 R1.Outlet.X = 0.5; 579 "Required 2nd reactor conversion"580 553 R2.Outlet.X = 0.8; 581 554 -
branches/gui/sample/reactors/fogler/chap3/equilibrium_conversion.mso
r202 r574 110 110 111 111 SPECIFY 112 "Inlet molar fraction"113 112 Inlet.z = [1.0, 0.0]; 114 115 "Inlet pressure"116 113 P = 2.0*'atm'; 117 "Inlet temperature"118 114 T = 340*'K'; 119 115 120 "Equilibrium constant"121 116 Kc = 0.1*'mol/l'; 122 117 … … 178 173 179 174 SPECIFY 180 "Inlet molar fraction"181 175 Inlet.z = [1.0, 0.0]; 182 176 183 "Inlet pressure"184 177 P = 2.0*'atm'; 185 "Inlet temperature"186 178 T = 340*'K'; 187 179 188 "Equilibrium constant"189 180 Kc = 0.1*'mol/l'; 190 181 -
branches/gui/sample/reactors/fogler/chap3/oxidation_of_so2.mso
r202 r574 108 108 109 109 SPECIFY 110 "Inlet molar fraction"111 110 Inlet.z = [0.28, 0.1512, 0.0, 0.5688]; 112 "Inlet pressure"113 111 P = 1485*'kPa'; 114 "Inlet temperature"115 112 T = (227 + 273.15)*'K'; 116 113 -
branches/gui/sample/reactors/fogler/chap4/membrane_reactor.mso
r188 r574 94 94 95 95 SPECIFY 96 "Pressure"97 96 P = 8.2*'atm'; # Isobaric system 98 "Temperature"99 97 T = 500*'K'; # Isotermic system 100 98 101 "Specific rate of reaction"102 99 k = 0.7*'1/min'; 103 100 -
branches/gui/sample/reactors/fogler/chap4/molarflow_pfr.mso
r188 r574 88 88 89 89 SPECIFY 90 "Input total molar concentration"91 90 Cto = 0.1*'mol/l'; 92 91 93 "Input molar flow"94 92 Fo = [10, 0]*'mol/min'; 95 93 -
branches/gui/sample/reactors/fogler/chap4/semibatch_reactor.mso
r202 r574 85 85 86 86 SPECIFY 87 "Specific rate of reaction"88 87 k = 2.2*'l/mol/s'; 89 88 90 "Inlet concentration"91 89 Co = [0.0, 0.025, 0.0, 0.0]*'mol/l'; 92 90 -
branches/gui/sample/reactors/fogler/chap4/spheric_reactor.mso
r188 r574 103 103 104 104 SPECIFY 105 "Input molar concentration of A"106 105 Ca0 = 320*'mol/m^3'; 107 "Input molar flow of A"108 106 Fa0 = 440*'mol/s'; 109 "Initial pressure"110 107 P0 = 2000*'kPa'; 111 "Input mass flow"112 108 m = 44*'kg/s'; 113 109 -
branches/gui/sample/reactors/fogler/chap8/acetic_anhydride.mso
r202 r574 145 145 146 146 SPECIFY 147 "Inlet molar flow"148 147 R.Fao = (8000/58)*'kmol/h'; 149 148 … … 187 186 188 187 SPECIFY 189 "Inlet molar flow"190 188 R.Fao = (18.8*2e-3)*'mol/s'; 191 189 -
branches/gui/sample/reactors/fogler/chap8/series_reactions.mso
r383 r574 123 123 124 124 SPECIFY 125 "Inlet temperature"126 125 To = 283*'K'; 127 "Inlet concentration of A"128 126 Co= 0.3*'mol/m^3'; 129 127 -
branches/gui/sample/reactors/fogler/chap9/cstr_startup.mso
r383 r574 139 139 140 140 SPECIFY 141 "Inlet molar flow"142 141 CSTR.Fo = [80, 1000, 0, 100]*'lbmol/h'; 143 "Inlet reactor temperature"144 142 CSTR.To = (75 + 460)*'degR'; 145 "Molar flow of cooling water"146 143 CSTR.mc = 1e3*'lbmol/h'; 147 144 … … 186 183 187 184 SPECIFY 188 "Inlet molar flow"189 185 CSTR.Fo = [80, 1000, 0, 100]*'lbmol/h'; 190 "Inlet reactor temperature"191 186 CSTR.To = (70 + 460)*'degR'; # Reduction of temperature: 75°F to 70°F 192 "Molar flow of cooling water"193 187 CSTR.mc = 1e3*'lbmol/h'; 194 188 … … 242 236 243 237 SPECIFY 244 "Inlet molar flow"245 238 CSTR.Fo = [80, 1000, 0, 100]*'lbmol/h'; 246 "Inlet reactor temperature"247 239 CSTR.To = (70 + 460)*'degR'; 248 240 -
branches/gui/sample/reactors/sample_batch.mso
r313 r574 74 74 75 75 SPECIFY 76 "Feed conditions"77 76 feed.T = 300*'K'; 78 77 feed.P = 1*'atm'; … … 81 80 feed.z = [0,1,0,0,0]; 82 81 83 "Reactor volume"84 82 reac.Vr = 1 * 'l'; 85 83 -
branches/gui/sample/reactors/sample_cstr.mso
r245 r574 62 62 Reac.Outlet.F = Reac.Inlet.F; 63 63 64 "Adiabatic"65 64 Reac.q = 0 * 'J/s'; 66 65 Reac.Outlet.P = 1 * 'atm'; -
branches/gui/sample/reactors/sample_pfr.mso
r213 r574 65 65 EQUATIONS 66 66 67 for z in [1:Reac.NDisc] 67 for z in [1:Reac.NDisc] do 68 68 69 69 "Reaction Rate = k*C(1)" … … 84 84 s1.Outlet.z = [1, 0, 0]; 85 85 86 "Adiabatic"87 86 Reac.q = 0 * 'J/s'; 88 87 … … 93 92 INITIAL 94 93 95 for z in [2:Reac.NDisc+1] 94 for z in [2:Reac.NDisc+1] do 96 95 97 96 Reac.str(z).T = Reac.Inlet.T; -
branches/gui/sample/stage_separators/sample_column.mso
r555 r574 341 341 Qr.OutletQ to col.reb.InletQ; 342 342 343 EQUATIONS 344 "Temperature Controller" 345 TCcond.Parameters.tau = 0*'s'; 346 TCcond.Parameters.tauSet = 0*'s'; 347 TCcond.Parameters.alpha = 0.3; 348 TCcond.Parameters.bias = 0.5; 349 TCcond.Parameters.gamma = 1; 350 TCcond.Parameters.beta = 1; 343 SET 344 TCcond.tau = 0*'s'; 345 TCcond.tauSet = 0*'s'; 346 TCcond.alpha = 0.3; 347 TCcond.bias = 0.5; 348 TCcond.gamma = 1; 349 TCcond.beta = 1; 351 350 TCcond.Action = "Direct"; 352 351 TCcond.Clip = "Clipped"; 353 352 TCcond.Mode = "Automatic"; 354 TCcond.Parameters.intTime = 60*'s'; 355 TCcond.Parameters.gain = 0.6; 356 TCcond.Parameters.derivTime = 1*'s'; 353 TCcond.intTime = 60*'s'; 354 TCcond.gain = 0.6; 355 TCcond.derivTime = 1*'s'; 356 357 PC.tau = 0*'s'; 358 PC.tauSet = 0*'s'; 359 PC.alpha = 0.3; 360 PC.bias = 0; 361 PC.gamma = 1; 362 PC.beta = 1; 363 PC.Action = "Reverse"; 364 PC.Clip = "Clipped"; 365 PC.Mode = "Automatic"; 366 PC.intTime = 50*'s'; 367 PC.gain = 0.5; 368 PC.derivTime = 1*'s'; 369 370 LCtop.tau = 0*'s'; 371 LCtop.tauSet = 0*'s'; 372 LCtop.alpha = 0.3; 373 LCtop.bias = 0.5; 374 LCtop.gamma = 1; 375 LCtop.beta = 1; 376 LCtop.Action = "Reverse"; 377 LCtop.Clip = "Clipped"; 378 LCtop.Mode = "Automatic"; 379 LCtop.intTime = 10*'s'; 380 LCtop.gain = 1; 381 LCtop.derivTime = 0*'s'; 382 383 LCbot.tau = 0*'s'; 384 LCbot.tauSet = 0*'s'; 385 LCbot.alpha = 0.3; 386 LCbot.bias = 0.5; 387 LCbot.gamma = 1; 388 LCbot.beta = 1; 389 LCbot.Action = "Reverse"; 390 LCbot.Clip = "Clipped"; 391 LCbot.Mode = "Automatic"; 392 LCbot.intTime = 100*'s'; 393 LCbot.gain = 1; 394 LCbot.derivTime = 0*'s'; 395 396 EQUATIONS 357 397 TCcond.Ports.setPoint = ((15+273.15) * 'K' - Tmin)/(Tmax-Tmin); 358 398 TCcond.Ports.input = Tad; … … 360 400 Qc.OutletQ = Qcmin+(Qcmax-Qcmin)*TCcond.Ports.output; 361 401 362 "Pressure Controller"363 PC.Parameters.tau = 0*'s';364 PC.Parameters.tauSet = 0*'s';365 PC.Parameters.alpha = 0.3;366 PC.Parameters.bias = 0;367 PC.Parameters.gamma = 1;368 PC.Parameters.beta = 1;369 PC.Action = "Reverse";370 PC.Clip = "Clipped";371 PC.Mode = "Automatic";372 PC.Parameters.intTime = 50*'s';373 PC.Parameters.gain = 0.5;374 PC.Parameters.derivTime = 1*'s';375 402 PC.Ports.setPoint = (4.0*'bar'-Pmin)/(Pmax-Pmin); 376 403 PC.Ports.input = Pad; … … 378 405 col.cond.OutletV.F = (Fcmin+(Fcmax-Fcmin)*PC.Ports.output); 379 406 380 "Ttop Level Controller"381 LCtop.Parameters.tau = 0*'s';382 LCtop.Parameters.tauSet = 0*'s';383 LCtop.Parameters.alpha = 0.3;384 LCtop.Parameters.bias = 0.5;385 LCtop.Parameters.gamma = 1;386 LCtop.Parameters.beta = 1;387 LCtop.Action = "Reverse";388 LCtop.Clip = "Clipped";389 LCtop.Mode = "Automatic";390 LCtop.Parameters.intTime = 10*'s';391 LCtop.Parameters.gain = 1;392 LCtop.Parameters.derivTime = 0*'s';393 407 LCtop.Ports.setPoint = (1.0 * 'm' - Hmint)/(Hmaxt-Hmint); 394 408 LCtop.Ports.input = Had_top; … … 396 410 col.sptop.Outlet1.F = Fcmin + (Fcmax-Fcmin) * LCtop.Ports.output; 397 411 398 "Tbottom Level Controller"399 LCbot.Parameters.tau = 0*'s';400 LCbot.Parameters.tauSet = 0*'s';401 LCbot.Parameters.alpha = 0.3;402 LCbot.Parameters.bias = 0.5;403 LCbot.Parameters.gamma = 1;404 LCbot.Parameters.beta = 1;405 LCbot.Action = "Reverse";406 LCbot.Clip = "Clipped";407 LCbot.Mode = "Automatic";408 LCbot.Parameters.intTime = 100*'s';409 LCbot.Parameters.gain = 1;410 LCbot.Parameters.derivTime = 0*'s';411 412 LCbot.Ports.setPoint = (1.0 * 'm' - Hminb)/(Hmaxb-Hminb); 412 413 LCbot.Ports.input = Had_bot; … … 731 732 TCcond.Clip = "Clipped"; 732 733 TCcond.Mode = "Automatic"; 734 TCcond.tau = 0*'s'; 735 TCcond.tauSet = 0*'s'; 736 TCcond.alpha = 0.3; 737 TCcond.bias = 0.5; 738 TCcond.gamma = 1; 739 TCcond.beta = 1; 740 TCcond.intTime = 60*'s'; 741 TCcond.gain = 0.6; 742 TCcond.derivTime = 1*'s'; 733 743 734 744 PC.Action = "Reverse"; 735 745 PC.Clip = "Clipped"; 736 746 PC.Mode = "Automatic"; 747 PC.tau = 0*'s'; 748 PC.tauSet = 0*'s'; 749 PC.alpha = 0.3; 750 PC.bias = 0; 751 PC.gamma = 1; 752 PC.beta = 1; 753 PC.intTime = 50*'s'; 754 PC.gain = 0.5; 755 PC.derivTime = 1*'s'; 737 756 738 757 LCtop.Action = "Reverse"; 739 758 LCtop.Clip = "Clipped"; 740 759 LCtop.Mode = "Automatic"; 741 760 LCtop.tau = 0*'s'; 761 LCtop.tauSet = 0*'s'; 762 LCtop.alpha = 0.3; 763 LCtop.bias = 0.5; 764 LCtop.gamma = 1; 765 LCtop.beta = 1; 766 LCtop.intTime = 10*'s'; 767 LCtop.gain = 1; 768 LCtop.derivTime = 0*'s'; 769 742 770 LCbot.Action = "Reverse"; 743 771 LCbot.Clip = "Clipped"; 744 772 LCbot.Mode = "Automatic"; 773 LCbot.tau = 0*'s'; 774 LCbot.tauSet = 0*'s'; 775 LCbot.alpha = 0.3; 776 LCbot.bias = 0.5; 777 LCbot.gamma = 1; 778 LCbot.beta = 1; 779 LCbot.intTime = 100*'s'; 780 LCbot.gain = 1; 781 LCbot.derivTime = 0*'s'; 745 782 746 783 EQUATIONS 747 "Temperature Controller"748 TCcond.Parameters.tau = 0*'s';749 TCcond.Parameters.tauSet = 0*'s';750 TCcond.Parameters.alpha = 0.3;751 TCcond.Parameters.bias = 0.5;752 TCcond.Parameters.gamma = 1;753 TCcond.Parameters.beta = 1;754 TCcond.Parameters.intTime = 60*'s';755 TCcond.Parameters.gain = 0.6;756 TCcond.Parameters.derivTime = 1*'s';757 784 TCcond.Ports.setPoint = ((15+273.15) * 'K' - Tmin)/(Tmax-Tmin); 758 785 TCcond.Ports.input = Tad; … … 760 787 Qc.OutletQ = Qcmin+(Qcmax-Qcmin)*TCcond.Ports.output; 761 788 762 "Pressure Controller"763 PC.Parameters.tau = 0*'s';764 PC.Parameters.tauSet = 0*'s';765 PC.Parameters.alpha = 0.3;766 PC.Parameters.bias = 0;767 PC.Parameters.gamma = 1;768 PC.Parameters.beta = 1;769 PC.Parameters.intTime = 50*'s';770 PC.Parameters.gain = 0.5;771 PC.Parameters.derivTime = 1*'s';772 789 PC.Ports.setPoint = (4.0*'bar'-Pmin)/(Pmax-Pmin); 773 790 PC.Ports.input = Pad; … … 775 792 col.cond.OutletV.F = (Fcmin+(Fcmax-Fcmin)*PC.Ports.output); 776 793 777 "Ttop Level Controller"778 LCtop.Parameters.tau = 0*'s';779 LCtop.Parameters.tauSet = 0*'s';780 LCtop.Parameters.alpha = 0.3;781 LCtop.Parameters.bias = 0.5;782 LCtop.Parameters.gamma = 1;783 LCtop.Parameters.beta = 1;784 LCtop.Parameters.intTime = 10*'s';785 LCtop.Parameters.gain = 1;786 LCtop.Parameters.derivTime = 0*'s';787 794 LCtop.Ports.setPoint = (1.0 * 'm' - Hmint)/(Hmaxt-Hmint); 788 795 LCtop.Ports.input = Had_top; … … 790 797 col.sptop.Outlet1.F = Fcmin + (Fcmax-Fcmin) * LCtop.Ports.output; 791 798 792 "Tbottom Level Controller"793 LCbot.Parameters.tau = 0*'s';794 LCbot.Parameters.tauSet = 0*'s';795 LCbot.Parameters.alpha = 0.3;796 LCbot.Parameters.bias = 0.5;797 LCbot.Parameters.gamma = 1;798 LCbot.Parameters.beta = 1;799 LCbot.Parameters.intTime = 100*'s';800 LCbot.Parameters.gain = 1;801 LCbot.Parameters.derivTime = 0*'s';802 799 LCbot.Ports.setPoint = (1.0 * 'm' - Hminb)/(Hmaxb-Hminb); 803 800 LCbot.Ports.input = Had_bot; -
branches/gui/sample/stage_separators/sample_columnReact.mso
r530 r574 91 91 92 92 if col.reb.startup then 93 Qc.OutletQ .Q= 0 * PIDTcond.Ports.output * 'kJ/s';94 Qr.OutletQ .Q= 0 * PIDTreb.Ports.output * 'kJ/s';93 Qc.OutletQ = 0 * PIDTcond.Ports.output * 'kJ/s'; 94 Qr.OutletQ = 0 * PIDTreb.Ports.output * 'kJ/s'; 95 95 96 96 PIDTreb.Ports.input = PIDTreb.Ports.setPoint; 97 97 else 98 Qc.OutletQ .Q= Qcmin+(Qcmax-Qcmin)*PIDTcond.Ports.output;99 Qr.OutletQ .Q= Qrmin+(Qrmax-Qrmin)*PIDTreb.Ports.output;98 Qc.OutletQ = Qcmin+(Qcmax-Qcmin)*PIDTcond.Ports.output; 99 Qr.OutletQ = Qrmin+(Qrmax-Qrmin)*PIDTreb.Ports.output; 100 100 101 101 PIDTreb.Ports.input=Treb_ad; 102 102 end 103 104 SET 105 PIDLreb.tau = 1*'s'; 106 PIDLreb.tauSet=1*'s'; 107 PIDLreb.bias = 0; 108 PIDLreb.alpha=1; 109 PIDLreb.gamma=1; 110 PIDLreb.beta=1; 111 PIDLreb.gain=0.9; 112 PIDLreb.intTime=20*'s'; 113 PIDLreb.derivTime=0*'s'; 114 PIDLreb.Action = "Direct"; 115 PIDLreb.Clip = "Clipped"; 116 PIDLreb.Mode = "Automatic"; 117 118 119 PIDLcond.tau = 1*'s'; 120 PIDLcond.tauSet=1*'s'; 121 PIDLcond.bias = 0.5; 122 PIDLcond.alpha=1; 123 PIDLcond.gamma=1; 124 PIDLcond.beta=1; 125 PIDLcond.gain=1; 126 PIDLcond.intTime=10*'s'; 127 PIDLcond.derivTime=1*'s'; 128 PIDLcond.Action = "Direct"; 129 PIDLcond.Clip = "Clipped"; 130 PIDLcond.Mode = "Automatic"; 131 132 PIDTreb.tau = 1*'s'; 133 PIDTreb.tauSet=1*'s'; 134 PIDTreb.bias = 0.2; 135 PIDTreb.alpha=0.2; 136 PIDTreb.gamma=1; 137 PIDTreb.beta=1; 138 PIDTreb.gain=0.9; 139 PIDTreb.intTime=100*'s'; 140 PIDTreb.derivTime=1*'s'; 141 PIDTreb.Action = "Direct"; 142 PIDTreb.Clip = "Clipped"; 143 PIDTreb.Mode = "Automatic"; 144 145 PIDTcond.tau = 1*'s'; 146 PIDTcond.tauSet=1*'s'; 147 PIDTcond.bias = 0.5; 148 PIDTcond.alpha=0.2; 149 PIDTcond.gamma=1; 150 PIDTcond.beta=1; 151 PIDTcond.gain=0.9; 152 PIDTcond.intTime=100*'s'; 153 PIDTcond.derivTime=1*'s'; 154 PIDTcond.Action = "Reverse"; 155 PIDTcond.Clip = "Clipped"; 156 PIDTcond.Mode = "Automatic"; 157 103 158 104 159 SPECIFY … … 118 173 col.trays.Emv = 1; 119 174 175 EQUATIONS 176 120 177 # Variáveis dos PID's especificadas 121 PIDLreb.Parameters.tau = 1*'s';122 PIDLreb.Parameters.tauSet=1*'s';123 PIDLreb.Parameters.bias = 0;124 PIDLreb.Parameters.alpha=1;125 PIDLreb.Parameters.gamma=1;126 PIDLreb.Parameters.beta=1;127 PIDLreb.Parameters.gain=0.9;128 PIDLreb.Parameters.intTime=20*'s';129 PIDLreb.Parameters.derivTime=0*'s';130 PIDLreb.Options.action=-1;131 PIDLreb.Options.clip=1;132 PIDLreb.Options.autoMan=0;133 178 PIDLreb.Ports.setPoint=(0.5 * 'm' - Lrebmin)/(Lrebmax-Lrebmin); 134 179 Lreb_ad*(Lrebmax-Lrebmin)=col.reb.Level-Lrebmin; … … 136 181 col.reb.OutletL.F = Frmin + (Frmax-Frmin) * PIDLreb.Ports.output; 137 182 138 PIDLcond.Parameters.tau = 1*'s';139 PIDLcond.Parameters.tauSet=1*'s';140 PIDLcond.Parameters.bias = 0.5;141 PIDLcond.Parameters.alpha=1;142 PIDLcond.Parameters.gamma=1;143 PIDLcond.Parameters.beta=1;144 PIDLcond.Parameters.gain=1;145 PIDLcond.Parameters.intTime=10*'s';146 PIDLcond.Parameters.derivTime=1*'s';147 PIDLcond.Options.action=-1;148 PIDLcond.Options.clip=1;149 PIDLcond.Options.autoMan=0;150 183 PIDLcond.Ports.setPoint=(0.5 * 'm' - Lcondmin)/(Lcondmax-Lcondmin); 151 184 Lcond_ad*(Lcondmax-Lcondmin)=col.cond.Level-Lcondmin; … … 153 186 col.sp.Outlet1.F = Fmin + (Fmax-Fmin) * PIDLcond.Ports.output; 154 187 155 PIDTreb.Parameters.tau = 1*'s';156 PIDTreb.Parameters.tauSet=1*'s';157 PIDTreb.Parameters.bias = 0.2;158 PIDTreb.Parameters.alpha=0.2;159 PIDTreb.Parameters.gamma=1;160 PIDTreb.Parameters.beta=1;161 PIDTreb.Parameters.gain=0.9;162 PIDTreb.Parameters.intTime=100*'s';163 PIDTreb.Parameters.derivTime=1*'s';164 PIDTreb.Options.action=1;165 PIDTreb.Options.clip=1;166 PIDTreb.Options.autoMan=0;167 188 PIDTreb.Ports.setPoint= (366 * 'K' - Trebmin)/(Trebmax-Trebmin); 168 189 Treb_ad*(Trebmax-Trebmin)=col.reb.OutletL.T-Trebmin; 169 190 170 PIDTcond.Parameters.tau = 1*'s';171 PIDTcond.Parameters.tauSet=1*'s';172 PIDTcond.Parameters.bias = 0.5;173 PIDTcond.Parameters.alpha=0.2;174 PIDTcond.Parameters.gamma=1;175 PIDTcond.Parameters.beta=1;176 PIDTcond.Parameters.gain=0.9;177 PIDTcond.Parameters.intTime=100*'s';178 PIDTcond.Parameters.derivTime=1*'s';179 PIDTcond.Options.action=1;180 PIDTcond.Options.clip=1;181 PIDTcond.Options.autoMan=0;182 191 PIDTcond.Ports.setPoint= (346 * 'K' - Tcondmin)/(Tcondmax-Tcondmin); 183 192 Tcond_ad*(Tcondmax-Tcondmin)=col.cond.OutletL.T-Tcondmin;
Note: See TracChangeset
for help on using the changeset viewer.