In this research we design a passive controller for an above knee prosthesis. The controller is a linear spring and damper for swing phase motion, parameters of which determined via optimization of adjustment of the prosthesis shank motion with a desired shank angle trajectory comes from experimental data. In this way, we exerted a certain thigh motion, hip movement included, into the system as its input and found a set of unknown parameters such that the model output gets as close as possible to a certain output which is shank motion in normal level walking. Also a robustness analysis of the controller with respect to input motion changes included to show the effectiveness in real application.