For your requirements , It is actually not necessary to use any functions or calculations.
In Tableau we have a Filter type called "Relative filter".
Below link will explain in detail. Explore the options
Thanks for your response. We have tried this options earlier but not help ful. Below is the details of requirements.
5 dimensions are there for that I have need to show.
Current month + 2 months data. For example if user selection is Jan-2015 then automatically i need to get the data for next two months.
Above Relative filters will work for one time only. Please correct me if I am wrong.
Please share your packaged workbook , this can be achieved by using parameters concepts, i can do it for you .