"use strict";
    
const main = arg => {
    arg = arg.trim().split("\n");
    const S = arg[0].split("");
    
    if(S.join("") !== S.reverse().join("")) {
        console.log("No");
        return;
    }
    
    let prefix = S.slice(0 , (S.length - 1) / 2);
    let suffix = S.slice(Math.ceil(S.length / 2), S.length);
    
    if(prefix.join("") !== prefix.reverse().join("")) {
        console.log("No")
        return;
    }

    if(suffix.join("") !== suffix.reverse().join("")) {
        console.log("No")
        return;
    }
    
    console.log("Yes");
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));