In this paper, we develop a framework for solving optimal trajectory generation problems with probabilistic uncertainty in system parameters. The framework is based on the generalized polynomial chaos theory. We consider both linear and nonlinear dynamics in this paper and demonstrate transformation of stochastic dynamics to equivalent deterministic dynamics in higher dimensional state space. Minimum expectation and variance cost function are shown to be equivalent to standard quadratic cost functions of the expanded state vector. Results are shown on a stochastic Van der Pol oscillator.