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

Learn moreOpportunities for recent engineering grads.

Apply TodayTo resolve issues starting MATLAB on Mac OS X 10.10 (Yosemite) visit: http://www.mathworks.com/matlabcentral/answers/159016

Asked by Feruza on 5 Dec 2012

I need to find maximum absolute value of displacement in a connected closed region, which is a 2D region closed by 3 neighboring circle regions of radius 'r' (they touch each other but do not overlap). Centers of the circles are (x1,y1), (x2,y2), (x3,y3). I calculated the magnitude of displacement field in 2D region, meshing [-2,2]x[-2,2] rectangle([X,Y]=meshgrid(-2:0.1:2)). From this region I need to subtract nodes which are outside the closed region I need to find the set of nodes such that: [X,Y] subtract {((X-x1)^2+(Y-y1)^2)<=(r)^2 && ((X-x2)^2+(Y-y2)^2) <=(r)^2 && ((X-x3)^2+(Y-y3)^2) <=(r)^2 && "region outside the circles"}. Then using "find" operator and the nodes inside the inclosed area I could find max value of displacement. Since my displacement vector is complex valued I used 'norm(U)' to find absolute value of U in each node.

I calculated max(max(Norm_U)) but it gives me max value in the whole region: [-2,2]x[-2,2] rectangle.

Do you have any idea?

Thank you so much.

Feruza

*No products are associated with this question.*

## 1 Comment

Direct link to this comment:http://www.mathworks.com/matlabcentral/answers/55820#comment_115580

A diagram or screenshot would really help here. Please upload one.