IP addresses are tied with the network, not the machine, indefinitely. When you join your computer to a network (for example, via wifi), the network allocates you an IP address for the duration of your connection.