The attainable region interpretation of the thermodynamic principles has indicated that carbon dioxide (CO2) can be either hydrogenated directly to form dimethyl ether (DME) or gasoline. The process that converts CO2 to DME is more thermodynamically favourable at lower temperature. A certain thermodynamic temperature range (25 to 300 °C) is suggested for the conversion of CO2 to DME via a methanol intermediate pathway without addition of work. Optimal synthesis routes derived from P-graph's mutual exclusion solver were compared with reactions reported in literature and showed great correlation. The reactions collectively possess Gibbs free energy of less than zero, and negative enthalpy of reaction. With P-graph attainable region technique, the case studies have demonstrated that the synthesis of DME and gasoline using CO2 hydrogenation via methanol intermediate and carbon monoxide intermediate from Fischer–Tropsch synthesis is feasible with no work and heat requirement. Both case studies have demonstrated visual advantage of P-graph and data-driven applications. The benefit of integrating the P-graph framework with machine learning model like decision tree classifier was also demonstrated in the second case study as it solves topological optimisation problems without scaling constraints.