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:
find the gradient in 3D data and fit the plane

Subject: find the gradient in 3D data and fit the plane

From: Mitul

Date: 12 Apr, 2012 11:32:11

Message: 1 of 5

Hi

I am new to image processing so please forgive me if I am asking to simple thing but I would appreciate your time and support.

I have 3D data which is x,y,& z coordinate. I am converting that data into matrix and then I use mesh to plot the point cloud data of z coordinate. I am observing a half spherical (not exactly) surface after plotting data set. Now my main intention to find the depth of this sphere (surface defect).

I want to find data points where it starts forming half sphere form the surface. Once I could find these data points, i want to fit the plane there and I have deepest point in z direction and then I can find perpendicular distance from that point to the plane.

How can I do this? Please feel free to ask if you don;t understand what exactly I am trying to do as I don't have any high technical terminology to explain my question.

Thank you very much
Regards,
Mitul

Subject: find the gradient in 3D data and fit the plane

From: Matt Kindig

Date: 13 Apr, 2012 14:28:11

Message: 2 of 5

I understand the first part of what you are trying to do, but have a few clarifying questions:

First you want to fit a subset of your coordinate data to a half sphere. Some questions:
- Can you easily tell which points are part of the half sphere, and which are not?
- Do you have points on the flat circular portion of the half sphere (the "bottom" face if the half-sphere were sitting on a table)?
- How many points do you have that are part of the half sphere for fitting?

I really don't understand the second part. You want to fit a plane to which points? Do you want the plane of the bottom of the half sphere, or some other plane?

I think one thing that would really help us is if we could see some of your data. Could you upload a representative set of your coordinate data for us?

Thanks,
Matt


"Mitul " <m.tailor@lboro.ac.uk> wrote in message <jm6efr$5nc$1@newscl01ah.mathworks.com>...
> Hi
>
> I am new to image processing so please forgive me if I am asking to simple thing but I would appreciate your time and support.
>
> I have 3D data which is x,y,& z coordinate. I am converting that data into matrix and then I use mesh to plot the point cloud data of z coordinate. I am observing a half spherical (not exactly) surface after plotting data set. Now my main intention to find the depth of this sphere (surface defect).
>
> I want to find data points where it starts forming half sphere form the surface. Once I could find these data points, i want to fit the plane there and I have deepest point in z direction and then I can find perpendicular distance from that point to the plane.
>
> How can I do this? Please feel free to ask if you don;t understand what exactly I am trying to do as I don't have any high technical terminology to explain my question.
>
> Thank you very much
> Regards,
> Mitul

Subject: find the gradient in 3D data and fit the plane

From: Nic Roberts

Date: 13 Apr, 2012 14:28:13

Message: 3 of 5

Hi,

Sorry if I'm misunderstanding you but wouldnt the maxium z value give you the greatest depth?

Nic

Subject: find the gradient in 3D data and fit the plane

From: Mitul

Date: 14 Apr, 2012 16:33:22

Message: 4 of 5

Hi Matt,

Thank you for your time and interest. Here are the answer of your questions

1. Can you easily tell which points are part of the half sphere, and which are not?

Well, The 3D data is of defect on metal plate. There's surface roughness. But certainly you can see the points on surface of half sphere.

2. Do you have points on the flat circular portion of the half sphere (the "bottom" face if the half-sphere were sitting on a table)?
I didn't understand what exactly you are saying but I am sending you my point cloud data on your email id which will help you to asnwer this question. (Hope that is ok with you as i could'nt find anything where I can attached my data here on forum.)

3. How many points do you have that are part of the half sphere for fitting?
Well, I am converting my 3D data into binari image and from that I am finding the boundary of the defect which has maximum area. And I have dataset(x,y) of this boundary which is [797*2]

I want to fit the plane to these data point of boundary which will represents starting of the defect on the surface.

Please check your email for my datapoint and code.

Thank you very much.
Kind regards
Mitul

"Matt Kindig " <mkindig@ric.org> wrote in message <jm9d5r$he9$1@newscl01ah.mathworks.com>...
> I understand the first part of what you are trying to do, but have a few clarifying questions:
>
> First you want to fit a subset of your coordinate data to a half sphere. Some questions:
> - Can you easily tell which points are part of the half sphere, and which are not?
> - Do you have points on the flat circular portion of the half sphere (the "bottom" face if the half-sphere were sitting on a table)?
> - How many points do you have that are part of the half sphere for fitting?
>
> I really don't understand the second part. You want to fit a plane to which points? Do you want the plane of the bottom of the half sphere, or some other plane?
>
> I think one thing that would really help us is if we could see some of your data. Could you upload a representative set of your coordinate data for us?
>
> Thanks,
> Matt
>
>
> "Mitul " <m.tailor@lboro.ac.uk> wrote in message <jm6efr$5nc$1@newscl01ah.mathworks.com>...
> > Hi
> >
> > I am new to image processing so please forgive me if I am asking to simple thing but I would appreciate your time and support.
> >
> > I have 3D data which is x,y,& z coordinate. I am converting that data into matrix and then I use mesh to plot the point cloud data of z coordinate. I am observing a half spherical (not exactly) surface after plotting data set. Now my main intention to find the depth of this sphere (surface defect).
> >
> > I want to find data points where it starts forming half sphere form the surface. Once I could find these data points, i want to fit the plane there and I have deepest point in z direction and then I can find perpendicular distance from that point to the plane.
> >
> > How can I do this? Please feel free to ask if you don;t understand what exactly I am trying to do as I don't have any high technical terminology to explain my question.
> >
> > Thank you very much
> > Regards,
> > Mitul

Subject: find the gradient in 3D data and fit the plane

From: Mitul

Date: 14 Apr, 2012 16:36:13

Message: 5 of 5

"Nic Roberts" wrote in message <jm9d5t$hem$1@newscl01ah.mathworks.com>...
> Hi,
>
> Sorry if I'm misunderstanding you but wouldnt the maxium z value give you the greatest depth?
>
> Nic

Hi Nic

Data which I have is a real sample data of the metal plate which has defects on. There's surface roughness. We have deepest point but we dont have refrence point/line/plane from where we can find the depth.
Thank you for your time.

Mitul

Tags for 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