13
$\begingroup$

I've recently come across these plots in this article (sorry for not posting the image directly, I'm not sure if I'm allowed to do it) and couldn't reproduce many aspects of it. I'll list some of my attempts(using a Gaussian function instead of his):

Attempt 1: Lots of plotpoints + color data rainbow + rescale:

color[x_] := ColorData["Rainbow"][x]
test = Function[{x, y, z}, color[Rescale[z, {-0.4, 1.05}]]]

Plot3D[Abs@Exp[-(x^2 + y^2)], {x, -5, 5}, {y, -5, 5}, Mesh -> None, 
 PlotPoints -> 200, ColorFunction -> test, Boxed -> False, 
 PlotRange -> All, RegionFunction -> Function[{x, y, z}, x^2 + y^2 < 25]]

The output is not only duller, it also seems to skip some colors much quicker, I suppose the original plot color gradient is diferent, but I don't know how to get any closer to it.

Attempt 2: The same as above + blending(trying to get the colors to be brighter)

color[x_] := Blend[{GrayLevel[1], ColorData["Rainbow"][x]}]

No matter what graylevel I input, it either looks like pastel or duller than the previous attempt.

Another aspect I couldn't replicate was the shadow bellow the plot,which I suppose requires the use of the Graphics function, but I couldn't get it to work.

Could anyone give me some tips on how to get closer to the desired result?

$\endgroup$
  • 2
    $\begingroup$ These plots are indeed beautiful. You can try to get shinier colors with Glow. However, the plots in the linked article were probably produced by a raytracer. Mathematica does not have any native raytracing capabilities. But you can try to export your plots and use, e.g. POVray or blender for raytracing. $\endgroup$ – Henrik Schumacher Apr 4 '18 at 18:47
  • 2
    $\begingroup$ "I'm not sure if I'm allowed to do it" I am sure you are allowed to. Paper is in public domain. You just have to include a reference next to the plot as where it was obtained from, that is all. $\endgroup$ – Nasser Apr 4 '18 at 19:46
  • $\begingroup$ Which software used to generate the plots? $\endgroup$ – Nasser Apr 4 '18 at 19:50
  • 1
    $\begingroup$ @Nasser the license seems to be arxiv.org/licenses/nonexclusive-distrib/1.0/license.html which does not put the paper into the public domain. That said, it's common academic practice to simply lift a figure in a situation like this in exchange for a citation. $\endgroup$ – evanb Apr 9 '18 at 16:13
10
$\begingroup$

thanks for the interest. "I'm not sure if I'm allowed to do it" -> it's science, feel free to use it!

The 3-D modelling was done in Mathematica and then exported as .stl (maybe this is not the optimal format). For the raytracing blender 2.79 was used. Albeit I think this workflow is okayish, I was wondering if there is a good blender package for scientific visualization?
Has anybody experiences with this? Generalized Wigner Function

$\endgroup$
  • 1
    $\begingroup$ Could you share the Mathematica part of the code? Now I guess I need to learn to use blender, these plots are just too beautiful $\endgroup$ – Pedro Portugal Apr 5 '18 at 1:35
  • 1
    $\begingroup$ what a moment!! $\endgroup$ – Pedro Harunari Apr 5 '18 at 1:39
  • 1
    $\begingroup$ Hi, please consider including the Mathematica code you used for your plots in this answer. Also, consider registering. $\endgroup$ – J. M. is away Apr 9 '18 at 14:41
  • $\begingroup$ There are some difficulties when you want to solve this more generally. The major pain is that someone needs to look through the Charting code so that we can extract graphics primitives for the ticks and axes that Mathematica uses. There is no direct way to do this afaik and in many other disciplines, a plot without labels and numbers is not acceptable. Re-using colors might be another problem. What if you have colored the e.g. curvature of your surface and you want to combine this with the material? These are some reasons why probably no one (including me) ever crossed the "do it manually" $\endgroup$ – halirutan Apr 9 '18 at 15:25
  • $\begingroup$ boundary. Nevertheless, your plots look very pleasing and modern. +1 $\endgroup$ – halirutan Apr 9 '18 at 15:26

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.