That entirely depends on the quality of the restoration. A 40k restoration can be good or bad, depending on the shop. Personally, if I were going to drop that kind of cash on a restoration that I wouldn't be around to oversee, I'd want the job handled by a coupe-specific expert, like La Jolla or Coupeking over a regular/reputable indy. I'm not saying the indy wouldn't do a good job, they probably would, but the experts know far more about the E9 in particular, and would do things a certain way, whereas an indy may just do them the normal way.
I've seen some regular E9s (with superb restorations) go for ~40k, but it has to be a perfect and original restoration to get that kind of cash for a standard E9. If it were a CSL, 40k would be about the going rate for a nicely repaired one, with concourse versions going up to 100k+.
In terms of investment quality, over the last 5-10 years E9 prices have risen by about 5%/year, for a given quality level. So, yeah, if you hold on to it and don't bang it up, you should be able to recoup your investment later.