The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Including an area into a circle
Replies: 20   Last Post: Jan 19, 2011 9:43 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 13,022
Registered: 12/26/06
Re: Including an area into a circle
Posted: Jan 19, 2011 3:48 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

On Jan 19, 3:07 pm, "Spulber " <> wrote:
> Hello, I have been waiting for a new response, and I have been trying to figure it out myself but I ended up with an insucces.
> Can anyone please tell me how to generate a number of circles without them being on top of each other, or how to take each line from a vector?
> What I have been trying to do is that:
> -I have been trying to take each line and to compare it with the next one, so if the difference between one of the elements is 1, that means they are neighbours.
> Let's take an example:
> rc=[ 100 67; 100 68; 100 74; ...]
> My question is how to put each value into a variable, or something like this?
> I am open minded, because I realise that there might be an easier way, but I am not aware of it.
> Thank you!

Spulber :
I didn't understand your rc example. Each number IS in a variable -
it's in the rc variable.

If you want to know the difference between pixel values, you can use
imfilter, conv2, or diff.
If you want to know which pixels are connected to each other
(neighbors), you can use bwlabel or bwconncomp.

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2017. All Rights Reserved.