Calculating 3d vectors

60 Views Asked by At

I am not a mathematician so I apologise if I get some terminology wrong.

I am analysing a signal V that varies in two dimensions (X,Y) looking for boundaries as indicated by maximum rate of change of V.

I have calculated the first differential in each direction (dVdX and dVdY). The peaks (+ve and -ve) in these accurately indicate the boundaries that I wish to detect.

I now want to combine the individual differentials at a given point to find the angle of the (tangent to the) boundary in the XY plane. Actually I want to find the line orthogonal to the boundary but I can manage that transformation.

The units are kind-of arbitrary(see edit) in that they have been through a lot of processing, but are about right. So I can take atan(KdVdX) and atan(KdVdY) and get reasonable looking results (for chosen value of K).

I feel that I have enough information in dVdX and dVdY to determine the result, but cannot figure out the correct mathematical incantation.

Can anyone help with this? Even better if you can explain it so that I can understand - but please remember that maths is not my native language.

Thanks in advance

Edit: The signal V is derived from rgb data and has been pre-multiplied to remove rounding errors during integer arithmetic. The value of V at any point is between zero and 195840. The differential is always against unit value.

@John Hughes: Yes thanks You are exactly right about the process that I am using, but Sobel is not accurate enough. I am following the method described by Deriche - which is similar to Canny, but replacing the Sobel with smoothing followed by simple differencing. The results are very pleasing.

When I have the tangents/orthogonals I will be doing arc extension as in Canny.

Edit 2: The boundaries are assumed to be smooth curves.

1

There are 1 best solutions below

0
On

It turns out that this was remarkably simple.... I just needed prodding in the right direction.

The vector orthogonal to the curve is simply (∂V∂x,∂V∂y). Works well in the software, giving lines that match expectations well.

Thanks to John Hughes for the help he gave.