A problem of broad interest in nonlinear science is to uncover the topologies of unknown complex networks and the equations of the dynamical systems based solely on measured time series. Recently the speaker's group has made progress toward developing general solutions to this inverse problem. In this talk, a framework based on compressive sensing will be discussed in detail. Examples of applications include: (1) predicting catastrophes in dynamical systems, (2) uncovering social-network topologies, and (3) detecting hidden nodes in networks. The methodology is expected to be applicable to networks arising in many fields of science and engineering, such as systems biology.