Fast -> slow -> stop animation using actionscript

i would like to know how to move a shape from left to right using actionscript. the movement should be fast up until it gets to the end point then slow down as it reaches it. i would also like to do this type of animation for a sahpe that shrinks. so basically it starts off as a sqaure or large rectangle then it shrinks up from the bottom while the top stays at the same value. i hope this is being explained well.