Hello and Assalam O Elikum Every one, My name is Mustafa, and i am looking for a help in development of a code... well the equation i have is H(X) = p(X1) log2(1/p(X1)) + ... + p(Xn) log2(1/p(Xn)). Its a entropy of the message equation details can be take from "groups.google.com/group/m_e_telecom/web/information-theory-and-coding---lecture-1" now i have stuck up at the input stage, where we normally have to take inputs like 1/2, 3/4, or 5/2 etc .... and the second variable is n. where n decides the number of inputs to be taken..... its basically a probability program. Can any one Help me for this ? I will be really thank full.. Muhammad Hassaan Mustafa