You could buy 2 Rheinland-Pfalz tickets, 29 EUR each, but that kind of kills the economics.
These tickets are sold like this: the 1st passenger costs 24 EUR and it is 5 EUR for each extra person up to 5 total traveling together. If there are up to 2 people on the ticket, they can take any number of their own children aged 14 and under, but not 3 people on the ticket. So you have to buy 2 2-person tickets, one with the parents and their children 14 and under, and the other with the 2 children that are over 14. All the names of the travelers must be written on the back of the ticket. If you buy them at the ticket window, there is a 2 EUR service charge, so they should be bought out of a ticket machine to save money. You could also get them with a DB app on your smart-phone, but the kids on the other ticket would also need a smartphone for their tickets.
Monday to Friday, you must travel only on regional trains after 9 am, weekends and German holidays you can travel anytime. It is good in the German Land of Rheinland-Pfalz, which covers the Rhine River down to just south of Bonn. It is good for any number of journeys until 3 am the next day. Do not get on ICE, IC, or EC trains. The tickets are not valid on these trains. You also get a discount when you show the tickets for the K-D tour boats.