Functional Component Analysis and Regression Using Elastic Methods