This preview shows page 1. Sign up to view the full content.
Unformatted text preview: size 5 mm x 5mm with about 2 million pixels uniformly distributed on the CCD array. 4. This is a MATLAB programming question. You need to familiarize yourself with the MATLAB environment first. It is strongly encouraged that you go through one of the many online MATLAB tutorials (see, for example, the book’s web site). Write an M-function with the following specifications: function H = imcircle(R, M, N) %IMCIRCLE Generates a circle inside a rectangle. % H = IMCIRCLE(R, M, N) generates a circle of radius R centered % on a rectangle of height M and width N. H is a binary image with % 1s on the circle and 0s elsewhere. R must be an integer >= 1. Your program must check the validity of R and also it should check to make sure that the specified circle fits in the given rectangle dimensions. Use of for or while loops is not permitted. Hint: Review function meshgrid and become familiar with function floor....
View Full Document
This note was uploaded on 12/28/2011 for the course ECE 178 taught by Professor Manjunath during the Fall '08 term at UCSB.
- Fall '08