For example, see this transaction: https://blockchain.info/de/tx/517c634fcf802bb8114516bc32718acf8a4e360decb7d93859e913f958d7bb6d
In my understanding, the bunch of input addresses (usually) come from a single HD wallet. I.e. a transaction input address is hierarchically derived from the previous one and so on. Is this true for every transaction? What else could be a reason for multiple input addresses? Is there any way/method/ready-to-use-script that I can input with some address from an HD wallet and that generates a series of child addresses? Say, I know some (hierarchically older) address of the user who sent this transaction. This method would allow me to compare the thus generated child addresses against the input addresses visible in the transaction. Hence, if there is a match, I would be able to link this transaction to this particular user. Is this train of thoughts correct?