import java.io.File

private fun readLn() = readLine()!! // string line
private fun readInt() = readLn().toInt() // single int
private fun readLong() = readLn().toLong() // single long
private fun readStrings() = readLn().split(" ") // list of strings
private fun readInts() = readStrings().map(String::toInt) // list of ints
private fun readLongs() = readStrings().map(String::toLong) // list of longs

var n: Int = 0

fun main(args: Array<String>) {
    val s = readLn()
    if (s == s.reversed()) {
        val s1 = s.substring(0..((s.length - 1) / 2 - 1))
        if (s1 == s1.reversed()) {
            val s2 = s.substring(((s.length + 3) / 2 - 1)..(s.length - 1))
            if (s2 == s2.reversed()) {
                println("Yes")
                return
            }
        }
    }
    println("No")
}
