0

I have problem with meshing this polygon:

enter image description here

I need fill this polygon with one of this finite element:

enter image description here

I don't how to type a code for this problem and then plot this polygon with mesh, all without using PDEtool.

Thank you.

MrPitivier
  • 71
  • 9

1 Answers1

0

I made sth like that:

matX = [0,0.2,0;
        0.2,0.2,0;
        0.2,1,0.2;
        1,1,0.2;
        0,0.2,0;
        0.2,0.2,0;
        0.2,1,0.2]

matY = [0,0,0.5;
        0,0.5,0.5;
        0,0,0.5;
        0,0.5,0.5;
        0.5,0.5,1;
        0.5,1,1;
        0.5,0.5,1]

x = zeros(7,4);
y = zeros(7,4);    

for i=1:7    
    x(i,:) = [matX(i,1),matX(i,2),matX(i,3),matX(i,1)];
    y(i,:) = [matY(i,1),matY(i,2),matY(i,3),matY(i,1)];
    plot(x(i,:),y(i,:))
    hold on
end

Mesh:

enter image description here

Have anyone better and more sophisticated solution?

MrPitivier
  • 71
  • 9
  • Looks like a start to me. Now you should do what every FEA practitioner would do: get a solution, refine the mesh, and continue until the answers don't change anymore. It's called "checking convergence". – duffymo Jan 26 '15 at 13:42
  • I made it all FEM stuff in Matlab. Our HW was like: create a program in Matlab, that will be calculate stress, strain etc similiar to NX, Catia etc. Really terrible HW, but done it, thank you for all your response, help me :) – MrPitivier Jan 27 '15 at 07:49
  • Terrible HW? Sounds like a great problem. – duffymo Jan 27 '15 at 11:15
  • Not the best in examination period, a lot of exams. ;) But it is useful HW. – MrPitivier Jan 27 '15 at 12:21