Mr Chong intends to purchase a few chickens, rabbits and ducks for his farm. The total numbers of animal is 50. He has RM1500 to be spent. A chicken costs RM20, A rabbit RM50 and a duck RM30. The number of chickens is equal to the number of ducks. How many of each animals should Mr Chong purchase? Write a system of linear equations to solve this problem.