#1. "RE: Optical Slave Flash" In response to Reply # 0
Using the pre-flash of the built-in flash to trigger an off camera slave flash would result in improper syncing of the flash with the shutter. The pre-flash fires before the shutter opens. You could use the built-in flash in manual mode to trigger the other flash. If you didn't want the built-in flash to contribute much to the scene, reduce the flash power to 1/16 or whatever the lowest setting is.
#2. "RE: Optical Slave Flash" In response to Reply # 0
Johns Creek, US
Since the D5100 does not have a CLS commander built in, you have to have either a commander or a flash with a commander on top to use the CLS, from what I understand. This will limit you to a manual optical flash. I have a Yongnuo YN-560 that is optically triggered. It is an inexpensive manual flash that works well off the pop-up.