Reliabiltiy analyis and Optimization