Hi, @thanhlamtrinh.
From what I understood, there are indeed situations where a certain optimization algorithm may not be the best option. The important thing is whether they’re representative of the error surface of your problem.
The example presented by Professor Ng is probably a good approximation for a common situation when training a neural network.
Here’s a very interesting post by @jonaslalin on this topic.
Good luck with course 2