trixi-framework / Trixi.jl

Trixi.jl: Adaptive high-order numerical simulations of conservation laws in Julia
https://trixi-framework.github.io/Trixi.jl
MIT License
541 stars 110 forks source link

Change name `scalar` to `density` in `LinearAdvectionEquation` #1910

Open ArseniyKholod opened 7 months ago

ArseniyKholod commented 7 months ago

Suggestion from the comment.

"The output after line 49 still shows the variable name scalar. I guess this hard-coded in the example. -> feature request to Trixi.jl: Please, change name scalar to density, because scalar just looks like a type specification :=O"

It's about how name of the variable in LinearScalarAdvection is shown. Take a look for example in https://github.com/trixi-framework/Trixi.jl/blob/dd051566a9079e22dfa792b145c0b50eaafa37fd/src/equations/linear_scalar_advection_1d.jl#L26C70-L26C76.

The same for 2D and 3D.

sloede commented 7 months ago

I have no strong feelings here. If it's really only about the scalar advection equation, density is wrong though IMHO. If scalar is confusing, I'd be OK to rename it something neutral like u, but given that this is the first time I hear about it, I'd like to wait a little to see if this proposal gains more support before considering such a change.

jlchan commented 7 months ago

I like u, though I think concentration would be a better physically-based name than density.

ArseniyKholod commented 7 months ago

I have no strong feelings here. If it's really only about the scalar advection equation, density is wrong though IMHO. If scalar is confusing, I'd be OK to rename it something neutral like u, but given that this is the first time I hear about it, I'd like to wait a little to see if this proposal gains more support before considering such a change.

I think this issue could wait, as it's not usage crucial. But may be to ask Manuel @torrilhon, why it should be density?

torrilhon commented 7 months ago

It is REALLY low-priority! My comment really came from somebody (me) who looked at this output literally with zero knowledge about Trixi at all... and I thought "oh, Trixi tells me the type of the advected quantity"

True, 'density' (something per volume) is actually convected differently. I like 'u' because this nicely connects to the documentation!