Sorry, but a 40 gallon is much to small for a lungfish, and most lungfish are kept by themselves because they are known to take chunks out of tank mates randomly.
Theres a lot of other fish to put in a 40 gallon, besides lungfish btw lots of oddballs, i believe african knives and african butterfly fish can go in this tank, would be a cool african tank, along with a small school of upside down catfish.