j-fu / VoronoiFVM.jl

Solution of nonlinear multiphysics partial differential equation systems using the Voronoi finite volume method
MIT License
183 stars 33 forks source link

Discontinous quantities: unexpected behavior #31

Closed fafroo closed 2 years ago

fafroo commented 2 years ago

Setting react =0.0 in https://github.com/j-fu/VoronoiFVM.jl/blob/8a7776fe09f331ca1aec238fc5e1fc347265a979/examples/Example420_DiscontinuousQuantities.jl#L104

turns the dspec the DiscontinuousQuantity in continuous one:

discontinous_a

I'd expect to see some sort of a step function -- depending on the initial condition. @j-fu @dilaraabdel is this behavior as intended?

dilaraabdel commented 2 years ago

Its strange ... Because this would be my output, if setting react to zero:

Figure_1

Can you show all adjustments?

j-fu commented 2 years ago

I second @dilaraabdel - I see the same result. Also be careful, due to the effectively missing (resp. homogeneous Neumann) boundary conditions, the solution for dspec in the interior domains is unique up to a constant.

fafroo commented 2 years ago

@j-fu & @dilaraabdel you're right, the problem is on my side. I've tried a fresh copy and it returns a piece-wise constant solution.

The continuous behavior was due to tinkering with the regionspec field. I set it all constant, which perhaps made the quantity continuous again :).