title "L2 SOLUTION U,XX + U + X = 0" ! begin keywords nodes 7 ! Number of nodes in the mesh elems 6 ! Number of elements in the system dof 1 ! Number of unknowns per node el_nodes 2 ! Maximum number of nodes per element space 1 ! Solution space dimension b_rows 1 ! Number of rows in the B (operator) matrix shape 1 ! Element shape, 1=line, 2=tri, 3=quad, 4=hex remarks 7 ! Number of user remarks gauss 2 ! Maximum number of quadrature points pt_list ! List the answers at each node point post_1 ! Post-processing, create n_tape1, for gradients post_2 ! Post-processing, create n_tape2, for norm exact_case 9 ! Analytic solution for list_exact, etc list_exact ! List given exact answers at nodes, etc list_exact_flux ! List given exact fluxes at nodes, etc example 104 ! Analytic solution for list_exact, etc data_set 1 ! Data for "example" (may set exact_case) quit ! keyword input U,XX + U + X = 0, U(0)=0=U(1), U = Sin(x)/Sin(1) - x Here we use six linear (L2) line elements. Notes: 1) The FE solution is continuous, but the gradients are not continuous between elements. 2) The (negative of the) reactions give a much more accurate estimate of the gradients at the boundary than the value found by evaluating a element gradient at the boundary. 1 1 0. ! node, bc_flag, x 2 0 0.166666667 3 0 0.333333333 4 0 0.5 5 0 0.666666667 6 0 0.833333334 7 1 1.00 1 1 2 ! elem, two nodes 2 2 3 3 3 4 4 4 5 5 5 6 6 6 7 1 1 0. ! node, dof, essential value 7 1 0.