Got Questions? Get Answers.
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Building 3D surface

Subject: Building 3D surface

From: evan um

Date: 2 Oct, 2009 18:25:05

Message: 1 of 4

I would like to draw the surface of a 3D complex structure.
For the structure, I have a set of data
(x1,y1,z1)
(x2,y2,z2)
.
.
(xn,yn,zn).
All these points are on the surface of the structure.
Using the point, I want to re-construct/interpolate the surface of the structure.
Intervals between the points are totally random.
Can you suggest how to build the 3D surface using MATLAB?
In advance, thanks!

Evan

Subject: Building 3D surface

From: Cesar Koers

Date: 2 Oct, 2009 20:29:51

Message: 2 of 4

evan um wrote:
> I would like to draw the surface of a 3D complex structure.
> For the structure, I have a set of data
> (x1,y1,z1)
> (x2,y2,z2)
> .
> .
> (xn,yn,zn).
> All these points are on the surface of the structure.
> Using the point, I want to re-construct/interpolate the surface of the structure.
> Intervals between the points are totally random.
> Can you suggest how to build the 3D surface using MATLAB?
> In advance, thanks!
>
> Evan
Hi,

I'd suggest using 'patch', which allows you to draw (shaded) faces in 3D


bye

C

Subject: Building 3D surface

From: Luigi Giaccari

Date: 8 Oct, 2009 07:24:05

Message: 3 of 4

"evan um" <evanum@gmail.com> wrote in message <ha5gi1$lq9$1@fred.mathworks.com>...
> I would like to draw the surface of a 3D complex structure.
> For the structure, I have a set of data
> (x1,y1,z1)
> (x2,y2,z2)
> .
> .
> (xn,yn,zn).
> All these points are on the surface of the structure.
> Using the point, I want to re-construct/interpolate the surface of the structure.
> Intervals between the points are totally random.
> Can you suggest how to build the 3D surface using MATLAB?
> In advance, thanks!
>
> Evan

I hope one of these work

http://www.advancedmcode.org/surface-recostruction-from-scattered-points-cloud-mycrustopen.html

http://www.advancedmcode.org/surface-recostruction-from-scattered-points-cloud-mycrust-robust.html

http://www.advancedmcode.org/how-to-plot-a-coloured-surface-from-3d-scatter.html

http://www.advancedmcode.org

Subject: Building 3D surface

From: Sebastiaan

Date: 8 Oct, 2009 07:46:02

Message: 4 of 4

"evan um" <evanum@gmail.com> wrote in message <ha5gi1$lq9$1@fred.mathworks.com>...
> I would like to draw the surface of a 3D complex structure.
> For the structure, I have a set of data
> (x1,y1,z1)
> (x2,y2,z2)
> .
> .
> (xn,yn,zn).
> All these points are on the surface of the structure.
> Using the point, I want to re-construct/interpolate the surface of the structure.
> Intervals between the points are totally random.
> Can you suggest how to build the 3D surface using MATLAB?
> In advance, thanks!
>
> Evan
If it is a surface, make a mesh first and then use griddata to find z:

[XIM, YIM] = meshgrid(linspace(range(1,1), range(2,1), 10), linspace(range(1,2), range(2,2), 10));
ZIM = griddata(values(:,1),values(:,2),values(:,3),XIM,YIM);
mesh(XIM, YIM, ZIM);

where range(1,1) is min(x), range(2,1) is max(x), etc. This generates a mesh with 10x10 gridpoints.

Sebastiaan

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us