Skip to content

Commit

Permalink
fix compat issue with SymPy 0.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
thorek1 committed Sep 2, 2023
1 parent 95d0c41 commit 9632823
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ RuntimeGeneratedFunctions = "^0.5"
SpecialFunctions = "^2"
SpeedMapping = "^0.3"
Subscripts = "^0.1"
SymPyPythonCall = "^0.1"
SymPyPythonCall = "^0.1.1"
Symbolics = "^5"
julia = "1.8"

Expand Down
3 changes: 2 additions & 1 deletion src/MacroModelling.jl
Original file line number Diff line number Diff line change
Expand Up @@ -919,6 +919,7 @@ function solve_steady_state!(𝓂::β„³, symbolic_SS, Symbolics::symbolics; verbo
push!(𝓂.solved_vals,Meta.parse(string(soll[1][k]))) #using convert(Expr,x) leads to ugly expressions

push!(atoms_in_equations_list, Set(Symbol.(soll[1][k].atoms())))
# push!(atoms_in_equations_list, Set(Symbol.(soll[vars].atoms()))) # to be fixed
push!(SS_solve_func,:($(𝓂.solved_vars[end]) = $(𝓂.solved_vals[end])))
end
end
Expand All @@ -939,7 +940,7 @@ function solve_steady_state!(𝓂::β„³, symbolic_SS, Symbolics::symbolics; verbo

for i in eqs_to_solve
# push!(syms_in_eqs, Symbol.(PythonCall.pystr.(i.atoms()))...)
push!(syms_in_eqs, Symbol.(SPyPyC.free_symbols(i))...)
push!(syms_in_eqs, Symbol.(SPyPyC.unSym.(SPyPyC.free_symbols(i)))...)
end

# println(syms_in_eqs)
Expand Down

0 comments on commit 9632823

Please sign in to comment.