palindrome [] = True
palindrome [x] = True
palindrome (x:xs) = (x == last xs) && palindrome (init xs)

main = do
  s <- getLine
  let n = length s
  let s1 = (take ((n-1)`div`2) s)
      s2 = (drop ((n+3)`div`2-1) s)
  putStrLn $ if (palindrome s && palindrome s1 && palindrome s2) then "Yes" else "No"