A 1D Euler-Bernoulli beam with uncertain bending rigidity (w=EI) and subjected to deterministic distributed load is analyzed by the spectral stochastic finite element method. This reference example is described in Sec. (5.2) of the book: "Stochastic finite elements: A spectral approach" by Ghanem and Spanos.
The main function 'SSFEM_EB_beam.m' contains a step-by-step solution of this problem. Several references to equations and useful comments are written in order to provide a better understanding of the code. The program estimates for a number terms in the Karhunen-Loève expansion (variable 'KLterms') and a given order of the polynomial chaos (variable 'p_order'), the corresponding PDF and CDF of the displacement at a given degree of freedom of the beam. For comparison purposes, the folder 'result_MCS' contains a .txt file with the solution obtained by the Monte Carlo simulation method.
Any suggestions, corrections and/or improvements will be kindly received :-)