如何从一组点作为地面 XY 基准开始绘制 3D 图形
这个问题可能看起来有点奇怪,但就我的目的而言,并不是那么疯狂。 这很容易,但我需要你跟着我。
目标
我的目标是绘制三维图表。
问题
问题是我手中开始构建这个图表的材料。实际上我有一个二维空间中的点的集合(因此是两个实数有序值的元组)。考虑一下将这些点的集合存储到一个数组中,然后考虑将它们绘制在 2D 图上。您只会对这些点有一个很好的稀疏视图。
那么,第二步是这样的:考虑具有这些点的表面,并创建与绘制这些点的平面正交的第三个轴。目的是为每个点分配一个数值标量值(使用接受该对并返回数值的函数)。因此,图表应显示从每个点开始并根据分配函数具有特定值的条形。
我怎样才能在 Mathematica 中实现这一目标?
一个小注释
基本上我在二维空间中的点也通过图表连接。是否可以将条形的顶部连接到基点在二维图中连接在一起的其他条形的顶部?
其他一些注释
我的图表不一定是一个表面,而只是放置在平面上的条形的集合,这些条形位于它们所引用的对应点所在的确切位置。但如果您有一个很好的提示如何绘制条形以外的曲面,我们将很乐意接受。
我希望我说清楚了。我想指出我有 Mathematica 8,所以所有功能都可用。谢谢。
This question might seem a little strange but for my purposes is not that crazy.
Its easy but I need you to follow me.
The aim
My aim is plotting a tridimensional graph.
The problem
The problem is the material I have in my hands to start building this graph. Actually I have a collection of points in the 2D space (thus tuples of two real ordered values). Consider a moment to have these collection of points stored into an array and now consider to plot them on a 2D diagram. You will just have a nice sparse view of these points.
Well, the second step is this: consider the surface with these points and create a third axis orthogonal to the plane where those points are drawn. The aim is assigning to every point a numerical scalar value (using a function that accepts the couple and returns a numerical value). So the graph should show bars starting from every point and having a specific value according to the assignment function.
How can I achieve this in Mathematica?
A little note
Basically my points in the 2d space are also connected by a graph. Is it possible to connect the top of the bars to the top of other bars whose base point are connected together in the 2d graph?
Some other notes
My graph doesn`t have to be a surface but just a collection of bars placed on a plane in the exact place where the correspondent point they refer to is located. But if you have a good hint how to draw a surface other than bars, it will be gladly accepted.
I hope I was clear. I would like to point that I have Mathematica 8 so all functionalities are available. Thank you.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这可以使用 Graphics3D 原语来完成。让我们从一些数据开始
然后可以按如下方式构建实际绘图(宽度是条形宽度的一半)
This can be done using
Graphics3D
primitives. Lets start with some dataThe actual plot can then be constructed as follows (width is half the width of the bars)