Lines Matching refs:p

135   PetscInt           dim, d, Np, p;  in RHSFunction()  local
144 for (p = 0; p < Np; ++p) { in RHSFunction()
146 g[(p * 2 + 0) * dim + d] = u[(p * 2 + 1) * dim + d]; in RHSFunction()
147 g[(p * 2 + 1) * dim + d] = -PetscSqr(omega) * u[(p * 2 + 0) * dim + d]; in RHSFunction()
163 PetscInt dim, d, Np, p, rStart; in RHSJacobian() local
171 for (p = 0; p < Np; ++p) { in RHSJacobian()
173 const PetscInt rows[2] = {(p * 2 + 0) * dim + d + rStart, (p * 2 + 1) * dim + d + rStart}; in RHSJacobian()
186 PetscInt Np, p; in RHSFunctionX() local
192 for (p = 0; p < Np; ++p) xres[p] = v[p]; in RHSFunctionX()
203 PetscInt Np, p; in RHSFunctionV() local
209 for (p = 0; p < Np; ++p) vres[p] = -PetscSqr(omega) * x[p]; in RHSFunctionV()
219 PetscInt dim, d, Np, p, rStart; in RHSJacobianS() local
227 for (p = 0; p < Np; ++p) { in RHSJacobianS()
229 const PetscInt rows[2] = {(p * 2 + 0) * dim + d + rStart, (p * 2 + 1) * dim + d + rStart}; in RHSJacobianS()
243 PetscInt dim, Np, p; in RHSObjectiveF() local
251 for (p = 0; p < Np; ++p) { in RHSObjectiveF()
252 … const PetscReal x2 = DMPlex_DotRealD_Internal(dim, &u[(p * 2 + 0) * dim], &u[(p * 2 + 0) * dim]); in RHSObjectiveF()
253 … const PetscReal v2 = DMPlex_DotRealD_Internal(dim, &u[(p * 2 + 1) * dim], &u[(p * 2 + 1) * dim]); in RHSObjectiveF()
269 PetscInt dim, d, Np, p; in RHSFunctionG() local
278 for (p = 0; p < Np; ++p) { in RHSFunctionG()
280 g[(p * 2 + 0) * dim + d] = PetscSqr(omega) * u[(p * 2 + 0) * dim + d]; in RHSFunctionG()
281 g[(p * 2 + 1) * dim + d] = u[(p * 2 + 1) * dim + d]; in RHSFunctionG()
402 PetscInt dim, d, Np, p; in ComputeError() local
415 for (p = 0; p < Np; ++p) { in ComputeError()
419 const PetscReal x0 = DMPlex_NormD_Internal(dim, &coords[p * dim]); in ComputeError()
422 …const PetscReal x = DMPlex_DotRealD_Internal(dim, &u[(p * 2 + 0) * dim], &coords[p * dim]) / x… in ComputeError()
423 …const PetscReal v = DMPlex_DotRealD_Internal(dim, &u[(p * 2 + 1) * dim], &coords[p * dim]) / x… in ComputeError()
428 …%.6lf %.6lf] exact [%.6lf %.6lf] energy/exact energy %g / %g (%.10lf%%)\n", p, (double)PetscAbsRea… in ComputeError()
431 e[(p * 2 + 0) * dim + d] = u[(p * 2 + 0) * dim + d] - coords[p * dim + d] * ct; in ComputeError()
432 e[(p * 2 + 1) * dim + d] = u[(p * 2 + 1) * dim + d] + coords[p * dim + d] * omega * st; in ComputeError()
448 PetscInt dim, Np, p; in EnergyMonitor() local
461 for (p = 0; p < Np; ++p) { in EnergyMonitor()
462 … const PetscReal x2 = DMPlex_DotRealD_Internal(dim, &u[(p * 2 + 0) * dim], &u[(p * 2 + 0) * dim]); in EnergyMonitor()
463 … const PetscReal v2 = DMPlex_DotRealD_Internal(dim, &u[(p * 2 + 1) * dim], &u[(p * 2 + 1) * dim]); in EnergyMonitor()
467 … %4" PetscInt_FMT " %4" PetscInt_FMT " %10.4lf %10.4lf\n", (double)t, step, p, (double)E, (double)… in EnergyMonitor()