What I'm getting at is I'd like to know how the Monero network can know that a key image used in a transaction is not either forged (probably an easy answer) or created from a different output owned by the same wallet (perhaps a more technical, but hopefully straightforward, answer).

The transaction private key, `x`, probably signs the ring and the key image, right?  My hunch is that the distinctive ring signature provides a way to check the math that `P` (the transaction public key) being spent is a ring member, and is also associated with `I`, the key image that's attached to the ring signature.  

How does it work?  I don't understand how the verification works without revealing the actual tx pub key being spent.

I've been reading other SE questions and answers [here][1], [here][2], and [here][3].  I haven't found an answer expressed in the way I'd like to understand it.


  [1]: https://monero.stackexchange.com/questions/2883/what-is-a-key-image
  [2]: https://monero.stackexchange.com/questions/2158/what-is-moneros-mechanism-for-defending-against-a-double-spend-attack?noredirect=1&lq=1
  [3]: https://monero.stackexchange.com/questions/4015/is-making-a-key-image-public-equal-to-giving-the-monero-in-that-output-away