Joint tests of cosmology and modified gravity in light of GW170817
  In this Letter we constrain for the first time both cosmology and modified
gravity theories conjointly, by combining the GW and electromagnetic
observations of GW170817. We provide joint posterior distributions for the
Hubble constant $H_0$, and two physical effects typical of modified gravity:
the gravitational wave (GW) friction, encoded by the parameter $\alpha_M$, and
several GW dispersion relations. Among the results of this analysis, we can
improve by 15\% the bound of the graviton mass with respect to measurement
using the same event, but fixing $H_0$. We obtain a value of
$m^2_g=2.08_{-4.25}^{+13.90} \cdot 10^{-44} \rm{eV^2/c^4}$ at 99.7\% confidence
level (CL), when marginalising over the Hubble constant and GW friction term
$\alpha_M$. We find poor constraints on $\alpha_M$, but demonstrate that for
all the GW dispersions relations considered, including massive gravity, the GW
must be emitted $\sim$ 1.74s before the Gamma-ray burst (GRB). Furthermore, at
the GW merger peak frequency, we show that the fractional difference between
the GW group velocity and $c$ is $\lesssim 10^{-17}$.
