We study the optimal tax system when taxpayers earn different kinds of income by supplying different inputs. Imperfect substitution between inputs allows for general equilibrium effects. We consider any type of cross-base responses to tax changes such as income-shifting. Formalizing the tax schedule as the sum of many one-dimensional schedules, we express optimal marginal tax rate on any kind of income in terms of sufficient statistics, including new ones for cross-base responses and general equilibrium effects. We also identify the conditions under which making the personal income tax marginally more schedular is socially desirable. The comprehensive and schedular (dual, in particular) income taxes being recurring proposals in the public debate, we derive sufficient conditions under which each form of tax is optimal. We stress how empirically restrictive these conditions are. Using a new algorithm on French tax return data, we characterize the optimal combination of a nonlinear tax schedule on personal income and a linear tax rate on capital income. We find that one should include, without any deduction, all income sources in the personal income base and subsidize the source of income which is more elastic. We find that crossbase responses have little effects on the personal nonlinear income tax schedule but increases by 5.9 to 6.9 percentage points the capital tax rate. General equilibrium effects also increases this tax rate by around 4.5 percentage points.