Hi guys. It can be done. If both your instructors are formation trained then you can both go up and do what you like.
Now the bad news. Chances are your instructors will just say no to the idea.
It looks good on paper but in reality a non-starter. Do a search here on formation flying and then look on the map for somewhere to stand on the way to video your mate from the ground as what you intend is seriously a bad idea.
Wait untill you have both passed out then take a formation flying course with someone like Ultimate High.
Please take the advice here seriously. We have some of the best formation flyers signed up here on pprune, whatever they recommend please take it seriously.
Regarding your question saying you have 40+ hours, then you clearly don't understand what all this involves or you wouldn't be asking. This is not a bad thing by the way, just trying to put over how serious the risks are involved in formation flying.
I have just searched and brought back to the top a thread when I asked all about this subject a while ago.