My 16 month old boy has been doing this for a while:
He will lay down on the floor and proceed to stiffly stretch out/flex both legs. Then while flexed, he will squeeze his legs close together and continue this over and over again.
While he is doing this, he's clearly working hard/concentrating, but will continue to look/interact/smile sometimes with us, so it's not like a seizure type thing.
He will also sometimes stop and get up, only to realize he's not really finished, and lay down again and keep going. Sometimes he might sit and do this for 10 minutes straight, maybe longer.
I brought it up with the ped who said it sounds like constipation. I made a little video of it and am going to make an appointment to show the doctor because it didn't really go away with traditional constipation remedies. (although we weren't really all that consistent with implementing them).
Thoughts guys? I tend to be a worrier and this is freaking me out just a hair.