| ||
//-------------------------------------------------- //Подпрограмма элемента "Теплообменник" //-------------------------------------------------- double K = 0.3; InputGas1.IsobarHeat = K * InputGas1.IsobarHeat + (1 - K) * InputGas1.TempIsobarHeat; InputGas1.TempIsobarHeat = InputGas1.IsobarHeat; InputGas1.GasConst = K * InputGas1.GasConst + (1 - K) * InputGas1.TempGasConst; InputGas1.TempGasConst = InputGas1.GasConst; InputGas1.Pressure = K * InputGas1.Pressure + (1 - K) * InputGas1.TempPressure; InputGas1.TempPressure = InputGas1.Pressure; InputGas1.Temperature = K * InputGas1.Temperature + (1 - K) * InputGas1.TempTemperature; InputGas1.TempTemperature = InputGas1.Temperature; InputGas1.Charge = K * InputGas1.Charge + (1 - K) * InputGas1.TempCharge; InputGas1.TempCharge = InputGas1.Charge; InputGas3.IsobarHeat = K * InputGas3.IsobarHeat + (1 - K) * InputGas3.TempIsobarHeat; InputGas3.TempIsobarHeat = InputGas3.IsobarHeat; InputGas3.GasConst = K * InputGas3.GasConst + (1 - K) * InputGas3.TempGasConst; InputGas3.TempGasConst = InputGas3.GasConst; InputGas3.Pressure = K * InputGas3.Pressure + (1 - K) * InputGas3.TempPressure; InputGas3.TempPressure = InputGas3.Pressure; InputGas3.Temperature = K * InputGas3.Temperature + (1 - K) * InputGas3.TempTemperature; InputGas3.TempTemperature = InputGas3.Temperature; InputGas3.Charge = K * InputGas3.Charge + (1 - K) * InputGas3.TempCharge; InputGas3.TempCharge = InputGas3.Charge; long double AT1 = InputGas1.IsobarHeat * InputGas1.Charge; long double AT3 = InputGas3.IsobarHeat * InputGas3.Charge; //-------------------------------------------------- OutputGas2.Pressure = InputGas1.Pressure; OutputGas4.Pressure = InputGas3.Pressure; OutputGas2.Temperature = (InputGas1.Temperature * AT1 + InputGas3.Temperature * AT3)/(AT1 + AT3); OutputGas4.Temperature = OutputGas2.Temperature; OutputGas2.Charge = InputGas1.Charge; OutputGas2.IsobarHeat = InputGas1.IsobarHeat; OutputGas2.GasConst = InputGas1.GasConst; OutputGas4.Charge = InputGas3.Charge; OutputGas4.IsobarHeat = InputGas3.IsobarHeat; OutputGas4.GasConst = InputGas3.GasConst; OutputGas2.Capacity_FlowExergs4 = OutputGas2.Charge * (OutputGas2.IsobarHeat * (OutputGas2.Temperature - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6) - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6 * (OutputGas2.IsobarHeat * log(OutputGas2.Temperature * Source1.OutputGas.TempShareExit6 / Source1.OutputGas.TempTemperature) - OutputGas2.GasConst * log(OutputGas2.Pressure * Drain1.InputGas.TempShareExit7 / Drain1.InputGas.Pressure))); OutputGas4.Capacity_FlowExergs4 = OutputGas4.Charge * (OutputGas4.IsobarHeat * (OutputGas4.Temperature - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6) - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6 * (OutputGas4.IsobarHeat * log(OutputGas4.Temperature * Source1.OutputGas.TempShareExit6 / Source1.OutputGas.TempTemperature) - OutputGas4.GasConst * log(OutputGas4.Pressure * Drain1.InputGas.TempShareExit7 / Drain1.InputGas.Pressure))); InputGas1.Capacity_FlowExergs4 = InputGas1.Charge * (InputGas1.IsobarHeat * (InputGas1.Temperature - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6) - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6 * (InputGas1.IsobarHeat * log(InputGas1.Temperature * Source1.OutputGas.TempShareExit6 / Source1.OutputGas.TempTemperature) - InputGas1.GasConst * log(InputGas1.Pressure * Drain1.InputGas.TempShareExit7 / Drain1.InputGas.Pressure))); InputGas3.Capacity_FlowExergs4 = InputGas3.Charge * (InputGas3.IsobarHeat * (InputGas3.Temperature - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6) - Source1.OutputGas.TempTemperature / Source1.OutputGas.TempShareExit6 * (InputGas3.IsobarHeat * log(InputGas3.Temperature * Source1.OutputGas.TempShareExit6 / Source1.OutputGas.TempTemperature) - InputGas3.GasConst * log(InputGas3.Pressure * Drain1.InputGas.TempShareExit7 / Drain1.InputGas.Pressure))); //-------------------------------------------------- /* Объект 1-го уровня (наборы параметров для…): OutputGas2 //- 1-ый выход газа OutputGas4 //- 2-ой выход газа InputGas1 //- 1-ый вход газа InputGas3 //- 2-ой вход газа Объект 2-го уровня (значения параметров): Pressure: Double; //давление Temperature: Double; //температура Charge: Double; //расход IsobarHeat: Double; //изобарная теплоемкость GasConst: Double; //газовая постоянная Capacity_FlowExergs4: Double; //поток эксергии ShareExit4: Double; //доля выхода / //--------------------------------------------------