Changeset 146 for branches/newlanguage/eml/heat_exchangers
- Timestamp:
- Jan 30, 2007, 7:42:28 PM (16 years ago)
- Location:
- branches/newlanguage/eml/heat_exchangers
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/newlanguage/eml/heat_exchangers/HEX_Engine.mso
r145 r146 86 86 VARIABLES 87 87 # Must be streamPH 88 Hot as streamPH(Brief="Outlet Hot Stream");89 Cold as streamPH(Brief="Outlet Cold Stream");88 Hot as vapour_stream (Brief="Outlet Hot Stream"); 89 Cold as liquid_stream (Brief="Outlet Cold Stream"); 90 90 91 91 end -
branches/newlanguage/eml/heat_exchangers/HeatExchangerSimplified.mso
r145 r146 477 477 Info = 478 478 "write some information"; 479 480 EQUATIONS 479 480 PARAMETERS 481 482 LMTDcorrection as Switcher(Brief="LMTD Correction Factor Model",Valid=["Bowmann","Fakeri"],Default="Bowmann"); 483 484 VARIABLES 485 486 R as positive; 487 P as positive; 488 Rho as positive; 489 Phi as positive; 490 491 EQUATIONS 492 493 "Capacity Ratio for LMTD Correction Fator" 494 R*(Outlet.Cold.T - Inlet.Cold.T ) = (Inlet.Hot.T-Outlet.Hot.T); 495 496 "Non - Dimensional Variable for LMTD Correction Fator" 497 P*(Inlet.Hot.T- Inlet.Cold.T)= (Outlet.Cold.T-Inlet.Cold.T); 498 481 499 "Temperature Difference at Inlet" 482 500 DT0 = Inlet.Hot.T - Outlet.Cold.T; … … 484 502 "Temperature Difference at Outlet" 485 503 DTL = Outlet.Hot.T - Inlet.Cold.T; 486 487 "LMTD Correction Factor" 488 Fc = HE.EshellCorrectionFactor(Inlet.Hot.T,Outlet.Hot.T,Inlet.Cold.T,Outlet.Cold.T); 504 505 "Rho: Non - Dimensional Variable for LMTD Correction Fator in Fakeri Equation" 506 Rho*(1-P*R) = (1-P); 507 508 "Phi: Non - Dimensional Variable for LMTD Correction Fator in Fakeri Equation" 509 Phi = (sqrt(((Inlet.Hot.T- Outlet.Hot.T)*(Inlet.Hot.T- Outlet.Hot.T))+((Outlet.Cold.T - Inlet.Cold.T)*(Outlet.Cold.T - Inlet.Cold.T))))/(2*((Inlet.Hot.T+ Outlet.Hot.T)-(Inlet.Cold.T+ Outlet.Cold.T))); 510 511 switch LMTDcorrection 512 513 case "Bowmann": 514 515 if R equal 1 516 517 then 518 Fc = (sqrt(2)*P)/((1-P)*ln( abs( ( 2-P*0.585786)/( 2-P*3.414214)))); 519 520 else 521 Fc = sqrt(R*R+1)*ln(abs((1-P*R)/(1-P)))/((1-R)*ln( abs( ( 2-P*(R+1-sqrt(R*R+1)))/ ( 2-P*(R + 1 + sqrt(R*R+1)))))); 522 523 end 524 525 case "Fakeri": 526 527 if Rho equal 1 528 529 then 530 Fc = (4*Phi)/(ln(abs((1+2*Phi)/(1-2*Phi)))); 531 532 else 533 Fc = (2*Phi*(Rho+1)*ln(abs(Rho)))/( ln(abs((1+2*Phi)/(1-2*Phi)))*(Rho-1)); 534 535 end 536 537 end 489 538 490 539 end … … 498 547 "write some information"; 499 548 500 EQUATIONS 549 PARAMETERS 550 551 LMTDcorrection as Switcher(Brief="LMTD Correction Factor Model",Valid=["Bowmann","Fakeri"],Default="Bowmann"); 552 553 VARIABLES 554 555 R as positive; 556 P as positive; 557 Pc as positive; 558 Rho as positive; 559 #Phi as positive; 560 561 EQUATIONS 562 563 "Rho: Non - Dimensional Variable for LMTD Correction Fator in Fakeri Equation" 564 Rho*(1-P*R) = (1-P); 565 566 "Capacity Ratio for LMTD Correction Fator" 567 R*(Outlet.Cold.T - Inlet.Cold.T ) = (Inlet.Hot.T-Outlet.Hot.T); 568 569 "Non - Dimensional Variable for LMTD Correction Fator" 570 P*(Inlet.Hot.T- Inlet.Cold.T)= (Outlet.Cold.T-Inlet.Cold.T); 571 501 572 "Temperature Difference at Inlet" 502 573 DT0 = Inlet.Hot.T - Outlet.Cold.T; … … 505 576 DTL = Outlet.Hot.T - Inlet.Cold.T; 506 577 507 "LMTD Correction Factor" 508 Fc = HE.FshellCorrectionFactor(Inlet.Hot.T,Outlet.Hot.T,Inlet.Cold.T,Outlet.Cold.T); 578 if R equal 1 579 580 then 581 Pc*(2-P)= P; 582 583 Fc= (sqrt(2)*Pc)/((1-Pc)*ln( abs( ( 2-Pc*0.585786)/( 2-Pc*3.414214)))); 584 585 else 586 Pc = (sqrt(abs(( 1-P*R)/(1-P)))-1)/(sqrt(abs(( 1-P*R)/(1-P)))-R); 587 Fc =sqrt(R*R+1)*ln(abs((1-Pc*R)/(1-Pc)))/((1-R)*ln( abs( ( 2-Pc*(R+1-sqrt(R*R+1)))/ ( 2-Pc*(R + 1 + sqrt(R*R+1)))))); 588 589 end 590 509 591 510 592 end
Note: See TracChangeset
for help on using the changeset viewer.