% Boundary conditions (fixed nodes 1 and 3) fixed = [1 1 0; 3 1 0]; % node, x-dof fixed (1), y-dof free (0) loads = [3 1 -10000]; % node 3, x-direction, -10 kN
Start with a simple 1D bar code, then graduate to 2D triangles, then 3D bricks. Download the hot community codes from File Exchange, but most importantly: modify, break, and rebuild them. That is how you move from a user to a developer of FEA. matlab codes for finite element analysis m files hot
% Assemble and solve [K, F] = assembleTruss(nodes, elements, fixed, loads); U = K \ F; % Nodal displacements % Boundary conditions (fixed nodes 1 and 3)