## 1D wave PDE with extended periodic IC

I have formula for 1D wave equation:

(*) u(x, t) = 1/2 [ f(x + ct) + f(x - ct) ] + 1 / (2c) Integral( g(s), wrt
s, from x-ct to x+ct )

I am trying to find u(1/2, 3/2) when L = 1, c = 1, f(x) = 0, g(x) = x(1 -
x).

However, for (*) to work, the initial position f(x) and initial velocity
g(x) must be extended to periodic functions.

"To determine f(x) and g(x) we need only find the integer n s.t. nL <= x <
(n+1)L, [where L is the right boundary length from the origin]."

It then gives the ways of extending if n is even or odd. If even, gx) =
g(x - nL). If odd, g(x) = -g((n+1)L - x).

How do I determine what n is for g to extend it correctly?

I need to figure out nL <= x < (n+1)L, yes. But what is x for g? For
f(x+ct) it is clear. But g is in the integral...
 PhysOrg.com science news on PhysOrg.com >> King Richard III found in 'untidy lozenge-shaped grave'>> Google Drive sports new view and scan enhancements>> Researcher admits mistakes in stem cell study
 did you take your question from 'A First Course in Partial Differential Equations with complex variables and transform methods' by H F Weinberger? anyway here is that question i had posted earlier http://physicsforums.com/showthread.php?t=90027