Let [tex]x[/tex] be the number of non-fiction books. We deduce that the number of fiction books is [tex]2x[/tex], since they are twice as much.
Since the difference between the two numbers is 17, we have
[tex]2x-x=17\iff x=17[/tex]
So, Henry has 17 non-fictional and 34 fictional books, for a total of 51 books.