Memory management API

Hello.

Can anybody give me an advice for a tutorial about the differences among the several API functions for working with memory? I want answers for questions like:

How is the better way to allocate a matrix in CUDA? (cudaMallocPitch, cudaMallocArray…) and respectively what function should I use to copy data to and from the device.

John.

Any help would be welcome.

John.