Implementing Ratin g raing