Skip to content

Commit fe351fd

Browse files
committed
remove unused code
1 parent 2e164bf commit fe351fd

File tree

8 files changed

+14
-24
lines changed

8 files changed

+14
-24
lines changed

src/methods/pT.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1052,7 +1052,7 @@ export gibbs_energy,helmholtz_energy,gibbs_energy_res,helmholtz_energy_res
10521052
export mass_enthalpy,mass_entropy,mass_internal_energy,mass_gibbs_energy,mass_gibbs_free_energy,mass_helmholtz_energy,mass_helmholtz_free_energy
10531053
#second derivative order properties
10541054
export isochoric_heat_capacity, isobaric_heat_capacity,adiabatic_index
1055-
export mass_isobaric_heat_capacity,mass_isobaric_heat_capacity
1055+
export mass_isobaric_heat_capacity,mass_isochoric_heat_capacity
10561056
export isothermal_compressibility, isentropic_compressibility, speed_of_sound
10571057
export isobaric_expansivity, joule_thomson_coefficient, inversion_temperature
10581058
#higher derivative order properties

src/methods/property_solvers/multicomponent/bubble_point.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -525,7 +525,7 @@ function bubble_temperature_init(model,p,x,vol0,T0,y0,volatiles)
525525
end
526526

527527
"""
528-
bubble_temperature(model::EoSModel, p, x,method::BubblePointMethod = ChemPotBubbleTemperature())
528+
bubble_temperature(model::EoSModel, p, x,method::ThermodynamicMethod = ChemPotBubbleTemperature())
529529
530530
Calculates the bubble temperature and properties at a given pressure `p`.
531531
Returns a tuple, containing:

src/models/CompositeModel/LiquidVolumeModel/LiquidVolumeModel.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
abstract type LiquidVolumeModel <: GibbsBasedModel end
22

3-
include("NaNLiquid/NaNLiquid.jl")
3+
include("ZeroLiquid/ZeroLiquid.jl")
44
include("Rackett/RackettLiquid.jl")
55
include("COSTALD/costald.jl")
66
include("DIPPR105Liquid/DIPPR105Liquid.jl")

src/models/CompositeModel/LiquidVolumeModel/NaNLiquid/NaNLiquid.jl renamed to src/models/CompositeModel/LiquidVolumeModel/ZeroLiquid/ZeroLiquid.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ liquid = ZeroLiquid(["water","carbon dioxide"])
2525
ZeroLiquid
2626

2727
export ZeroLiquid
28-
const NaNLiquid = ZeroLiquid
28+
29+
@deprecate NaNLiquid(args...;kwargs...) ZeroLiquid(args...;kwargs...)
2930

3031
function volume_impl(model::ZeroLiquidModel,p,T,z,phase,threaded,vol0)
3132
_0 = zero(first(z))

src/models/CompositeModel/SaturationModel/SaturationModel.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ function saturation_temperature_impl(model::SaturationModel,p,method::Saturation
3535
return sol,nan,nan
3636
end
3737

38-
#this method allows to use a Saturation Model as a whole fluid model. it supposes ideal gas and no info about the liquid phase (NaNLiquid)
38+
#this method allows to use a Saturation Model as a whole fluid model. it supposes ideal gas and no info about the liquid phase (ZeroLiquid)
3939
function init_puremodel(model::SaturationModel,components,userlocations,verbose)
4040
_components = format_components(components)
41-
fluid = CompositeModel(_components,gas=BasicIdeal(),liquid=NaNLiquid(),saturation = model)
41+
fluid = CompositeModel(_components,gas=BasicIdeal(),liquid=ZeroLiquid(),saturation = model)
4242
return EoSVectorParam(fluid,_components)
4343
end
4444

src/models/cubic/alphas/CPAAlpha.jl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ end
5353
const sCPAAlphaModel = CPAAlphaModel
5454

5555
@newmodelsimple sCPAAlpha CPAAlphaModel CPAAlphaParam
56-
56+
export sCPAAlpha
5757
"""
5858
sCPAAlpha <: sCPAAlphaModel
5959
@@ -91,6 +91,7 @@ alpha = sCPAAlpha(["water","carbon dioxide"];userlocations = (;c1 = [0.67,0.76])
9191
sCPAAlpha
9292
default_locations(::Type{sCPAAlpha}) = ["SAFT/CPA/sCPA/sCPA_like.csv"]
9393

94+
#=
9495
@newmodelsimple eCPAAlpha CPAAlphaModel CPAAlphaParam
9596
9697
"""
@@ -128,4 +129,5 @@ alpha = eCPAAlpha(["water","carbon dioxide"];userlocations = (;c1 = [0.67,0.76])
128129
129130
"""
130131
eCPAAlpha
131-
default_locations(::Type{eCPAAlpha}) = ["SAFT/CPA/eCPA/eCPA_like.csv"]
132+
default_locations(::Type{eCPAAlpha}) = ["SAFT/CPA/eCPA/eCPA_like.csv"]
133+
=#

src/models/cubic/alphas/RKAlpha.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
abstract type RKAlphaModel <: AlphaModel end
22

33
@newmodelsingleton RKAlpha RKAlphaModel
4+
export RKAlpha
45

56
"""
67
RKAlpha <: RKAlphaModel
@@ -45,4 +46,4 @@ function α_function(model::CubicModel,V,T,z::SingleComp,alpha_model::RKAlphaMod
4546
Tc = model.params.Tc.values[1]
4647
Tr = T/Tc
4748
α = 1 /sqrt(Tr)
48-
end
49+
end

src/utils/macros.jl

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,4 @@
11
#const IDEALTYPE = Union{T,Type{T}} where T<:EoSModel
2-
3-
"""
4-
arbitraryparam(params)
5-
6-
Returns the first field in the struct that is a subtype of `ClapeyronParam`. Errors if it finds none.
7-
"""
8-
function arbitraryparam(params)
9-
paramstype = typeof(params)
10-
idx = findfirst(z->z <: ClapeyronParam,fieldtypes(paramstype))
11-
if isnothing(idx)
12-
error("The parameter struct ", paramstype, " must contain at least one ClapeyronParam")
13-
end
14-
return fieldnames(paramstype)[idx] |> z->getfield(params,z)
15-
end
16-
172
"""
183
@groups
194
@@ -622,6 +607,7 @@ the necessary traits to make the model compatible with Clapeyron routines.
622607
This macro is a no-op from Clapeyron 0.5 onwards.
623608
"""
624609
macro registermodel(model)
610+
Base.depwarn("`@registermodel` is deprecated, it is a no-op.")
625611
esc(model)
626612
end
627613

0 commit comments

Comments
 (0)