level 2
伏枥老马
楼主
我把一系列数据点插值,然后用DensityPlot把密度图(Fig1)画出来了,但现在我想把它映射到一个圆柱形的曲面上,结果图像Fig2这样的。
查了一下帮助和其他资料好像没找到案例,求各位大佬指路。

Fig1

Fig2
inter[x_, y_] =
Interpolation[plotdata2D, InterpolationOrder -> 3][x, y];
p1 = DensityPlot[inter[x, y], {x, -30, 30}, {y, 30, 120}]
cylin[x_, y_] = Sqrt[50*50 - x^2];
plotdata3D = {{
#[[1, 1]], #
[[1, 2]],
cylin[
#[[1, 1]], #
[[1, 2]]]}, #[[2]]} & /@ plotdata2D
2022年05月16日 03点05分
1
查了一下帮助和其他资料好像没找到案例,求各位大佬指路。

Fig1
Fig2inter[x_, y_] =
Interpolation[plotdata2D, InterpolationOrder -> 3][x, y];
p1 = DensityPlot[inter[x, y], {x, -30, 30}, {y, 30, 120}]
cylin[x_, y_] = Sqrt[50*50 - x^2];
plotdata3D = {{
#[[1, 1]], #
[[1, 2]],
cylin[
#[[1, 1]], #
[[1, 2]]]}, #[[2]]} & /@ plotdata2D