Receiving PyObject instead of Sym while appending result of a sympify to an empty list!

I just found another way to turn around this issue which is better than adding and removing an auxiliary element. To define my empty list as a one-dimensional array with entries of type Sym and no entry.

f=Array{Sym,1}()

Now everything works fine without need of an extra step in the algorithm.

for i in List
       append!(f,sympify(i))
end
diff(f[1],x[1])
1 Like