#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int n;
  n = s.size();
  bool loop1 = true;
  int i;
  i = 0;
  while (i < (n - 1) / 2) {
    if (s[i] != s[n - 1 - i]) loop1 = false;
    i++;
  }
  i = 0;
  while (i < (int)((n - 1) / 4)) {
    if (s[i] != s[(n - 1) / 2 - 1 - i]) loop1 = false;
    i++;
  }
  i = (n - 1) / 2 + 1;
  while (i < (n - 1) / 2 + 1 + (int)((n - 1) / 4)) {
    if (s[i] != s[(n - 1) - i]) loop1 = false;
    i++;
  }
  if (!loop1) {
    cout << "No" << endl;
  } else {
    cout << "Yes" << endl;
  }
  return 0;
}
