fun isKaibun(input: String): Boolean {
    val mid = if(input.length % 2 == 0) { input.length/2 - 1 } else {input.length /2 }
    return (0..mid).map { input[it] == input[input.length - 1 - it] }.all { it }
} 

fun main(args: Array<String>) {
    val S = readLine()!!
    val N = S.length
    if(isKaibun(S) && isKaibun(S.substring(0, ((N - 2)/ 2) + 1)) && isKaibun(S.substring(((N - 1 + 3)/2), N))) { "Yes" } else { "No" }.run(::println)
}