Hierarchical one-dimensional finite elements for the thermal stress analysis of three-dimensional functionally graded beams