The JSP variables exist when the JSP is being processed on the server. At that point the Javascript variables are just markup. Later, when the output of the JSP is processed on the client, the Javascript variables exist but the JSP variables are long gone.
So you can't do that. I would attempt to answer the real question behind your question but I can't tell what it is.