To connect your iPhone 7 Plus to a Samsung TV, you can use either of the following methods:
Wirelessly: Ensure that both the iPhone and TV are on the same Wi-Fi connection. Launch the Samsung SmartView app.(which you may have to download on your phone) It will ask you to enter the code that appears on your Samsung Smart TV screen. Enter the pin, and the device should automatically connect to your TV.
Wired: Connect your iPhone to your Samsung TV with an HDMI cable to achieve the same effect. You will need a Lightning Digital AV Adapter and an HDMI cable for this method. Plug one end of the HDMI cable into your TV and the other end of it into the Lightning Digital AV adapter. Then, plug the AV adapter into your iPhone.