References

Contents

Index

ThermoCycleGlides.ORC — Type

ORC{T<:Real} <: ThermoCycleProblem

Defines an Organic Rankine Cycle (ORC) problem with thermodynamic and design parameters specified in Kelvin and dimensionless efficiencies.

Fields

  • fluid::EoSModel: Equation of State (EoS) model representing the working fluid.
  • z::AbstractVector{T}: Mole fraction composition vector of the working fluid.
  • T_evap_in::T: Inlet temperature of the evaporator [K].
  • T_evap_out::T: Outlet temperature of the evaporator [K].
  • ΔT_sh::T: Degree of superheating at the expander inlet [K].
  • T_cond_in::T: Inlet temperature of the condenser [K].
  • T_cond_out::T: Outlet temperature of the condenser [K].
  • ΔT_sc::T: Degree of subcooling at the pump inlet [K].
  • η_pump::T: Isentropic efficiency of the pump [-].
  • η_expander::T: Isentropic efficiency of the expander [-].
  • pp_evap::T: Minimum temperature difference (pinch point) at the evaporator [K].
  • pp_cond::T: Minimum temperature difference (pinch point) at the condenser [K].
source
ThermoCycleGlides.ORCEconomizer — Type
    ORCEconomizer{T<:Real} <: ThermoCycleProblem

Defines an Organic Rankine Cycle (ORC) configuration with an economiser (regenerative heat exchanger), extending the base ORC problem with a specified effectiveness.

Fields

  • orc::ORC{T}: Base ORC system definition containing the thermodynamic parameters.
  • ϵ::T: Effectiveness of the economiser (regenerator) [-].
source
ThermoCycleGlides.SolutionState — Type

SolutionState - A struct to hold the solution state of the nonlinear solver.

  • x::Vector{T}: The solution vector.
  • f_calls::I: The number of function calls made during the solving process.
  • iterations::I: The number of iterations taken to converge.
  • residuals::Vector{T}: The residuals at the solution.
  • lb::Vector{T}: The lower bounds used in the solver.
  • ub::Vector{T}: The upper bounds used in the solver.
  • autodiff::Bool: A flag indicating whether automatic differentiation was used.
  • fd_order::I: The order of finite difference used if autodiff is false.
  • lenx::T: The final change in the solution vector.
  • lenf::T: The final change in the residuals.
  • soltype::Symbol: A symbol indicating the type of cycle (:unknown,:subcritical,:transcritical). This will be updated with the cycle type after solving.
source
ThermoCycleGlides.COP — Method
COP(prob::ThermoCycleGlides.ThermoCycleProblem, sol::SolutionState) -> Float64

Computes the coefficient of performance (COP) of a thermodynamic cycle given the problem definition and its corresponding solution state.

Arguments

  • prob::ThermoCycleGlides.ThermoCycleProblem: The thermodynamic cycle problem containing fluid models, boundary conditions, and component parameters.
  • sol::SolutionState: The solution state object containing the converged state variables (x), residuals, and convergence information.
source
ThermoCycleGlides.optimize — Method

optimize(prob::ThermoCycleProblem; kwargs...)

Its goal is to find the optimal subcooling and superheating values that maximize the cycle performance (COP or ORC -efficiency).

This should return the optimized cycle struct and the result from Metaheuristics

source
ThermoCycleGlides.solve — Method
Solves for pressure values in HP and ORC cycles for the given glide and problem parameters. 
Define those problems in the respective structs. 
For now the default box-nonlinear solver is newton-raphson, but this can be changed to other solvers in the future.
source
ThermoCycleGlides.η — Method
η(prob::ThermoCycleGlides.ThermoCycleProblem, sol::SolutionState) -> Float64

Computes the thermal efficiency of a thermodynamic cycle given a problem definition and its corresponding solution state.

Arguments

  • prob::ThermoCycleGlides.ThermoCycleProblem: The thermodynamic cycle problem containing fluid properties, boundary conditions, and component parameters.
  • sol::SolutionState: The solution state object containing the converged state variables (x), residuals, and convergence information.

Returns

  • Float64: The computed cycle efficiency, defined as the ratio of net work output to heat input.

Notes

This method acts as a wrapper that extracts the solution vector x from sol and calls the lower-level η(prob, x) implementation.

source