In this paper, we define the notion of rigidity for linear electrical multiports and for matroid pairs. We show the parallel between the two and study the consequences of this parallel. We present applications to testing, using purely matroidal methods, whether a connection of rigid multiports yields a linear network with unique solution. We also indicate that rigidity can be regarded as the closest notion to duality that can be hoped for, when the spaces correspond to different physical constraints, such as topological and device characteristic. A multiport is an ordered pair $(\V^1_{AB},\A^2_{B}),$ where $\V^1_{AB}$ is the solution space on $A\uplus B$ of the Kirchhoff current and voltage equations of the graph of the multiport and $\A^2_{B}\equivd \alpha_B+\V^2_B$ is the device characteristic of the multiport, with $A$ corresponding to port voltages and currents and $B$ corresponding to internal voltages and currents. The pair $\{\V^1_{AB},\alpha_B+\V^2_{B}\}$ is said to be rigid iff it has a solution $(x_A,x_B)$ for every vector $\alpha_B$ and given a restriction $x_A$ of the solution, $x_B$ is unique. A matroid $\M_S$ on $S,$ is a family of `independent' sets with the property that maximal independent sets contained in any given subset of $S$ have the same cardinality. The pair $\{\M^1_{AB},\M^2_{B}\}$ is said to be rigid iff the two matroids have disjoint bases which cover $B.$ We show that the properties of rigid pairs of matroids closely parallel those of rigid multiports. We use the methods developed in the paper to show that a multiport with independent and controlled sources and positive or negative resistors, whose parameters can be taken to be algebraically independent over $\Q,$ is rigid, if certain simple topological conditions are satisfied by the device edges., Comment: keywords: Rigidity, multiports, matroids, implicit duality