Variable stars as essential astrophysical tools