Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

simplified interface #891

Open
rveltz opened this issue Sep 30, 2021 · 3 comments
Open

simplified interface #891

rveltz opened this issue Sep 30, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@rveltz
Copy link

rveltz commented Sep 30, 2021

Hi,

I am really interested in using your package for solving McKean-Vlasov equations describing the distribution of mean field of particles. All examples I have in mind are like (say in 2d), x=(x1,x2)

However, I find there is quite some boilerplate to implement in order to use your package.

  1. Would it be possible to borrow the definition of the problem like in Gridap? I understand if this is akinng for too much ;)

You could focus on nonlinear reaction diffusion equations like

du/dt = ∇(c(x,u) + d(x,u) ∇ NL(x,u)) + f(x, u)

Could you not define a struct asking for the functions c,d,NL,f, the discretisation, the boundary conditions and return a problem that implement the discretisation.

Even if this is a subset of what your package can handle, I'd say it would be helpful.

That you for your valuable tool

PS: I posted the same issue on (VoronoiFVM)[https://github.com/WIAS-PDELib/VoronoiFVM.jl/issues/20] which is akin to Trixi

@ranocha
Copy link
Member

ranocha commented Oct 1, 2021

Right now, Trixi.jl focuses on first-order hyperbolic systems. Second-order terms still need to be implemented and are on our radar (see, e.g., #704, #356, #497). Thus, we need to focus on first-order terms in this request for now. What kind of c do you have in mind - linear, scalar? The Your function f is basically what we have as source_terms right now, so that's basically done.

@ranocha ranocha added the enhancement New feature or request label Oct 1, 2021
@ranocha
Copy link
Member

ranocha commented Oct 1, 2021

I imagine it could be possible to define some more general interfaces for problem setups. However, creating proper and stable (!) discretizations out of it for general hyperbolic problems is quite demanding... So far, most of our developers are working on high-order methods and stability issues etc. and a lot of effort has been spent to come up with the type of discretizations in use today (not only in Trixi.jl). Currently, I don't think it's possible to automate this completely. However, it might be an option to start looking at some general and robust low-order methods to get something like this. In general, I definitely like the idea of creating an interface like

prob = HyperbolicProblem(flux, source_terms, boundary_conditions, initial_condition, geometry) # flux == your c, source_terms == your f
sol = solve(prob, tolerances_or_size) # choose some method automagically

@jlchan
Copy link
Contributor

jlchan commented Jun 1, 2023

In case it's still helpful, we now have (somewhat experimental) support for parabolic terms. See https://trixi-framework.github.io/Trixi.jl/stable/tutorials/adding_new_parabolic_terms/ and the tutorial before it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants