Assuming the formula is F = ((T-25)/308)*(S-64) and not F = (T-25)/(308*(S-64))

T=(308*F/(S-64))+25
S=(308*F/(T-25))+64

:P