created function to determine system size