0
$\begingroup$

I am trying to solve a partial differential equation which gives as a solution a function $f(x,y,z,t)$. I would like to visualise this object and assume that this could perhaps be done by means on an animation of a 3d density plot.

Does anybody have a good suggestion for how to tackle this problem?

Thanks!

Edit:

The PDE for the wave equation is $[\partial_t^2-\partial_x^2-\partial_y^2-\partial_z^2]f(x,y,z,t)=0$. My PDE looks very similar to it - it has a nonlinearity in f(x,y,z,t) added. But this does not change the issue with the visualisation. On stackexchange I have not found much about how to effectively visualise such a function. If there is anybody with experience I would be happy!

$\endgroup$
  • 1
    $\begingroup$ Where is the PDE and your try?? $\endgroup$ – zhk Feb 3 '17 at 16:57
  • $\begingroup$ here is a example of a visualization of the 3D transient solution of the heat equation. Warning : ContourPlot3 is very slow (see text)) $\endgroup$ – andre314 Feb 3 '17 at 18:44
3
$\begingroup$

Since you're asking about visualization, I'll just use a random example, but ideally your question should include enough information that people can tackle the part of the problem you want help with. So either provide the solution, or make up an f[x,y,z,t] that suits your problem

One option is to create a table of DensityPlot3D's at different times then animate them, like so:

images=(Image /@ Table[
    DensityPlot3D[
     Sin[x + 2 t] Cos[y + t] Sin[
       z + t], {x, -2 \[Pi], \[Pi]}, {y, -2 \[Pi], 
      2 \[Pi]}, {z, -2 \[Pi], 2 \[Pi]}]
    , {t, 0, 1, 0.1}
    ])

Which you can export as a gif, or apply ListAnimate to, if you just want to see it in the front end.

enter image description here

$\endgroup$
  • $\begingroup$ Thanks. I would have provided an exact solution if I had one. Mine is numerical. I will try to compute the solution at different $t$ and do the same as you in your reply! $\endgroup$ – Hamurabi Feb 4 '17 at 22:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.