MethodOfLines

Hi Everybody & happy new year to all :slight_smile:

Happy new year Alex and Chris :slight_smile:

I installed the new version of Julia 1.10. I was surprised by not usual error in MethodOfLines package … so I uninstalled it and used the one proposed in this fork

but this did not work I still have the exact same error bellow

UndefVarError: issymbollike not defined

Stacktrace:
[1] getindex(A::SciMLBase.PDETimeSeriesSolution{Float64, 2, Dict{Num, Array{Float64, 3}}, MethodOfLines.MOLMetadata{Val{true}(), MethodOfLines.DiscreteSpace{2, 2, MethodOfLines.CenterAlignedGrid}, MOLFiniteDifference{MethodOfLines.CenterAlignedGrid, MethodOfLines.ScalarizedDiscretization}, PDESystem, Base.RefValue{Any}, Nothing, MethodOfLines.ScalarizedDiscretization},

@ MethodOfLines ~/.julia/packages/MethodOfLines/qu7lv/src/interface/solution/common.jl:49

I will be happy if one of you folks could help me … maybe I’m not using the package proposed by Aayush Sabharwal the right way ?

What I did is : 1- remove the official MethodOfLines and 2- install the one proposed by Aayush Sabharwal

this way

] add GitHub - AayushSabharwal/MethodOfLines.jl: Automatic Finite Difference PDE solving with Julia SciML

I do not know If I’m doing this right ?

Naceur

Everything go fine until the need to retrieve the solution in order to plot it to analyze the physics. The bug seems to occur at that very last stage, that all what I can say for now.

Naceur

None of the examples provided in the doc page works now :frowning: !
They all worked just fine before.

The error is : UndefVarError: issymbollike not defined

Hi, first of all you can use an Environment for this Project. Here you install all that you need and when installing Method of Lines you use add https://github.com/AayushSabharwal/MethodOfLines.jl#as/issymbollike i.e. “”“add https://github.com/username/package_name#branch_name”“” then it will work nicely

1 Like

MethodOfLines didn’t quite follow the symbolic indexing interface and so when it updated it didn’t have a kind effect on it :sweat_smile:. We’re working through this.

3 Likes

Hi Gabo :slight_smile:

I did that, create a directory in which I installed all the needed packages along with the proposed fork of MethodOfLines as I mentioned

It seems that colleagues are working hard to solve the issue.

Have a nice day
Naceur

Hi Chris :slight_smile:

Great ! I will wait until the tests give you the green light. :slight_smile:

If something changes in our syntax to retrieve the solution,
for example, a new way of writing the following :

discrete_x = sol[x]
discrete_y = sol[y]
discrete_t = sol[t]

solu = sol[u(x, y, t)]
solv = sol[v(x, y, t)]

In The Brusselator PDE web page example. I will be happy to write this in all the web pages of the tutorials, if this could save you some time, that’s easy for me it’s just syntax and tests of all the provided examples :smiley:

Have A Nice Day

Naceur

I don’t think we plan to change that surface level syntax, just how it’s done.

1 Like

Yes, Chris, Right :slightly_smiling_face: And this makes a lot of sense if the surface level is invariant. This is always the case with Julia’s updates, packages get better and better without asking the user to change the syntax

Hi there. Working through the MethodOfLines tutorial myself just now in Julia 1.10, I hit the same trouble extracting results and a WWW-search for the UndefVarError led me here. By poking around in sol in the VS Code IDE, I did find a way to reproduce the GIF:

anim = @animate for (k, tk) in enumerate(sol.t)
    heatmap(sol.u[v(x, y, t)][2:end, 2:end, k], title="$tk")
end

We don’t need the coordinates for this, but they can be obtained with, e.g., sol.disc_data.discretespace.grid[x].

1 Like