Correlated changes in structure and viscosity during gelatinization and gelation of tapioca starch granules