> with(linalg):
Warning, the protected names norm and trace have been redefined and
unprotected

> a(x):=-6*x/l^2+6*x^2/l^3: b(x):=1-4*x/l+3*x^2/l^2;
> c(x):=6*x/l^2-6*x^2/l^3: d(x):=-2*x/l+3*x^2/l^2;                      
>  

                                             2
                                    4 x   3 x
                        b(x) := 1 - --- + ----
                                     l      2
                                           l


                                            2
                                   2 x   3 x
                         d(x) := - --- + ----
                                    l      2
                                          l

> J:=matrix(4,4,[a(x)*a(x),a(x)*b(x),a(x)*c(x),a(x)*d(x),b(x)*a(x),b(x)*
> b(x),b(x)*c(x),b(x)*d(x),c(x)*a(x),c(x)*b(x),c(x)*c(x),c(x)*d(x),d(x)*
> a(x),d(x)*b(x),d(x)*c(x),d(x)*d(x)]):
> n:=(P/10)*evalm((10)*map(int,J,x=0..l));

                       [  12                  12          ]
                       [ ----       1      - ----      1  ]
                       [  l                   l           ]
                       [                                  ]
                       [           4 l                    ]
                       [  1        ---       -1      - l/3]
                       [            3                     ]
           n := 1/10 P [                                  ]
                       [   12                12           ]
                       [- ----     -1       ----      -1  ]
                       [   l                 l            ]
                       [                                  ]
                       [                              4 l ]
                       [  1       - l/3      -1       --- ]
                       [                               3  ]

> 
> 
