import Foundation

let input = readLine()!
let N = input.count

let firstString  = input
let endString = input


let firstPalindrome = input.dropLast((N - 1) / 2 + 1).map{ String($0)}
let endPalindrome = input.dropFirst((N + 3) / 2 - 1).map{ String($0)}




let StringNums = firstString.count
let halfNums = StringNums / 2



for i in 0...halfNums - 1 {
    if firstPalindrome[i] != firstPalindrome[halfNums - i - 1] || endPalindrome[i] != endPalindrome[halfNums - i - 1] {
        print("No")
        break
    } else if i == halfNums - 1 {
        print("Yes")
    }
}

