/*
  This file was generated automatically with scripts/maple2c.py.
  Do not edit this file directly as it can be overwritten!!

  This Source Code Form is subject to the terms of the Mozilla Public
  License, v. 2.0. If a copy of the MPL was not distributed with this
  file, You can obtain one at http://mozilla.org/MPL/2.0/.

  Maple version     : Maple 2022 (X86 64 LINUX)
  Maple source      : ./maple/mgga_exc/mgga_x_2d_js17.mpl
  Type of functional: mgga_exc
*/

#define maple2c_order 4
#define MAPLE2C_FLAGS (XC_FLAGS_I_HAVE_EXC | XC_FLAGS_I_HAVE_VXC | XC_FLAGS_I_HAVE_FXC | XC_FLAGS_I_HAVE_KXC | XC_FLAGS_I_HAVE_LXC)


#ifndef XC_DONT_COMPILE_EXC
GPU_DEVICE_FUNCTION static inline void
func_exc_unpol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t3, t4, t6, t7, t9, t10, t12, t14;
  double t16, t17, t18, t19, t20, t21, t22, t23;
  double t24, t26, t27, t29, t32, t33, t43, t44;
  double t45, t48, t52, tzk0;


  t3 = rho[0] / 0.2e1 <= p->dens_threshold;
  t4 = sqrt(M_PI);
  t6 = 0.1e1 <= p->zeta_threshold;
  t7 = p->zeta_threshold - 0.1e1;
  t9 = my_piecewise5(t6, t7, t6, -t7, 0);
  t10 = 0.1e1 + t9;
  t12 = sqrt(p->zeta_threshold);
  t14 = sqrt(t10);
  t16 = my_piecewise3(t10 <= p->zeta_threshold, t12 * p->zeta_threshold, t14 * t10);
  t17 = 0.1e1 / t4 * t16;
  t18 = M_SQRT2;
  t19 = sqrt(rho[0]);
  t20 = t18 * t19;
  t21 = rho[0] * rho[0];
  t22 = t21 * rho[0];
  t23 = 0.1e1 / t22;
  t24 = sigma[0] * t23;
  t26 = sigma[0] * sigma[0];
  t27 = t21 * t21;
  t29 = 0.1e1 / t27 / t21;
  t32 = 0.1e1 + 0.82505922498838542062e0 * t24 + 0.25211952768090192343e-2 * t26 * t29;
  t33 = pow(t32, 0.1e1 / 0.15e2);
  t43 = 0.1e1 + 0.55877026877520282455e-1 * t24 + (-0.1544e0 * tau[0] / t21 - 0.11596246802930644802e2) / M_PI / 0.4e1;
  t44 = pow(t32, 0.1e1 / 0.5e1);
  t45 = 0.1e1 / t44;
  t48 = 0.1e1 / t33 + 0.2e1 / 0.5e1 * t43 * t45;
  t52 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t48);
  tzk0 = 0.2e1 * t52;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

}

#endif


#ifndef XC_DONT_COMPILE_VXC
GPU_DEVICE_FUNCTION static inline void
func_vxc_unpol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t3, t4, t6, t7, t9, t10, t12, t14;
  double t16, t17, t18, t19, t20, t21, t22, t23;
  double t24, t26, t27, t29, t32, t33, t43, t44;
  double t45, t48, t52, tzk0;

  double t54, t59, t60, t61, t63, t64, t67, t73;
  double t77, t78, t81, t86, tvrho0, t90, t92, t99;
  double t103, tvsigma0, tvlapl0, t105, t107, t111, tvtau0;


  t3 = rho[0] / 0.2e1 <= p->dens_threshold;
  t4 = sqrt(M_PI);
  t6 = 0.1e1 <= p->zeta_threshold;
  t7 = p->zeta_threshold - 0.1e1;
  t9 = my_piecewise5(t6, t7, t6, -t7, 0);
  t10 = 0.1e1 + t9;
  t12 = sqrt(p->zeta_threshold);
  t14 = sqrt(t10);
  t16 = my_piecewise3(t10 <= p->zeta_threshold, t12 * p->zeta_threshold, t14 * t10);
  t17 = 0.1e1 / t4 * t16;
  t18 = M_SQRT2;
  t19 = sqrt(rho[0]);
  t20 = t18 * t19;
  t21 = rho[0] * rho[0];
  t22 = t21 * rho[0];
  t23 = 0.1e1 / t22;
  t24 = sigma[0] * t23;
  t26 = sigma[0] * sigma[0];
  t27 = t21 * t21;
  t29 = 0.1e1 / t27 / t21;
  t32 = 0.1e1 + 0.82505922498838542062e0 * t24 + 0.25211952768090192343e-2 * t26 * t29;
  t33 = pow(t32, 0.1e1 / 0.15e2);
  t43 = 0.1e1 + 0.55877026877520282455e-1 * t24 + (-0.1544e0 * tau[0] / t21 - 0.11596246802930644802e2) / M_PI / 0.4e1;
  t44 = pow(t32, 0.1e1 / 0.5e1);
  t45 = 0.1e1 / t44;
  t48 = 0.1e1 / t33 + 0.2e1 / 0.5e1 * t43 * t45;
  t52 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t48);
  tzk0 = 0.2e1 * t52;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t54 = t18 / t19;
  t59 = 0.1e1 / t33 / t32;
  t60 = 0.1e1 / t27;
  t61 = sigma[0] * t60;
  t63 = t27 * t22;
  t64 = 0.1e1 / t63;
  t67 = -0.24751776749651562619e1 * t61 - 0.15127171660854115406e-1 * t26 * t64;
  t73 = -0.16763108063256084736e0 * t61 + 0.24573523213388639842e-1 * tau[0] * t23;
  t77 = 0.1e1 / t44 / t32;
  t78 = t43 * t77;
  t81 = -t59 * t67 / 0.15e2 + 0.2e1 / 0.5e1 * t73 * t45 - 0.2e1 / 0.25e2 * t78 * t67;
  t86 = my_piecewise3(t3, 0, -t17 * t54 * t48 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t81);
  tvrho0 = 0.2e1 * rho[0] * t86 + 0.2e1 * t52;

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t90 = sigma[0] * t29;
  t92 = 0.82505922498838542062e0 * t23 + 0.50423905536180384686e-2 * t90;
  t99 = -t59 * t92 / 0.15e2 + 0.22350810751008112982e-1 * t23 * t45 - 0.2e1 / 0.25e2 * t78 * t92;
  t103 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t99);
  tvsigma0 = 0.2e1 * rho[0] * t103;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  t105 = t16 * t18;
  t107 = 0.1e1 / t19 / rho[0];
  t111 = my_piecewise3(t3, 0, 0.18485501104083811416e-2 * t105 * t107 * t45);
  tvtau0 = 0.2e1 * rho[0] * t111;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

}

#endif


#ifndef XC_DONT_COMPILE_FXC
GPU_DEVICE_FUNCTION static inline void
func_fxc_unpol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t3, t4, t6, t7, t9, t10, t12, t14;
  double t16, t17, t18, t19, t20, t21, t22, t23;
  double t24, t26, t27, t29, t32, t33, t43, t44;
  double t45, t48, t52, tzk0;

  double t54, t59, t60, t61, t63, t64, t67, t73;
  double t77, t78, t81, t86, tvrho0, t90, t92, t99;
  double t103, tvsigma0, tvlapl0, t105, t107, t111, tvtau0;

  double t114, t121, t123, t124, t128, t129, t131, t132;
  double t135, t141, t144, t148, t149, t154, t159, tv2rho20;
  double t165, t169, t171, t176, t181, t186, t191, tv2rhosigma0;
  double tv2rholapl0, t195, t199, t204, tv2rhotau0, t207, t218, t222;
  double tv2sigma20, tv2sigmalapl0, t227, tv2sigmatau0, tv2lapl20, tv2lapltau0, tv2tau20;


  t3 = rho[0] / 0.2e1 <= p->dens_threshold;
  t4 = sqrt(M_PI);
  t6 = 0.1e1 <= p->zeta_threshold;
  t7 = p->zeta_threshold - 0.1e1;
  t9 = my_piecewise5(t6, t7, t6, -t7, 0);
  t10 = 0.1e1 + t9;
  t12 = sqrt(p->zeta_threshold);
  t14 = sqrt(t10);
  t16 = my_piecewise3(t10 <= p->zeta_threshold, t12 * p->zeta_threshold, t14 * t10);
  t17 = 0.1e1 / t4 * t16;
  t18 = M_SQRT2;
  t19 = sqrt(rho[0]);
  t20 = t18 * t19;
  t21 = rho[0] * rho[0];
  t22 = t21 * rho[0];
  t23 = 0.1e1 / t22;
  t24 = sigma[0] * t23;
  t26 = sigma[0] * sigma[0];
  t27 = t21 * t21;
  t29 = 0.1e1 / t27 / t21;
  t32 = 0.1e1 + 0.82505922498838542062e0 * t24 + 0.25211952768090192343e-2 * t26 * t29;
  t33 = pow(t32, 0.1e1 / 0.15e2);
  t43 = 0.1e1 + 0.55877026877520282455e-1 * t24 + (-0.1544e0 * tau[0] / t21 - 0.11596246802930644802e2) / M_PI / 0.4e1;
  t44 = pow(t32, 0.1e1 / 0.5e1);
  t45 = 0.1e1 / t44;
  t48 = 0.1e1 / t33 + 0.2e1 / 0.5e1 * t43 * t45;
  t52 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t48);
  tzk0 = 0.2e1 * t52;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t54 = t18 / t19;
  t59 = 0.1e1 / t33 / t32;
  t60 = 0.1e1 / t27;
  t61 = sigma[0] * t60;
  t63 = t27 * t22;
  t64 = 0.1e1 / t63;
  t67 = -0.24751776749651562619e1 * t61 - 0.15127171660854115406e-1 * t26 * t64;
  t73 = -0.16763108063256084736e0 * t61 + 0.24573523213388639842e-1 * tau[0] * t23;
  t77 = 0.1e1 / t44 / t32;
  t78 = t43 * t77;
  t81 = -t59 * t67 / 0.15e2 + 0.2e1 / 0.5e1 * t73 * t45 - 0.2e1 / 0.25e2 * t78 * t67;
  t86 = my_piecewise3(t3, 0, -t17 * t54 * t48 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t81);
  tvrho0 = 0.2e1 * rho[0] * t86 + 0.2e1 * t52;

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t90 = sigma[0] * t29;
  t92 = 0.82505922498838542062e0 * t23 + 0.50423905536180384686e-2 * t90;
  t99 = -t59 * t92 / 0.15e2 + 0.22350810751008112982e-1 * t23 * t45 - 0.2e1 / 0.25e2 * t78 * t92;
  t103 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t99);
  tvsigma0 = 0.2e1 * rho[0] * t103;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  t105 = t16 * t18;
  t107 = 0.1e1 / t19 / rho[0];
  t111 = my_piecewise3(t3, 0, 0.18485501104083811416e-2 * t105 * t107 * t45);
  tvtau0 = 0.2e1 * rho[0] * t111;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t114 = t18 * t107;
  t121 = t32 * t32;
  t123 = 0.1e1 / t33 / t121;
  t124 = t67 * t67;
  t128 = 0.1e1 / t27 / rho[0];
  t129 = sigma[0] * t128;
  t131 = t27 * t27;
  t132 = 0.1e1 / t131;
  t135 = 0.99007106998606250476e1 * t129 + 0.10589020162597880784e0 * t26 * t132;
  t141 = 0.67052432253024338944e0 * t129 - 0.73720569640165919526e-1 * tau[0] * t60;
  t144 = t73 * t77;
  t148 = 0.1e1 / t44 / t121;
  t149 = t43 * t148;
  t154 = 0.16e2 / 0.225e3 * t123 * t124 - t59 * t135 / 0.15e2 + 0.2e1 / 0.5e1 * t141 * t45 - 0.4e1 / 0.25e2 * t144 * t67 + 0.12e2 / 0.125e3 * t149 * t124 - 0.2e1 / 0.25e2 * t78 * t135;
  t159 = my_piecewise3(t3, 0, t17 * t114 * t48 / 0.6e1 - 0.2e1 / 0.3e1 * t17 * t54 * t81 - 0.2e1 / 0.3e1 * t17 * t20 * t154);
  tv2rho20 = 0.2e1 * rho[0] * t159 + 0.4e1 * t86;

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 0] += tv2rho20;

  t165 = t123 * t92;
  t169 = sigma[0] * t64;
  t171 = -0.24751776749651562619e1 * t60 - 0.30254343321708230812e-1 * t169;
  t176 = t23 * t77;
  t181 = t92 * t67;
  t186 = 0.16e2 / 0.225e3 * t165 * t67 - t59 * t171 / 0.15e2 - 0.67052432253024338946e-1 * t60 * t45 - 0.44701621502016225964e-2 * t176 * t67 - 0.2e1 / 0.25e2 * t144 * t92 + 0.12e2 / 0.125e3 * t149 * t181 - 0.2e1 / 0.25e2 * t78 * t171;
  t191 = my_piecewise3(t3, 0, -t17 * t54 * t99 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t186);
  tv2rhosigma0 = 0.2e1 * rho[0] * t191 + 0.2e1 * t103;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 0] += tv2rhosigma0;

  tv2rholapl0 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 0] += tv2rholapl0;

  t195 = 0.1e1 / t19 / t21;
  t199 = t107 * t77;
  t204 = my_piecewise3(t3, 0, -0.27728251656125717124e-2 * t105 * t195 * t45 - 0.36971002208167622832e-3 * t105 * t199 * t67);
  tv2rhotau0 = 0.2e1 * rho[0] * t204 + 0.2e1 * t111;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 0] += tv2rhotau0;

  t207 = t92 * t92;
  t218 = 0.16e2 / 0.225e3 * t123 * t207 - 0.33615937024120256457e-3 * t59 * t29 - 0.89403243004032451928e-2 * t176 * t92 + 0.12e2 / 0.125e3 * t149 * t207 - 0.40339124428944307749e-3 * t78 * t29;
  t222 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t218);
  tv2sigma20 = 0.2e1 * rho[0] * t222;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 0] += tv2sigma20;

  tv2sigmalapl0 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 0] += tv2sigmalapl0;

  t227 = my_piecewise3(t3, 0, -0.36971002208167622832e-3 * t105 * t199 * t92);
  tv2sigmatau0 = 0.2e1 * rho[0] * t227;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 0] += tv2sigmatau0;

  tv2lapl20 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 0] += tv2lapl20;

  tv2lapltau0 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 0] += tv2lapltau0;

  tv2tau20 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 0] += tv2tau20;

}

#endif


#ifndef XC_DONT_COMPILE_KXC
GPU_DEVICE_FUNCTION static inline void
func_kxc_unpol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t3, t4, t6, t7, t9, t10, t12, t14;
  double t16, t17, t18, t19, t20, t21, t22, t23;
  double t24, t26, t27, t29, t32, t33, t43, t44;
  double t45, t48, t52, tzk0;

  double t54, t59, t60, t61, t63, t64, t67, t73;
  double t77, t78, t81, t86, tvrho0, t90, t92, t99;
  double t103, tvsigma0, tvlapl0, t105, t107, t111, tvtau0;

  double t114, t121, t123, t124, t128, t129, t131, t132;
  double t135, t141, t144, t148, t149, t154, t159, tv2rho20;
  double t165, t169, t171, t176, t181, t186, t191, tv2rhosigma0;
  double tv2rholapl0, t195, t199, t204, tv2rhotau0, t207, t218, t222;
  double tv2sigma20, tv2sigmalapl0, t227, tv2sigmatau0, tv2lapl20, tv2lapltau0, tv2tau20;

  double t230, t239, t241, t242, t245, t250, t253, t259;
  double t262, t265, t271, t272, t275, t280, t285, tv3rho30;
  double t295, t298, t306, t311, t314, t325, t328, t331;
  double t336, t341, tv3rho2sigma0, tv3rho2lapl0, t346, t350, t354, t362;
  double tv3rho2tau0, t368, t373, t386, t389, t394, t399, t404;
  double tv3rhosigma20, tv3rhosigmalapl0, t410, t411, t412, t419, tv3rhosigmatau0, tv3rholapl20;
  double tv3rholapltau0, tv3rhotau20, t422, t433, t436, t440, tv3sigma30, tv3sigma2lapl0;
  double t446, t451, tv3sigma2tau0, tv3sigmalapl20, tv3sigmalapltau0, tv3sigmatau20, tv3lapl30, tv3lapl2tau0;
  double tv3lapltau20, tv3tau30;


  t3 = rho[0] / 0.2e1 <= p->dens_threshold;
  t4 = sqrt(M_PI);
  t6 = 0.1e1 <= p->zeta_threshold;
  t7 = p->zeta_threshold - 0.1e1;
  t9 = my_piecewise5(t6, t7, t6, -t7, 0);
  t10 = 0.1e1 + t9;
  t12 = sqrt(p->zeta_threshold);
  t14 = sqrt(t10);
  t16 = my_piecewise3(t10 <= p->zeta_threshold, t12 * p->zeta_threshold, t14 * t10);
  t17 = 0.1e1 / t4 * t16;
  t18 = M_SQRT2;
  t19 = sqrt(rho[0]);
  t20 = t18 * t19;
  t21 = rho[0] * rho[0];
  t22 = t21 * rho[0];
  t23 = 0.1e1 / t22;
  t24 = sigma[0] * t23;
  t26 = sigma[0] * sigma[0];
  t27 = t21 * t21;
  t29 = 0.1e1 / t27 / t21;
  t32 = 0.1e1 + 0.82505922498838542062e0 * t24 + 0.25211952768090192343e-2 * t26 * t29;
  t33 = pow(t32, 0.1e1 / 0.15e2);
  t43 = 0.1e1 + 0.55877026877520282455e-1 * t24 + (-0.1544e0 * tau[0] / t21 - 0.11596246802930644802e2) / M_PI / 0.4e1;
  t44 = pow(t32, 0.1e1 / 0.5e1);
  t45 = 0.1e1 / t44;
  t48 = 0.1e1 / t33 + 0.2e1 / 0.5e1 * t43 * t45;
  t52 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t48);
  tzk0 = 0.2e1 * t52;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t54 = t18 / t19;
  t59 = 0.1e1 / t33 / t32;
  t60 = 0.1e1 / t27;
  t61 = sigma[0] * t60;
  t63 = t27 * t22;
  t64 = 0.1e1 / t63;
  t67 = -0.24751776749651562619e1 * t61 - 0.15127171660854115406e-1 * t26 * t64;
  t73 = -0.16763108063256084736e0 * t61 + 0.24573523213388639842e-1 * tau[0] * t23;
  t77 = 0.1e1 / t44 / t32;
  t78 = t43 * t77;
  t81 = -t59 * t67 / 0.15e2 + 0.2e1 / 0.5e1 * t73 * t45 - 0.2e1 / 0.25e2 * t78 * t67;
  t86 = my_piecewise3(t3, 0, -t17 * t54 * t48 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t81);
  tvrho0 = 0.2e1 * rho[0] * t86 + 0.2e1 * t52;

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t90 = sigma[0] * t29;
  t92 = 0.82505922498838542062e0 * t23 + 0.50423905536180384686e-2 * t90;
  t99 = -t59 * t92 / 0.15e2 + 0.22350810751008112982e-1 * t23 * t45 - 0.2e1 / 0.25e2 * t78 * t92;
  t103 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t99);
  tvsigma0 = 0.2e1 * rho[0] * t103;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  t105 = t16 * t18;
  t107 = 0.1e1 / t19 / rho[0];
  t111 = my_piecewise3(t3, 0, 0.18485501104083811416e-2 * t105 * t107 * t45);
  tvtau0 = 0.2e1 * rho[0] * t111;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t114 = t18 * t107;
  t121 = t32 * t32;
  t123 = 0.1e1 / t33 / t121;
  t124 = t67 * t67;
  t128 = 0.1e1 / t27 / rho[0];
  t129 = sigma[0] * t128;
  t131 = t27 * t27;
  t132 = 0.1e1 / t131;
  t135 = 0.99007106998606250476e1 * t129 + 0.10589020162597880784e0 * t26 * t132;
  t141 = 0.67052432253024338944e0 * t129 - 0.73720569640165919526e-1 * tau[0] * t60;
  t144 = t73 * t77;
  t148 = 0.1e1 / t44 / t121;
  t149 = t43 * t148;
  t154 = 0.16e2 / 0.225e3 * t123 * t124 - t59 * t135 / 0.15e2 + 0.2e1 / 0.5e1 * t141 * t45 - 0.4e1 / 0.25e2 * t144 * t67 + 0.12e2 / 0.125e3 * t149 * t124 - 0.2e1 / 0.25e2 * t78 * t135;
  t159 = my_piecewise3(t3, 0, t17 * t114 * t48 / 0.6e1 - 0.2e1 / 0.3e1 * t17 * t54 * t81 - 0.2e1 / 0.3e1 * t17 * t20 * t154);
  tv2rho20 = 0.2e1 * rho[0] * t159 + 0.4e1 * t86;

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 0] += tv2rho20;

  t165 = t123 * t92;
  t169 = sigma[0] * t64;
  t171 = -0.24751776749651562619e1 * t60 - 0.30254343321708230812e-1 * t169;
  t176 = t23 * t77;
  t181 = t92 * t67;
  t186 = 0.16e2 / 0.225e3 * t165 * t67 - t59 * t171 / 0.15e2 - 0.67052432253024338946e-1 * t60 * t45 - 0.44701621502016225964e-2 * t176 * t67 - 0.2e1 / 0.25e2 * t144 * t92 + 0.12e2 / 0.125e3 * t149 * t181 - 0.2e1 / 0.25e2 * t78 * t171;
  t191 = my_piecewise3(t3, 0, -t17 * t54 * t99 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t186);
  tv2rhosigma0 = 0.2e1 * rho[0] * t191 + 0.2e1 * t103;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 0] += tv2rhosigma0;

  tv2rholapl0 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 0] += tv2rholapl0;

  t195 = 0.1e1 / t19 / t21;
  t199 = t107 * t77;
  t204 = my_piecewise3(t3, 0, -0.27728251656125717124e-2 * t105 * t195 * t45 - 0.36971002208167622832e-3 * t105 * t199 * t67);
  tv2rhotau0 = 0.2e1 * rho[0] * t204 + 0.2e1 * t111;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 0] += tv2rhotau0;

  t207 = t92 * t92;
  t218 = 0.16e2 / 0.225e3 * t123 * t207 - 0.33615937024120256457e-3 * t59 * t29 - 0.89403243004032451928e-2 * t176 * t92 + 0.12e2 / 0.125e3 * t149 * t207 - 0.40339124428944307749e-3 * t78 * t29;
  t222 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t218);
  tv2sigma20 = 0.2e1 * rho[0] * t222;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 0] += tv2sigma20;

  tv2sigmalapl0 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 0] += tv2sigmalapl0;

  t227 = my_piecewise3(t3, 0, -0.36971002208167622832e-3 * t105 * t199 * t92);
  tv2sigmatau0 = 0.2e1 * rho[0] * t227;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 0] += tv2sigmatau0;

  tv2lapl20 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 0] += tv2lapl20;

  tv2lapltau0 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 0] += tv2lapltau0;

  tv2tau20 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 0] += tv2tau20;

  t230 = t18 * t195;
  t239 = t121 * t32;
  t241 = 0.1e1 / t33 / t239;
  t242 = t124 * t67;
  t245 = t123 * t67;
  t250 = 0.1e1 / t131 / rho[0];
  t253 = -0.49503553499303125238e2 * t90 - 0.84712161300783046272e0 * t26 * t250;
  t259 = -0.33526216126512169472e1 * t90 + 0.2948822785606636781e0 * tau[0] * t128;
  t262 = t141 * t77;
  t265 = t73 * t148;
  t271 = 0.1e1 / t44 / t239;
  t272 = t43 * t271;
  t275 = t67 * t135;
  t280 = -0.496e3 / 0.3375e4 * t241 * t242 + 0.16e2 / 0.75e2 * t245 * t135 - t59 * t253 / 0.15e2 + 0.2e1 / 0.5e1 * t259 * t45 - 0.6e1 / 0.25e2 * t262 * t67 + 0.36e2 / 0.125e3 * t265 * t124 - 0.6e1 / 0.25e2 * t144 * t135 - 0.132e3 / 0.625e3 * t272 * t242 + 0.36e2 / 0.125e3 * t149 * t275 - 0.2e1 / 0.25e2 * t78 * t253;
  t285 = my_piecewise3(t3, 0, -t17 * t230 * t48 / 0.4e1 + t17 * t114 * t81 / 0.2e1 - t17 * t54 * t154 - 0.2e1 / 0.3e1 * t17 * t20 * t280);
  tv3rho30 = 0.2e1 * rho[0] * t285 + 0.6e1 * t159;

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 0] += tv3rho30;

  t295 = t241 * t92;
  t298 = t123 * t171;
  t306 = 0.99007106998606250476e1 * t128 + 0.21178040325195761568e0 * sigma[0] * t132;
  t311 = t60 * t77;
  t314 = t23 * t148;
  t325 = t92 * t124;
  t328 = t171 * t67;
  t331 = t92 * t135;
  t336 = -0.496e3 / 0.3375e4 * t295 * t124 + 0.32e2 / 0.225e3 * t298 * t67 + 0.16e2 / 0.225e3 * t165 * t135 - t59 * t306 / 0.15e2 + 0.26820972901209735578e0 * t128 * t45 + 0.26820972901209735578e-1 * t311 * t67 + 0.53641945802419471157e-2 * t314 * t124 - 0.44701621502016225964e-2 * t176 * t135 - 0.2e1 / 0.25e2 * t262 * t92 + 0.24e2 / 0.125e3 * t265 * t181 - 0.4e1 / 0.25e2 * t144 * t171 - 0.132e3 / 0.625e3 * t272 * t325 + 0.24e2 / 0.125e3 * t149 * t328 + 0.12e2 / 0.125e3 * t149 * t331 - 0.2e1 / 0.25e2 * t78 * t306;
  t341 = my_piecewise3(t3, 0, t17 * t114 * t99 / 0.6e1 - 0.2e1 / 0.3e1 * t17 * t54 * t186 - 0.2e1 / 0.3e1 * t17 * t20 * t336);
  tv3rho2sigma0 = 0.2e1 * rho[0] * t341 + 0.4e1 * t191;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 0] += tv3rho2sigma0;

  tv3rho2lapl0 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 0] += tv3rho2lapl0;

  t346 = 0.1e1 / t19 / t22;
  t350 = t195 * t77;
  t354 = t107 * t148;
  t362 = my_piecewise3(t3, 0, 0.6932062914031429281e-2 * t105 * t346 * t45 + 0.1109130066245028685e-2 * t105 * t350 * t67 + 0.44365202649801147398e-3 * t105 * t354 * t124 - 0.36971002208167622832e-3 * t105 * t199 * t135);
  tv3rho2tau0 = 0.2e1 * rho[0] * t362 + 0.4e1 * t204;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 0] += tv3rho2tau0;

  t368 = t241 * t207;
  t373 = t123 * t29;
  t386 = t207 * t67;
  t389 = t92 * t171;
  t394 = t29 * t67;
  t399 = -0.496e3 / 0.3375e4 * t368 * t67 + 0.32e2 / 0.225e3 * t165 * t171 + 0.35856999492394940221e-3 * t373 * t67 + 0.20169562214472153874e-2 * t59 * t64 + 0.26820972901209735578e-1 * t311 * t92 + 0.10728389160483894231e-1 * t314 * t181 - 0.89403243004032451928e-2 * t176 * t171 + 0.12e2 / 0.125e3 * t265 * t207 - 0.132e3 / 0.625e3 * t272 * t386 + 0.24e2 / 0.125e3 * t149 * t389 - 0.40339124428944307749e-3 * t144 * t29 + 0.48406949314733169299e-3 * t149 * t394 + 0.24203474657366584649e-2 * t78 * t64;
  t404 = my_piecewise3(t3, 0, -t17 * t54 * t218 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t399);
  tv3rhosigma20 = 0.2e1 * rho[0] * t404 + 0.2e1 * t222;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 0] += tv3rhosigma20;

  tv3rhosigmalapl0 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 0] += tv3rhosigmalapl0;

  t410 = t105 * t107;
  t411 = t148 * t92;
  t412 = t411 * t67;
  t419 = my_piecewise3(t3, 0, 0.55456503312251434248e-3 * t105 * t350 * t92 + 0.44365202649801147398e-3 * t410 * t412 - 0.36971002208167622832e-3 * t105 * t199 * t171);
  tv3rhosigmatau0 = 0.2e1 * rho[0] * t419 + 0.2e1 * t227;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 0] += tv3rhosigmatau0;

  tv3rholapl20 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 0] += tv3rholapl20;

  tv3rholapltau0 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 0] += tv3rholapltau0;

  tv3rhotau20 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 0] += tv3rhotau20;

  t422 = t207 * t92;
  t433 = t92 * t29;
  t436 = -0.496e3 / 0.3375e4 * t241 * t422 + 0.10757099847718482066e-2 * t165 * t29 + 0.16092583740725841347e-1 * t314 * t207 - 0.67620910197952682985e-4 * t250 * t77 - 0.132e3 / 0.625e3 * t272 * t422 + 0.14522084794419950789e-2 * t149 * t433;
  t440 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t436);
  tv3sigma30 = 0.2e1 * rho[0] * t440;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 0] += tv3sigma30;

  tv3sigma2lapl0 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 0] += tv3sigma2lapl0;

  t446 = 0.1e1 / t19 / t63;
  t451 = my_piecewise3(t3, 0, 0.44365202649801147398e-3 * t105 * t354 * t207 - 0.1864222322922560624e-5 * t105 * t446 * t77);
  tv3sigma2tau0 = 0.2e1 * rho[0] * t451;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 0] += tv3sigma2tau0;

  tv3sigmalapl20 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 0] += tv3sigmalapl20;

  tv3sigmalapltau0 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 0] += tv3sigmalapltau0;

  tv3sigmatau20 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 0] += tv3sigmatau20;

  tv3lapl30 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 0] += tv3lapl30;

  tv3lapl2tau0 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 0] += tv3lapl2tau0;

  tv3lapltau20 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 0] += tv3lapltau20;

  tv3tau30 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 0] += tv3tau30;

}

#endif


#ifndef XC_DONT_COMPILE_LXC
GPU_DEVICE_FUNCTION static inline void
func_lxc_unpol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t3, t4, t6, t7, t9, t10, t12, t14;
  double t16, t17, t18, t19, t20, t21, t22, t23;
  double t24, t26, t27, t29, t32, t33, t43, t44;
  double t45, t48, t52, tzk0;

  double t54, t59, t60, t61, t63, t64, t67, t73;
  double t77, t78, t81, t86, tvrho0, t90, t92, t99;
  double t103, tvsigma0, tvlapl0, t105, t107, t111, tvtau0;

  double t114, t121, t123, t124, t128, t129, t131, t132;
  double t135, t141, t144, t148, t149, t154, t159, tv2rho20;
  double t165, t169, t171, t176, t181, t186, t191, tv2rhosigma0;
  double tv2rholapl0, t195, t199, t204, tv2rhotau0, t207, t218, t222;
  double tv2sigma20, tv2sigmalapl0, t227, tv2sigmatau0, tv2lapl20, tv2lapltau0, tv2tau20;

  double t230, t239, t241, t242, t245, t250, t253, t259;
  double t262, t265, t271, t272, t275, t280, t285, tv3rho30;
  double t295, t298, t306, t311, t314, t325, t328, t331;
  double t336, t341, tv3rho2sigma0, tv3rho2lapl0, t346, t350, t354, t362;
  double tv3rho2tau0, t368, t373, t386, t389, t394, t399, t404;
  double tv3rhosigma20, tv3rhosigmalapl0, t410, t411, t412, t419, tv3rhosigmatau0, tv3rholapl20;
  double tv3rholapltau0, tv3rhotau20, t422, t433, t436, t440, tv3sigma30, tv3sigma2lapl0;
  double t446, t451, tv3sigma2tau0, tv3sigmalapl20, tv3sigmalapltau0, tv3sigmatau20, tv3lapl30, tv3lapl2tau0;
  double tv3lapltau20, tv3tau30;

  double t467, t470, t479, t482, t487, t490, t491, t497;
  double t506, t516, t523, t528, tv4rho40, t550, t558, t561;
  double t575, t578, t613, t619, tv4rho3sigma0, tv4rho3lapl0, t628, t632;
  double t639, t651, tv4rho3tau0, t661, t695, t735, t741, tv4rho2sigma20;
  double tv4rho2sigmalapl0, t769, tv4rho2sigmatau0, tv4rho2lapl20, tv4rho2lapltau0, tv4rho2tau20, t794, t816;
  double t821, tv4rhosigma30, tv4rhosigma2lapl0, t839, t844, tv4rhosigma2tau0, tv4rhosigmalapl20, tv4rhosigmalapltau0;
  double tv4rhosigmatau20, tv4rholapl30, tv4rholapl2tau0, tv4rholapltau20, tv4rhotau30, t847, t853, t871;
  double tv4sigma40, tv4sigma3lapl0, t880, tv4sigma3tau0, tv4sigma2lapl20, tv4sigma2lapltau0, tv4sigma2tau20, tv4sigmalapl30;
  double tv4sigmalapl2tau0, tv4sigmalapltau20, tv4sigmatau30, tv4lapl40, tv4lapl3tau0, tv4lapl2tau20, tv4lapltau30, tv4tau40;


  t3 = rho[0] / 0.2e1 <= p->dens_threshold;
  t4 = sqrt(M_PI);
  t6 = 0.1e1 <= p->zeta_threshold;
  t7 = p->zeta_threshold - 0.1e1;
  t9 = my_piecewise5(t6, t7, t6, -t7, 0);
  t10 = 0.1e1 + t9;
  t12 = sqrt(p->zeta_threshold);
  t14 = sqrt(t10);
  t16 = my_piecewise3(t10 <= p->zeta_threshold, t12 * p->zeta_threshold, t14 * t10);
  t17 = 0.1e1 / t4 * t16;
  t18 = M_SQRT2;
  t19 = sqrt(rho[0]);
  t20 = t18 * t19;
  t21 = rho[0] * rho[0];
  t22 = t21 * rho[0];
  t23 = 0.1e1 / t22;
  t24 = sigma[0] * t23;
  t26 = sigma[0] * sigma[0];
  t27 = t21 * t21;
  t29 = 0.1e1 / t27 / t21;
  t32 = 0.1e1 + 0.82505922498838542062e0 * t24 + 0.25211952768090192343e-2 * t26 * t29;
  t33 = pow(t32, 0.1e1 / 0.15e2);
  t43 = 0.1e1 + 0.55877026877520282455e-1 * t24 + (-0.1544e0 * tau[0] / t21 - 0.11596246802930644802e2) / M_PI / 0.4e1;
  t44 = pow(t32, 0.1e1 / 0.5e1);
  t45 = 0.1e1 / t44;
  t48 = 0.1e1 / t33 + 0.2e1 / 0.5e1 * t43 * t45;
  t52 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t48);
  tzk0 = 0.2e1 * t52;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t54 = t18 / t19;
  t59 = 0.1e1 / t33 / t32;
  t60 = 0.1e1 / t27;
  t61 = sigma[0] * t60;
  t63 = t27 * t22;
  t64 = 0.1e1 / t63;
  t67 = -0.24751776749651562619e1 * t61 - 0.15127171660854115406e-1 * t26 * t64;
  t73 = -0.16763108063256084736e0 * t61 + 0.24573523213388639842e-1 * tau[0] * t23;
  t77 = 0.1e1 / t44 / t32;
  t78 = t43 * t77;
  t81 = -t59 * t67 / 0.15e2 + 0.2e1 / 0.5e1 * t73 * t45 - 0.2e1 / 0.25e2 * t78 * t67;
  t86 = my_piecewise3(t3, 0, -t17 * t54 * t48 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t81);
  tvrho0 = 0.2e1 * rho[0] * t86 + 0.2e1 * t52;

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t90 = sigma[0] * t29;
  t92 = 0.82505922498838542062e0 * t23 + 0.50423905536180384686e-2 * t90;
  t99 = -t59 * t92 / 0.15e2 + 0.22350810751008112982e-1 * t23 * t45 - 0.2e1 / 0.25e2 * t78 * t92;
  t103 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t99);
  tvsigma0 = 0.2e1 * rho[0] * t103;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  t105 = t16 * t18;
  t107 = 0.1e1 / t19 / rho[0];
  t111 = my_piecewise3(t3, 0, 0.18485501104083811416e-2 * t105 * t107 * t45);
  tvtau0 = 0.2e1 * rho[0] * t111;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t114 = t18 * t107;
  t121 = t32 * t32;
  t123 = 0.1e1 / t33 / t121;
  t124 = t67 * t67;
  t128 = 0.1e1 / t27 / rho[0];
  t129 = sigma[0] * t128;
  t131 = t27 * t27;
  t132 = 0.1e1 / t131;
  t135 = 0.99007106998606250476e1 * t129 + 0.10589020162597880784e0 * t26 * t132;
  t141 = 0.67052432253024338944e0 * t129 - 0.73720569640165919526e-1 * tau[0] * t60;
  t144 = t73 * t77;
  t148 = 0.1e1 / t44 / t121;
  t149 = t43 * t148;
  t154 = 0.16e2 / 0.225e3 * t123 * t124 - t59 * t135 / 0.15e2 + 0.2e1 / 0.5e1 * t141 * t45 - 0.4e1 / 0.25e2 * t144 * t67 + 0.12e2 / 0.125e3 * t149 * t124 - 0.2e1 / 0.25e2 * t78 * t135;
  t159 = my_piecewise3(t3, 0, t17 * t114 * t48 / 0.6e1 - 0.2e1 / 0.3e1 * t17 * t54 * t81 - 0.2e1 / 0.3e1 * t17 * t20 * t154);
  tv2rho20 = 0.2e1 * rho[0] * t159 + 0.4e1 * t86;

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 0] += tv2rho20;

  t165 = t123 * t92;
  t169 = sigma[0] * t64;
  t171 = -0.24751776749651562619e1 * t60 - 0.30254343321708230812e-1 * t169;
  t176 = t23 * t77;
  t181 = t92 * t67;
  t186 = 0.16e2 / 0.225e3 * t165 * t67 - t59 * t171 / 0.15e2 - 0.67052432253024338946e-1 * t60 * t45 - 0.44701621502016225964e-2 * t176 * t67 - 0.2e1 / 0.25e2 * t144 * t92 + 0.12e2 / 0.125e3 * t149 * t181 - 0.2e1 / 0.25e2 * t78 * t171;
  t191 = my_piecewise3(t3, 0, -t17 * t54 * t99 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t186);
  tv2rhosigma0 = 0.2e1 * rho[0] * t191 + 0.2e1 * t103;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 0] += tv2rhosigma0;

  tv2rholapl0 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 0] += tv2rholapl0;

  t195 = 0.1e1 / t19 / t21;
  t199 = t107 * t77;
  t204 = my_piecewise3(t3, 0, -0.27728251656125717124e-2 * t105 * t195 * t45 - 0.36971002208167622832e-3 * t105 * t199 * t67);
  tv2rhotau0 = 0.2e1 * rho[0] * t204 + 0.2e1 * t111;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 0] += tv2rhotau0;

  t207 = t92 * t92;
  t218 = 0.16e2 / 0.225e3 * t123 * t207 - 0.33615937024120256457e-3 * t59 * t29 - 0.89403243004032451928e-2 * t176 * t92 + 0.12e2 / 0.125e3 * t149 * t207 - 0.40339124428944307749e-3 * t78 * t29;
  t222 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t218);
  tv2sigma20 = 0.2e1 * rho[0] * t222;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 0] += tv2sigma20;

  tv2sigmalapl0 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 0] += tv2sigmalapl0;

  t227 = my_piecewise3(t3, 0, -0.36971002208167622832e-3 * t105 * t199 * t92);
  tv2sigmatau0 = 0.2e1 * rho[0] * t227;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 0] += tv2sigmatau0;

  tv2lapl20 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 0] += tv2lapl20;

  tv2lapltau0 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 0] += tv2lapltau0;

  tv2tau20 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 0] += tv2tau20;

  t230 = t18 * t195;
  t239 = t121 * t32;
  t241 = 0.1e1 / t33 / t239;
  t242 = t124 * t67;
  t245 = t123 * t67;
  t250 = 0.1e1 / t131 / rho[0];
  t253 = -0.49503553499303125238e2 * t90 - 0.84712161300783046272e0 * t26 * t250;
  t259 = -0.33526216126512169472e1 * t90 + 0.2948822785606636781e0 * tau[0] * t128;
  t262 = t141 * t77;
  t265 = t73 * t148;
  t271 = 0.1e1 / t44 / t239;
  t272 = t43 * t271;
  t275 = t67 * t135;
  t280 = -0.496e3 / 0.3375e4 * t241 * t242 + 0.16e2 / 0.75e2 * t245 * t135 - t59 * t253 / 0.15e2 + 0.2e1 / 0.5e1 * t259 * t45 - 0.6e1 / 0.25e2 * t262 * t67 + 0.36e2 / 0.125e3 * t265 * t124 - 0.6e1 / 0.25e2 * t144 * t135 - 0.132e3 / 0.625e3 * t272 * t242 + 0.36e2 / 0.125e3 * t149 * t275 - 0.2e1 / 0.25e2 * t78 * t253;
  t285 = my_piecewise3(t3, 0, -t17 * t230 * t48 / 0.4e1 + t17 * t114 * t81 / 0.2e1 - t17 * t54 * t154 - 0.2e1 / 0.3e1 * t17 * t20 * t280);
  tv3rho30 = 0.2e1 * rho[0] * t285 + 0.6e1 * t159;

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 0] += tv3rho30;

  t295 = t241 * t92;
  t298 = t123 * t171;
  t306 = 0.99007106998606250476e1 * t128 + 0.21178040325195761568e0 * sigma[0] * t132;
  t311 = t60 * t77;
  t314 = t23 * t148;
  t325 = t92 * t124;
  t328 = t171 * t67;
  t331 = t92 * t135;
  t336 = -0.496e3 / 0.3375e4 * t295 * t124 + 0.32e2 / 0.225e3 * t298 * t67 + 0.16e2 / 0.225e3 * t165 * t135 - t59 * t306 / 0.15e2 + 0.26820972901209735578e0 * t128 * t45 + 0.26820972901209735578e-1 * t311 * t67 + 0.53641945802419471157e-2 * t314 * t124 - 0.44701621502016225964e-2 * t176 * t135 - 0.2e1 / 0.25e2 * t262 * t92 + 0.24e2 / 0.125e3 * t265 * t181 - 0.4e1 / 0.25e2 * t144 * t171 - 0.132e3 / 0.625e3 * t272 * t325 + 0.24e2 / 0.125e3 * t149 * t328 + 0.12e2 / 0.125e3 * t149 * t331 - 0.2e1 / 0.25e2 * t78 * t306;
  t341 = my_piecewise3(t3, 0, t17 * t114 * t99 / 0.6e1 - 0.2e1 / 0.3e1 * t17 * t54 * t186 - 0.2e1 / 0.3e1 * t17 * t20 * t336);
  tv3rho2sigma0 = 0.2e1 * rho[0] * t341 + 0.4e1 * t191;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 0] += tv3rho2sigma0;

  tv3rho2lapl0 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 0] += tv3rho2lapl0;

  t346 = 0.1e1 / t19 / t22;
  t350 = t195 * t77;
  t354 = t107 * t148;
  t362 = my_piecewise3(t3, 0, 0.6932062914031429281e-2 * t105 * t346 * t45 + 0.1109130066245028685e-2 * t105 * t350 * t67 + 0.44365202649801147398e-3 * t105 * t354 * t124 - 0.36971002208167622832e-3 * t105 * t199 * t135);
  tv3rho2tau0 = 0.2e1 * rho[0] * t362 + 0.4e1 * t204;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 0] += tv3rho2tau0;

  t368 = t241 * t207;
  t373 = t123 * t29;
  t386 = t207 * t67;
  t389 = t92 * t171;
  t394 = t29 * t67;
  t399 = -0.496e3 / 0.3375e4 * t368 * t67 + 0.32e2 / 0.225e3 * t165 * t171 + 0.35856999492394940221e-3 * t373 * t67 + 0.20169562214472153874e-2 * t59 * t64 + 0.26820972901209735578e-1 * t311 * t92 + 0.10728389160483894231e-1 * t314 * t181 - 0.89403243004032451928e-2 * t176 * t171 + 0.12e2 / 0.125e3 * t265 * t207 - 0.132e3 / 0.625e3 * t272 * t386 + 0.24e2 / 0.125e3 * t149 * t389 - 0.40339124428944307749e-3 * t144 * t29 + 0.48406949314733169299e-3 * t149 * t394 + 0.24203474657366584649e-2 * t78 * t64;
  t404 = my_piecewise3(t3, 0, -t17 * t54 * t218 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t399);
  tv3rhosigma20 = 0.2e1 * rho[0] * t404 + 0.2e1 * t222;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 0] += tv3rhosigma20;

  tv3rhosigmalapl0 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 0] += tv3rhosigmalapl0;

  t410 = t105 * t107;
  t411 = t148 * t92;
  t412 = t411 * t67;
  t419 = my_piecewise3(t3, 0, 0.55456503312251434248e-3 * t105 * t350 * t92 + 0.44365202649801147398e-3 * t410 * t412 - 0.36971002208167622832e-3 * t105 * t199 * t171);
  tv3rhosigmatau0 = 0.2e1 * rho[0] * t419 + 0.2e1 * t227;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 0] += tv3rhosigmatau0;

  tv3rholapl20 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 0] += tv3rholapl20;

  tv3rholapltau0 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 0] += tv3rholapltau0;

  tv3rhotau20 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 0] += tv3rhotau20;

  t422 = t207 * t92;
  t433 = t92 * t29;
  t436 = -0.496e3 / 0.3375e4 * t241 * t422 + 0.10757099847718482066e-2 * t165 * t29 + 0.16092583740725841347e-1 * t314 * t207 - 0.67620910197952682985e-4 * t250 * t77 - 0.132e3 / 0.625e3 * t272 * t422 + 0.14522084794419950789e-2 * t149 * t433;
  t440 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * t436);
  tv3sigma30 = 0.2e1 * rho[0] * t440;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 0] += tv3sigma30;

  tv3sigma2lapl0 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 0] += tv3sigma2lapl0;

  t446 = 0.1e1 / t19 / t63;
  t451 = my_piecewise3(t3, 0, 0.44365202649801147398e-3 * t105 * t354 * t207 - 0.1864222322922560624e-5 * t105 * t446 * t77);
  tv3sigma2tau0 = 0.2e1 * rho[0] * t451;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 0] += tv3sigma2tau0;

  tv3sigmalapl20 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 0] += tv3sigmalapl20;

  tv3sigmalapltau0 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 0] += tv3sigmalapltau0;

  tv3sigmatau20 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 0] += tv3sigmatau20;

  tv3lapl30 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 0] += tv3lapl30;

  tv3lapl2tau0 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 0] += tv3lapl2tau0;

  tv3lapltau20 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 0] += tv3lapltau20;

  tv3tau30 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 0] += tv3tau30;

  t467 = 0.1e1 / t131 / t21;
  t470 = 0.29702132099581875143e3 * t169 + 0.76240945170704741645e1 * t26 * t467;
  t479 = t141 * t148;
  t482 = t73 * t271;
  t487 = t121 * t121;
  t490 = t43 / t44 / t487;
  t491 = t124 * t124;
  t497 = t135 * t135;
  t506 = 0.1e1 / t33 / t487;
  t516 = t259 * t77;
  t523 = -t59 * t470 / 0.15e2 + 0.2e1 / 0.5e1 * (0.20115729675907301683e2 * t169 - 0.14744113928033183905e1 * tau[0] * t29) * t45 + 0.72e2 / 0.125e3 * t479 * t124 - 0.528e3 / 0.625e3 * t482 * t242 + 0.144e3 / 0.125e3 * t265 * t275 + 0.2112e4 / 0.3125e4 * t490 * t491 - 0.792e3 / 0.625e3 * t272 * t124 * t135 + 0.36e2 / 0.125e3 * t149 * t497 + 0.48e2 / 0.125e3 * t149 * t67 * t253 - 0.2e1 / 0.25e2 * t78 * t470 + 0.22816e5 / 0.50625e5 * t506 * t491 - 0.992e3 / 0.1125e4 * t241 * t124 * t135 + 0.16e2 / 0.75e2 * t123 * t497 + 0.64e2 / 0.225e3 * t245 * t253 - 0.8e1 / 0.25e2 * t516 * t67 - 0.12e2 / 0.25e2 * t262 * t135 - 0.8e1 / 0.25e2 * t144 * t253;
  t528 = my_piecewise3(t3, 0, 0.5e1 / 0.8e1 * t17 * t18 * t346 * t48 - t17 * t230 * t81 + t17 * t114 * t154 - 0.4e1 / 0.3e1 * t17 * t54 * t280 - 0.2e1 / 0.3e1 * t17 * t20 * t523);
  tv4rho40 = 0.2e1 * rho[0] * t528 + 0.8e1 * t285;

  if(out->v4rho4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho4[ip*p->dim.v4rho4 + 0] += tv4rho40;

  t550 = t128 * t77;
  t558 = t60 * t148;
  t561 = t23 * t271;
  t575 = -0.49503553499303125238e2 * t29 - 0.16942432260156609254e1 * sigma[0] * t250;
  t578 = -0.496e3 / 0.1125e4 * t241 * t171 * t124 + 0.16e2 / 0.75e2 * t123 * t306 * t67 + 0.16e2 / 0.75e2 * t298 * t135 + 0.16e2 / 0.225e3 * t165 * t253 - 0.16092583740725841347e0 * t550 * t67 + 0.40231459351814603367e-1 * t311 * t135 + 0.22816e5 / 0.50625e5 * t506 * t92 * t242 - 0.48277751222177524041e-1 * t558 * t124 - 0.11801228076532283655e-1 * t561 * t242 - 0.44701621502016225964e-2 * t176 * t253 - 0.2e1 / 0.25e2 * t516 * t92 - 0.6e1 / 0.25e2 * t262 * t171 - 0.6e1 / 0.25e2 * t144 * t306 - 0.2e1 / 0.25e2 * t78 * t575;
  t613 = -0.13410486450604867789e1 * t29 * t45 - t59 * t575 / 0.15e2 - 0.396e3 / 0.625e3 * t272 * t181 * t135 - 0.496e3 / 0.1125e4 * t295 * t275 + 0.16092583740725841347e-1 * t314 * t275 + 0.36e2 / 0.125e3 * t479 * t181 + 0.72e2 / 0.125e3 * t265 * t328 + 0.36e2 / 0.125e3 * t265 * t331 - 0.396e3 / 0.625e3 * t272 * t171 * t124 + 0.36e2 / 0.125e3 * t149 * t306 * t67 + 0.36e2 / 0.125e3 * t149 * t171 * t135 + 0.12e2 / 0.125e3 * t149 * t92 * t253 - 0.396e3 / 0.625e3 * t482 * t325 + 0.2112e4 / 0.3125e4 * t490 * t92 * t242;
  t619 = my_piecewise3(t3, 0, -t17 * t230 * t99 / 0.4e1 + t17 * t114 * t186 / 0.2e1 - t17 * t54 * t336 - 0.2e1 / 0.3e1 * t17 * t20 * (t578 + t613));
  tv4rho3sigma0 = 0.2e1 * rho[0] * t619 + 0.6e1 * t341;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 0] += tv4rho3sigma0;

  tv4rho3lapl0 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 0] += tv4rho3lapl0;

  t628 = t346 * t77;
  t632 = t195 * t148;
  t639 = t107 * t271;
  t651 = my_piecewise3(t3, 0, -0.24262220199110002484e-1 * t105 / t19 / t27 * t45 - 0.41592377484188575687e-2 * t105 * t628 * t67 - 0.1996434119241051633e-2 * t105 * t632 * t124 + 0.16636950993675430275e-2 * t105 * t350 * t135 - 0.97603445829562524276e-3 * t105 * t639 * t242 + 0.13309560794940344219e-2 * t410 * t148 * t67 * t135 - 0.36971002208167622832e-3 * t105 * t199 * t253);
  tv4rho3tau0 = 0.2e1 * rho[0] * t651 + 0.6e1 * t362;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 0] += tv4rho3tau0;

  t661 = t171 * t171;
  t695 = 0.24e2 / 0.125e3 * t149 * t661 + 0.48406949314733169298e-2 * t144 * t64 - 0.16942432260156609254e-1 * t78 * t132 + 0.22816e5 / 0.50625e5 * t506 * t207 * t124 - 0.7410446561761620979e-3 * t241 * t29 * t124 - 0.43028399390873928265e-2 * t123 * t64 * t67 - 0.10728389160483894231e0 * t550 * t92 + 0.53641945802419471156e-1 * t311 * t171 - 0.89403243004032451928e-2 * t176 * t306 + 0.12e2 / 0.125e3 * t479 * t207 - 0.40339124428944307749e-3 * t262 * t29 - 0.496e3 / 0.3375e4 * t368 * t135 + 0.32e2 / 0.225e3 * t165 * t306 + 0.35856999492394940221e-3 * t373 * t135 - 0.14118693550130507712e-1 * t59 * t132;
  t735 = 0.32e2 / 0.225e3 * t123 * t661 - 0.528e3 / 0.625e3 * t272 * t181 * t171 - 0.23602456153064567308e-1 * t561 * t325 + 0.2112e4 / 0.3125e4 * t490 * t207 * t124 - 0.10649528849241297246e-2 * t272 * t29 * t124 - 0.58088339177679803158e-2 * t149 * t64 * t67 + 0.24e2 / 0.125e3 * t149 * t92 * t306 + 0.96813898629466338598e-3 * t265 * t394 + 0.48406949314733169299e-3 * t149 * t29 * t135 - 0.1984e4 / 0.3375e4 * t295 * t328 - 0.64370334962903365387e-1 * t558 * t181 + 0.21456778320967788462e-1 * t314 * t328 + 0.10728389160483894231e-1 * t314 * t331 - 0.264e3 / 0.625e3 * t482 * t386 + 0.48e2 / 0.125e3 * t265 * t389 - 0.132e3 / 0.625e3 * t272 * t207 * t135;
  t741 = my_piecewise3(t3, 0, t17 * t114 * t218 / 0.6e1 - 0.2e1 / 0.3e1 * t17 * t54 * t399 - 0.2e1 / 0.3e1 * t17 * t20 * (t695 + t735));
  tv4rho2sigma20 = 0.2e1 * rho[0] * t741 + 0.4e1 * t404;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 0] += tv4rho2sigma20;

  tv4rho2sigmalapl0 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 0] += tv4rho2sigmalapl0;

  t769 = my_piecewise3(t3, 0, -0.13864125828062858562e-2 * t105 * t628 * t92 - 0.1330956079494034422e-2 * t105 * t195 * t412 + 0.1109130066245028685e-2 * t105 * t350 * t171 - 0.97603445829562524276e-3 * t410 * t271 * t92 * t124 + 0.88730405299602294796e-3 * t410 * t148 * t171 * t67 + 0.44365202649801147398e-3 * t410 * t411 * t135 - 0.36971002208167622832e-3 * t105 * t199 * t306);
  tv4rho2sigmatau0 = 0.2e1 * rho[0] * t769 + 0.4e1 * t419;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 0] += tv4rho2sigmatau0;

  tv4rho2lapl20 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 0] += tv4rho2lapl20;

  tv4rho2lapltau0 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 0] += tv4rho2lapltau0;

  tv4rho2tau20 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 0] += tv4rho2tau20;

  t794 = t250 * t148;
  t816 = 0.22816e5 / 0.50625e5 * t506 * t422 * t67 - 0.496e3 / 0.1125e4 * t368 * t171 - 0.22231339685284862936e-2 * t295 * t394 + 0.10757099847718482066e-2 * t298 * t29 - 0.64542599086310892396e-2 * t165 * t64 - 0.48277751222177524041e-1 * t558 * t207 - 0.35403684229596850963e-1 * t561 * t386 + 0.32185167481451682694e-1 * t314 * t389 + 0.60858819178157414686e-3 * t467 * t77 + 0.81145092237543219582e-4 * t794 * t67 - 0.132e3 / 0.625e3 * t482 * t422 + 0.2112e4 / 0.3125e4 * t490 * t422 * t67 - 0.396e3 / 0.625e3 * t272 * t207 * t171 + 0.14522084794419950789e-2 * t265 * t433 - 0.31948586547723891736e-2 * t272 * t433 * t67 + 0.14522084794419950789e-2 * t149 * t171 * t29 - 0.87132508766519704734e-2 * t149 * t92 * t64;
  t821 = my_piecewise3(t3, 0, -t17 * t54 * t436 / 0.3e1 - 0.2e1 / 0.3e1 * t17 * t20 * t816);
  tv4rhosigma30 = 0.2e1 * rho[0] * t821 + 0.2e1 * t440;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 0] += tv4rhosigma30;

  tv4rhosigma2lapl0 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 0] += tv4rhosigma2lapl0;

  t839 = t446 * t148;
  t844 = my_piecewise3(t3, 0, -0.66547803974701721097e-3 * t105 * t632 * t207 - 0.97603445829562524276e-3 * t410 * t271 * t207 * t67 + 0.88730405299602294796e-3 * t410 * t411 * t171 + 0.1398166742191920468e-4 * t105 / t19 / t131 * t77 + 0.22370667875070727488e-5 * t105 * t839 * t67);
  tv4rhosigma2tau0 = 0.2e1 * rho[0] * t844 + 0.2e1 * t451;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 0] += tv4rhosigma2tau0;

  tv4rhosigmalapl20 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 0] += tv4rhosigmalapl20;

  tv4rhosigmalapltau0 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 0] += tv4rhosigmalapltau0;

  tv4rhosigmatau20 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 0] += tv4rhosigmatau20;

  tv4rholapl30 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 0] += tv4rholapl30;

  tv4rholapl2tau0 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 0] += tv4rholapl2tau0;

  tv4rholapltau20 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 0] += tv4rholapltau20;

  tv4rhotau30 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 0] += tv4rhotau30;

  t847 = t207 * t207;
  t853 = 0.1e1 / t131 / t27;
  t871 = my_piecewise3(t3, 0, -0.2e1 / 0.3e1 * t17 * t20 * (0.22816e5 / 0.50625e5 * t506 * t847 - 0.44462679370569725873e-2 * t368 * t29 + 0.5424149865646171409e-5 * t123 * t853 - 0.47204912306129134617e-1 * t561 * t422 + 0.32458036895017287832e-3 * t794 * t92 + 0.2112e4 / 0.3125e4 * t490 * t847 - 0.63897173095447783473e-2 * t272 * t207 * t29 + 0.7322602318622331402e-5 * t149 * t853));
  tv4sigma40 = 0.2e1 * rho[0] * t871;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 0] += tv4sigma40;

  tv4sigma3lapl0 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 0] += tv4sigma3lapl0;

  t880 = my_piecewise3(t3, 0, -0.97603445829562524276e-3 * t105 * t639 * t422 + 0.67112003625212182462e-5 * t105 * t839 * t92);
  tv4sigma3tau0 = 0.2e1 * rho[0] * t880;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 0] += tv4sigma3tau0;

  tv4sigma2lapl20 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 0] += tv4sigma2lapl20;

  tv4sigma2lapltau0 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 0] += tv4sigma2lapltau0;

  tv4sigma2tau20 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 0] += tv4sigma2tau20;

  tv4sigmalapl30 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 0] += tv4sigmalapl30;

  tv4sigmalapl2tau0 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 0] += tv4sigmalapl2tau0;

  tv4sigmalapltau20 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 0] += tv4sigmalapltau20;

  tv4sigmatau30 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 0] += tv4sigmatau30;

  tv4lapl40 = 0.e0;

  if(out->v4lapl4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl4[ip*p->dim.v4lapl4 + 0] += tv4lapl40;

  tv4lapl3tau0 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 0] += tv4lapl3tau0;

  tv4lapl2tau20 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 0] += tv4lapl2tau20;

  tv4lapltau30 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 0] += tv4lapltau30;

  tv4tau40 = 0.e0;

  if(out->v4tau4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4tau4[ip*p->dim.v4tau4 + 0] += tv4tau40;

}

#endif


#ifndef XC_DONT_COMPILE_EXC
GPU_DEVICE_FUNCTION static inline void
func_exc_pol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t2, t3, t4, t5, t6, t9, t10, t13;
  double t14, t15, t17, t18, t19, t20, t21, t22;
  double t23, t24, t25, t26, t27, t28, t29, t30;
  double t31, t32, t34, t35, t37, t40, t41, t44;
  double t48, t51, t52, t53, t56, t57, t60, t61;
  double t62, t64, t65, t66, t67, t68, t69, t70;
  double t71, t72, t73, t74, t76, t77, t79, t82;
  double t83, t86, t92, t93, t94, t97, t98, t101;
  double tzk0;


  t2 = rho[0] <= p->dens_threshold;
  t3 = sqrt(M_PI);
  t4 = 0.1e1 / t3;
  t5 = rho[0] + rho[1];
  t6 = 0.1e1 / t5;
  t9 = 0.2e1 * rho[0] * t6 <= p->zeta_threshold;
  t10 = p->zeta_threshold - 0.1e1;
  t13 = 0.2e1 * rho[1] * t6 <= p->zeta_threshold;
  t14 = -t10;
  t15 = rho[0] - rho[1];
  t17 = my_piecewise5(t9, t10, t13, t14, t15 * t6);
  t18 = 0.1e1 + t17;
  t19 = t18 <= p->zeta_threshold;
  t20 = sqrt(p->zeta_threshold);
  t21 = t20 * p->zeta_threshold;
  t22 = sqrt(t18);
  t23 = t22 * t18;
  t24 = my_piecewise3(t19, t21, t23);
  t25 = t4 * t24;
  t26 = M_SQRT2;
  t27 = sqrt(t5);
  t28 = t26 * t27;
  t29 = rho[0] * rho[0];
  t30 = t29 * rho[0];
  t31 = 0.1e1 / t30;
  t32 = sigma[0] * t31;
  t34 = sigma[0] * sigma[0];
  t35 = t29 * t29;
  t37 = 0.1e1 / t35 / t29;
  t40 = 0.1e1 + 0.41252961249419271031e0 * t32 + 0.63029881920225480858e-3 * t34 * t37;
  t41 = pow(t40, 0.1e1 / 0.15e2);
  t44 = 0.1e1 / t29;
  t48 = 0.1e1 / M_PI;
  t51 = 0.1e1 + 0.27938513438760141227e-1 * t32 + (-0.772e-1 * tau[0] * t44 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t52 = pow(t40, 0.1e1 / 0.5e1);
  t53 = 0.1e1 / t52;
  t56 = 0.1e1 / t41 + 0.2e1 / 0.5e1 * t51 * t53;
  t57 = t28 * t56;
  t60 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t57);
  t61 = rho[1] <= p->dens_threshold;
  t62 = -t15;
  t64 = my_piecewise5(t13, t10, t9, t14, t62 * t6);
  t65 = 0.1e1 + t64;
  t66 = t65 <= p->zeta_threshold;
  t67 = sqrt(t65);
  t68 = t67 * t65;
  t69 = my_piecewise3(t66, t21, t68);
  t70 = t4 * t69;
  t71 = rho[1] * rho[1];
  t72 = t71 * rho[1];
  t73 = 0.1e1 / t72;
  t74 = sigma[2] * t73;
  t76 = sigma[2] * sigma[2];
  t77 = t71 * t71;
  t79 = 0.1e1 / t77 / t71;
  t82 = 0.1e1 + 0.41252961249419271031e0 * t74 + 0.63029881920225480858e-3 * t76 * t79;
  t83 = pow(t82, 0.1e1 / 0.15e2);
  t86 = 0.1e1 / t71;
  t92 = 0.1e1 + 0.27938513438760141227e-1 * t74 + (-0.772e-1 * tau[1] * t86 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t93 = pow(t82, 0.1e1 / 0.5e1);
  t94 = 0.1e1 / t93;
  t97 = 0.1e1 / t83 + 0.2e1 / 0.5e1 * t92 * t94;
  t98 = t28 * t97;
  t101 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t98);
  tzk0 = t60 + t101;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

}

#endif


#ifndef XC_DONT_COMPILE_VXC
GPU_DEVICE_FUNCTION static inline void
func_vxc_pol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t2, t3, t4, t5, t6, t9, t10, t13;
  double t14, t15, t17, t18, t19, t20, t21, t22;
  double t23, t24, t25, t26, t27, t28, t29, t30;
  double t31, t32, t34, t35, t37, t40, t41, t44;
  double t48, t51, t52, t53, t56, t57, t60, t61;
  double t62, t64, t65, t66, t67, t68, t69, t70;
  double t71, t72, t73, t74, t76, t77, t79, t82;
  double t83, t86, t92, t93, t94, t97, t98, t101;
  double tzk0;

  double t102, t103, t104, t106, t109, t110, t113, t114;
  double t115, t117, t119, t120, t121, t124, t127, t133;
  double t137, t138, t141, t142, t146, t147, t149, t152;
  double t153, t156, t158, t160, tvrho0, t164, t167, t168;
  double t172, t174, t177, t178, t182, t183, t184, t187;
  double t190, t196, t200, t201, t204, t205, t209, tvrho1;
  double t213, t215, t222, t223, t226, tvsigma0, tvsigma1, t228;
  double t230, t237, t238, t241, tvsigma2, tvlapl0, tvlapl1, t242;
  double t244, t247, tvtau0, t248, t250, t253, tvtau1;


  t2 = rho[0] <= p->dens_threshold;
  t3 = sqrt(M_PI);
  t4 = 0.1e1 / t3;
  t5 = rho[0] + rho[1];
  t6 = 0.1e1 / t5;
  t9 = 0.2e1 * rho[0] * t6 <= p->zeta_threshold;
  t10 = p->zeta_threshold - 0.1e1;
  t13 = 0.2e1 * rho[1] * t6 <= p->zeta_threshold;
  t14 = -t10;
  t15 = rho[0] - rho[1];
  t17 = my_piecewise5(t9, t10, t13, t14, t15 * t6);
  t18 = 0.1e1 + t17;
  t19 = t18 <= p->zeta_threshold;
  t20 = sqrt(p->zeta_threshold);
  t21 = t20 * p->zeta_threshold;
  t22 = sqrt(t18);
  t23 = t22 * t18;
  t24 = my_piecewise3(t19, t21, t23);
  t25 = t4 * t24;
  t26 = M_SQRT2;
  t27 = sqrt(t5);
  t28 = t26 * t27;
  t29 = rho[0] * rho[0];
  t30 = t29 * rho[0];
  t31 = 0.1e1 / t30;
  t32 = sigma[0] * t31;
  t34 = sigma[0] * sigma[0];
  t35 = t29 * t29;
  t37 = 0.1e1 / t35 / t29;
  t40 = 0.1e1 + 0.41252961249419271031e0 * t32 + 0.63029881920225480858e-3 * t34 * t37;
  t41 = pow(t40, 0.1e1 / 0.15e2);
  t44 = 0.1e1 / t29;
  t48 = 0.1e1 / M_PI;
  t51 = 0.1e1 + 0.27938513438760141227e-1 * t32 + (-0.772e-1 * tau[0] * t44 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t52 = pow(t40, 0.1e1 / 0.5e1);
  t53 = 0.1e1 / t52;
  t56 = 0.1e1 / t41 + 0.2e1 / 0.5e1 * t51 * t53;
  t57 = t28 * t56;
  t60 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t57);
  t61 = rho[1] <= p->dens_threshold;
  t62 = -t15;
  t64 = my_piecewise5(t13, t10, t9, t14, t62 * t6);
  t65 = 0.1e1 + t64;
  t66 = t65 <= p->zeta_threshold;
  t67 = sqrt(t65);
  t68 = t67 * t65;
  t69 = my_piecewise3(t66, t21, t68);
  t70 = t4 * t69;
  t71 = rho[1] * rho[1];
  t72 = t71 * rho[1];
  t73 = 0.1e1 / t72;
  t74 = sigma[2] * t73;
  t76 = sigma[2] * sigma[2];
  t77 = t71 * t71;
  t79 = 0.1e1 / t77 / t71;
  t82 = 0.1e1 + 0.41252961249419271031e0 * t74 + 0.63029881920225480858e-3 * t76 * t79;
  t83 = pow(t82, 0.1e1 / 0.15e2);
  t86 = 0.1e1 / t71;
  t92 = 0.1e1 + 0.27938513438760141227e-1 * t74 + (-0.772e-1 * tau[1] * t86 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t93 = pow(t82, 0.1e1 / 0.5e1);
  t94 = 0.1e1 / t93;
  t97 = 0.1e1 / t83 + 0.2e1 / 0.5e1 * t92 * t94;
  t98 = t28 * t97;
  t101 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t98);
  tzk0 = t60 + t101;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t102 = t5 * t5;
  t103 = 0.1e1 / t102;
  t104 = t15 * t103;
  t106 = my_piecewise5(t9, 0, t13, 0, t6 - t104);
  t109 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t106);
  t110 = t4 * t109;
  t113 = 0.1e1 / t27;
  t114 = t26 * t113;
  t115 = t114 * t56;
  t117 = t25 * t115 / 0.3e1;
  t119 = 0.1e1 / t41 / t40;
  t120 = 0.1e1 / t35;
  t121 = sigma[0] * t120;
  t124 = 0.1e1 / t35 / t30;
  t127 = -0.12375888374825781309e1 * t121 - 0.37817929152135288515e-2 * t34 * t124;
  t133 = -0.83815540316280423681e-1 * t121 + 0.12286761606694319921e-1 * tau[0] * t31;
  t137 = 0.1e1 / t52 / t40;
  t138 = t51 * t137;
  t141 = -t119 * t127 / 0.15e2 + 0.2e1 / 0.5e1 * t133 * t53 - 0.2e1 / 0.25e2 * t138 * t127;
  t142 = t28 * t141;
  t146 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t57 - t117 - 0.2e1 / 0.3e1 * t25 * t142);
  t147 = t62 * t103;
  t149 = my_piecewise5(t13, 0, t9, 0, -t6 - t147);
  t152 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t149);
  t153 = t4 * t152;
  t156 = t114 * t97;
  t158 = t70 * t156 / 0.3e1;
  t160 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t98 - t158);
  tvrho0 = t60 + t101 + t5 * (t146 + t160);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t164 = my_piecewise5(t9, 0, t13, 0, -t6 - t104);
  t167 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t164);
  t168 = t4 * t167;
  t172 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t57 - t117);
  t174 = my_piecewise5(t13, 0, t9, 0, t6 - t147);
  t177 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t174);
  t178 = t4 * t177;
  t182 = 0.1e1 / t83 / t82;
  t183 = 0.1e1 / t77;
  t184 = sigma[2] * t183;
  t187 = 0.1e1 / t77 / t72;
  t190 = -0.12375888374825781309e1 * t184 - 0.37817929152135288515e-2 * t76 * t187;
  t196 = -0.83815540316280423681e-1 * t184 + 0.12286761606694319921e-1 * tau[1] * t73;
  t200 = 0.1e1 / t93 / t82;
  t201 = t92 * t200;
  t204 = -t182 * t190 / 0.15e2 + 0.2e1 / 0.5e1 * t196 * t94 - 0.2e1 / 0.25e2 * t201 * t190;
  t205 = t28 * t204;
  t209 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t98 - t158 - 0.2e1 / 0.3e1 * t70 * t205);
  tvrho1 = t60 + t101 + t5 * (t172 + t209);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 1] += tvrho1;

  t213 = sigma[0] * t37;
  t215 = 0.41252961249419271031e0 * t31 + 0.12605976384045096172e-2 * t213;
  t222 = -t119 * t215 / 0.15e2 + 0.11175405375504056491e-1 * t31 * t53 - 0.2e1 / 0.25e2 * t138 * t215;
  t223 = t28 * t222;
  t226 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t223);
  tvsigma0 = t5 * t226;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvsigma1 = 0.e0;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 1] += tvsigma1;

  t228 = sigma[2] * t79;
  t230 = 0.41252961249419271031e0 * t73 + 0.12605976384045096172e-2 * t228;
  t237 = -t182 * t230 / 0.15e2 + 0.11175405375504056491e-1 * t73 * t94 - 0.2e1 / 0.25e2 * t201 * t230;
  t238 = t28 * t237;
  t241 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t238);
  tvsigma2 = t5 * t241;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 2] += tvsigma2;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  tvlapl1 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 1] += tvlapl1;

  t242 = t24 * t26;
  t244 = t27 * t44 * t53;
  t247 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t242 * t244);
  tvtau0 = t5 * t247;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t248 = t69 * t26;
  t250 = t27 * t86 * t94;
  t253 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t248 * t250);
  tvtau1 = t5 * t253;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 1] += tvtau1;

}

#endif


#ifndef XC_DONT_COMPILE_FXC
GPU_DEVICE_FUNCTION static inline void
func_fxc_pol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t2, t3, t4, t5, t6, t9, t10, t13;
  double t14, t15, t17, t18, t19, t20, t21, t22;
  double t23, t24, t25, t26, t27, t28, t29, t30;
  double t31, t32, t34, t35, t37, t40, t41, t44;
  double t48, t51, t52, t53, t56, t57, t60, t61;
  double t62, t64, t65, t66, t67, t68, t69, t70;
  double t71, t72, t73, t74, t76, t77, t79, t82;
  double t83, t86, t92, t93, t94, t97, t98, t101;
  double tzk0;

  double t102, t103, t104, t106, t109, t110, t113, t114;
  double t115, t117, t119, t120, t121, t124, t127, t133;
  double t137, t138, t141, t142, t146, t147, t149, t152;
  double t153, t156, t158, t160, tvrho0, t164, t167, t168;
  double t172, t174, t177, t178, t182, t183, t184, t187;
  double t190, t196, t200, t201, t204, t205, t209, tvrho1;
  double t213, t215, t222, t223, t226, tvsigma0, tvsigma1, t228;
  double t230, t237, t238, t241, tvsigma2, tvlapl0, tvlapl1, t242;
  double t244, t247, tvtau0, t248, t250, t253, tvtau1;

  double t256, t257, t260, t261, t262, t265, t269, t270;
  double t273, t278, t279, t280, t282, t283, t284, t286;
  double t288, t289, t293, t294, t296, t297, t300, t306;
  double t309, t313, t314, t319, t320, t324, t325, t326;
  double t329, t332, t336, t337, t340, t342, t344, t346;
  double tv2rho20, t349, t353, t357, t358, t361, t368, t369;
  double t373, t377, t378, t381, t386, t387, t390, tv2rho21;
  double t395, t400, t404, t405, t410, t411, t416, t420;
  double t421, t428, t430, t431, t435, t436, t438, t439;
  double t442, t448, t451, t455, t456, t461, t462, t466;
  double tv2rho22, t471, t473, t474, t478, t480, t485, t486;
  double t490, t495, t496, t500, tv2rhosigma0, tv2rhosigma1, t504, t506;
  double t508, tv2rhosigma2, t513, tv2rhosigma3, tv2rhosigma4, t517, t521, t523;
  double t528, t529, t533, t538, t539, t543, tv2rhosigma5, tv2rholapl0;
  double tv2rholapl1, tv2rholapl2, tv2rholapl3, t545, t549, t551, t553, t556;
  double t557, t558, t562, tv2rhotau0, t564, t568, t570, t572;
  double tv2rhotau1, t574, t578, tv2rhotau2, t580, t584, t587, t588;
  double t589, t593, tv2rhotau3, t595, t600, t606, t607, t610;
  double tv2sigma20, tv2sigma21, tv2sigma22, tv2sigma23, tv2sigma24, t611, t616, t622;
  double t623, t626, tv2sigma25, tv2sigmalapl0, tv2sigmalapl1, tv2sigmalapl2, tv2sigmalapl3, tv2sigmalapl4;
  double tv2sigmalapl5, t627, t630, tv2sigmatau0, tv2sigmatau1, tv2sigmatau2, tv2sigmatau3, tv2sigmatau4;
  double t631, t634, tv2sigmatau5, tv2lapl20, tv2lapl21, tv2lapl22, tv2lapltau0, tv2lapltau1;
  double tv2lapltau2, tv2lapltau3, tv2tau20, tv2tau21, tv2tau22;


  t2 = rho[0] <= p->dens_threshold;
  t3 = sqrt(M_PI);
  t4 = 0.1e1 / t3;
  t5 = rho[0] + rho[1];
  t6 = 0.1e1 / t5;
  t9 = 0.2e1 * rho[0] * t6 <= p->zeta_threshold;
  t10 = p->zeta_threshold - 0.1e1;
  t13 = 0.2e1 * rho[1] * t6 <= p->zeta_threshold;
  t14 = -t10;
  t15 = rho[0] - rho[1];
  t17 = my_piecewise5(t9, t10, t13, t14, t15 * t6);
  t18 = 0.1e1 + t17;
  t19 = t18 <= p->zeta_threshold;
  t20 = sqrt(p->zeta_threshold);
  t21 = t20 * p->zeta_threshold;
  t22 = sqrt(t18);
  t23 = t22 * t18;
  t24 = my_piecewise3(t19, t21, t23);
  t25 = t4 * t24;
  t26 = M_SQRT2;
  t27 = sqrt(t5);
  t28 = t26 * t27;
  t29 = rho[0] * rho[0];
  t30 = t29 * rho[0];
  t31 = 0.1e1 / t30;
  t32 = sigma[0] * t31;
  t34 = sigma[0] * sigma[0];
  t35 = t29 * t29;
  t37 = 0.1e1 / t35 / t29;
  t40 = 0.1e1 + 0.41252961249419271031e0 * t32 + 0.63029881920225480858e-3 * t34 * t37;
  t41 = pow(t40, 0.1e1 / 0.15e2);
  t44 = 0.1e1 / t29;
  t48 = 0.1e1 / M_PI;
  t51 = 0.1e1 + 0.27938513438760141227e-1 * t32 + (-0.772e-1 * tau[0] * t44 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t52 = pow(t40, 0.1e1 / 0.5e1);
  t53 = 0.1e1 / t52;
  t56 = 0.1e1 / t41 + 0.2e1 / 0.5e1 * t51 * t53;
  t57 = t28 * t56;
  t60 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t57);
  t61 = rho[1] <= p->dens_threshold;
  t62 = -t15;
  t64 = my_piecewise5(t13, t10, t9, t14, t62 * t6);
  t65 = 0.1e1 + t64;
  t66 = t65 <= p->zeta_threshold;
  t67 = sqrt(t65);
  t68 = t67 * t65;
  t69 = my_piecewise3(t66, t21, t68);
  t70 = t4 * t69;
  t71 = rho[1] * rho[1];
  t72 = t71 * rho[1];
  t73 = 0.1e1 / t72;
  t74 = sigma[2] * t73;
  t76 = sigma[2] * sigma[2];
  t77 = t71 * t71;
  t79 = 0.1e1 / t77 / t71;
  t82 = 0.1e1 + 0.41252961249419271031e0 * t74 + 0.63029881920225480858e-3 * t76 * t79;
  t83 = pow(t82, 0.1e1 / 0.15e2);
  t86 = 0.1e1 / t71;
  t92 = 0.1e1 + 0.27938513438760141227e-1 * t74 + (-0.772e-1 * tau[1] * t86 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t93 = pow(t82, 0.1e1 / 0.5e1);
  t94 = 0.1e1 / t93;
  t97 = 0.1e1 / t83 + 0.2e1 / 0.5e1 * t92 * t94;
  t98 = t28 * t97;
  t101 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t98);
  tzk0 = t60 + t101;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t102 = t5 * t5;
  t103 = 0.1e1 / t102;
  t104 = t15 * t103;
  t106 = my_piecewise5(t9, 0, t13, 0, t6 - t104);
  t109 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t106);
  t110 = t4 * t109;
  t113 = 0.1e1 / t27;
  t114 = t26 * t113;
  t115 = t114 * t56;
  t117 = t25 * t115 / 0.3e1;
  t119 = 0.1e1 / t41 / t40;
  t120 = 0.1e1 / t35;
  t121 = sigma[0] * t120;
  t124 = 0.1e1 / t35 / t30;
  t127 = -0.12375888374825781309e1 * t121 - 0.37817929152135288515e-2 * t34 * t124;
  t133 = -0.83815540316280423681e-1 * t121 + 0.12286761606694319921e-1 * tau[0] * t31;
  t137 = 0.1e1 / t52 / t40;
  t138 = t51 * t137;
  t141 = -t119 * t127 / 0.15e2 + 0.2e1 / 0.5e1 * t133 * t53 - 0.2e1 / 0.25e2 * t138 * t127;
  t142 = t28 * t141;
  t146 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t57 - t117 - 0.2e1 / 0.3e1 * t25 * t142);
  t147 = t62 * t103;
  t149 = my_piecewise5(t13, 0, t9, 0, -t6 - t147);
  t152 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t149);
  t153 = t4 * t152;
  t156 = t114 * t97;
  t158 = t70 * t156 / 0.3e1;
  t160 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t98 - t158);
  tvrho0 = t60 + t101 + t5 * (t146 + t160);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t164 = my_piecewise5(t9, 0, t13, 0, -t6 - t104);
  t167 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t164);
  t168 = t4 * t167;
  t172 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t57 - t117);
  t174 = my_piecewise5(t13, 0, t9, 0, t6 - t147);
  t177 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t174);
  t178 = t4 * t177;
  t182 = 0.1e1 / t83 / t82;
  t183 = 0.1e1 / t77;
  t184 = sigma[2] * t183;
  t187 = 0.1e1 / t77 / t72;
  t190 = -0.12375888374825781309e1 * t184 - 0.37817929152135288515e-2 * t76 * t187;
  t196 = -0.83815540316280423681e-1 * t184 + 0.12286761606694319921e-1 * tau[1] * t73;
  t200 = 0.1e1 / t93 / t82;
  t201 = t92 * t200;
  t204 = -t182 * t190 / 0.15e2 + 0.2e1 / 0.5e1 * t196 * t94 - 0.2e1 / 0.25e2 * t201 * t190;
  t205 = t28 * t204;
  t209 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t98 - t158 - 0.2e1 / 0.3e1 * t70 * t205);
  tvrho1 = t60 + t101 + t5 * (t172 + t209);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 1] += tvrho1;

  t213 = sigma[0] * t37;
  t215 = 0.41252961249419271031e0 * t31 + 0.12605976384045096172e-2 * t213;
  t222 = -t119 * t215 / 0.15e2 + 0.11175405375504056491e-1 * t31 * t53 - 0.2e1 / 0.25e2 * t138 * t215;
  t223 = t28 * t222;
  t226 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t223);
  tvsigma0 = t5 * t226;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvsigma1 = 0.e0;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 1] += tvsigma1;

  t228 = sigma[2] * t79;
  t230 = 0.41252961249419271031e0 * t73 + 0.12605976384045096172e-2 * t228;
  t237 = -t182 * t230 / 0.15e2 + 0.11175405375504056491e-1 * t73 * t94 - 0.2e1 / 0.25e2 * t201 * t230;
  t238 = t28 * t237;
  t241 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t238);
  tvsigma2 = t5 * t241;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 2] += tvsigma2;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  tvlapl1 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 1] += tvlapl1;

  t242 = t24 * t26;
  t244 = t27 * t44 * t53;
  t247 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t242 * t244);
  tvtau0 = t5 * t247;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t248 = t69 * t26;
  t250 = t27 * t86 * t94;
  t253 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t248 * t250);
  tvtau1 = t5 * t253;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 1] += tvtau1;

  t256 = 0.1e1 / t22;
  t257 = t106 * t106;
  t260 = t102 * t5;
  t261 = 0.1e1 / t260;
  t262 = t15 * t261;
  t265 = my_piecewise5(t9, 0, t13, 0, -0.2e1 * t103 + 0.2e1 * t262);
  t269 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t256 * t257 + 0.3e1 / 0.2e1 * t22 * t265);
  t270 = t4 * t269;
  t273 = t110 * t115;
  t278 = 0.1e1 / t27 / t5;
  t279 = t26 * t278;
  t280 = t279 * t56;
  t282 = t25 * t280 / 0.6e1;
  t283 = t114 * t141;
  t284 = t25 * t283;
  t286 = t40 * t40;
  t288 = 0.1e1 / t41 / t286;
  t289 = t127 * t127;
  t293 = 0.1e1 / t35 / rho[0];
  t294 = sigma[0] * t293;
  t296 = t35 * t35;
  t297 = 0.1e1 / t296;
  t300 = 0.49503553499303125236e1 * t294 + 0.2647255040649470196e-1 * t34 * t297;
  t306 = 0.33526216126512169472e0 * t294 - 0.36860284820082959763e-1 * tau[0] * t120;
  t309 = t133 * t137;
  t313 = 0.1e1 / t52 / t286;
  t314 = t51 * t313;
  t319 = 0.16e2 / 0.225e3 * t288 * t289 - t119 * t300 / 0.15e2 + 0.2e1 / 0.5e1 * t306 * t53 - 0.4e1 / 0.25e2 * t309 * t127 + 0.12e2 / 0.125e3 * t314 * t289 - 0.2e1 / 0.25e2 * t138 * t300;
  t320 = t28 * t319;
  t324 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t270 * t57 - 0.2e1 / 0.3e1 * t273 - 0.4e1 / 0.3e1 * t110 * t142 + t282 - 0.2e1 / 0.3e1 * t284 - 0.2e1 / 0.3e1 * t25 * t320);
  t325 = 0.1e1 / t67;
  t326 = t149 * t149;
  t329 = t62 * t261;
  t332 = my_piecewise5(t13, 0, t9, 0, 0.2e1 * t103 + 0.2e1 * t329);
  t336 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t325 * t326 + 0.3e1 / 0.2e1 * t67 * t332);
  t337 = t4 * t336;
  t340 = t153 * t156;
  t342 = t279 * t97;
  t344 = t70 * t342 / 0.6e1;
  t346 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t337 * t98 - 0.2e1 / 0.3e1 * t340 + t344);
  tv2rho20 = 0.2e1 * t146 + 0.2e1 * t160 + t5 * (t324 + t346);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 0] += tv2rho20;

  t349 = t256 * t164;
  t353 = my_piecewise5(t9, 0, t13, 0, 0.2e1 * t262);
  t357 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t349 * t106 + 0.3e1 / 0.2e1 * t22 * t353);
  t358 = t4 * t357;
  t361 = t168 * t115;
  t368 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t358 * t57 - t361 / 0.3e1 - 0.2e1 / 0.3e1 * t168 * t142 - t273 / 0.3e1 + t282 - t284 / 0.3e1);
  t369 = t325 * t174;
  t373 = my_piecewise5(t13, 0, t9, 0, 0.2e1 * t329);
  t377 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t369 * t149 + 0.3e1 / 0.2e1 * t67 * t373);
  t378 = t4 * t377;
  t381 = t178 * t156;
  t386 = t114 * t204;
  t387 = t70 * t386;
  t390 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t378 * t98 - t381 / 0.3e1 - t340 / 0.3e1 + t344 - 0.2e1 / 0.3e1 * t153 * t205 - t387 / 0.3e1);
  tv2rho21 = t146 + t160 + t172 + t209 + t5 * (t368 + t390);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 1] += tv2rho21;

  t395 = t164 * t164;
  t400 = my_piecewise5(t9, 0, t13, 0, 0.2e1 * t103 + 0.2e1 * t262);
  t404 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t256 * t395 + 0.3e1 / 0.2e1 * t22 * t400);
  t405 = t4 * t404;
  t410 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t405 * t57 - 0.2e1 / 0.3e1 * t361 + t282);
  t411 = t174 * t174;
  t416 = my_piecewise5(t13, 0, t9, 0, -0.2e1 * t103 + 0.2e1 * t329);
  t420 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t325 * t411 + 0.3e1 / 0.2e1 * t67 * t416);
  t421 = t4 * t420;
  t428 = t82 * t82;
  t430 = 0.1e1 / t83 / t428;
  t431 = t190 * t190;
  t435 = 0.1e1 / t77 / rho[1];
  t436 = sigma[2] * t435;
  t438 = t77 * t77;
  t439 = 0.1e1 / t438;
  t442 = 0.49503553499303125236e1 * t436 + 0.2647255040649470196e-1 * t76 * t439;
  t448 = 0.33526216126512169472e0 * t436 - 0.36860284820082959763e-1 * tau[1] * t183;
  t451 = t196 * t200;
  t455 = 0.1e1 / t93 / t428;
  t456 = t92 * t455;
  t461 = 0.16e2 / 0.225e3 * t430 * t431 - t182 * t442 / 0.15e2 + 0.2e1 / 0.5e1 * t448 * t94 - 0.4e1 / 0.25e2 * t451 * t190 + 0.12e2 / 0.125e3 * t456 * t431 - 0.2e1 / 0.25e2 * t201 * t442;
  t462 = t28 * t461;
  t466 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t421 * t98 - 0.2e1 / 0.3e1 * t381 - 0.4e1 / 0.3e1 * t178 * t205 + t344 - 0.2e1 / 0.3e1 * t387 - 0.2e1 / 0.3e1 * t70 * t462);
  tv2rho22 = 0.2e1 * t172 + 0.2e1 * t209 + t5 * (t410 + t466);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 2] += tv2rho22;

  t471 = t114 * t222;
  t473 = t25 * t471 / 0.3e1;
  t474 = t288 * t215;
  t478 = sigma[0] * t124;
  t480 = -0.12375888374825781309e1 * t120 - 0.75635858304270577032e-2 * t478;
  t485 = t31 * t137;
  t486 = t485 * t127;
  t490 = t215 * t127;
  t495 = 0.16e2 / 0.225e3 * t474 * t127 - t119 * t480 / 0.15e2 - 0.33526216126512169473e-1 * t120 * t53 - 0.22350810751008112982e-2 * t486 - 0.2e1 / 0.25e2 * t309 * t215 + 0.12e2 / 0.125e3 * t314 * t490 - 0.2e1 / 0.25e2 * t138 * t480;
  t496 = t28 * t495;
  t500 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t223 - t473 - 0.2e1 / 0.3e1 * t25 * t496);
  tv2rhosigma0 = t5 * t500 + t226;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 0] += tv2rhosigma0;

  tv2rhosigma1 = 0.e0;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 1] += tv2rhosigma1;

  t504 = t114 * t237;
  t506 = t70 * t504 / 0.3e1;
  t508 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t238 - t506);
  tv2rhosigma2 = t5 * t508 + t241;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 2] += tv2rhosigma2;

  t513 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t223 - t473);
  tv2rhosigma3 = t5 * t513 + t226;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 3] += tv2rhosigma3;

  tv2rhosigma4 = 0.e0;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 4] += tv2rhosigma4;

  t517 = t430 * t230;
  t521 = sigma[2] * t187;
  t523 = -0.12375888374825781309e1 * t183 - 0.75635858304270577032e-2 * t521;
  t528 = t73 * t200;
  t529 = t528 * t190;
  t533 = t230 * t190;
  t538 = 0.16e2 / 0.225e3 * t517 * t190 - t182 * t523 / 0.15e2 - 0.33526216126512169473e-1 * t183 * t94 - 0.22350810751008112982e-2 * t529 - 0.2e1 / 0.25e2 * t451 * t230 + 0.12e2 / 0.125e3 * t456 * t533 - 0.2e1 / 0.25e2 * t201 * t523;
  t539 = t28 * t538;
  t543 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t238 - t506 - 0.2e1 / 0.3e1 * t70 * t539);
  tv2rhosigma5 = t5 * t543 + t241;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 5] += tv2rhosigma5;

  tv2rholapl0 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 0] += tv2rholapl0;

  tv2rholapl1 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 1] += tv2rholapl1;

  tv2rholapl2 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 2] += tv2rholapl2;

  tv2rholapl3 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 3] += tv2rholapl3;

  t545 = t109 * t26;
  t549 = t113 * t44 * t53;
  t551 = 0.4621375276020952854e-3 * t242 * t549;
  t553 = t27 * t31 * t53;
  t556 = t242 * t27;
  t557 = t44 * t137;
  t558 = t557 * t127;
  t562 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t545 * t244 + t551 - 0.18485501104083811416e-2 * t242 * t553 - 0.18485501104083811416e-3 * t556 * t558);
  tv2rhotau0 = t5 * t562 + t247;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 0] += tv2rhotau0;

  t564 = t152 * t26;
  t568 = t113 * t86 * t94;
  t570 = 0.4621375276020952854e-3 * t248 * t568;
  t572 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t564 * t250 + t570);
  tv2rhotau1 = t5 * t572 + t253;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 1] += tv2rhotau1;

  t574 = t167 * t26;
  t578 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t574 * t244 + t551);
  tv2rhotau2 = t5 * t578 + t247;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 2] += tv2rhotau2;

  t580 = t177 * t26;
  t584 = t27 * t73 * t94;
  t587 = t248 * t27;
  t588 = t86 * t200;
  t589 = t588 * t190;
  t593 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t580 * t250 + t570 - 0.18485501104083811416e-2 * t248 * t584 - 0.18485501104083811416e-3 * t587 * t589);
  tv2rhotau3 = t5 * t593 + t253;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 3] += tv2rhotau3;

  t595 = t215 * t215;
  t600 = t485 * t215;
  t606 = 0.16e2 / 0.225e3 * t288 * t595 - 0.84039842560300641147e-4 * t119 * t37 - 0.44701621502016225964e-2 * t600 + 0.12e2 / 0.125e3 * t314 * t595 - 0.10084781107236076938e-3 * t138 * t37;
  t607 = t28 * t606;
  t610 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t607);
  tv2sigma20 = t5 * t610;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 0] += tv2sigma20;

  tv2sigma21 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 1] += tv2sigma21;

  tv2sigma22 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 2] += tv2sigma22;

  tv2sigma23 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 3] += tv2sigma23;

  tv2sigma24 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 4] += tv2sigma24;

  t611 = t230 * t230;
  t616 = t528 * t230;
  t622 = 0.16e2 / 0.225e3 * t430 * t611 - 0.84039842560300641147e-4 * t182 * t79 - 0.44701621502016225964e-2 * t616 + 0.12e2 / 0.125e3 * t456 * t611 - 0.10084781107236076938e-3 * t201 * t79;
  t623 = t28 * t622;
  t626 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t623);
  tv2sigma25 = t5 * t626;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 5] += tv2sigma25;

  tv2sigmalapl0 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 0] += tv2sigmalapl0;

  tv2sigmalapl1 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 1] += tv2sigmalapl1;

  tv2sigmalapl2 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 2] += tv2sigmalapl2;

  tv2sigmalapl3 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 3] += tv2sigmalapl3;

  tv2sigmalapl4 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 4] += tv2sigmalapl4;

  tv2sigmalapl5 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 5] += tv2sigmalapl5;

  t627 = t557 * t215;
  t630 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t556 * t627);
  tv2sigmatau0 = t5 * t630;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 0] += tv2sigmatau0;

  tv2sigmatau1 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 1] += tv2sigmatau1;

  tv2sigmatau2 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 2] += tv2sigmatau2;

  tv2sigmatau3 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 3] += tv2sigmatau3;

  tv2sigmatau4 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 4] += tv2sigmatau4;

  t631 = t588 * t230;
  t634 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t587 * t631);
  tv2sigmatau5 = t5 * t634;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 5] += tv2sigmatau5;

  tv2lapl20 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 0] += tv2lapl20;

  tv2lapl21 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 1] += tv2lapl21;

  tv2lapl22 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 2] += tv2lapl22;

  tv2lapltau0 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 0] += tv2lapltau0;

  tv2lapltau1 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 1] += tv2lapltau1;

  tv2lapltau2 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 2] += tv2lapltau2;

  tv2lapltau3 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 3] += tv2lapltau3;

  tv2tau20 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 0] += tv2tau20;

  tv2tau21 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 1] += tv2tau21;

  tv2tau22 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 2] += tv2tau22;

}

#endif


#ifndef XC_DONT_COMPILE_KXC
GPU_DEVICE_FUNCTION static inline void
func_kxc_pol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t2, t3, t4, t5, t6, t9, t10, t13;
  double t14, t15, t17, t18, t19, t20, t21, t22;
  double t23, t24, t25, t26, t27, t28, t29, t30;
  double t31, t32, t34, t35, t37, t40, t41, t44;
  double t48, t51, t52, t53, t56, t57, t60, t61;
  double t62, t64, t65, t66, t67, t68, t69, t70;
  double t71, t72, t73, t74, t76, t77, t79, t82;
  double t83, t86, t92, t93, t94, t97, t98, t101;
  double tzk0;

  double t102, t103, t104, t106, t109, t110, t113, t114;
  double t115, t117, t119, t120, t121, t124, t127, t133;
  double t137, t138, t141, t142, t146, t147, t149, t152;
  double t153, t156, t158, t160, tvrho0, t164, t167, t168;
  double t172, t174, t177, t178, t182, t183, t184, t187;
  double t190, t196, t200, t201, t204, t205, t209, tvrho1;
  double t213, t215, t222, t223, t226, tvsigma0, tvsigma1, t228;
  double t230, t237, t238, t241, tvsigma2, tvlapl0, tvlapl1, t242;
  double t244, t247, tvtau0, t248, t250, t253, tvtau1;

  double t256, t257, t260, t261, t262, t265, t269, t270;
  double t273, t278, t279, t280, t282, t283, t284, t286;
  double t288, t289, t293, t294, t296, t297, t300, t306;
  double t309, t313, t314, t319, t320, t324, t325, t326;
  double t329, t332, t336, t337, t340, t342, t344, t346;
  double tv2rho20, t349, t353, t357, t358, t361, t368, t369;
  double t373, t377, t378, t381, t386, t387, t390, tv2rho21;
  double t395, t400, t404, t405, t410, t411, t416, t420;
  double t421, t428, t430, t431, t435, t436, t438, t439;
  double t442, t448, t451, t455, t456, t461, t462, t466;
  double tv2rho22, t471, t473, t474, t478, t480, t485, t486;
  double t490, t495, t496, t500, tv2rhosigma0, tv2rhosigma1, t504, t506;
  double t508, tv2rhosigma2, t513, tv2rhosigma3, tv2rhosigma4, t517, t521, t523;
  double t528, t529, t533, t538, t539, t543, tv2rhosigma5, tv2rholapl0;
  double tv2rholapl1, tv2rholapl2, tv2rholapl3, t545, t549, t551, t553, t556;
  double t557, t558, t562, tv2rhotau0, t564, t568, t570, t572;
  double tv2rhotau1, t574, t578, tv2rhotau2, t580, t584, t587, t588;
  double t589, t593, tv2rhotau3, t595, t600, t606, t607, t610;
  double tv2sigma20, tv2sigma21, tv2sigma22, tv2sigma23, tv2sigma24, t611, t616, t622;
  double t623, t626, tv2sigma25, tv2sigmalapl0, tv2sigmalapl1, tv2sigmalapl2, tv2sigmalapl3, tv2sigmalapl4;
  double tv2sigmalapl5, t627, t630, tv2sigmatau0, tv2sigmatau1, tv2sigmatau2, tv2sigmatau3, tv2sigmatau4;
  double t631, t634, tv2sigmatau5, tv2lapl20, tv2lapl21, tv2lapl22, tv2lapltau0, tv2lapltau1;
  double tv2lapltau2, tv2lapltau3, tv2tau20, tv2tau21, tv2tau22;

  double t637, t638, t641, t644, t645, t646, t649, t653;
  double t654, t657, t660, t662, t667, t668, t669, t671;
  double t672, t673, t675, t676, t677, t679, t680, t683;
  double t688, t691, t697, t700, t703, t709, t710, t713;
  double t718, t719, t723, t724, t725, t728, t731, t734;
  double t738, t739, t742, t743, t745, t747, t749, tv3rho30;
  double t752, t753, t754, t757, t762, t763, t765, t769;
  double t770, t774, t777, t780, t788, t789, t790, t793;
  double t798, t800, t804, t805, t809, t810, t817, t818;
  double t819, t822, tv3rho31, t825, t830, t834, t838, t839;
  double t842, t850, t851, t856, t860, t864, t865, t868;
  double t873, t879, t880, t882, t883, tv3rho32, t888, t895;
  double t899, t900, t905, t906, t913, t917, t918, t928;
  double t930, t931, t934, t939, t942, t948, t951, t954;
  double t960, t961, t964, t969, t970, t974, tv3rho33, t980;
  double t984, t986, t987, t988, t990, t993, t1001, t1006;
  double t1007, t1009, t1010, t1012, t1020, t1023, t1026, t1031;
  double t1032, t1036, tv3rho2sigma0, tv3rho2sigma1, t1041, t1043, t1045, t1047;
  double tv3rho2sigma2, t1051, t1058, tv3rho2sigma3, tv3rho2sigma4, t1062, t1067, t1068;
  double t1071, tv3rho2sigma5, t1078, tv3rho2sigma6, tv3rho2sigma7, t1087, t1090, t1098;
  double t1103, t1104, t1106, t1107, t1109, t1117, t1120, t1123;
  double t1128, t1129, t1133, tv3rho2sigma8, tv3rho2lapl0, tv3rho2lapl1, tv3rho2lapl2, tv3rho2lapl3;
  double tv3rho2lapl4, tv3rho2lapl5, t1136, t1139, t1143, t1147, t1149, t1151;
  double t1152, t1154, t1155, t1158, t1163, t1164, t1167, t1170;
  double t1171, tv3rho2tau0, t1174, t1177, t1180, t1182, t1184, tv3rho2tau1;
  double t1186, t1189, t1193, t1200, tv3rho2tau2, t1202, t1205, t1211;
  double t1212, t1214, t1217, t1218, t1221, tv3rho2tau3, t1224, t1229;
  double tv3rho2tau4, t1232, t1238, t1244, t1249, t1250, t1253, t1256;
  double t1257, tv3rho2tau5, t1261, t1263, t1264, t1269, t1274, t1276;
  double t1278, t1282, t1285, t1290, t1295, t1296, t1300, tv3rhosigma20;
  double tv3rhosigma21, tv3rhosigma22, tv3rhosigma23, tv3rhosigma24, t1304, t1306, t1308, tv3rhosigma25;
  double t1313, tv3rhosigma26, tv3rhosigma27, tv3rhosigma28, tv3rhosigma29, tv3rhosigma210, t1317, t1322;
  double t1327, t1329, t1331, t1335, t1338, t1343, t1348, t1349;
  double t1353, tv3rhosigma211, tv3rhosigmalapl0, tv3rhosigmalapl1, tv3rhosigmalapl2, tv3rhosigmalapl3, tv3rhosigmalapl4, tv3rhosigmalapl5;
  double tv3rhosigmalapl6, tv3rhosigmalapl7, tv3rhosigmalapl8, tv3rhosigmalapl9, tv3rhosigmalapl10, tv3rhosigmalapl11, t1358, t1361;
  double t1364, t1368, tv3rhosigmatau0, tv3rhosigmatau1, tv3rhosigmatau2, tv3rhosigmatau3, tv3rhosigmatau4, t1373;
  double t1375, tv3rhosigmatau5, t1380, tv3rhosigmatau6, tv3rhosigmatau7, tv3rhosigmatau8, tv3rhosigmatau9, tv3rhosigmatau10;
  double t1386, t1389, t1393, tv3rhosigmatau11, tv3rholapl20, tv3rholapl21, tv3rholapl22, tv3rholapl23;
  double tv3rholapl24, tv3rholapl25, tv3rholapltau0, tv3rholapltau1, tv3rholapltau2, tv3rholapltau3, tv3rholapltau4, tv3rholapltau5;
  double tv3rholapltau6, tv3rholapltau7, tv3rhotau20, tv3rhotau21, tv3rhotau22, tv3rhotau23, tv3rhotau24, tv3rhotau25;
  double t1395, t1400, t1406, t1409, t1410, t1413, tv3sigma30, tv3sigma31;
  double tv3sigma32, tv3sigma33, tv3sigma34, tv3sigma35, tv3sigma36, tv3sigma37, tv3sigma38, t1414;
  double t1419, t1425, t1428, t1429, t1432, tv3sigma39, tv3sigma2lapl0, tv3sigma2lapl1;
  double tv3sigma2lapl2, tv3sigma2lapl3, tv3sigma2lapl4, tv3sigma2lapl5, tv3sigma2lapl6, tv3sigma2lapl7, tv3sigma2lapl8, tv3sigma2lapl9;
  double tv3sigma2lapl10, tv3sigma2lapl11, t1433, t1437, t1441, tv3sigma2tau0, tv3sigma2tau1, tv3sigma2tau2;
  double tv3sigma2tau3, tv3sigma2tau4, tv3sigma2tau5, tv3sigma2tau6, tv3sigma2tau7, tv3sigma2tau8, tv3sigma2tau9, tv3sigma2tau10;
  double t1442, t1446, t1450, tv3sigma2tau11, tv3sigmalapl20, tv3sigmalapl21, tv3sigmalapl22, tv3sigmalapl23;
  double tv3sigmalapl24, tv3sigmalapl25, tv3sigmalapl26, tv3sigmalapl27, tv3sigmalapl28, tv3sigmalapltau0, tv3sigmalapltau1, tv3sigmalapltau2;
  double tv3sigmalapltau3, tv3sigmalapltau4, tv3sigmalapltau5, tv3sigmalapltau6, tv3sigmalapltau7, tv3sigmalapltau8, tv3sigmalapltau9, tv3sigmalapltau10;
  double tv3sigmalapltau11, tv3sigmatau20, tv3sigmatau21, tv3sigmatau22, tv3sigmatau23, tv3sigmatau24, tv3sigmatau25, tv3sigmatau26;
  double tv3sigmatau27, tv3sigmatau28, tv3lapl30, tv3lapl31, tv3lapl32, tv3lapl33, tv3lapl2tau0, tv3lapl2tau1;
  double tv3lapl2tau2, tv3lapl2tau3, tv3lapl2tau4, tv3lapl2tau5, tv3lapltau20, tv3lapltau21, tv3lapltau22, tv3lapltau23;
  double tv3lapltau24, tv3lapltau25, tv3tau30, tv3tau31, tv3tau32, tv3tau33;


  t2 = rho[0] <= p->dens_threshold;
  t3 = sqrt(M_PI);
  t4 = 0.1e1 / t3;
  t5 = rho[0] + rho[1];
  t6 = 0.1e1 / t5;
  t9 = 0.2e1 * rho[0] * t6 <= p->zeta_threshold;
  t10 = p->zeta_threshold - 0.1e1;
  t13 = 0.2e1 * rho[1] * t6 <= p->zeta_threshold;
  t14 = -t10;
  t15 = rho[0] - rho[1];
  t17 = my_piecewise5(t9, t10, t13, t14, t15 * t6);
  t18 = 0.1e1 + t17;
  t19 = t18 <= p->zeta_threshold;
  t20 = sqrt(p->zeta_threshold);
  t21 = t20 * p->zeta_threshold;
  t22 = sqrt(t18);
  t23 = t22 * t18;
  t24 = my_piecewise3(t19, t21, t23);
  t25 = t4 * t24;
  t26 = M_SQRT2;
  t27 = sqrt(t5);
  t28 = t26 * t27;
  t29 = rho[0] * rho[0];
  t30 = t29 * rho[0];
  t31 = 0.1e1 / t30;
  t32 = sigma[0] * t31;
  t34 = sigma[0] * sigma[0];
  t35 = t29 * t29;
  t37 = 0.1e1 / t35 / t29;
  t40 = 0.1e1 + 0.41252961249419271031e0 * t32 + 0.63029881920225480858e-3 * t34 * t37;
  t41 = pow(t40, 0.1e1 / 0.15e2);
  t44 = 0.1e1 / t29;
  t48 = 0.1e1 / M_PI;
  t51 = 0.1e1 + 0.27938513438760141227e-1 * t32 + (-0.772e-1 * tau[0] * t44 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t52 = pow(t40, 0.1e1 / 0.5e1);
  t53 = 0.1e1 / t52;
  t56 = 0.1e1 / t41 + 0.2e1 / 0.5e1 * t51 * t53;
  t57 = t28 * t56;
  t60 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t57);
  t61 = rho[1] <= p->dens_threshold;
  t62 = -t15;
  t64 = my_piecewise5(t13, t10, t9, t14, t62 * t6);
  t65 = 0.1e1 + t64;
  t66 = t65 <= p->zeta_threshold;
  t67 = sqrt(t65);
  t68 = t67 * t65;
  t69 = my_piecewise3(t66, t21, t68);
  t70 = t4 * t69;
  t71 = rho[1] * rho[1];
  t72 = t71 * rho[1];
  t73 = 0.1e1 / t72;
  t74 = sigma[2] * t73;
  t76 = sigma[2] * sigma[2];
  t77 = t71 * t71;
  t79 = 0.1e1 / t77 / t71;
  t82 = 0.1e1 + 0.41252961249419271031e0 * t74 + 0.63029881920225480858e-3 * t76 * t79;
  t83 = pow(t82, 0.1e1 / 0.15e2);
  t86 = 0.1e1 / t71;
  t92 = 0.1e1 + 0.27938513438760141227e-1 * t74 + (-0.772e-1 * tau[1] * t86 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t93 = pow(t82, 0.1e1 / 0.5e1);
  t94 = 0.1e1 / t93;
  t97 = 0.1e1 / t83 + 0.2e1 / 0.5e1 * t92 * t94;
  t98 = t28 * t97;
  t101 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t98);
  tzk0 = t60 + t101;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t102 = t5 * t5;
  t103 = 0.1e1 / t102;
  t104 = t15 * t103;
  t106 = my_piecewise5(t9, 0, t13, 0, t6 - t104);
  t109 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t106);
  t110 = t4 * t109;
  t113 = 0.1e1 / t27;
  t114 = t26 * t113;
  t115 = t114 * t56;
  t117 = t25 * t115 / 0.3e1;
  t119 = 0.1e1 / t41 / t40;
  t120 = 0.1e1 / t35;
  t121 = sigma[0] * t120;
  t124 = 0.1e1 / t35 / t30;
  t127 = -0.12375888374825781309e1 * t121 - 0.37817929152135288515e-2 * t34 * t124;
  t133 = -0.83815540316280423681e-1 * t121 + 0.12286761606694319921e-1 * tau[0] * t31;
  t137 = 0.1e1 / t52 / t40;
  t138 = t51 * t137;
  t141 = -t119 * t127 / 0.15e2 + 0.2e1 / 0.5e1 * t133 * t53 - 0.2e1 / 0.25e2 * t138 * t127;
  t142 = t28 * t141;
  t146 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t57 - t117 - 0.2e1 / 0.3e1 * t25 * t142);
  t147 = t62 * t103;
  t149 = my_piecewise5(t13, 0, t9, 0, -t6 - t147);
  t152 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t149);
  t153 = t4 * t152;
  t156 = t114 * t97;
  t158 = t70 * t156 / 0.3e1;
  t160 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t98 - t158);
  tvrho0 = t60 + t101 + t5 * (t146 + t160);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t164 = my_piecewise5(t9, 0, t13, 0, -t6 - t104);
  t167 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t164);
  t168 = t4 * t167;
  t172 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t57 - t117);
  t174 = my_piecewise5(t13, 0, t9, 0, t6 - t147);
  t177 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t174);
  t178 = t4 * t177;
  t182 = 0.1e1 / t83 / t82;
  t183 = 0.1e1 / t77;
  t184 = sigma[2] * t183;
  t187 = 0.1e1 / t77 / t72;
  t190 = -0.12375888374825781309e1 * t184 - 0.37817929152135288515e-2 * t76 * t187;
  t196 = -0.83815540316280423681e-1 * t184 + 0.12286761606694319921e-1 * tau[1] * t73;
  t200 = 0.1e1 / t93 / t82;
  t201 = t92 * t200;
  t204 = -t182 * t190 / 0.15e2 + 0.2e1 / 0.5e1 * t196 * t94 - 0.2e1 / 0.25e2 * t201 * t190;
  t205 = t28 * t204;
  t209 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t98 - t158 - 0.2e1 / 0.3e1 * t70 * t205);
  tvrho1 = t60 + t101 + t5 * (t172 + t209);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 1] += tvrho1;

  t213 = sigma[0] * t37;
  t215 = 0.41252961249419271031e0 * t31 + 0.12605976384045096172e-2 * t213;
  t222 = -t119 * t215 / 0.15e2 + 0.11175405375504056491e-1 * t31 * t53 - 0.2e1 / 0.25e2 * t138 * t215;
  t223 = t28 * t222;
  t226 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t223);
  tvsigma0 = t5 * t226;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvsigma1 = 0.e0;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 1] += tvsigma1;

  t228 = sigma[2] * t79;
  t230 = 0.41252961249419271031e0 * t73 + 0.12605976384045096172e-2 * t228;
  t237 = -t182 * t230 / 0.15e2 + 0.11175405375504056491e-1 * t73 * t94 - 0.2e1 / 0.25e2 * t201 * t230;
  t238 = t28 * t237;
  t241 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t238);
  tvsigma2 = t5 * t241;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 2] += tvsigma2;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  tvlapl1 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 1] += tvlapl1;

  t242 = t24 * t26;
  t244 = t27 * t44 * t53;
  t247 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t242 * t244);
  tvtau0 = t5 * t247;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t248 = t69 * t26;
  t250 = t27 * t86 * t94;
  t253 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t248 * t250);
  tvtau1 = t5 * t253;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 1] += tvtau1;

  t256 = 0.1e1 / t22;
  t257 = t106 * t106;
  t260 = t102 * t5;
  t261 = 0.1e1 / t260;
  t262 = t15 * t261;
  t265 = my_piecewise5(t9, 0, t13, 0, -0.2e1 * t103 + 0.2e1 * t262);
  t269 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t256 * t257 + 0.3e1 / 0.2e1 * t22 * t265);
  t270 = t4 * t269;
  t273 = t110 * t115;
  t278 = 0.1e1 / t27 / t5;
  t279 = t26 * t278;
  t280 = t279 * t56;
  t282 = t25 * t280 / 0.6e1;
  t283 = t114 * t141;
  t284 = t25 * t283;
  t286 = t40 * t40;
  t288 = 0.1e1 / t41 / t286;
  t289 = t127 * t127;
  t293 = 0.1e1 / t35 / rho[0];
  t294 = sigma[0] * t293;
  t296 = t35 * t35;
  t297 = 0.1e1 / t296;
  t300 = 0.49503553499303125236e1 * t294 + 0.2647255040649470196e-1 * t34 * t297;
  t306 = 0.33526216126512169472e0 * t294 - 0.36860284820082959763e-1 * tau[0] * t120;
  t309 = t133 * t137;
  t313 = 0.1e1 / t52 / t286;
  t314 = t51 * t313;
  t319 = 0.16e2 / 0.225e3 * t288 * t289 - t119 * t300 / 0.15e2 + 0.2e1 / 0.5e1 * t306 * t53 - 0.4e1 / 0.25e2 * t309 * t127 + 0.12e2 / 0.125e3 * t314 * t289 - 0.2e1 / 0.25e2 * t138 * t300;
  t320 = t28 * t319;
  t324 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t270 * t57 - 0.2e1 / 0.3e1 * t273 - 0.4e1 / 0.3e1 * t110 * t142 + t282 - 0.2e1 / 0.3e1 * t284 - 0.2e1 / 0.3e1 * t25 * t320);
  t325 = 0.1e1 / t67;
  t326 = t149 * t149;
  t329 = t62 * t261;
  t332 = my_piecewise5(t13, 0, t9, 0, 0.2e1 * t103 + 0.2e1 * t329);
  t336 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t325 * t326 + 0.3e1 / 0.2e1 * t67 * t332);
  t337 = t4 * t336;
  t340 = t153 * t156;
  t342 = t279 * t97;
  t344 = t70 * t342 / 0.6e1;
  t346 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t337 * t98 - 0.2e1 / 0.3e1 * t340 + t344);
  tv2rho20 = 0.2e1 * t146 + 0.2e1 * t160 + t5 * (t324 + t346);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 0] += tv2rho20;

  t349 = t256 * t164;
  t353 = my_piecewise5(t9, 0, t13, 0, 0.2e1 * t262);
  t357 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t349 * t106 + 0.3e1 / 0.2e1 * t22 * t353);
  t358 = t4 * t357;
  t361 = t168 * t115;
  t368 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t358 * t57 - t361 / 0.3e1 - 0.2e1 / 0.3e1 * t168 * t142 - t273 / 0.3e1 + t282 - t284 / 0.3e1);
  t369 = t325 * t174;
  t373 = my_piecewise5(t13, 0, t9, 0, 0.2e1 * t329);
  t377 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t369 * t149 + 0.3e1 / 0.2e1 * t67 * t373);
  t378 = t4 * t377;
  t381 = t178 * t156;
  t386 = t114 * t204;
  t387 = t70 * t386;
  t390 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t378 * t98 - t381 / 0.3e1 - t340 / 0.3e1 + t344 - 0.2e1 / 0.3e1 * t153 * t205 - t387 / 0.3e1);
  tv2rho21 = t146 + t160 + t172 + t209 + t5 * (t368 + t390);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 1] += tv2rho21;

  t395 = t164 * t164;
  t400 = my_piecewise5(t9, 0, t13, 0, 0.2e1 * t103 + 0.2e1 * t262);
  t404 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t256 * t395 + 0.3e1 / 0.2e1 * t22 * t400);
  t405 = t4 * t404;
  t410 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t405 * t57 - 0.2e1 / 0.3e1 * t361 + t282);
  t411 = t174 * t174;
  t416 = my_piecewise5(t13, 0, t9, 0, -0.2e1 * t103 + 0.2e1 * t329);
  t420 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t325 * t411 + 0.3e1 / 0.2e1 * t67 * t416);
  t421 = t4 * t420;
  t428 = t82 * t82;
  t430 = 0.1e1 / t83 / t428;
  t431 = t190 * t190;
  t435 = 0.1e1 / t77 / rho[1];
  t436 = sigma[2] * t435;
  t438 = t77 * t77;
  t439 = 0.1e1 / t438;
  t442 = 0.49503553499303125236e1 * t436 + 0.2647255040649470196e-1 * t76 * t439;
  t448 = 0.33526216126512169472e0 * t436 - 0.36860284820082959763e-1 * tau[1] * t183;
  t451 = t196 * t200;
  t455 = 0.1e1 / t93 / t428;
  t456 = t92 * t455;
  t461 = 0.16e2 / 0.225e3 * t430 * t431 - t182 * t442 / 0.15e2 + 0.2e1 / 0.5e1 * t448 * t94 - 0.4e1 / 0.25e2 * t451 * t190 + 0.12e2 / 0.125e3 * t456 * t431 - 0.2e1 / 0.25e2 * t201 * t442;
  t462 = t28 * t461;
  t466 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t421 * t98 - 0.2e1 / 0.3e1 * t381 - 0.4e1 / 0.3e1 * t178 * t205 + t344 - 0.2e1 / 0.3e1 * t387 - 0.2e1 / 0.3e1 * t70 * t462);
  tv2rho22 = 0.2e1 * t172 + 0.2e1 * t209 + t5 * (t410 + t466);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 2] += tv2rho22;

  t471 = t114 * t222;
  t473 = t25 * t471 / 0.3e1;
  t474 = t288 * t215;
  t478 = sigma[0] * t124;
  t480 = -0.12375888374825781309e1 * t120 - 0.75635858304270577032e-2 * t478;
  t485 = t31 * t137;
  t486 = t485 * t127;
  t490 = t215 * t127;
  t495 = 0.16e2 / 0.225e3 * t474 * t127 - t119 * t480 / 0.15e2 - 0.33526216126512169473e-1 * t120 * t53 - 0.22350810751008112982e-2 * t486 - 0.2e1 / 0.25e2 * t309 * t215 + 0.12e2 / 0.125e3 * t314 * t490 - 0.2e1 / 0.25e2 * t138 * t480;
  t496 = t28 * t495;
  t500 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t223 - t473 - 0.2e1 / 0.3e1 * t25 * t496);
  tv2rhosigma0 = t5 * t500 + t226;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 0] += tv2rhosigma0;

  tv2rhosigma1 = 0.e0;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 1] += tv2rhosigma1;

  t504 = t114 * t237;
  t506 = t70 * t504 / 0.3e1;
  t508 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t238 - t506);
  tv2rhosigma2 = t5 * t508 + t241;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 2] += tv2rhosigma2;

  t513 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t223 - t473);
  tv2rhosigma3 = t5 * t513 + t226;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 3] += tv2rhosigma3;

  tv2rhosigma4 = 0.e0;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 4] += tv2rhosigma4;

  t517 = t430 * t230;
  t521 = sigma[2] * t187;
  t523 = -0.12375888374825781309e1 * t183 - 0.75635858304270577032e-2 * t521;
  t528 = t73 * t200;
  t529 = t528 * t190;
  t533 = t230 * t190;
  t538 = 0.16e2 / 0.225e3 * t517 * t190 - t182 * t523 / 0.15e2 - 0.33526216126512169473e-1 * t183 * t94 - 0.22350810751008112982e-2 * t529 - 0.2e1 / 0.25e2 * t451 * t230 + 0.12e2 / 0.125e3 * t456 * t533 - 0.2e1 / 0.25e2 * t201 * t523;
  t539 = t28 * t538;
  t543 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t238 - t506 - 0.2e1 / 0.3e1 * t70 * t539);
  tv2rhosigma5 = t5 * t543 + t241;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 5] += tv2rhosigma5;

  tv2rholapl0 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 0] += tv2rholapl0;

  tv2rholapl1 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 1] += tv2rholapl1;

  tv2rholapl2 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 2] += tv2rholapl2;

  tv2rholapl3 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 3] += tv2rholapl3;

  t545 = t109 * t26;
  t549 = t113 * t44 * t53;
  t551 = 0.4621375276020952854e-3 * t242 * t549;
  t553 = t27 * t31 * t53;
  t556 = t242 * t27;
  t557 = t44 * t137;
  t558 = t557 * t127;
  t562 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t545 * t244 + t551 - 0.18485501104083811416e-2 * t242 * t553 - 0.18485501104083811416e-3 * t556 * t558);
  tv2rhotau0 = t5 * t562 + t247;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 0] += tv2rhotau0;

  t564 = t152 * t26;
  t568 = t113 * t86 * t94;
  t570 = 0.4621375276020952854e-3 * t248 * t568;
  t572 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t564 * t250 + t570);
  tv2rhotau1 = t5 * t572 + t253;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 1] += tv2rhotau1;

  t574 = t167 * t26;
  t578 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t574 * t244 + t551);
  tv2rhotau2 = t5 * t578 + t247;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 2] += tv2rhotau2;

  t580 = t177 * t26;
  t584 = t27 * t73 * t94;
  t587 = t248 * t27;
  t588 = t86 * t200;
  t589 = t588 * t190;
  t593 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t580 * t250 + t570 - 0.18485501104083811416e-2 * t248 * t584 - 0.18485501104083811416e-3 * t587 * t589);
  tv2rhotau3 = t5 * t593 + t253;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 3] += tv2rhotau3;

  t595 = t215 * t215;
  t600 = t485 * t215;
  t606 = 0.16e2 / 0.225e3 * t288 * t595 - 0.84039842560300641147e-4 * t119 * t37 - 0.44701621502016225964e-2 * t600 + 0.12e2 / 0.125e3 * t314 * t595 - 0.10084781107236076938e-3 * t138 * t37;
  t607 = t28 * t606;
  t610 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t607);
  tv2sigma20 = t5 * t610;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 0] += tv2sigma20;

  tv2sigma21 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 1] += tv2sigma21;

  tv2sigma22 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 2] += tv2sigma22;

  tv2sigma23 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 3] += tv2sigma23;

  tv2sigma24 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 4] += tv2sigma24;

  t611 = t230 * t230;
  t616 = t528 * t230;
  t622 = 0.16e2 / 0.225e3 * t430 * t611 - 0.84039842560300641147e-4 * t182 * t79 - 0.44701621502016225964e-2 * t616 + 0.12e2 / 0.125e3 * t456 * t611 - 0.10084781107236076938e-3 * t201 * t79;
  t623 = t28 * t622;
  t626 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t623);
  tv2sigma25 = t5 * t626;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 5] += tv2sigma25;

  tv2sigmalapl0 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 0] += tv2sigmalapl0;

  tv2sigmalapl1 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 1] += tv2sigmalapl1;

  tv2sigmalapl2 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 2] += tv2sigmalapl2;

  tv2sigmalapl3 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 3] += tv2sigmalapl3;

  tv2sigmalapl4 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 4] += tv2sigmalapl4;

  tv2sigmalapl5 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 5] += tv2sigmalapl5;

  t627 = t557 * t215;
  t630 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t556 * t627);
  tv2sigmatau0 = t5 * t630;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 0] += tv2sigmatau0;

  tv2sigmatau1 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 1] += tv2sigmatau1;

  tv2sigmatau2 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 2] += tv2sigmatau2;

  tv2sigmatau3 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 3] += tv2sigmatau3;

  tv2sigmatau4 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 4] += tv2sigmatau4;

  t631 = t588 * t230;
  t634 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t587 * t631);
  tv2sigmatau5 = t5 * t634;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 5] += tv2sigmatau5;

  tv2lapl20 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 0] += tv2lapl20;

  tv2lapl21 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 1] += tv2lapl21;

  tv2lapl22 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 2] += tv2lapl22;

  tv2lapltau0 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 0] += tv2lapltau0;

  tv2lapltau1 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 1] += tv2lapltau1;

  tv2lapltau2 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 2] += tv2lapltau2;

  tv2lapltau3 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 3] += tv2lapltau3;

  tv2tau20 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 0] += tv2tau20;

  tv2tau21 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 1] += tv2tau21;

  tv2tau22 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 2] += tv2tau22;

  t637 = 0.1e1 / t23;
  t638 = t257 * t106;
  t641 = t256 * t106;
  t644 = t102 * t102;
  t645 = 0.1e1 / t644;
  t646 = t15 * t645;
  t649 = my_piecewise5(t9, 0, t13, 0, 0.6e1 * t261 - 0.6e1 * t646);
  t653 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t637 * t638 + 0.9e1 / 0.4e1 * t641 * t265 + 0.3e1 / 0.2e1 * t22 * t649);
  t654 = t4 * t653;
  t657 = t270 * t115;
  t660 = t110 * t280;
  t662 = t110 * t283;
  t667 = 0.1e1 / t27 / t102;
  t668 = t26 * t667;
  t669 = t668 * t56;
  t671 = t25 * t669 / 0.4e1;
  t672 = t279 * t141;
  t673 = t25 * t672;
  t675 = t114 * t319;
  t676 = t25 * t675;
  t677 = t286 * t40;
  t679 = 0.1e1 / t41 / t677;
  t680 = t289 * t127;
  t683 = t288 * t127;
  t688 = 0.1e1 / t296 / rho[0];
  t691 = -0.24751776749651562618e2 * t213 - 0.21178040325195761568e0 * t34 * t688;
  t697 = -0.16763108063256084736e1 * t213 + 0.14744113928033183905e0 * tau[0] * t293;
  t700 = t306 * t137;
  t703 = t133 * t313;
  t709 = 0.1e1 / t52 / t677;
  t710 = t51 * t709;
  t713 = t127 * t300;
  t718 = -0.496e3 / 0.3375e4 * t679 * t680 + 0.16e2 / 0.75e2 * t683 * t300 - t119 * t691 / 0.15e2 + 0.2e1 / 0.5e1 * t697 * t53 - 0.6e1 / 0.25e2 * t700 * t127 + 0.36e2 / 0.125e3 * t703 * t289 - 0.6e1 / 0.25e2 * t309 * t300 - 0.132e3 / 0.625e3 * t710 * t680 + 0.36e2 / 0.125e3 * t314 * t713 - 0.2e1 / 0.25e2 * t138 * t691;
  t719 = t28 * t718;
  t723 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t654 * t57 - t657 - 0.2e1 * t270 * t142 + t660 / 0.2e1 - 0.2e1 * t662 - 0.2e1 * t110 * t320 - t671 + t673 / 0.2e1 - t676 - 0.2e1 / 0.3e1 * t25 * t719);
  t724 = 0.1e1 / t68;
  t725 = t326 * t149;
  t728 = t325 * t149;
  t731 = t62 * t645;
  t734 = my_piecewise5(t13, 0, t9, 0, -0.6e1 * t261 - 0.6e1 * t731);
  t738 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t724 * t725 + 0.9e1 / 0.4e1 * t728 * t332 + 0.3e1 / 0.2e1 * t67 * t734);
  t739 = t4 * t738;
  t742 = t337 * t156;
  t743 = t153 * t342;
  t745 = t668 * t97;
  t747 = t70 * t745 / 0.4e1;
  t749 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t739 * t98 - t742 + t743 / 0.2e1 - t747);
  tv3rho30 = 0.3e1 * t324 + 0.3e1 * t346 + t5 * (t723 + t749);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 0] += tv3rho30;

  t752 = 0.2e1 * t368;
  t753 = 0.2e1 * t390;
  t754 = t637 * t164;
  t757 = t256 * t353;
  t762 = 0.2e1 * t261;
  t763 = 0.6e1 * t646;
  t765 = my_piecewise5(t9, 0, t13, 0, t762 - t763);
  t769 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t754 * t257 + 0.3e1 / 0.2e1 * t757 * t106 + 0.3e1 / 0.4e1 * t349 * t265 + 0.3e1 / 0.2e1 * t22 * t765);
  t770 = t4 * t769;
  t774 = 0.2e1 / 0.3e1 * t358 * t115;
  t777 = t168 * t280;
  t780 = 0.2e1 / 0.3e1 * t168 * t283;
  t788 = -0.2e1 / 0.3e1 * t770 * t57 - t774 - 0.4e1 / 0.3e1 * t358 * t142 + t777 / 0.6e1 - t780 - 0.2e1 / 0.3e1 * t168 * t320 - t657 / 0.3e1 + t660 / 0.3e1 - 0.2e1 / 0.3e1 * t662 - t671 + t673 / 0.3e1 - t676 / 0.3e1;
  t789 = my_piecewise3(t2, 0, t788);
  t790 = t724 * t174;
  t793 = t325 * t373;
  t798 = 0.6e1 * t731;
  t800 = my_piecewise5(t13, 0, t9, 0, -t762 - t798);
  t804 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t790 * t326 + 0.3e1 / 0.2e1 * t793 * t149 + 0.3e1 / 0.4e1 * t369 * t332 + 0.3e1 / 0.2e1 * t67 * t800);
  t805 = t4 * t804;
  t809 = 0.2e1 / 0.3e1 * t378 * t156;
  t810 = t178 * t342;
  t817 = 0.2e1 / 0.3e1 * t153 * t386;
  t818 = t279 * t204;
  t819 = t70 * t818;
  t822 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t805 * t98 - t809 + t810 / 0.6e1 - t742 / 0.3e1 + t743 / 0.3e1 - t747 - 0.2e1 / 0.3e1 * t337 * t205 - t817 + t819 / 0.6e1);
  tv3rho31 = t324 + t346 + t752 + t753 + t5 * (t789 + t822);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 1] += tv3rho31;

  t825 = t637 * t395;
  t830 = t256 * t400;
  t834 = my_piecewise5(t9, 0, t13, 0, -t762 - t763);
  t838 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t825 * t106 + 0.3e1 / 0.2e1 * t349 * t353 + 0.3e1 / 0.4e1 * t830 * t106 + 0.3e1 / 0.2e1 * t22 * t834);
  t839 = t4 * t838;
  t842 = t405 * t115;
  t850 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t839 * t57 - t842 / 0.3e1 - 0.2e1 / 0.3e1 * t405 * t142 - t774 + t777 / 0.3e1 - t780 + t660 / 0.6e1 - t671 + t673 / 0.6e1);
  t851 = t724 * t411;
  t856 = t325 * t416;
  t860 = my_piecewise5(t13, 0, t9, 0, t762 - t798);
  t864 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t851 * t149 + 0.3e1 / 0.2e1 * t369 * t373 + 0.3e1 / 0.4e1 * t856 * t149 + 0.3e1 / 0.2e1 * t67 * t860);
  t865 = t4 * t864;
  t868 = t421 * t156;
  t873 = t178 * t386;
  t879 = t114 * t461;
  t880 = t70 * t879;
  t882 = -0.2e1 / 0.3e1 * t865 * t98 - t868 / 0.3e1 - t809 + t810 / 0.3e1 - 0.4e1 / 0.3e1 * t378 * t205 - 0.2e1 / 0.3e1 * t873 + t743 / 0.6e1 - t747 - t817 + t819 / 0.3e1 - 0.2e1 / 0.3e1 * t153 * t462 - t880 / 0.3e1;
  t883 = my_piecewise3(t61, 0, t882);
  tv3rho32 = t752 + t753 + t410 + t466 + t5 * (t850 + t883);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 2] += tv3rho32;

  t888 = t395 * t164;
  t895 = my_piecewise5(t9, 0, t13, 0, -0.6e1 * t261 - 0.6e1 * t646);
  t899 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t637 * t888 + 0.9e1 / 0.4e1 * t349 * t400 + 0.3e1 / 0.2e1 * t22 * t895);
  t900 = t4 * t899;
  t905 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t900 * t57 - t842 + t777 / 0.2e1 - t671);
  t906 = t411 * t174;
  t913 = my_piecewise5(t13, 0, t9, 0, 0.6e1 * t261 - 0.6e1 * t731);
  t917 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t724 * t906 + 0.9e1 / 0.4e1 * t369 * t416 + 0.3e1 / 0.2e1 * t67 * t913);
  t918 = t4 * t917;
  t928 = t428 * t82;
  t930 = 0.1e1 / t83 / t928;
  t931 = t431 * t190;
  t934 = t430 * t190;
  t939 = 0.1e1 / t438 / rho[1];
  t942 = -0.24751776749651562618e2 * t228 - 0.21178040325195761568e0 * t76 * t939;
  t948 = -0.16763108063256084736e1 * t228 + 0.14744113928033183905e0 * tau[1] * t435;
  t951 = t448 * t200;
  t954 = t196 * t455;
  t960 = 0.1e1 / t93 / t928;
  t961 = t92 * t960;
  t964 = t190 * t442;
  t969 = -0.496e3 / 0.3375e4 * t930 * t931 + 0.16e2 / 0.75e2 * t934 * t442 - t182 * t942 / 0.15e2 + 0.2e1 / 0.5e1 * t948 * t94 - 0.6e1 / 0.25e2 * t951 * t190 + 0.36e2 / 0.125e3 * t954 * t431 - 0.6e1 / 0.25e2 * t451 * t442 - 0.132e3 / 0.625e3 * t961 * t931 + 0.36e2 / 0.125e3 * t456 * t964 - 0.2e1 / 0.25e2 * t201 * t942;
  t970 = t28 * t969;
  t974 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t918 * t98 - t868 - 0.2e1 * t421 * t205 + t810 / 0.2e1 - 0.2e1 * t873 - 0.2e1 * t178 * t462 - t747 + t819 / 0.2e1 - t880 - 0.2e1 / 0.3e1 * t70 * t970);
  tv3rho33 = 0.3e1 * t410 + 0.3e1 * t466 + t5 * (t905 + t974);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 3] += tv3rho33;

  t980 = t110 * t471;
  t984 = t279 * t222;
  t986 = t25 * t984 / 0.6e1;
  t987 = t114 * t495;
  t988 = t25 * t987;
  t990 = t679 * t215;
  t993 = t288 * t480;
  t1001 = 0.49503553499303125236e1 * t293 + 0.52945100812989403922e-1 * sigma[0] * t297;
  t1006 = t120 * t137;
  t1007 = t1006 * t127;
  t1009 = t31 * t313;
  t1010 = t1009 * t289;
  t1012 = t485 * t300;
  t1020 = t215 * t289;
  t1023 = t480 * t127;
  t1026 = t215 * t300;
  t1031 = -0.496e3 / 0.3375e4 * t990 * t289 + 0.32e2 / 0.225e3 * t993 * t127 + 0.16e2 / 0.225e3 * t474 * t300 - t119 * t1001 / 0.15e2 + 0.13410486450604867789e0 * t293 * t53 + 0.13410486450604867789e-1 * t1007 + 0.26820972901209735578e-2 * t1010 - 0.22350810751008112982e-2 * t1012 - 0.2e1 / 0.25e2 * t700 * t215 + 0.24e2 / 0.125e3 * t703 * t490 - 0.4e1 / 0.25e2 * t309 * t480 - 0.132e3 / 0.625e3 * t710 * t1020 + 0.24e2 / 0.125e3 * t314 * t1023 + 0.12e2 / 0.125e3 * t314 * t1026 - 0.2e1 / 0.25e2 * t138 * t1001;
  t1032 = t28 * t1031;
  t1036 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t270 * t223 - 0.2e1 / 0.3e1 * t980 - 0.4e1 / 0.3e1 * t110 * t496 + t986 - 0.2e1 / 0.3e1 * t988 - 0.2e1 / 0.3e1 * t25 * t1032);
  tv3rho2sigma0 = t5 * t1036 + 0.2e1 * t500;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 0] += tv3rho2sigma0;

  tv3rho2sigma1 = 0.e0;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 1] += tv3rho2sigma1;

  t1041 = t153 * t504;
  t1043 = t279 * t237;
  t1045 = t70 * t1043 / 0.6e1;
  t1047 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t337 * t238 - 0.2e1 / 0.3e1 * t1041 + t1045);
  tv3rho2sigma2 = t5 * t1047 + 0.2e1 * t508;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 2] += tv3rho2sigma2;

  t1051 = t168 * t471;
  t1058 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t358 * t223 - t1051 / 0.3e1 - 0.2e1 / 0.3e1 * t168 * t496 - t980 / 0.3e1 + t986 - t988 / 0.3e1);
  tv3rho2sigma3 = t5 * t1058 + t500 + t513;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 3] += tv3rho2sigma3;

  tv3rho2sigma4 = 0.e0;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 4] += tv3rho2sigma4;

  t1062 = t178 * t504;
  t1067 = t114 * t538;
  t1068 = t70 * t1067;
  t1071 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t378 * t238 - t1062 / 0.3e1 - t1041 / 0.3e1 + t1045 - 0.2e1 / 0.3e1 * t153 * t539 - t1068 / 0.3e1);
  tv3rho2sigma5 = t5 * t1071 + t508 + t543;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 5] += tv3rho2sigma5;

  t1078 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t405 * t223 - 0.2e1 / 0.3e1 * t1051 + t986);
  tv3rho2sigma6 = t5 * t1078 + 0.2e1 * t513;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 6] += tv3rho2sigma6;

  tv3rho2sigma7 = 0.e0;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 7] += tv3rho2sigma7;

  t1087 = t930 * t230;
  t1090 = t430 * t523;
  t1098 = 0.49503553499303125236e1 * t435 + 0.52945100812989403922e-1 * sigma[2] * t439;
  t1103 = t183 * t200;
  t1104 = t1103 * t190;
  t1106 = t73 * t455;
  t1107 = t1106 * t431;
  t1109 = t528 * t442;
  t1117 = t230 * t431;
  t1120 = t523 * t190;
  t1123 = t230 * t442;
  t1128 = -0.496e3 / 0.3375e4 * t1087 * t431 + 0.32e2 / 0.225e3 * t1090 * t190 + 0.16e2 / 0.225e3 * t517 * t442 - t182 * t1098 / 0.15e2 + 0.13410486450604867789e0 * t435 * t94 + 0.13410486450604867789e-1 * t1104 + 0.26820972901209735578e-2 * t1107 - 0.22350810751008112982e-2 * t1109 - 0.2e1 / 0.25e2 * t951 * t230 + 0.24e2 / 0.125e3 * t954 * t533 - 0.4e1 / 0.25e2 * t451 * t523 - 0.132e3 / 0.625e3 * t961 * t1117 + 0.24e2 / 0.125e3 * t456 * t1120 + 0.12e2 / 0.125e3 * t456 * t1123 - 0.2e1 / 0.25e2 * t201 * t1098;
  t1129 = t28 * t1128;
  t1133 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t421 * t238 - 0.2e1 / 0.3e1 * t1062 - 0.4e1 / 0.3e1 * t178 * t539 + t1045 - 0.2e1 / 0.3e1 * t1068 - 0.2e1 / 0.3e1 * t70 * t1129);
  tv3rho2sigma8 = t1133 * t5 + 0.2e1 * t543;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 8] += tv3rho2sigma8;

  tv3rho2lapl0 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 0] += tv3rho2lapl0;

  tv3rho2lapl1 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 1] += tv3rho2lapl1;

  tv3rho2lapl2 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 2] += tv3rho2lapl2;

  tv3rho2lapl3 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 3] += tv3rho2lapl3;

  tv3rho2lapl4 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 4] += tv3rho2lapl4;

  tv3rho2lapl5 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 5] += tv3rho2lapl5;

  t1136 = t269 * t26;
  t1139 = t545 * t549;
  t1143 = t545 * t27;
  t1147 = t278 * t44 * t53;
  t1149 = 0.2310687638010476427e-3 * t242 * t1147;
  t1151 = t113 * t31 * t53;
  t1152 = t242 * t1151;
  t1154 = t242 * t113;
  t1155 = t1154 * t558;
  t1158 = t27 * t120 * t53;
  t1163 = t44 * t313;
  t1164 = t1163 * t289;
  t1167 = t557 * t300;
  t1170 = 0.9242750552041905708e-3 * t1136 * t244 + 0.9242750552041905708e-3 * t1139 - 0.36971002208167622832e-2 * t545 * t553 - 0.36971002208167622832e-3 * t1143 * t558 - t1149 - 0.18485501104083811416e-2 * t1152 - 0.18485501104083811416e-3 * t1155 + 0.55456503312251434248e-2 * t242 * t1158 + 0.73942004416335245664e-3 * t556 * t486 + 0.22182601324900573699e-3 * t556 * t1164 - 0.18485501104083811416e-3 * t556 * t1167;
  t1171 = my_piecewise3(t2, 0, t1170);
  tv3rho2tau0 = t1171 * t5 + 0.2e1 * t562;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 0] += tv3rho2tau0;

  t1174 = t336 * t26;
  t1177 = t564 * t568;
  t1180 = t278 * t86 * t94;
  t1182 = 0.2310687638010476427e-3 * t248 * t1180;
  t1184 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t1174 * t250 + 0.9242750552041905708e-3 * t1177 - t1182);
  tv3rho2tau1 = t1184 * t5 + 0.2e1 * t572;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 1] += tv3rho2tau1;

  t1186 = t357 * t26;
  t1189 = t574 * t549;
  t1193 = t574 * t27;
  t1200 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t1186 * t244 + 0.4621375276020952854e-3 * t1189 - 0.18485501104083811416e-2 * t574 * t553 - 0.18485501104083811416e-3 * t1193 * t558 + 0.4621375276020952854e-3 * t1139 - t1149 - 0.9242750552041905708e-3 * t1152 - 0.9242750552041905708e-4 * t1155);
  tv3rho2tau2 = t1200 * t5 + t562 + t578;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 2] += tv3rho2tau2;

  t1202 = t377 * t26;
  t1205 = t580 * t568;
  t1211 = t113 * t73 * t94;
  t1212 = t248 * t1211;
  t1214 = t564 * t27;
  t1217 = t248 * t113;
  t1218 = t1217 * t589;
  t1221 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t1202 * t250 + 0.4621375276020952854e-3 * t1205 + 0.4621375276020952854e-3 * t1177 - t1182 - 0.18485501104083811416e-2 * t564 * t584 - 0.9242750552041905708e-3 * t1212 - 0.18485501104083811416e-3 * t1214 * t589 - 0.9242750552041905708e-4 * t1218);
  tv3rho2tau3 = t1221 * t5 + t572 + t593;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 3] += tv3rho2tau3;

  t1224 = t404 * t26;
  t1229 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t1224 * t244 + 0.9242750552041905708e-3 * t1189 - t1149);
  tv3rho2tau4 = t1229 * t5 + 0.2e1 * t578;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 4] += tv3rho2tau4;

  t1232 = t420 * t26;
  t1238 = t580 * t27;
  t1244 = t27 * t183 * t94;
  t1249 = t86 * t455;
  t1250 = t1249 * t431;
  t1253 = t588 * t442;
  t1256 = 0.9242750552041905708e-3 * t1232 * t250 + 0.9242750552041905708e-3 * t1205 - 0.36971002208167622832e-2 * t580 * t584 - 0.36971002208167622832e-3 * t1238 * t589 - t1182 - 0.18485501104083811416e-2 * t1212 - 0.18485501104083811416e-3 * t1218 + 0.55456503312251434248e-2 * t248 * t1244 + 0.73942004416335245664e-3 * t587 * t529 + 0.22182601324900573699e-3 * t587 * t1250 - 0.18485501104083811416e-3 * t587 * t1253;
  t1257 = my_piecewise3(t61, 0, t1256);
  tv3rho2tau5 = t1257 * t5 + 0.2e1 * t593;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 5] += tv3rho2tau5;

  t1261 = t114 * t606;
  t1263 = t25 * t1261 / 0.3e1;
  t1264 = t679 * t595;
  t1269 = t288 * t37;
  t1274 = t1006 * t215;
  t1276 = t1009 * t490;
  t1278 = t485 * t480;
  t1282 = t595 * t127;
  t1285 = t215 * t480;
  t1290 = t37 * t127;
  t1295 = -0.496e3 / 0.3375e4 * t1264 * t127 + 0.32e2 / 0.225e3 * t474 * t480 + 0.89642498730987350557e-4 * t1269 * t127 + 0.50423905536180384688e-3 * t119 * t124 + 0.13410486450604867789e-1 * t1274 + 0.53641945802419471157e-2 * t1276 - 0.44701621502016225964e-2 * t1278 + 0.12e2 / 0.125e3 * t703 * t595 - 0.132e3 / 0.625e3 * t710 * t1282 + 0.24e2 / 0.125e3 * t314 * t1285 - 0.10084781107236076938e-3 * t309 * t37 + 0.12101737328683292326e-3 * t314 * t1290 + 0.60508686643416461628e-3 * t138 * t124;
  t1296 = t28 * t1295;
  t1300 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t607 - t1263 - 0.2e1 / 0.3e1 * t25 * t1296);
  tv3rhosigma20 = t1300 * t5 + t610;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 0] += tv3rhosigma20;

  tv3rhosigma21 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 1] += tv3rhosigma21;

  tv3rhosigma22 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 2] += tv3rhosigma22;

  tv3rhosigma23 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 3] += tv3rhosigma23;

  tv3rhosigma24 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 4] += tv3rhosigma24;

  t1304 = t114 * t622;
  t1306 = t70 * t1304 / 0.3e1;
  t1308 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t623 - t1306);
  tv3rhosigma25 = t1308 * t5 + t626;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 5] += tv3rhosigma25;

  t1313 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t607 - t1263);
  tv3rhosigma26 = t1313 * t5 + t610;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 6] += tv3rhosigma26;

  tv3rhosigma27 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 7] += tv3rhosigma27;

  tv3rhosigma28 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 8] += tv3rhosigma28;

  tv3rhosigma29 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 9] += tv3rhosigma29;

  tv3rhosigma210 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 10] += tv3rhosigma210;

  t1317 = t930 * t611;
  t1322 = t430 * t79;
  t1327 = t1103 * t230;
  t1329 = t1106 * t533;
  t1331 = t528 * t523;
  t1335 = t611 * t190;
  t1338 = t230 * t523;
  t1343 = t79 * t190;
  t1348 = -0.496e3 / 0.3375e4 * t1317 * t190 + 0.32e2 / 0.225e3 * t517 * t523 + 0.89642498730987350557e-4 * t1322 * t190 + 0.50423905536180384688e-3 * t182 * t187 + 0.13410486450604867789e-1 * t1327 + 0.53641945802419471157e-2 * t1329 - 0.44701621502016225964e-2 * t1331 + 0.12e2 / 0.125e3 * t954 * t611 - 0.132e3 / 0.625e3 * t961 * t1335 + 0.24e2 / 0.125e3 * t456 * t1338 - 0.10084781107236076938e-3 * t451 * t79 + 0.12101737328683292326e-3 * t456 * t1343 + 0.60508686643416461628e-3 * t201 * t187;
  t1349 = t28 * t1348;
  t1353 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t623 - t1306 - 0.2e1 / 0.3e1 * t70 * t1349);
  tv3rhosigma211 = t1353 * t5 + t626;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 11] += tv3rhosigma211;

  tv3rhosigmalapl0 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 0] += tv3rhosigmalapl0;

  tv3rhosigmalapl1 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 1] += tv3rhosigmalapl1;

  tv3rhosigmalapl2 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 2] += tv3rhosigmalapl2;

  tv3rhosigmalapl3 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 3] += tv3rhosigmalapl3;

  tv3rhosigmalapl4 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 4] += tv3rhosigmalapl4;

  tv3rhosigmalapl5 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 5] += tv3rhosigmalapl5;

  tv3rhosigmalapl6 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 6] += tv3rhosigmalapl6;

  tv3rhosigmalapl7 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 7] += tv3rhosigmalapl7;

  tv3rhosigmalapl8 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 8] += tv3rhosigmalapl8;

  tv3rhosigmalapl9 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 9] += tv3rhosigmalapl9;

  tv3rhosigmalapl10 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 10] += tv3rhosigmalapl10;

  tv3rhosigmalapl11 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 11] += tv3rhosigmalapl11;

  t1358 = 0.9242750552041905708e-4 * t1154 * t627;
  t1361 = t1163 * t490;
  t1364 = t557 * t480;
  t1368 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t1143 * t627 - t1358 + 0.36971002208167622832e-3 * t556 * t600 + 0.22182601324900573699e-3 * t556 * t1361 - 0.18485501104083811416e-3 * t556 * t1364);
  tv3rhosigmatau0 = t1368 * t5 + t630;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 0] += tv3rhosigmatau0;

  tv3rhosigmatau1 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 1] += tv3rhosigmatau1;

  tv3rhosigmatau2 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 2] += tv3rhosigmatau2;

  tv3rhosigmatau3 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 3] += tv3rhosigmatau3;

  tv3rhosigmatau4 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 4] += tv3rhosigmatau4;

  t1373 = 0.9242750552041905708e-4 * t1217 * t631;
  t1375 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t1214 * t631 - t1373);
  tv3rhosigmatau5 = t1375 * t5 + t634;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 5] += tv3rhosigmatau5;

  t1380 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t1193 * t627 - t1358);
  tv3rhosigmatau6 = t1380 * t5 + t630;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 6] += tv3rhosigmatau6;

  tv3rhosigmatau7 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 7] += tv3rhosigmatau7;

  tv3rhosigmatau8 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 8] += tv3rhosigmatau8;

  tv3rhosigmatau9 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 9] += tv3rhosigmatau9;

  tv3rhosigmatau10 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 10] += tv3rhosigmatau10;

  t1386 = t1249 * t533;
  t1389 = t588 * t523;
  t1393 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t1238 * t631 - t1373 + 0.36971002208167622832e-3 * t587 * t616 + 0.22182601324900573699e-3 * t587 * t1386 - 0.18485501104083811416e-3 * t587 * t1389);
  tv3rhosigmatau11 = t1393 * t5 + t634;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 11] += tv3rhosigmatau11;

  tv3rholapl20 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 0] += tv3rholapl20;

  tv3rholapl21 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 1] += tv3rholapl21;

  tv3rholapl22 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 2] += tv3rholapl22;

  tv3rholapl23 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 3] += tv3rholapl23;

  tv3rholapl24 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 4] += tv3rholapl24;

  tv3rholapl25 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 5] += tv3rholapl25;

  tv3rholapltau0 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 0] += tv3rholapltau0;

  tv3rholapltau1 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 1] += tv3rholapltau1;

  tv3rholapltau2 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 2] += tv3rholapltau2;

  tv3rholapltau3 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 3] += tv3rholapltau3;

  tv3rholapltau4 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 4] += tv3rholapltau4;

  tv3rholapltau5 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 5] += tv3rholapltau5;

  tv3rholapltau6 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 6] += tv3rholapltau6;

  tv3rholapltau7 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 7] += tv3rholapltau7;

  tv3rhotau20 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 0] += tv3rhotau20;

  tv3rhotau21 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 1] += tv3rhotau21;

  tv3rhotau22 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 2] += tv3rhotau22;

  tv3rhotau23 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 3] += tv3rhotau23;

  tv3rhotau24 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 4] += tv3rhotau24;

  tv3rhotau25 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 5] += tv3rhotau25;

  t1395 = t595 * t215;
  t1400 = t1009 * t595;
  t1406 = t215 * t37;
  t1409 = -0.496e3 / 0.3375e4 * t679 * t1395 + 0.26892749619296205167e-3 * t474 * t37 + 0.80462918703629206735e-2 * t1400 - 0.84526137747440853736e-5 * t688 * t137 - 0.132e3 / 0.625e3 * t710 * t1395 + 0.36305211986049876976e-3 * t314 * t1406;
  t1410 = t28 * t1409;
  t1413 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t1410);
  tv3sigma30 = t5 * t1413;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 0] += tv3sigma30;

  tv3sigma31 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 1] += tv3sigma31;

  tv3sigma32 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 2] += tv3sigma32;

  tv3sigma33 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 3] += tv3sigma33;

  tv3sigma34 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 4] += tv3sigma34;

  tv3sigma35 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 5] += tv3sigma35;

  tv3sigma36 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 6] += tv3sigma36;

  tv3sigma37 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 7] += tv3sigma37;

  tv3sigma38 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 8] += tv3sigma38;

  t1414 = t611 * t230;
  t1419 = t1106 * t611;
  t1425 = t230 * t79;
  t1428 = -0.496e3 / 0.3375e4 * t930 * t1414 + 0.26892749619296205167e-3 * t517 * t79 + 0.80462918703629206735e-2 * t1419 - 0.84526137747440853736e-5 * t939 * t200 - 0.132e3 / 0.625e3 * t961 * t1414 + 0.36305211986049876976e-3 * t456 * t1425;
  t1429 = t28 * t1428;
  t1432 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t1429);
  tv3sigma39 = t5 * t1432;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 9] += tv3sigma39;

  tv3sigma2lapl0 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 0] += tv3sigma2lapl0;

  tv3sigma2lapl1 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 1] += tv3sigma2lapl1;

  tv3sigma2lapl2 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 2] += tv3sigma2lapl2;

  tv3sigma2lapl3 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 3] += tv3sigma2lapl3;

  tv3sigma2lapl4 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 4] += tv3sigma2lapl4;

  tv3sigma2lapl5 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 5] += tv3sigma2lapl5;

  tv3sigma2lapl6 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 6] += tv3sigma2lapl6;

  tv3sigma2lapl7 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 7] += tv3sigma2lapl7;

  tv3sigma2lapl8 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 8] += tv3sigma2lapl8;

  tv3sigma2lapl9 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 9] += tv3sigma2lapl9;

  tv3sigma2lapl10 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 10] += tv3sigma2lapl10;

  tv3sigma2lapl11 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 11] += tv3sigma2lapl11;

  t1433 = t1163 * t595;
  t1437 = t27 * t297 * t137;
  t1441 = my_piecewise3(t2, 0, 0.22182601324900573699e-3 * t556 * t1433 - 0.233027790365320078e-6 * t242 * t1437);
  tv3sigma2tau0 = t5 * t1441;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 0] += tv3sigma2tau0;

  tv3sigma2tau1 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 1] += tv3sigma2tau1;

  tv3sigma2tau2 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 2] += tv3sigma2tau2;

  tv3sigma2tau3 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 3] += tv3sigma2tau3;

  tv3sigma2tau4 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 4] += tv3sigma2tau4;

  tv3sigma2tau5 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 5] += tv3sigma2tau5;

  tv3sigma2tau6 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 6] += tv3sigma2tau6;

  tv3sigma2tau7 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 7] += tv3sigma2tau7;

  tv3sigma2tau8 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 8] += tv3sigma2tau8;

  tv3sigma2tau9 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 9] += tv3sigma2tau9;

  tv3sigma2tau10 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 10] += tv3sigma2tau10;

  t1442 = t1249 * t611;
  t1446 = t27 * t439 * t200;
  t1450 = my_piecewise3(t61, 0, 0.22182601324900573699e-3 * t587 * t1442 - 0.233027790365320078e-6 * t248 * t1446);
  tv3sigma2tau11 = t5 * t1450;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 11] += tv3sigma2tau11;

  tv3sigmalapl20 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 0] += tv3sigmalapl20;

  tv3sigmalapl21 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 1] += tv3sigmalapl21;

  tv3sigmalapl22 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 2] += tv3sigmalapl22;

  tv3sigmalapl23 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 3] += tv3sigmalapl23;

  tv3sigmalapl24 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 4] += tv3sigmalapl24;

  tv3sigmalapl25 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 5] += tv3sigmalapl25;

  tv3sigmalapl26 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 6] += tv3sigmalapl26;

  tv3sigmalapl27 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 7] += tv3sigmalapl27;

  tv3sigmalapl28 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 8] += tv3sigmalapl28;

  tv3sigmalapltau0 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 0] += tv3sigmalapltau0;

  tv3sigmalapltau1 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 1] += tv3sigmalapltau1;

  tv3sigmalapltau2 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 2] += tv3sigmalapltau2;

  tv3sigmalapltau3 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 3] += tv3sigmalapltau3;

  tv3sigmalapltau4 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 4] += tv3sigmalapltau4;

  tv3sigmalapltau5 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 5] += tv3sigmalapltau5;

  tv3sigmalapltau6 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 6] += tv3sigmalapltau6;

  tv3sigmalapltau7 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 7] += tv3sigmalapltau7;

  tv3sigmalapltau8 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 8] += tv3sigmalapltau8;

  tv3sigmalapltau9 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 9] += tv3sigmalapltau9;

  tv3sigmalapltau10 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 10] += tv3sigmalapltau10;

  tv3sigmalapltau11 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 11] += tv3sigmalapltau11;

  tv3sigmatau20 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 0] += tv3sigmatau20;

  tv3sigmatau21 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 1] += tv3sigmatau21;

  tv3sigmatau22 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 2] += tv3sigmatau22;

  tv3sigmatau23 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 3] += tv3sigmatau23;

  tv3sigmatau24 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 4] += tv3sigmatau24;

  tv3sigmatau25 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 5] += tv3sigmatau25;

  tv3sigmatau26 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 6] += tv3sigmatau26;

  tv3sigmatau27 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 7] += tv3sigmatau27;

  tv3sigmatau28 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 8] += tv3sigmatau28;

  tv3lapl30 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 0] += tv3lapl30;

  tv3lapl31 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 1] += tv3lapl31;

  tv3lapl32 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 2] += tv3lapl32;

  tv3lapl33 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 3] += tv3lapl33;

  tv3lapl2tau0 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 0] += tv3lapl2tau0;

  tv3lapl2tau1 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 1] += tv3lapl2tau1;

  tv3lapl2tau2 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 2] += tv3lapl2tau2;

  tv3lapl2tau3 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 3] += tv3lapl2tau3;

  tv3lapl2tau4 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 4] += tv3lapl2tau4;

  tv3lapl2tau5 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 5] += tv3lapl2tau5;

  tv3lapltau20 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 0] += tv3lapltau20;

  tv3lapltau21 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 1] += tv3lapltau21;

  tv3lapltau22 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 2] += tv3lapltau22;

  tv3lapltau23 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 3] += tv3lapltau23;

  tv3lapltau24 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 4] += tv3lapltau24;

  tv3lapltau25 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 5] += tv3lapltau25;

  tv3tau30 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 0] += tv3tau30;

  tv3tau31 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 1] += tv3tau31;

  tv3tau32 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 2] += tv3tau32;

  tv3tau33 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 3] += tv3tau33;

}

#endif


#ifndef XC_DONT_COMPILE_LXC
GPU_DEVICE_FUNCTION static inline void
func_lxc_pol(const xc_func_type *p, size_t ip, const double *rho, const double *sigma, const double *lapl, const double *tau, xc_mgga_out_params *out)
{
  double t2, t3, t4, t5, t6, t9, t10, t13;
  double t14, t15, t17, t18, t19, t20, t21, t22;
  double t23, t24, t25, t26, t27, t28, t29, t30;
  double t31, t32, t34, t35, t37, t40, t41, t44;
  double t48, t51, t52, t53, t56, t57, t60, t61;
  double t62, t64, t65, t66, t67, t68, t69, t70;
  double t71, t72, t73, t74, t76, t77, t79, t82;
  double t83, t86, t92, t93, t94, t97, t98, t101;
  double tzk0;

  double t102, t103, t104, t106, t109, t110, t113, t114;
  double t115, t117, t119, t120, t121, t124, t127, t133;
  double t137, t138, t141, t142, t146, t147, t149, t152;
  double t153, t156, t158, t160, tvrho0, t164, t167, t168;
  double t172, t174, t177, t178, t182, t183, t184, t187;
  double t190, t196, t200, t201, t204, t205, t209, tvrho1;
  double t213, t215, t222, t223, t226, tvsigma0, tvsigma1, t228;
  double t230, t237, t238, t241, tvsigma2, tvlapl0, tvlapl1, t242;
  double t244, t247, tvtau0, t248, t250, t253, tvtau1;

  double t256, t257, t260, t261, t262, t265, t269, t270;
  double t273, t278, t279, t280, t282, t283, t284, t286;
  double t288, t289, t293, t294, t296, t297, t300, t306;
  double t309, t313, t314, t319, t320, t324, t325, t326;
  double t329, t332, t336, t337, t340, t342, t344, t346;
  double tv2rho20, t349, t353, t357, t358, t361, t368, t369;
  double t373, t377, t378, t381, t386, t387, t390, tv2rho21;
  double t395, t400, t404, t405, t410, t411, t416, t420;
  double t421, t428, t430, t431, t435, t436, t438, t439;
  double t442, t448, t451, t455, t456, t461, t462, t466;
  double tv2rho22, t471, t473, t474, t478, t480, t485, t486;
  double t490, t495, t496, t500, tv2rhosigma0, tv2rhosigma1, t504, t506;
  double t508, tv2rhosigma2, t513, tv2rhosigma3, tv2rhosigma4, t517, t521, t523;
  double t528, t529, t533, t538, t539, t543, tv2rhosigma5, tv2rholapl0;
  double tv2rholapl1, tv2rholapl2, tv2rholapl3, t545, t549, t551, t553, t556;
  double t557, t558, t562, tv2rhotau0, t564, t568, t570, t572;
  double tv2rhotau1, t574, t578, tv2rhotau2, t580, t584, t587, t588;
  double t589, t593, tv2rhotau3, t595, t600, t606, t607, t610;
  double tv2sigma20, tv2sigma21, tv2sigma22, tv2sigma23, tv2sigma24, t611, t616, t622;
  double t623, t626, tv2sigma25, tv2sigmalapl0, tv2sigmalapl1, tv2sigmalapl2, tv2sigmalapl3, tv2sigmalapl4;
  double tv2sigmalapl5, t627, t630, tv2sigmatau0, tv2sigmatau1, tv2sigmatau2, tv2sigmatau3, tv2sigmatau4;
  double t631, t634, tv2sigmatau5, tv2lapl20, tv2lapl21, tv2lapl22, tv2lapltau0, tv2lapltau1;
  double tv2lapltau2, tv2lapltau3, tv2tau20, tv2tau21, tv2tau22;

  double t637, t638, t641, t644, t645, t646, t649, t653;
  double t654, t657, t660, t662, t667, t668, t669, t671;
  double t672, t673, t675, t676, t677, t679, t680, t683;
  double t688, t691, t697, t700, t703, t709, t710, t713;
  double t718, t719, t723, t724, t725, t728, t731, t734;
  double t738, t739, t742, t743, t745, t747, t749, tv3rho30;
  double t752, t753, t754, t757, t762, t763, t765, t769;
  double t770, t774, t777, t780, t788, t789, t790, t793;
  double t798, t800, t804, t805, t809, t810, t817, t818;
  double t819, t822, tv3rho31, t825, t830, t834, t838, t839;
  double t842, t850, t851, t856, t860, t864, t865, t868;
  double t873, t879, t880, t882, t883, tv3rho32, t888, t895;
  double t899, t900, t905, t906, t913, t917, t918, t928;
  double t930, t931, t934, t939, t942, t948, t951, t954;
  double t960, t961, t964, t969, t970, t974, tv3rho33, t980;
  double t984, t986, t987, t988, t990, t993, t1001, t1006;
  double t1007, t1009, t1010, t1012, t1020, t1023, t1026, t1031;
  double t1032, t1036, tv3rho2sigma0, tv3rho2sigma1, t1041, t1043, t1045, t1047;
  double tv3rho2sigma2, t1051, t1058, tv3rho2sigma3, tv3rho2sigma4, t1062, t1067, t1068;
  double t1071, tv3rho2sigma5, t1078, tv3rho2sigma6, tv3rho2sigma7, t1087, t1090, t1098;
  double t1103, t1104, t1106, t1107, t1109, t1117, t1120, t1123;
  double t1128, t1129, t1133, tv3rho2sigma8, tv3rho2lapl0, tv3rho2lapl1, tv3rho2lapl2, tv3rho2lapl3;
  double tv3rho2lapl4, tv3rho2lapl5, t1136, t1139, t1143, t1147, t1149, t1151;
  double t1152, t1154, t1155, t1158, t1163, t1164, t1167, t1170;
  double t1171, tv3rho2tau0, t1174, t1177, t1180, t1182, t1184, tv3rho2tau1;
  double t1186, t1189, t1193, t1200, tv3rho2tau2, t1202, t1205, t1211;
  double t1212, t1214, t1217, t1218, t1221, tv3rho2tau3, t1224, t1229;
  double tv3rho2tau4, t1232, t1238, t1244, t1249, t1250, t1253, t1256;
  double t1257, tv3rho2tau5, t1261, t1263, t1264, t1269, t1274, t1276;
  double t1278, t1282, t1285, t1290, t1295, t1296, t1300, tv3rhosigma20;
  double tv3rhosigma21, tv3rhosigma22, tv3rhosigma23, tv3rhosigma24, t1304, t1306, t1308, tv3rhosigma25;
  double t1313, tv3rhosigma26, tv3rhosigma27, tv3rhosigma28, tv3rhosigma29, tv3rhosigma210, t1317, t1322;
  double t1327, t1329, t1331, t1335, t1338, t1343, t1348, t1349;
  double t1353, tv3rhosigma211, tv3rhosigmalapl0, tv3rhosigmalapl1, tv3rhosigmalapl2, tv3rhosigmalapl3, tv3rhosigmalapl4, tv3rhosigmalapl5;
  double tv3rhosigmalapl6, tv3rhosigmalapl7, tv3rhosigmalapl8, tv3rhosigmalapl9, tv3rhosigmalapl10, tv3rhosigmalapl11, t1358, t1361;
  double t1364, t1368, tv3rhosigmatau0, tv3rhosigmatau1, tv3rhosigmatau2, tv3rhosigmatau3, tv3rhosigmatau4, t1373;
  double t1375, tv3rhosigmatau5, t1380, tv3rhosigmatau6, tv3rhosigmatau7, tv3rhosigmatau8, tv3rhosigmatau9, tv3rhosigmatau10;
  double t1386, t1389, t1393, tv3rhosigmatau11, tv3rholapl20, tv3rholapl21, tv3rholapl22, tv3rholapl23;
  double tv3rholapl24, tv3rholapl25, tv3rholapltau0, tv3rholapltau1, tv3rholapltau2, tv3rholapltau3, tv3rholapltau4, tv3rholapltau5;
  double tv3rholapltau6, tv3rholapltau7, tv3rhotau20, tv3rhotau21, tv3rhotau22, tv3rhotau23, tv3rhotau24, tv3rhotau25;
  double t1395, t1400, t1406, t1409, t1410, t1413, tv3sigma30, tv3sigma31;
  double tv3sigma32, tv3sigma33, tv3sigma34, tv3sigma35, tv3sigma36, tv3sigma37, tv3sigma38, t1414;
  double t1419, t1425, t1428, t1429, t1432, tv3sigma39, tv3sigma2lapl0, tv3sigma2lapl1;
  double tv3sigma2lapl2, tv3sigma2lapl3, tv3sigma2lapl4, tv3sigma2lapl5, tv3sigma2lapl6, tv3sigma2lapl7, tv3sigma2lapl8, tv3sigma2lapl9;
  double tv3sigma2lapl10, tv3sigma2lapl11, t1433, t1437, t1441, tv3sigma2tau0, tv3sigma2tau1, tv3sigma2tau2;
  double tv3sigma2tau3, tv3sigma2tau4, tv3sigma2tau5, tv3sigma2tau6, tv3sigma2tau7, tv3sigma2tau8, tv3sigma2tau9, tv3sigma2tau10;
  double t1442, t1446, t1450, tv3sigma2tau11, tv3sigmalapl20, tv3sigmalapl21, tv3sigmalapl22, tv3sigmalapl23;
  double tv3sigmalapl24, tv3sigmalapl25, tv3sigmalapl26, tv3sigmalapl27, tv3sigmalapl28, tv3sigmalapltau0, tv3sigmalapltau1, tv3sigmalapltau2;
  double tv3sigmalapltau3, tv3sigmalapltau4, tv3sigmalapltau5, tv3sigmalapltau6, tv3sigmalapltau7, tv3sigmalapltau8, tv3sigmalapltau9, tv3sigmalapltau10;
  double tv3sigmalapltau11, tv3sigmatau20, tv3sigmatau21, tv3sigmatau22, tv3sigmatau23, tv3sigmatau24, tv3sigmatau25, tv3sigmatau26;
  double tv3sigmatau27, tv3sigmatau28, tv3lapl30, tv3lapl31, tv3lapl32, tv3lapl33, tv3lapl2tau0, tv3lapl2tau1;
  double tv3lapl2tau2, tv3lapl2tau3, tv3lapl2tau4, tv3lapl2tau5, tv3lapltau20, tv3lapltau21, tv3lapltau22, tv3lapltau23;
  double tv3lapltau24, tv3lapltau25, tv3tau30, tv3tau31, tv3tau32, tv3tau33;

  double t1453, t1455, t1456, t1459, t1462, t1465, t1467, t1472;
  double t1474, t1476, t1480, t1483, t1494, t1496, t1497, t1503;
  double t1508, t1515, t1518, t1525, t1536, t1540, t1542, t1543;
  double t1549, t1555, t1556, t1559, t1563, t1569, t1571, t1572;
  double t1573, t1575, t1576, t1582, t1587, t1590, t1594, t1598;
  double t1600, t1601, t1604, t1606, tv4rho40, t1611, t1612, t1613;
  double t1614, t1621, t1622, t1623, t1642, t1643, t1645, t1649;
  double t1655, t1660, t1661, t1678, t1680, t1684, t1688, t1689;
  double t1690, t1691, t1698, t1699, t1700, t1702, t1704, t1705;
  double tv4rho41, t1712, t1714, t1729, t1742, t1746, t1752, t1762;
  double t1763, t1772, t1785, t1789, t1793, t1795, t1802, t1804;
  double t1813, t1816, t1818, t1819, tv4rho42, t1840, t1844, t1848;
  double t1856, t1857, t1874, t1878, t1882, t1887, t1892, t1899;
  double t1901, t1902, tv4rho43, t1907, t1912, t1919, t1923, t1929;
  double t1938, t1941, t1952, t1954, t1955, t1961, t1966, t1973;
  double t1976, t1983, t1994, t1998, t2003, t2010, t2014, t2023;
  double t2024, tv4rho44, t2030, t2033, t2035, t2041, t2043, t2046;
  double t2083, t2088, t2104, t2110, t2113, t2120, t2126, tv4rho3sigma0;
  double tv4rho3sigma1, t2131, t2132, t2136, t2138, tv4rho3sigma2, t2140, t2144;
  double t2147, t2150, t2158, t2159, tv4rho3sigma3, tv4rho3sigma4, t2161, t2165;
  double t2166, t2173, t2175, t2178, tv4rho3sigma5, t2182, t2190, tv4rho3sigma6;
  double tv4rho3sigma7, t2194, t2199, t2206, t2208, t2209, tv4rho3sigma8, t2216;
  double tv4rho3sigma9, tv4rho3sigma10, t2261, t2264, t2265, t2268, t2284, t2301;
  double t2307, tv4rho3sigma11, tv4rho3lapl0, tv4rho3lapl1, tv4rho3lapl2, tv4rho3lapl3, tv4rho3lapl4, tv4rho3lapl5;
  double tv4rho3lapl6, tv4rho3lapl7, t2310, t2312, t2319, t2322, t2326, t2332;
  double t2339, t2340, t2344, t2347, t2348, t2350, t2352, t2361;
  double t2364, t2368, t2377, t2379, tv4rho3tau0, t2385, t2387, t2392;
  double t2394, tv4rho3tau1, t2396, t2400, t2403, t2406, t2409, t2410;
  double t2412, t2420, t2433, t2435, tv4rho3tau2, t2437, t2442, t2443;
  double t2450, t2453, t2455, t2458, t2460, t2461, t2462, t2464;
  double t2465, tv4rho3tau3, t2470, t2474, t2481, t2482, tv4rho3tau4, t2487;
  double t2492, t2494, t2497, t2498, t2501, t2508, t2512, t2516;
  double t2520, t2522, t2524, tv4rho3tau5, t2533, tv4rho3tau6, t2552, t2558;
  double t2559, t2583, t2585, tv4rho3tau7, t2590, t2596, t2598, t2637;
  double t2653, t2674, t2680, tv4rho2sigma20, tv4rho2sigma21, tv4rho2sigma22, tv4rho2sigma23, tv4rho2sigma24;
  double t2685, t2689, t2691, tv4rho2sigma25, t2695, t2702, tv4rho2sigma26, tv4rho2sigma27;
  double tv4rho2sigma28, tv4rho2sigma29, tv4rho2sigma210, t2706, t2712, t2715, tv4rho2sigma211, t2722;
  double tv4rho2sigma212, tv4rho2sigma213, tv4rho2sigma214, tv4rho2sigma215, tv4rho2sigma216, t2767, t2778, t2805;
  double t2811, tv4rho2sigma217, tv4rho2sigmalapl0, tv4rho2sigmalapl1, tv4rho2sigmalapl2, tv4rho2sigmalapl3, tv4rho2sigmalapl4, tv4rho2sigmalapl5;
  double tv4rho2sigmalapl6, tv4rho2sigmalapl7, tv4rho2sigmalapl8, tv4rho2sigmalapl9, tv4rho2sigmalapl10, tv4rho2sigmalapl11, tv4rho2sigmalapl12, tv4rho2sigmalapl13;
  double tv4rho2sigmalapl14, tv4rho2sigmalapl15, tv4rho2sigmalapl16, tv4rho2sigmalapl17, t2818, t2825, t2832, t2833;
  double t2835, t2850, t2851, tv4rho2sigmatau0, tv4rho2sigmatau1, tv4rho2sigmatau2, tv4rho2sigmatau3, tv4rho2sigmatau4;
  double t2856, t2859, t2861, tv4rho2sigmatau5, t2865, t2878, tv4rho2sigmatau6, tv4rho2sigmatau7;
  double tv4rho2sigmatau8, tv4rho2sigmatau9, tv4rho2sigmatau10, t2882, t2887, t2891, t2895, t2898;
  double tv4rho2sigmatau11, t2905, tv4rho2sigmatau12, tv4rho2sigmatau13, tv4rho2sigmatau14, tv4rho2sigmatau15, tv4rho2sigmatau16, t2938;
  double t2939, tv4rho2sigmatau17, tv4rho2lapl20, tv4rho2lapl21, tv4rho2lapl22, tv4rho2lapl23, tv4rho2lapl24, tv4rho2lapl25;
  double tv4rho2lapl26, tv4rho2lapl27, tv4rho2lapl28, tv4rho2lapltau0, tv4rho2lapltau1, tv4rho2lapltau2, tv4rho2lapltau3, tv4rho2lapltau4;
  double tv4rho2lapltau5, tv4rho2lapltau6, tv4rho2lapltau7, tv4rho2lapltau8, tv4rho2lapltau9, tv4rho2lapltau10, tv4rho2lapltau11, tv4rho2tau20;
  double tv4rho2tau21, tv4rho2tau22, tv4rho2tau23, tv4rho2tau24, tv4rho2tau25, tv4rho2tau26, tv4rho2tau27, tv4rho2tau28;
  double t2945, t2965, t2987, t2992, tv4rhosigma30, tv4rhosigma31, tv4rhosigma32, tv4rhosigma33;
  double tv4rhosigma34, tv4rhosigma35, tv4rhosigma36, tv4rhosigma37, tv4rhosigma38, t2998, t3000, tv4rhosigma39;
  double t3005, tv4rhosigma310, tv4rhosigma311, tv4rhosigma312, tv4rhosigma313, tv4rhosigma314, tv4rhosigma315, tv4rhosigma316;
  double tv4rhosigma317, tv4rhosigma318, t3028, t3050, t3055, tv4rhosigma319, tv4rhosigma2lapl0, tv4rhosigma2lapl1;
  double tv4rhosigma2lapl2, tv4rhosigma2lapl3, tv4rhosigma2lapl4, tv4rhosigma2lapl5, tv4rhosigma2lapl6, tv4rhosigma2lapl7, tv4rhosigma2lapl8, tv4rhosigma2lapl9;
  double tv4rhosigma2lapl10, tv4rhosigma2lapl11, tv4rhosigma2lapl12, tv4rhosigma2lapl13, tv4rhosigma2lapl14, tv4rhosigma2lapl15, tv4rhosigma2lapl16, tv4rhosigma2lapl17;
  double tv4rhosigma2lapl18, tv4rhosigma2lapl19, tv4rhosigma2lapl20, tv4rhosigma2lapl21, tv4rhosigma2lapl22, tv4rhosigma2lapl23, t3060, t3074;
  double t3079, t3084, tv4rhosigma2tau0, tv4rhosigma2tau1, tv4rhosigma2tau2, tv4rhosigma2tau3, tv4rhosigma2tau4, tv4rhosigma2tau5;
  double tv4rhosigma2tau6, tv4rhosigma2tau7, tv4rhosigma2tau8, tv4rhosigma2tau9, tv4rhosigma2tau10, t3089, t3095, t3097;
  double tv4rhosigma2tau11, t3104, tv4rhosigma2tau12, tv4rhosigma2tau13, tv4rhosigma2tau14, tv4rhosigma2tau15, tv4rhosigma2tau16, tv4rhosigma2tau17;
  double tv4rhosigma2tau18, tv4rhosigma2tau19, tv4rhosigma2tau20, tv4rhosigma2tau21, tv4rhosigma2tau22, t3122, t3127, tv4rhosigma2tau23;
  double tv4rhosigmalapl20, tv4rhosigmalapl21, tv4rhosigmalapl22, tv4rhosigmalapl23, tv4rhosigmalapl24, tv4rhosigmalapl25, tv4rhosigmalapl26, tv4rhosigmalapl27;
  double tv4rhosigmalapl28, tv4rhosigmalapl29, tv4rhosigmalapl210, tv4rhosigmalapl211, tv4rhosigmalapl212, tv4rhosigmalapl213, tv4rhosigmalapl214, tv4rhosigmalapl215;
  double tv4rhosigmalapl216, tv4rhosigmalapl217, tv4rhosigmalapltau0, tv4rhosigmalapltau1, tv4rhosigmalapltau2, tv4rhosigmalapltau3, tv4rhosigmalapltau4, tv4rhosigmalapltau5;
  double tv4rhosigmalapltau6, tv4rhosigmalapltau7, tv4rhosigmalapltau8, tv4rhosigmalapltau9, tv4rhosigmalapltau10, tv4rhosigmalapltau11, tv4rhosigmalapltau12, tv4rhosigmalapltau13;
  double tv4rhosigmalapltau14, tv4rhosigmalapltau15, tv4rhosigmalapltau16, tv4rhosigmalapltau17, tv4rhosigmalapltau18, tv4rhosigmalapltau19, tv4rhosigmalapltau20, tv4rhosigmalapltau21;
  double tv4rhosigmalapltau22, tv4rhosigmalapltau23, tv4rhosigmatau20, tv4rhosigmatau21, tv4rhosigmatau22, tv4rhosigmatau23, tv4rhosigmatau24, tv4rhosigmatau25;
  double tv4rhosigmatau26, tv4rhosigmatau27, tv4rhosigmatau28, tv4rhosigmatau29, tv4rhosigmatau210, tv4rhosigmatau211, tv4rhosigmatau212, tv4rhosigmatau213;
  double tv4rhosigmatau214, tv4rhosigmatau215, tv4rhosigmatau216, tv4rhosigmatau217, tv4rholapl30, tv4rholapl31, tv4rholapl32, tv4rholapl33;
  double tv4rholapl34, tv4rholapl35, tv4rholapl36, tv4rholapl37, tv4rholapl2tau0, tv4rholapl2tau1, tv4rholapl2tau2, tv4rholapl2tau3;
  double tv4rholapl2tau4, tv4rholapl2tau5, tv4rholapl2tau6, tv4rholapl2tau7, tv4rholapl2tau8, tv4rholapl2tau9, tv4rholapl2tau10, tv4rholapl2tau11;
  double tv4rholapltau20, tv4rholapltau21, tv4rholapltau22, tv4rholapltau23, tv4rholapltau24, tv4rholapltau25, tv4rholapltau26, tv4rholapltau27;
  double tv4rholapltau28, tv4rholapltau29, tv4rholapltau210, tv4rholapltau211, tv4rhotau30, tv4rhotau31, tv4rhotau32, tv4rhotau33;
  double tv4rhotau34, tv4rhotau35, tv4rhotau36, tv4rhotau37, t3129, t3135, t3153, tv4sigma40;
  double tv4sigma41, tv4sigma42, tv4sigma43, tv4sigma44, tv4sigma45, tv4sigma46, tv4sigma47, tv4sigma48;
  double tv4sigma49, tv4sigma410, tv4sigma411, tv4sigma412, tv4sigma413, t3154, t3160, t3178;
  double tv4sigma414, tv4sigma3lapl0, tv4sigma3lapl1, tv4sigma3lapl2, tv4sigma3lapl3, tv4sigma3lapl4, tv4sigma3lapl5, tv4sigma3lapl6;
  double tv4sigma3lapl7, tv4sigma3lapl8, tv4sigma3lapl9, tv4sigma3lapl10, tv4sigma3lapl11, tv4sigma3lapl12, tv4sigma3lapl13, tv4sigma3lapl14;
  double tv4sigma3lapl15, tv4sigma3lapl16, tv4sigma3lapl17, tv4sigma3lapl18, tv4sigma3lapl19, t3186, tv4sigma3tau0, tv4sigma3tau1;
  double tv4sigma3tau2, tv4sigma3tau3, tv4sigma3tau4, tv4sigma3tau5, tv4sigma3tau6, tv4sigma3tau7, tv4sigma3tau8, tv4sigma3tau9;
  double tv4sigma3tau10, tv4sigma3tau11, tv4sigma3tau12, tv4sigma3tau13, tv4sigma3tau14, tv4sigma3tau15, tv4sigma3tau16, tv4sigma3tau17;
  double tv4sigma3tau18, t3194, tv4sigma3tau19, tv4sigma2lapl20, tv4sigma2lapl21, tv4sigma2lapl22, tv4sigma2lapl23, tv4sigma2lapl24;
  double tv4sigma2lapl25, tv4sigma2lapl26, tv4sigma2lapl27, tv4sigma2lapl28, tv4sigma2lapl29, tv4sigma2lapl210, tv4sigma2lapl211, tv4sigma2lapl212;
  double tv4sigma2lapl213, tv4sigma2lapl214, tv4sigma2lapl215, tv4sigma2lapl216, tv4sigma2lapl217, tv4sigma2lapltau0, tv4sigma2lapltau1, tv4sigma2lapltau2;
  double tv4sigma2lapltau3, tv4sigma2lapltau4, tv4sigma2lapltau5, tv4sigma2lapltau6, tv4sigma2lapltau7, tv4sigma2lapltau8, tv4sigma2lapltau9, tv4sigma2lapltau10;
  double tv4sigma2lapltau11, tv4sigma2lapltau12, tv4sigma2lapltau13, tv4sigma2lapltau14, tv4sigma2lapltau15, tv4sigma2lapltau16, tv4sigma2lapltau17, tv4sigma2lapltau18;
  double tv4sigma2lapltau19, tv4sigma2lapltau20, tv4sigma2lapltau21, tv4sigma2lapltau22, tv4sigma2lapltau23, tv4sigma2tau20, tv4sigma2tau21, tv4sigma2tau22;
  double tv4sigma2tau23, tv4sigma2tau24, tv4sigma2tau25, tv4sigma2tau26, tv4sigma2tau27, tv4sigma2tau28, tv4sigma2tau29, tv4sigma2tau210;
  double tv4sigma2tau211, tv4sigma2tau212, tv4sigma2tau213, tv4sigma2tau214, tv4sigma2tau215, tv4sigma2tau216, tv4sigma2tau217, tv4sigmalapl30;
  double tv4sigmalapl31, tv4sigmalapl32, tv4sigmalapl33, tv4sigmalapl34, tv4sigmalapl35, tv4sigmalapl36, tv4sigmalapl37, tv4sigmalapl38;
  double tv4sigmalapl39, tv4sigmalapl310, tv4sigmalapl311, tv4sigmalapl2tau0, tv4sigmalapl2tau1, tv4sigmalapl2tau2, tv4sigmalapl2tau3, tv4sigmalapl2tau4;
  double tv4sigmalapl2tau5, tv4sigmalapl2tau6, tv4sigmalapl2tau7, tv4sigmalapl2tau8, tv4sigmalapl2tau9, tv4sigmalapl2tau10, tv4sigmalapl2tau11, tv4sigmalapl2tau12;
  double tv4sigmalapl2tau13, tv4sigmalapl2tau14, tv4sigmalapl2tau15, tv4sigmalapl2tau16, tv4sigmalapl2tau17, tv4sigmalapltau20, tv4sigmalapltau21, tv4sigmalapltau22;
  double tv4sigmalapltau23, tv4sigmalapltau24, tv4sigmalapltau25, tv4sigmalapltau26, tv4sigmalapltau27, tv4sigmalapltau28, tv4sigmalapltau29, tv4sigmalapltau210;
  double tv4sigmalapltau211, tv4sigmalapltau212, tv4sigmalapltau213, tv4sigmalapltau214, tv4sigmalapltau215, tv4sigmalapltau216, tv4sigmalapltau217, tv4sigmatau30;
  double tv4sigmatau31, tv4sigmatau32, tv4sigmatau33, tv4sigmatau34, tv4sigmatau35, tv4sigmatau36, tv4sigmatau37, tv4sigmatau38;
  double tv4sigmatau39, tv4sigmatau310, tv4sigmatau311, tv4lapl40, tv4lapl41, tv4lapl42, tv4lapl43, tv4lapl44;
  double tv4lapl3tau0, tv4lapl3tau1, tv4lapl3tau2, tv4lapl3tau3, tv4lapl3tau4, tv4lapl3tau5, tv4lapl3tau6, tv4lapl3tau7;
  double tv4lapl2tau20, tv4lapl2tau21, tv4lapl2tau22, tv4lapl2tau23, tv4lapl2tau24, tv4lapl2tau25, tv4lapl2tau26, tv4lapl2tau27;
  double tv4lapl2tau28, tv4lapltau30, tv4lapltau31, tv4lapltau32, tv4lapltau33, tv4lapltau34, tv4lapltau35, tv4lapltau36;
  double tv4lapltau37, tv4tau40, tv4tau41, tv4tau42, tv4tau43, tv4tau44;


  t2 = rho[0] <= p->dens_threshold;
  t3 = sqrt(M_PI);
  t4 = 0.1e1 / t3;
  t5 = rho[0] + rho[1];
  t6 = 0.1e1 / t5;
  t9 = 0.2e1 * rho[0] * t6 <= p->zeta_threshold;
  t10 = p->zeta_threshold - 0.1e1;
  t13 = 0.2e1 * rho[1] * t6 <= p->zeta_threshold;
  t14 = -t10;
  t15 = rho[0] - rho[1];
  t17 = my_piecewise5(t9, t10, t13, t14, t15 * t6);
  t18 = 0.1e1 + t17;
  t19 = t18 <= p->zeta_threshold;
  t20 = sqrt(p->zeta_threshold);
  t21 = t20 * p->zeta_threshold;
  t22 = sqrt(t18);
  t23 = t22 * t18;
  t24 = my_piecewise3(t19, t21, t23);
  t25 = t4 * t24;
  t26 = M_SQRT2;
  t27 = sqrt(t5);
  t28 = t26 * t27;
  t29 = rho[0] * rho[0];
  t30 = t29 * rho[0];
  t31 = 0.1e1 / t30;
  t32 = sigma[0] * t31;
  t34 = sigma[0] * sigma[0];
  t35 = t29 * t29;
  t37 = 0.1e1 / t35 / t29;
  t40 = 0.1e1 + 0.41252961249419271031e0 * t32 + 0.63029881920225480858e-3 * t34 * t37;
  t41 = pow(t40, 0.1e1 / 0.15e2);
  t44 = 0.1e1 / t29;
  t48 = 0.1e1 / M_PI;
  t51 = 0.1e1 + 0.27938513438760141227e-1 * t32 + (-0.772e-1 * tau[0] * t44 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t52 = pow(t40, 0.1e1 / 0.5e1);
  t53 = 0.1e1 / t52;
  t56 = 0.1e1 / t41 + 0.2e1 / 0.5e1 * t51 * t53;
  t57 = t28 * t56;
  t60 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t57);
  t61 = rho[1] <= p->dens_threshold;
  t62 = -t15;
  t64 = my_piecewise5(t13, t10, t9, t14, t62 * t6);
  t65 = 0.1e1 + t64;
  t66 = t65 <= p->zeta_threshold;
  t67 = sqrt(t65);
  t68 = t67 * t65;
  t69 = my_piecewise3(t66, t21, t68);
  t70 = t4 * t69;
  t71 = rho[1] * rho[1];
  t72 = t71 * rho[1];
  t73 = 0.1e1 / t72;
  t74 = sigma[2] * t73;
  t76 = sigma[2] * sigma[2];
  t77 = t71 * t71;
  t79 = 0.1e1 / t77 / t71;
  t82 = 0.1e1 + 0.41252961249419271031e0 * t74 + 0.63029881920225480858e-3 * t76 * t79;
  t83 = pow(t82, 0.1e1 / 0.15e2);
  t86 = 0.1e1 / t71;
  t92 = 0.1e1 + 0.27938513438760141227e-1 * t74 + (-0.772e-1 * tau[1] * t86 - 0.11596246802930644802e2) * t48 / 0.4e1;
  t93 = pow(t82, 0.1e1 / 0.5e1);
  t94 = 0.1e1 / t93;
  t97 = 0.1e1 / t83 + 0.2e1 / 0.5e1 * t92 * t94;
  t98 = t28 * t97;
  t101 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t98);
  tzk0 = t60 + t101;

  if(out->zk != NULL && (p->info->flags & XC_FLAGS_HAVE_EXC))
    out->zk[ip*p->dim.zk + 0] += tzk0;

  t102 = t5 * t5;
  t103 = 0.1e1 / t102;
  t104 = t15 * t103;
  t106 = my_piecewise5(t9, 0, t13, 0, t6 - t104);
  t109 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t106);
  t110 = t4 * t109;
  t113 = 0.1e1 / t27;
  t114 = t26 * t113;
  t115 = t114 * t56;
  t117 = t25 * t115 / 0.3e1;
  t119 = 0.1e1 / t41 / t40;
  t120 = 0.1e1 / t35;
  t121 = sigma[0] * t120;
  t124 = 0.1e1 / t35 / t30;
  t127 = -0.12375888374825781309e1 * t121 - 0.37817929152135288515e-2 * t34 * t124;
  t133 = -0.83815540316280423681e-1 * t121 + 0.12286761606694319921e-1 * tau[0] * t31;
  t137 = 0.1e1 / t52 / t40;
  t138 = t51 * t137;
  t141 = -t119 * t127 / 0.15e2 + 0.2e1 / 0.5e1 * t133 * t53 - 0.2e1 / 0.25e2 * t138 * t127;
  t142 = t28 * t141;
  t146 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t57 - t117 - 0.2e1 / 0.3e1 * t25 * t142);
  t147 = t62 * t103;
  t149 = my_piecewise5(t13, 0, t9, 0, -t6 - t147);
  t152 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t149);
  t153 = t4 * t152;
  t156 = t114 * t97;
  t158 = t70 * t156 / 0.3e1;
  t160 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t98 - t158);
  tvrho0 = t60 + t101 + t5 * (t146 + t160);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 0] += tvrho0;

  t164 = my_piecewise5(t9, 0, t13, 0, -t6 - t104);
  t167 = my_piecewise3(t19, 0, 0.3e1 / 0.2e1 * t22 * t164);
  t168 = t4 * t167;
  t172 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t57 - t117);
  t174 = my_piecewise5(t13, 0, t9, 0, t6 - t147);
  t177 = my_piecewise3(t66, 0, 0.3e1 / 0.2e1 * t67 * t174);
  t178 = t4 * t177;
  t182 = 0.1e1 / t83 / t82;
  t183 = 0.1e1 / t77;
  t184 = sigma[2] * t183;
  t187 = 0.1e1 / t77 / t72;
  t190 = -0.12375888374825781309e1 * t184 - 0.37817929152135288515e-2 * t76 * t187;
  t196 = -0.83815540316280423681e-1 * t184 + 0.12286761606694319921e-1 * tau[1] * t73;
  t200 = 0.1e1 / t93 / t82;
  t201 = t92 * t200;
  t204 = -t182 * t190 / 0.15e2 + 0.2e1 / 0.5e1 * t196 * t94 - 0.2e1 / 0.25e2 * t201 * t190;
  t205 = t28 * t204;
  t209 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t98 - t158 - 0.2e1 / 0.3e1 * t70 * t205);
  tvrho1 = t60 + t101 + t5 * (t172 + t209);

  if(out->vrho != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vrho[ip*p->dim.vrho + 1] += tvrho1;

  t213 = sigma[0] * t37;
  t215 = 0.41252961249419271031e0 * t31 + 0.12605976384045096172e-2 * t213;
  t222 = -t119 * t215 / 0.15e2 + 0.11175405375504056491e-1 * t31 * t53 - 0.2e1 / 0.25e2 * t138 * t215;
  t223 = t28 * t222;
  t226 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t223);
  tvsigma0 = t5 * t226;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 0] += tvsigma0;

  tvsigma1 = 0.e0;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 1] += tvsigma1;

  t228 = sigma[2] * t79;
  t230 = 0.41252961249419271031e0 * t73 + 0.12605976384045096172e-2 * t228;
  t237 = -t182 * t230 / 0.15e2 + 0.11175405375504056491e-1 * t73 * t94 - 0.2e1 / 0.25e2 * t201 * t230;
  t238 = t28 * t237;
  t241 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t238);
  tvsigma2 = t5 * t241;

  if(out->vsigma != NULL && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vsigma[ip*p->dim.vsigma + 2] += tvsigma2;

  tvlapl0 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 0] += tvlapl0;

  tvlapl1 = 0.e0;

  if(out->vlapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vlapl[ip*p->dim.vlapl + 1] += tvlapl1;

  t242 = t24 * t26;
  t244 = t27 * t44 * t53;
  t247 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t242 * t244);
  tvtau0 = t5 * t247;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 0] += tvtau0;

  t248 = t69 * t26;
  t250 = t27 * t86 * t94;
  t253 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t248 * t250);
  tvtau1 = t5 * t253;

  if(out->vtau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_VXC))
    out->vtau[ip*p->dim.vtau + 1] += tvtau1;

  t256 = 0.1e1 / t22;
  t257 = t106 * t106;
  t260 = t102 * t5;
  t261 = 0.1e1 / t260;
  t262 = t15 * t261;
  t265 = my_piecewise5(t9, 0, t13, 0, -0.2e1 * t103 + 0.2e1 * t262);
  t269 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t256 * t257 + 0.3e1 / 0.2e1 * t22 * t265);
  t270 = t4 * t269;
  t273 = t110 * t115;
  t278 = 0.1e1 / t27 / t5;
  t279 = t26 * t278;
  t280 = t279 * t56;
  t282 = t25 * t280 / 0.6e1;
  t283 = t114 * t141;
  t284 = t25 * t283;
  t286 = t40 * t40;
  t288 = 0.1e1 / t41 / t286;
  t289 = t127 * t127;
  t293 = 0.1e1 / t35 / rho[0];
  t294 = sigma[0] * t293;
  t296 = t35 * t35;
  t297 = 0.1e1 / t296;
  t300 = 0.49503553499303125236e1 * t294 + 0.2647255040649470196e-1 * t34 * t297;
  t306 = 0.33526216126512169472e0 * t294 - 0.36860284820082959763e-1 * tau[0] * t120;
  t309 = t133 * t137;
  t313 = 0.1e1 / t52 / t286;
  t314 = t51 * t313;
  t319 = 0.16e2 / 0.225e3 * t288 * t289 - t119 * t300 / 0.15e2 + 0.2e1 / 0.5e1 * t306 * t53 - 0.4e1 / 0.25e2 * t309 * t127 + 0.12e2 / 0.125e3 * t314 * t289 - 0.2e1 / 0.25e2 * t138 * t300;
  t320 = t28 * t319;
  t324 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t270 * t57 - 0.2e1 / 0.3e1 * t273 - 0.4e1 / 0.3e1 * t110 * t142 + t282 - 0.2e1 / 0.3e1 * t284 - 0.2e1 / 0.3e1 * t25 * t320);
  t325 = 0.1e1 / t67;
  t326 = t149 * t149;
  t329 = t62 * t261;
  t332 = my_piecewise5(t13, 0, t9, 0, 0.2e1 * t103 + 0.2e1 * t329);
  t336 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t325 * t326 + 0.3e1 / 0.2e1 * t67 * t332);
  t337 = t4 * t336;
  t340 = t153 * t156;
  t342 = t279 * t97;
  t344 = t70 * t342 / 0.6e1;
  t346 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t337 * t98 - 0.2e1 / 0.3e1 * t340 + t344);
  tv2rho20 = 0.2e1 * t146 + 0.2e1 * t160 + t5 * (t324 + t346);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 0] += tv2rho20;

  t349 = t256 * t164;
  t353 = my_piecewise5(t9, 0, t13, 0, 0.2e1 * t262);
  t357 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t349 * t106 + 0.3e1 / 0.2e1 * t22 * t353);
  t358 = t4 * t357;
  t361 = t168 * t115;
  t368 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t358 * t57 - t361 / 0.3e1 - 0.2e1 / 0.3e1 * t168 * t142 - t273 / 0.3e1 + t282 - t284 / 0.3e1);
  t369 = t325 * t174;
  t373 = my_piecewise5(t13, 0, t9, 0, 0.2e1 * t329);
  t377 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t369 * t149 + 0.3e1 / 0.2e1 * t67 * t373);
  t378 = t4 * t377;
  t381 = t178 * t156;
  t386 = t114 * t204;
  t387 = t70 * t386;
  t390 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t378 * t98 - t381 / 0.3e1 - t340 / 0.3e1 + t344 - 0.2e1 / 0.3e1 * t153 * t205 - t387 / 0.3e1);
  tv2rho21 = t146 + t160 + t172 + t209 + t5 * (t368 + t390);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 1] += tv2rho21;

  t395 = t164 * t164;
  t400 = my_piecewise5(t9, 0, t13, 0, 0.2e1 * t103 + 0.2e1 * t262);
  t404 = my_piecewise3(t19, 0, 0.3e1 / 0.4e1 * t256 * t395 + 0.3e1 / 0.2e1 * t22 * t400);
  t405 = t4 * t404;
  t410 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t405 * t57 - 0.2e1 / 0.3e1 * t361 + t282);
  t411 = t174 * t174;
  t416 = my_piecewise5(t13, 0, t9, 0, -0.2e1 * t103 + 0.2e1 * t329);
  t420 = my_piecewise3(t66, 0, 0.3e1 / 0.4e1 * t325 * t411 + 0.3e1 / 0.2e1 * t67 * t416);
  t421 = t4 * t420;
  t428 = t82 * t82;
  t430 = 0.1e1 / t83 / t428;
  t431 = t190 * t190;
  t435 = 0.1e1 / t77 / rho[1];
  t436 = sigma[2] * t435;
  t438 = t77 * t77;
  t439 = 0.1e1 / t438;
  t442 = 0.49503553499303125236e1 * t436 + 0.2647255040649470196e-1 * t76 * t439;
  t448 = 0.33526216126512169472e0 * t436 - 0.36860284820082959763e-1 * tau[1] * t183;
  t451 = t196 * t200;
  t455 = 0.1e1 / t93 / t428;
  t456 = t92 * t455;
  t461 = 0.16e2 / 0.225e3 * t430 * t431 - t182 * t442 / 0.15e2 + 0.2e1 / 0.5e1 * t448 * t94 - 0.4e1 / 0.25e2 * t451 * t190 + 0.12e2 / 0.125e3 * t456 * t431 - 0.2e1 / 0.25e2 * t201 * t442;
  t462 = t28 * t461;
  t466 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t421 * t98 - 0.2e1 / 0.3e1 * t381 - 0.4e1 / 0.3e1 * t178 * t205 + t344 - 0.2e1 / 0.3e1 * t387 - 0.2e1 / 0.3e1 * t70 * t462);
  tv2rho22 = 0.2e1 * t172 + 0.2e1 * t209 + t5 * (t410 + t466);

  if(out->v2rho2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rho2[ip*p->dim.v2rho2 + 2] += tv2rho22;

  t471 = t114 * t222;
  t473 = t25 * t471 / 0.3e1;
  t474 = t288 * t215;
  t478 = sigma[0] * t124;
  t480 = -0.12375888374825781309e1 * t120 - 0.75635858304270577032e-2 * t478;
  t485 = t31 * t137;
  t486 = t485 * t127;
  t490 = t215 * t127;
  t495 = 0.16e2 / 0.225e3 * t474 * t127 - t119 * t480 / 0.15e2 - 0.33526216126512169473e-1 * t120 * t53 - 0.22350810751008112982e-2 * t486 - 0.2e1 / 0.25e2 * t309 * t215 + 0.12e2 / 0.125e3 * t314 * t490 - 0.2e1 / 0.25e2 * t138 * t480;
  t496 = t28 * t495;
  t500 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t223 - t473 - 0.2e1 / 0.3e1 * t25 * t496);
  tv2rhosigma0 = t5 * t500 + t226;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 0] += tv2rhosigma0;

  tv2rhosigma1 = 0.e0;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 1] += tv2rhosigma1;

  t504 = t114 * t237;
  t506 = t70 * t504 / 0.3e1;
  t508 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t238 - t506);
  tv2rhosigma2 = t5 * t508 + t241;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 2] += tv2rhosigma2;

  t513 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t223 - t473);
  tv2rhosigma3 = t5 * t513 + t226;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 3] += tv2rhosigma3;

  tv2rhosigma4 = 0.e0;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 4] += tv2rhosigma4;

  t517 = t430 * t230;
  t521 = sigma[2] * t187;
  t523 = -0.12375888374825781309e1 * t183 - 0.75635858304270577032e-2 * t521;
  t528 = t73 * t200;
  t529 = t528 * t190;
  t533 = t230 * t190;
  t538 = 0.16e2 / 0.225e3 * t517 * t190 - t182 * t523 / 0.15e2 - 0.33526216126512169473e-1 * t183 * t94 - 0.22350810751008112982e-2 * t529 - 0.2e1 / 0.25e2 * t451 * t230 + 0.12e2 / 0.125e3 * t456 * t533 - 0.2e1 / 0.25e2 * t201 * t523;
  t539 = t28 * t538;
  t543 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t238 - t506 - 0.2e1 / 0.3e1 * t70 * t539);
  tv2rhosigma5 = t5 * t543 + t241;

  if(out->v2rhosigma != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhosigma[ip*p->dim.v2rhosigma + 5] += tv2rhosigma5;

  tv2rholapl0 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 0] += tv2rholapl0;

  tv2rholapl1 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 1] += tv2rholapl1;

  tv2rholapl2 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 2] += tv2rholapl2;

  tv2rholapl3 = 0.e0;

  if(out->v2rholapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rholapl[ip*p->dim.v2rholapl + 3] += tv2rholapl3;

  t545 = t109 * t26;
  t549 = t113 * t44 * t53;
  t551 = 0.4621375276020952854e-3 * t242 * t549;
  t553 = t27 * t31 * t53;
  t556 = t242 * t27;
  t557 = t44 * t137;
  t558 = t557 * t127;
  t562 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t545 * t244 + t551 - 0.18485501104083811416e-2 * t242 * t553 - 0.18485501104083811416e-3 * t556 * t558);
  tv2rhotau0 = t5 * t562 + t247;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 0] += tv2rhotau0;

  t564 = t152 * t26;
  t568 = t113 * t86 * t94;
  t570 = 0.4621375276020952854e-3 * t248 * t568;
  t572 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t564 * t250 + t570);
  tv2rhotau1 = t5 * t572 + t253;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 1] += tv2rhotau1;

  t574 = t167 * t26;
  t578 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t574 * t244 + t551);
  tv2rhotau2 = t5 * t578 + t247;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 2] += tv2rhotau2;

  t580 = t177 * t26;
  t584 = t27 * t73 * t94;
  t587 = t248 * t27;
  t588 = t86 * t200;
  t589 = t588 * t190;
  t593 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t580 * t250 + t570 - 0.18485501104083811416e-2 * t248 * t584 - 0.18485501104083811416e-3 * t587 * t589);
  tv2rhotau3 = t5 * t593 + t253;

  if(out->v2rhotau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2rhotau[ip*p->dim.v2rhotau + 3] += tv2rhotau3;

  t595 = t215 * t215;
  t600 = t485 * t215;
  t606 = 0.16e2 / 0.225e3 * t288 * t595 - 0.84039842560300641147e-4 * t119 * t37 - 0.44701621502016225964e-2 * t600 + 0.12e2 / 0.125e3 * t314 * t595 - 0.10084781107236076938e-3 * t138 * t37;
  t607 = t28 * t606;
  t610 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t607);
  tv2sigma20 = t5 * t610;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 0] += tv2sigma20;

  tv2sigma21 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 1] += tv2sigma21;

  tv2sigma22 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 2] += tv2sigma22;

  tv2sigma23 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 3] += tv2sigma23;

  tv2sigma24 = 0.e0;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 4] += tv2sigma24;

  t611 = t230 * t230;
  t616 = t528 * t230;
  t622 = 0.16e2 / 0.225e3 * t430 * t611 - 0.84039842560300641147e-4 * t182 * t79 - 0.44701621502016225964e-2 * t616 + 0.12e2 / 0.125e3 * t456 * t611 - 0.10084781107236076938e-3 * t201 * t79;
  t623 = t28 * t622;
  t626 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t623);
  tv2sigma25 = t5 * t626;

  if(out->v2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigma2[ip*p->dim.v2sigma2 + 5] += tv2sigma25;

  tv2sigmalapl0 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 0] += tv2sigmalapl0;

  tv2sigmalapl1 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 1] += tv2sigmalapl1;

  tv2sigmalapl2 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 2] += tv2sigmalapl2;

  tv2sigmalapl3 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 3] += tv2sigmalapl3;

  tv2sigmalapl4 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 4] += tv2sigmalapl4;

  tv2sigmalapl5 = 0.e0;

  if(out->v2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmalapl[ip*p->dim.v2sigmalapl + 5] += tv2sigmalapl5;

  t627 = t557 * t215;
  t630 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t556 * t627);
  tv2sigmatau0 = t5 * t630;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 0] += tv2sigmatau0;

  tv2sigmatau1 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 1] += tv2sigmatau1;

  tv2sigmatau2 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 2] += tv2sigmatau2;

  tv2sigmatau3 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 3] += tv2sigmatau3;

  tv2sigmatau4 = 0.e0;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 4] += tv2sigmatau4;

  t631 = t588 * t230;
  t634 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t587 * t631);
  tv2sigmatau5 = t5 * t634;

  if(out->v2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2sigmatau[ip*p->dim.v2sigmatau + 5] += tv2sigmatau5;

  tv2lapl20 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 0] += tv2lapl20;

  tv2lapl21 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 1] += tv2lapl21;

  tv2lapl22 = 0.e0;

  if(out->v2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapl2[ip*p->dim.v2lapl2 + 2] += tv2lapl22;

  tv2lapltau0 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 0] += tv2lapltau0;

  tv2lapltau1 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 1] += tv2lapltau1;

  tv2lapltau2 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 2] += tv2lapltau2;

  tv2lapltau3 = 0.e0;

  if(out->v2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2lapltau[ip*p->dim.v2lapltau + 3] += tv2lapltau3;

  tv2tau20 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 0] += tv2tau20;

  tv2tau21 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 1] += tv2tau21;

  tv2tau22 = 0.e0;

  if(out->v2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_FXC))
    out->v2tau2[ip*p->dim.v2tau2 + 2] += tv2tau22;

  t637 = 0.1e1 / t23;
  t638 = t257 * t106;
  t641 = t256 * t106;
  t644 = t102 * t102;
  t645 = 0.1e1 / t644;
  t646 = t15 * t645;
  t649 = my_piecewise5(t9, 0, t13, 0, 0.6e1 * t261 - 0.6e1 * t646);
  t653 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t637 * t638 + 0.9e1 / 0.4e1 * t641 * t265 + 0.3e1 / 0.2e1 * t22 * t649);
  t654 = t4 * t653;
  t657 = t270 * t115;
  t660 = t110 * t280;
  t662 = t110 * t283;
  t667 = 0.1e1 / t27 / t102;
  t668 = t26 * t667;
  t669 = t668 * t56;
  t671 = t25 * t669 / 0.4e1;
  t672 = t279 * t141;
  t673 = t25 * t672;
  t675 = t114 * t319;
  t676 = t25 * t675;
  t677 = t286 * t40;
  t679 = 0.1e1 / t41 / t677;
  t680 = t289 * t127;
  t683 = t288 * t127;
  t688 = 0.1e1 / t296 / rho[0];
  t691 = -0.24751776749651562618e2 * t213 - 0.21178040325195761568e0 * t34 * t688;
  t697 = -0.16763108063256084736e1 * t213 + 0.14744113928033183905e0 * tau[0] * t293;
  t700 = t306 * t137;
  t703 = t133 * t313;
  t709 = 0.1e1 / t52 / t677;
  t710 = t51 * t709;
  t713 = t127 * t300;
  t718 = -0.496e3 / 0.3375e4 * t679 * t680 + 0.16e2 / 0.75e2 * t683 * t300 - t119 * t691 / 0.15e2 + 0.2e1 / 0.5e1 * t697 * t53 - 0.6e1 / 0.25e2 * t700 * t127 + 0.36e2 / 0.125e3 * t703 * t289 - 0.6e1 / 0.25e2 * t309 * t300 - 0.132e3 / 0.625e3 * t710 * t680 + 0.36e2 / 0.125e3 * t314 * t713 - 0.2e1 / 0.25e2 * t138 * t691;
  t719 = t28 * t718;
  t723 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t654 * t57 - t657 - 0.2e1 * t270 * t142 + t660 / 0.2e1 - 0.2e1 * t662 - 0.2e1 * t110 * t320 - t671 + t673 / 0.2e1 - t676 - 0.2e1 / 0.3e1 * t25 * t719);
  t724 = 0.1e1 / t68;
  t725 = t326 * t149;
  t728 = t325 * t149;
  t731 = t62 * t645;
  t734 = my_piecewise5(t13, 0, t9, 0, -0.6e1 * t261 - 0.6e1 * t731);
  t738 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t724 * t725 + 0.9e1 / 0.4e1 * t728 * t332 + 0.3e1 / 0.2e1 * t67 * t734);
  t739 = t4 * t738;
  t742 = t337 * t156;
  t743 = t153 * t342;
  t745 = t668 * t97;
  t747 = t70 * t745 / 0.4e1;
  t749 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t739 * t98 - t742 + t743 / 0.2e1 - t747);
  tv3rho30 = 0.3e1 * t324 + 0.3e1 * t346 + t5 * (t723 + t749);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 0] += tv3rho30;

  t752 = 0.2e1 * t368;
  t753 = 0.2e1 * t390;
  t754 = t637 * t164;
  t757 = t256 * t353;
  t762 = 0.2e1 * t261;
  t763 = 0.6e1 * t646;
  t765 = my_piecewise5(t9, 0, t13, 0, t762 - t763);
  t769 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t754 * t257 + 0.3e1 / 0.2e1 * t757 * t106 + 0.3e1 / 0.4e1 * t349 * t265 + 0.3e1 / 0.2e1 * t22 * t765);
  t770 = t4 * t769;
  t774 = 0.2e1 / 0.3e1 * t358 * t115;
  t777 = t168 * t280;
  t780 = 0.2e1 / 0.3e1 * t168 * t283;
  t788 = -0.2e1 / 0.3e1 * t770 * t57 - t774 - 0.4e1 / 0.3e1 * t358 * t142 + t777 / 0.6e1 - t780 - 0.2e1 / 0.3e1 * t168 * t320 - t657 / 0.3e1 + t660 / 0.3e1 - 0.2e1 / 0.3e1 * t662 - t671 + t673 / 0.3e1 - t676 / 0.3e1;
  t789 = my_piecewise3(t2, 0, t788);
  t790 = t724 * t174;
  t793 = t325 * t373;
  t798 = 0.6e1 * t731;
  t800 = my_piecewise5(t13, 0, t9, 0, -t762 - t798);
  t804 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t790 * t326 + 0.3e1 / 0.2e1 * t793 * t149 + 0.3e1 / 0.4e1 * t369 * t332 + 0.3e1 / 0.2e1 * t67 * t800);
  t805 = t4 * t804;
  t809 = 0.2e1 / 0.3e1 * t378 * t156;
  t810 = t178 * t342;
  t817 = 0.2e1 / 0.3e1 * t153 * t386;
  t818 = t279 * t204;
  t819 = t70 * t818;
  t822 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t805 * t98 - t809 + t810 / 0.6e1 - t742 / 0.3e1 + t743 / 0.3e1 - t747 - 0.2e1 / 0.3e1 * t337 * t205 - t817 + t819 / 0.6e1);
  tv3rho31 = t324 + t346 + t752 + t753 + t5 * (t789 + t822);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 1] += tv3rho31;

  t825 = t637 * t395;
  t830 = t256 * t400;
  t834 = my_piecewise5(t9, 0, t13, 0, -t762 - t763);
  t838 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t825 * t106 + 0.3e1 / 0.2e1 * t349 * t353 + 0.3e1 / 0.4e1 * t830 * t106 + 0.3e1 / 0.2e1 * t22 * t834);
  t839 = t4 * t838;
  t842 = t405 * t115;
  t850 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t839 * t57 - t842 / 0.3e1 - 0.2e1 / 0.3e1 * t405 * t142 - t774 + t777 / 0.3e1 - t780 + t660 / 0.6e1 - t671 + t673 / 0.6e1);
  t851 = t724 * t411;
  t856 = t325 * t416;
  t860 = my_piecewise5(t13, 0, t9, 0, t762 - t798);
  t864 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t851 * t149 + 0.3e1 / 0.2e1 * t369 * t373 + 0.3e1 / 0.4e1 * t856 * t149 + 0.3e1 / 0.2e1 * t67 * t860);
  t865 = t4 * t864;
  t868 = t421 * t156;
  t873 = t178 * t386;
  t879 = t114 * t461;
  t880 = t70 * t879;
  t882 = -0.2e1 / 0.3e1 * t865 * t98 - t868 / 0.3e1 - t809 + t810 / 0.3e1 - 0.4e1 / 0.3e1 * t378 * t205 - 0.2e1 / 0.3e1 * t873 + t743 / 0.6e1 - t747 - t817 + t819 / 0.3e1 - 0.2e1 / 0.3e1 * t153 * t462 - t880 / 0.3e1;
  t883 = my_piecewise3(t61, 0, t882);
  tv3rho32 = t752 + t753 + t410 + t466 + t5 * (t850 + t883);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 2] += tv3rho32;

  t888 = t395 * t164;
  t895 = my_piecewise5(t9, 0, t13, 0, -0.6e1 * t261 - 0.6e1 * t646);
  t899 = my_piecewise3(t19, 0, -0.3e1 / 0.8e1 * t637 * t888 + 0.9e1 / 0.4e1 * t349 * t400 + 0.3e1 / 0.2e1 * t22 * t895);
  t900 = t4 * t899;
  t905 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t900 * t57 - t842 + t777 / 0.2e1 - t671);
  t906 = t411 * t174;
  t913 = my_piecewise5(t13, 0, t9, 0, 0.6e1 * t261 - 0.6e1 * t731);
  t917 = my_piecewise3(t66, 0, -0.3e1 / 0.8e1 * t724 * t906 + 0.9e1 / 0.4e1 * t369 * t416 + 0.3e1 / 0.2e1 * t67 * t913);
  t918 = t4 * t917;
  t928 = t428 * t82;
  t930 = 0.1e1 / t83 / t928;
  t931 = t431 * t190;
  t934 = t430 * t190;
  t939 = 0.1e1 / t438 / rho[1];
  t942 = -0.24751776749651562618e2 * t228 - 0.21178040325195761568e0 * t76 * t939;
  t948 = -0.16763108063256084736e1 * t228 + 0.14744113928033183905e0 * tau[1] * t435;
  t951 = t448 * t200;
  t954 = t196 * t455;
  t960 = 0.1e1 / t93 / t928;
  t961 = t92 * t960;
  t964 = t190 * t442;
  t969 = -0.496e3 / 0.3375e4 * t930 * t931 + 0.16e2 / 0.75e2 * t934 * t442 - t182 * t942 / 0.15e2 + 0.2e1 / 0.5e1 * t948 * t94 - 0.6e1 / 0.25e2 * t951 * t190 + 0.36e2 / 0.125e3 * t954 * t431 - 0.6e1 / 0.25e2 * t451 * t442 - 0.132e3 / 0.625e3 * t961 * t931 + 0.36e2 / 0.125e3 * t456 * t964 - 0.2e1 / 0.25e2 * t201 * t942;
  t970 = t28 * t969;
  t974 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t918 * t98 - t868 - 0.2e1 * t421 * t205 + t810 / 0.2e1 - 0.2e1 * t873 - 0.2e1 * t178 * t462 - t747 + t819 / 0.2e1 - t880 - 0.2e1 / 0.3e1 * t70 * t970);
  tv3rho33 = 0.3e1 * t410 + 0.3e1 * t466 + t5 * (t905 + t974);

  if(out->v3rho3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho3[ip*p->dim.v3rho3 + 3] += tv3rho33;

  t980 = t110 * t471;
  t984 = t279 * t222;
  t986 = t25 * t984 / 0.6e1;
  t987 = t114 * t495;
  t988 = t25 * t987;
  t990 = t679 * t215;
  t993 = t288 * t480;
  t1001 = 0.49503553499303125236e1 * t293 + 0.52945100812989403922e-1 * sigma[0] * t297;
  t1006 = t120 * t137;
  t1007 = t1006 * t127;
  t1009 = t31 * t313;
  t1010 = t1009 * t289;
  t1012 = t485 * t300;
  t1020 = t215 * t289;
  t1023 = t480 * t127;
  t1026 = t215 * t300;
  t1031 = -0.496e3 / 0.3375e4 * t990 * t289 + 0.32e2 / 0.225e3 * t993 * t127 + 0.16e2 / 0.225e3 * t474 * t300 - t119 * t1001 / 0.15e2 + 0.13410486450604867789e0 * t293 * t53 + 0.13410486450604867789e-1 * t1007 + 0.26820972901209735578e-2 * t1010 - 0.22350810751008112982e-2 * t1012 - 0.2e1 / 0.25e2 * t700 * t215 + 0.24e2 / 0.125e3 * t703 * t490 - 0.4e1 / 0.25e2 * t309 * t480 - 0.132e3 / 0.625e3 * t710 * t1020 + 0.24e2 / 0.125e3 * t314 * t1023 + 0.12e2 / 0.125e3 * t314 * t1026 - 0.2e1 / 0.25e2 * t138 * t1001;
  t1032 = t28 * t1031;
  t1036 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t270 * t223 - 0.2e1 / 0.3e1 * t980 - 0.4e1 / 0.3e1 * t110 * t496 + t986 - 0.2e1 / 0.3e1 * t988 - 0.2e1 / 0.3e1 * t25 * t1032);
  tv3rho2sigma0 = t5 * t1036 + 0.2e1 * t500;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 0] += tv3rho2sigma0;

  tv3rho2sigma1 = 0.e0;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 1] += tv3rho2sigma1;

  t1041 = t153 * t504;
  t1043 = t279 * t237;
  t1045 = t70 * t1043 / 0.6e1;
  t1047 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t337 * t238 - 0.2e1 / 0.3e1 * t1041 + t1045);
  tv3rho2sigma2 = t5 * t1047 + 0.2e1 * t508;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 2] += tv3rho2sigma2;

  t1051 = t168 * t471;
  t1058 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t358 * t223 - t1051 / 0.3e1 - 0.2e1 / 0.3e1 * t168 * t496 - t980 / 0.3e1 + t986 - t988 / 0.3e1);
  tv3rho2sigma3 = t5 * t1058 + t500 + t513;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 3] += tv3rho2sigma3;

  tv3rho2sigma4 = 0.e0;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 4] += tv3rho2sigma4;

  t1062 = t178 * t504;
  t1067 = t114 * t538;
  t1068 = t70 * t1067;
  t1071 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t378 * t238 - t1062 / 0.3e1 - t1041 / 0.3e1 + t1045 - 0.2e1 / 0.3e1 * t153 * t539 - t1068 / 0.3e1);
  tv3rho2sigma5 = t5 * t1071 + t508 + t543;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 5] += tv3rho2sigma5;

  t1078 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t405 * t223 - 0.2e1 / 0.3e1 * t1051 + t986);
  tv3rho2sigma6 = t5 * t1078 + 0.2e1 * t513;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 6] += tv3rho2sigma6;

  tv3rho2sigma7 = 0.e0;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 7] += tv3rho2sigma7;

  t1087 = t930 * t230;
  t1090 = t430 * t523;
  t1098 = 0.49503553499303125236e1 * t435 + 0.52945100812989403922e-1 * sigma[2] * t439;
  t1103 = t183 * t200;
  t1104 = t1103 * t190;
  t1106 = t73 * t455;
  t1107 = t1106 * t431;
  t1109 = t528 * t442;
  t1117 = t230 * t431;
  t1120 = t523 * t190;
  t1123 = t230 * t442;
  t1128 = -0.496e3 / 0.3375e4 * t1087 * t431 + 0.32e2 / 0.225e3 * t1090 * t190 + 0.16e2 / 0.225e3 * t517 * t442 - t182 * t1098 / 0.15e2 + 0.13410486450604867789e0 * t435 * t94 + 0.13410486450604867789e-1 * t1104 + 0.26820972901209735578e-2 * t1107 - 0.22350810751008112982e-2 * t1109 - 0.2e1 / 0.25e2 * t951 * t230 + 0.24e2 / 0.125e3 * t954 * t533 - 0.4e1 / 0.25e2 * t451 * t523 - 0.132e3 / 0.625e3 * t961 * t1117 + 0.24e2 / 0.125e3 * t456 * t1120 + 0.12e2 / 0.125e3 * t456 * t1123 - 0.2e1 / 0.25e2 * t201 * t1098;
  t1129 = t28 * t1128;
  t1133 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t421 * t238 - 0.2e1 / 0.3e1 * t1062 - 0.4e1 / 0.3e1 * t178 * t539 + t1045 - 0.2e1 / 0.3e1 * t1068 - 0.2e1 / 0.3e1 * t70 * t1129);
  tv3rho2sigma8 = t1133 * t5 + 0.2e1 * t543;

  if(out->v3rho2sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2sigma[ip*p->dim.v3rho2sigma + 8] += tv3rho2sigma8;

  tv3rho2lapl0 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 0] += tv3rho2lapl0;

  tv3rho2lapl1 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 1] += tv3rho2lapl1;

  tv3rho2lapl2 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 2] += tv3rho2lapl2;

  tv3rho2lapl3 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 3] += tv3rho2lapl3;

  tv3rho2lapl4 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 4] += tv3rho2lapl4;

  tv3rho2lapl5 = 0.e0;

  if(out->v3rho2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2lapl[ip*p->dim.v3rho2lapl + 5] += tv3rho2lapl5;

  t1136 = t269 * t26;
  t1139 = t545 * t549;
  t1143 = t545 * t27;
  t1147 = t278 * t44 * t53;
  t1149 = 0.2310687638010476427e-3 * t242 * t1147;
  t1151 = t113 * t31 * t53;
  t1152 = t242 * t1151;
  t1154 = t242 * t113;
  t1155 = t1154 * t558;
  t1158 = t27 * t120 * t53;
  t1163 = t44 * t313;
  t1164 = t1163 * t289;
  t1167 = t557 * t300;
  t1170 = 0.9242750552041905708e-3 * t1136 * t244 + 0.9242750552041905708e-3 * t1139 - 0.36971002208167622832e-2 * t545 * t553 - 0.36971002208167622832e-3 * t1143 * t558 - t1149 - 0.18485501104083811416e-2 * t1152 - 0.18485501104083811416e-3 * t1155 + 0.55456503312251434248e-2 * t242 * t1158 + 0.73942004416335245664e-3 * t556 * t486 + 0.22182601324900573699e-3 * t556 * t1164 - 0.18485501104083811416e-3 * t556 * t1167;
  t1171 = my_piecewise3(t2, 0, t1170);
  tv3rho2tau0 = t1171 * t5 + 0.2e1 * t562;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 0] += tv3rho2tau0;

  t1174 = t336 * t26;
  t1177 = t564 * t568;
  t1180 = t278 * t86 * t94;
  t1182 = 0.2310687638010476427e-3 * t248 * t1180;
  t1184 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t1174 * t250 + 0.9242750552041905708e-3 * t1177 - t1182);
  tv3rho2tau1 = t1184 * t5 + 0.2e1 * t572;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 1] += tv3rho2tau1;

  t1186 = t357 * t26;
  t1189 = t574 * t549;
  t1193 = t574 * t27;
  t1200 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t1186 * t244 + 0.4621375276020952854e-3 * t1189 - 0.18485501104083811416e-2 * t574 * t553 - 0.18485501104083811416e-3 * t1193 * t558 + 0.4621375276020952854e-3 * t1139 - t1149 - 0.9242750552041905708e-3 * t1152 - 0.9242750552041905708e-4 * t1155);
  tv3rho2tau2 = t1200 * t5 + t562 + t578;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 2] += tv3rho2tau2;

  t1202 = t377 * t26;
  t1205 = t580 * t568;
  t1211 = t113 * t73 * t94;
  t1212 = t248 * t1211;
  t1214 = t564 * t27;
  t1217 = t248 * t113;
  t1218 = t1217 * t589;
  t1221 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t1202 * t250 + 0.4621375276020952854e-3 * t1205 + 0.4621375276020952854e-3 * t1177 - t1182 - 0.18485501104083811416e-2 * t564 * t584 - 0.9242750552041905708e-3 * t1212 - 0.18485501104083811416e-3 * t1214 * t589 - 0.9242750552041905708e-4 * t1218);
  tv3rho2tau3 = t1221 * t5 + t572 + t593;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 3] += tv3rho2tau3;

  t1224 = t404 * t26;
  t1229 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t1224 * t244 + 0.9242750552041905708e-3 * t1189 - t1149);
  tv3rho2tau4 = t1229 * t5 + 0.2e1 * t578;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 4] += tv3rho2tau4;

  t1232 = t420 * t26;
  t1238 = t580 * t27;
  t1244 = t27 * t183 * t94;
  t1249 = t86 * t455;
  t1250 = t1249 * t431;
  t1253 = t588 * t442;
  t1256 = 0.9242750552041905708e-3 * t1232 * t250 + 0.9242750552041905708e-3 * t1205 - 0.36971002208167622832e-2 * t580 * t584 - 0.36971002208167622832e-3 * t1238 * t589 - t1182 - 0.18485501104083811416e-2 * t1212 - 0.18485501104083811416e-3 * t1218 + 0.55456503312251434248e-2 * t248 * t1244 + 0.73942004416335245664e-3 * t587 * t529 + 0.22182601324900573699e-3 * t587 * t1250 - 0.18485501104083811416e-3 * t587 * t1253;
  t1257 = my_piecewise3(t61, 0, t1256);
  tv3rho2tau5 = t1257 * t5 + 0.2e1 * t593;

  if(out->v3rho2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rho2tau[ip*p->dim.v3rho2tau + 5] += tv3rho2tau5;

  t1261 = t114 * t606;
  t1263 = t25 * t1261 / 0.3e1;
  t1264 = t679 * t595;
  t1269 = t288 * t37;
  t1274 = t1006 * t215;
  t1276 = t1009 * t490;
  t1278 = t485 * t480;
  t1282 = t595 * t127;
  t1285 = t215 * t480;
  t1290 = t37 * t127;
  t1295 = -0.496e3 / 0.3375e4 * t1264 * t127 + 0.32e2 / 0.225e3 * t474 * t480 + 0.89642498730987350557e-4 * t1269 * t127 + 0.50423905536180384688e-3 * t119 * t124 + 0.13410486450604867789e-1 * t1274 + 0.53641945802419471157e-2 * t1276 - 0.44701621502016225964e-2 * t1278 + 0.12e2 / 0.125e3 * t703 * t595 - 0.132e3 / 0.625e3 * t710 * t1282 + 0.24e2 / 0.125e3 * t314 * t1285 - 0.10084781107236076938e-3 * t309 * t37 + 0.12101737328683292326e-3 * t314 * t1290 + 0.60508686643416461628e-3 * t138 * t124;
  t1296 = t28 * t1295;
  t1300 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t607 - t1263 - 0.2e1 / 0.3e1 * t25 * t1296);
  tv3rhosigma20 = t1300 * t5 + t610;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 0] += tv3rhosigma20;

  tv3rhosigma21 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 1] += tv3rhosigma21;

  tv3rhosigma22 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 2] += tv3rhosigma22;

  tv3rhosigma23 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 3] += tv3rhosigma23;

  tv3rhosigma24 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 4] += tv3rhosigma24;

  t1304 = t114 * t622;
  t1306 = t70 * t1304 / 0.3e1;
  t1308 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t623 - t1306);
  tv3rhosigma25 = t1308 * t5 + t626;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 5] += tv3rhosigma25;

  t1313 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t607 - t1263);
  tv3rhosigma26 = t1313 * t5 + t610;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 6] += tv3rhosigma26;

  tv3rhosigma27 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 7] += tv3rhosigma27;

  tv3rhosigma28 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 8] += tv3rhosigma28;

  tv3rhosigma29 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 9] += tv3rhosigma29;

  tv3rhosigma210 = 0.e0;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 10] += tv3rhosigma210;

  t1317 = t930 * t611;
  t1322 = t430 * t79;
  t1327 = t1103 * t230;
  t1329 = t1106 * t533;
  t1331 = t528 * t523;
  t1335 = t611 * t190;
  t1338 = t230 * t523;
  t1343 = t79 * t190;
  t1348 = -0.496e3 / 0.3375e4 * t1317 * t190 + 0.32e2 / 0.225e3 * t517 * t523 + 0.89642498730987350557e-4 * t1322 * t190 + 0.50423905536180384688e-3 * t182 * t187 + 0.13410486450604867789e-1 * t1327 + 0.53641945802419471157e-2 * t1329 - 0.44701621502016225964e-2 * t1331 + 0.12e2 / 0.125e3 * t954 * t611 - 0.132e3 / 0.625e3 * t961 * t1335 + 0.24e2 / 0.125e3 * t456 * t1338 - 0.10084781107236076938e-3 * t451 * t79 + 0.12101737328683292326e-3 * t456 * t1343 + 0.60508686643416461628e-3 * t201 * t187;
  t1349 = t28 * t1348;
  t1353 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t623 - t1306 - 0.2e1 / 0.3e1 * t70 * t1349);
  tv3rhosigma211 = t1353 * t5 + t626;

  if(out->v3rhosigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigma2[ip*p->dim.v3rhosigma2 + 11] += tv3rhosigma211;

  tv3rhosigmalapl0 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 0] += tv3rhosigmalapl0;

  tv3rhosigmalapl1 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 1] += tv3rhosigmalapl1;

  tv3rhosigmalapl2 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 2] += tv3rhosigmalapl2;

  tv3rhosigmalapl3 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 3] += tv3rhosigmalapl3;

  tv3rhosigmalapl4 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 4] += tv3rhosigmalapl4;

  tv3rhosigmalapl5 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 5] += tv3rhosigmalapl5;

  tv3rhosigmalapl6 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 6] += tv3rhosigmalapl6;

  tv3rhosigmalapl7 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 7] += tv3rhosigmalapl7;

  tv3rhosigmalapl8 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 8] += tv3rhosigmalapl8;

  tv3rhosigmalapl9 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 9] += tv3rhosigmalapl9;

  tv3rhosigmalapl10 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 10] += tv3rhosigmalapl10;

  tv3rhosigmalapl11 = 0.e0;

  if(out->v3rhosigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmalapl[ip*p->dim.v3rhosigmalapl + 11] += tv3rhosigmalapl11;

  t1358 = 0.9242750552041905708e-4 * t1154 * t627;
  t1361 = t1163 * t490;
  t1364 = t557 * t480;
  t1368 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t1143 * t627 - t1358 + 0.36971002208167622832e-3 * t556 * t600 + 0.22182601324900573699e-3 * t556 * t1361 - 0.18485501104083811416e-3 * t556 * t1364);
  tv3rhosigmatau0 = t1368 * t5 + t630;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 0] += tv3rhosigmatau0;

  tv3rhosigmatau1 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 1] += tv3rhosigmatau1;

  tv3rhosigmatau2 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 2] += tv3rhosigmatau2;

  tv3rhosigmatau3 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 3] += tv3rhosigmatau3;

  tv3rhosigmatau4 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 4] += tv3rhosigmatau4;

  t1373 = 0.9242750552041905708e-4 * t1217 * t631;
  t1375 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t1214 * t631 - t1373);
  tv3rhosigmatau5 = t1375 * t5 + t634;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 5] += tv3rhosigmatau5;

  t1380 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t1193 * t627 - t1358);
  tv3rhosigmatau6 = t1380 * t5 + t630;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 6] += tv3rhosigmatau6;

  tv3rhosigmatau7 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 7] += tv3rhosigmatau7;

  tv3rhosigmatau8 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 8] += tv3rhosigmatau8;

  tv3rhosigmatau9 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 9] += tv3rhosigmatau9;

  tv3rhosigmatau10 = 0.e0;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 10] += tv3rhosigmatau10;

  t1386 = t1249 * t533;
  t1389 = t588 * t523;
  t1393 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t1238 * t631 - t1373 + 0.36971002208167622832e-3 * t587 * t616 + 0.22182601324900573699e-3 * t587 * t1386 - 0.18485501104083811416e-3 * t587 * t1389);
  tv3rhosigmatau11 = t1393 * t5 + t634;

  if(out->v3rhosigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhosigmatau[ip*p->dim.v3rhosigmatau + 11] += tv3rhosigmatau11;

  tv3rholapl20 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 0] += tv3rholapl20;

  tv3rholapl21 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 1] += tv3rholapl21;

  tv3rholapl22 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 2] += tv3rholapl22;

  tv3rholapl23 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 3] += tv3rholapl23;

  tv3rholapl24 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 4] += tv3rholapl24;

  tv3rholapl25 = 0.e0;

  if(out->v3rholapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapl2[ip*p->dim.v3rholapl2 + 5] += tv3rholapl25;

  tv3rholapltau0 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 0] += tv3rholapltau0;

  tv3rholapltau1 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 1] += tv3rholapltau1;

  tv3rholapltau2 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 2] += tv3rholapltau2;

  tv3rholapltau3 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 3] += tv3rholapltau3;

  tv3rholapltau4 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 4] += tv3rholapltau4;

  tv3rholapltau5 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 5] += tv3rholapltau5;

  tv3rholapltau6 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 6] += tv3rholapltau6;

  tv3rholapltau7 = 0.e0;

  if(out->v3rholapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rholapltau[ip*p->dim.v3rholapltau + 7] += tv3rholapltau7;

  tv3rhotau20 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 0] += tv3rhotau20;

  tv3rhotau21 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 1] += tv3rhotau21;

  tv3rhotau22 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 2] += tv3rhotau22;

  tv3rhotau23 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 3] += tv3rhotau23;

  tv3rhotau24 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 4] += tv3rhotau24;

  tv3rhotau25 = 0.e0;

  if(out->v3rhotau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3rhotau2[ip*p->dim.v3rhotau2 + 5] += tv3rhotau25;

  t1395 = t595 * t215;
  t1400 = t1009 * t595;
  t1406 = t215 * t37;
  t1409 = -0.496e3 / 0.3375e4 * t679 * t1395 + 0.26892749619296205167e-3 * t474 * t37 + 0.80462918703629206735e-2 * t1400 - 0.84526137747440853736e-5 * t688 * t137 - 0.132e3 / 0.625e3 * t710 * t1395 + 0.36305211986049876976e-3 * t314 * t1406;
  t1410 = t28 * t1409;
  t1413 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t1410);
  tv3sigma30 = t5 * t1413;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 0] += tv3sigma30;

  tv3sigma31 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 1] += tv3sigma31;

  tv3sigma32 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 2] += tv3sigma32;

  tv3sigma33 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 3] += tv3sigma33;

  tv3sigma34 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 4] += tv3sigma34;

  tv3sigma35 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 5] += tv3sigma35;

  tv3sigma36 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 6] += tv3sigma36;

  tv3sigma37 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 7] += tv3sigma37;

  tv3sigma38 = 0.e0;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 8] += tv3sigma38;

  t1414 = t611 * t230;
  t1419 = t1106 * t611;
  t1425 = t230 * t79;
  t1428 = -0.496e3 / 0.3375e4 * t930 * t1414 + 0.26892749619296205167e-3 * t517 * t79 + 0.80462918703629206735e-2 * t1419 - 0.84526137747440853736e-5 * t939 * t200 - 0.132e3 / 0.625e3 * t961 * t1414 + 0.36305211986049876976e-3 * t456 * t1425;
  t1429 = t28 * t1428;
  t1432 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t1429);
  tv3sigma39 = t5 * t1432;

  if(out->v3sigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma3[ip*p->dim.v3sigma3 + 9] += tv3sigma39;

  tv3sigma2lapl0 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 0] += tv3sigma2lapl0;

  tv3sigma2lapl1 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 1] += tv3sigma2lapl1;

  tv3sigma2lapl2 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 2] += tv3sigma2lapl2;

  tv3sigma2lapl3 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 3] += tv3sigma2lapl3;

  tv3sigma2lapl4 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 4] += tv3sigma2lapl4;

  tv3sigma2lapl5 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 5] += tv3sigma2lapl5;

  tv3sigma2lapl6 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 6] += tv3sigma2lapl6;

  tv3sigma2lapl7 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 7] += tv3sigma2lapl7;

  tv3sigma2lapl8 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 8] += tv3sigma2lapl8;

  tv3sigma2lapl9 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 9] += tv3sigma2lapl9;

  tv3sigma2lapl10 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 10] += tv3sigma2lapl10;

  tv3sigma2lapl11 = 0.e0;

  if(out->v3sigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2lapl[ip*p->dim.v3sigma2lapl + 11] += tv3sigma2lapl11;

  t1433 = t1163 * t595;
  t1437 = t27 * t297 * t137;
  t1441 = my_piecewise3(t2, 0, 0.22182601324900573699e-3 * t556 * t1433 - 0.233027790365320078e-6 * t242 * t1437);
  tv3sigma2tau0 = t5 * t1441;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 0] += tv3sigma2tau0;

  tv3sigma2tau1 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 1] += tv3sigma2tau1;

  tv3sigma2tau2 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 2] += tv3sigma2tau2;

  tv3sigma2tau3 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 3] += tv3sigma2tau3;

  tv3sigma2tau4 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 4] += tv3sigma2tau4;

  tv3sigma2tau5 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 5] += tv3sigma2tau5;

  tv3sigma2tau6 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 6] += tv3sigma2tau6;

  tv3sigma2tau7 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 7] += tv3sigma2tau7;

  tv3sigma2tau8 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 8] += tv3sigma2tau8;

  tv3sigma2tau9 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 9] += tv3sigma2tau9;

  tv3sigma2tau10 = 0.e0;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 10] += tv3sigma2tau10;

  t1442 = t1249 * t611;
  t1446 = t27 * t439 * t200;
  t1450 = my_piecewise3(t61, 0, 0.22182601324900573699e-3 * t587 * t1442 - 0.233027790365320078e-6 * t248 * t1446);
  tv3sigma2tau11 = t5 * t1450;

  if(out->v3sigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigma2tau[ip*p->dim.v3sigma2tau + 11] += tv3sigma2tau11;

  tv3sigmalapl20 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 0] += tv3sigmalapl20;

  tv3sigmalapl21 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 1] += tv3sigmalapl21;

  tv3sigmalapl22 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 2] += tv3sigmalapl22;

  tv3sigmalapl23 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 3] += tv3sigmalapl23;

  tv3sigmalapl24 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 4] += tv3sigmalapl24;

  tv3sigmalapl25 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 5] += tv3sigmalapl25;

  tv3sigmalapl26 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 6] += tv3sigmalapl26;

  tv3sigmalapl27 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 7] += tv3sigmalapl27;

  tv3sigmalapl28 = 0.e0;

  if(out->v3sigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapl2[ip*p->dim.v3sigmalapl2 + 8] += tv3sigmalapl28;

  tv3sigmalapltau0 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 0] += tv3sigmalapltau0;

  tv3sigmalapltau1 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 1] += tv3sigmalapltau1;

  tv3sigmalapltau2 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 2] += tv3sigmalapltau2;

  tv3sigmalapltau3 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 3] += tv3sigmalapltau3;

  tv3sigmalapltau4 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 4] += tv3sigmalapltau4;

  tv3sigmalapltau5 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 5] += tv3sigmalapltau5;

  tv3sigmalapltau6 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 6] += tv3sigmalapltau6;

  tv3sigmalapltau7 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 7] += tv3sigmalapltau7;

  tv3sigmalapltau8 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 8] += tv3sigmalapltau8;

  tv3sigmalapltau9 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 9] += tv3sigmalapltau9;

  tv3sigmalapltau10 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 10] += tv3sigmalapltau10;

  tv3sigmalapltau11 = 0.e0;

  if(out->v3sigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmalapltau[ip*p->dim.v3sigmalapltau + 11] += tv3sigmalapltau11;

  tv3sigmatau20 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 0] += tv3sigmatau20;

  tv3sigmatau21 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 1] += tv3sigmatau21;

  tv3sigmatau22 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 2] += tv3sigmatau22;

  tv3sigmatau23 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 3] += tv3sigmatau23;

  tv3sigmatau24 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 4] += tv3sigmatau24;

  tv3sigmatau25 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 5] += tv3sigmatau25;

  tv3sigmatau26 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 6] += tv3sigmatau26;

  tv3sigmatau27 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 7] += tv3sigmatau27;

  tv3sigmatau28 = 0.e0;

  if(out->v3sigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3sigmatau2[ip*p->dim.v3sigmatau2 + 8] += tv3sigmatau28;

  tv3lapl30 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 0] += tv3lapl30;

  tv3lapl31 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 1] += tv3lapl31;

  tv3lapl32 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 2] += tv3lapl32;

  tv3lapl33 = 0.e0;

  if(out->v3lapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl3[ip*p->dim.v3lapl3 + 3] += tv3lapl33;

  tv3lapl2tau0 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 0] += tv3lapl2tau0;

  tv3lapl2tau1 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 1] += tv3lapl2tau1;

  tv3lapl2tau2 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 2] += tv3lapl2tau2;

  tv3lapl2tau3 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 3] += tv3lapl2tau3;

  tv3lapl2tau4 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 4] += tv3lapl2tau4;

  tv3lapl2tau5 = 0.e0;

  if(out->v3lapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapl2tau[ip*p->dim.v3lapl2tau + 5] += tv3lapl2tau5;

  tv3lapltau20 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 0] += tv3lapltau20;

  tv3lapltau21 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 1] += tv3lapltau21;

  tv3lapltau22 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 2] += tv3lapltau22;

  tv3lapltau23 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 3] += tv3lapltau23;

  tv3lapltau24 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 4] += tv3lapltau24;

  tv3lapltau25 = 0.e0;

  if(out->v3lapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3lapltau2[ip*p->dim.v3lapltau2 + 5] += tv3lapltau25;

  tv3tau30 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 0] += tv3tau30;

  tv3tau31 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 1] += tv3tau31;

  tv3tau32 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 2] += tv3tau32;

  tv3tau33 = 0.e0;

  if(out->v3tau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_KXC))
    out->v3tau3[ip*p->dim.v3tau3 + 3] += tv3tau33;

  t1453 = t654 * t115;
  t1455 = t270 * t280;
  t1456 = t110 * t669;
  t1459 = t26 / t27 / t260;
  t1462 = 0.5e1 / 0.8e1 * t25 * t1459 * t56;
  t1465 = t110 * t672;
  t1467 = t110 * t675;
  t1472 = t25 * t668 * t141;
  t1474 = t25 * t279 * t319;
  t1476 = t25 * t114 * t718;
  t1480 = 0.1e1 / t296 / t29;
  t1483 = 0.14851066049790937571e3 * t478 + 0.19060236292676185411e1 * t34 * t1480;
  t1494 = t286 * t286;
  t1496 = 0.1e1 / t41 / t1494;
  t1497 = t289 * t289;
  t1503 = t300 * t300;
  t1508 = t697 * t137;
  t1515 = t306 * t313;
  t1518 = t133 * t709;
  t1525 = t51 / t52 / t1494;
  t1536 = -t119 * t1483 / 0.15e2 + 0.2e1 / 0.5e1 * (0.10057864837953650842e2 * t478 - 0.73720569640165919525e0 * tau[0] * t37) * t53 - 0.2e1 / 0.25e2 * t138 * t1483 + 0.22816e5 / 0.50625e5 * t1496 * t1497 - 0.992e3 / 0.1125e4 * t679 * t289 * t300 + 0.16e2 / 0.75e2 * t288 * t1503 + 0.64e2 / 0.225e3 * t683 * t691 - 0.8e1 / 0.25e2 * t1508 * t127 - 0.12e2 / 0.25e2 * t700 * t300 - 0.8e1 / 0.25e2 * t309 * t691 + 0.72e2 / 0.125e3 * t1515 * t289 - 0.528e3 / 0.625e3 * t1518 * t680 + 0.144e3 / 0.125e3 * t703 * t713 + 0.2112e4 / 0.3125e4 * t1525 * t1497 - 0.792e3 / 0.625e3 * t710 * t289 * t300 + 0.36e2 / 0.125e3 * t314 * t1503 + 0.48e2 / 0.125e3 * t314 * t127 * t691;
  t1540 = t18 * t18;
  t1542 = 0.1e1 / t22 / t1540;
  t1543 = t257 * t257;
  t1549 = t265 * t265;
  t1555 = 0.1e1 / t644 / t5;
  t1556 = t15 * t1555;
  t1559 = my_piecewise5(t9, 0, t13, 0, -0.24e2 * t645 + 0.24e2 * t1556);
  t1563 = my_piecewise3(t19, 0, 0.9e1 / 0.16e2 * t1542 * t1543 - 0.9e1 / 0.4e1 * t637 * t257 * t265 + 0.9e1 / 0.4e1 * t256 * t1549 + 0.3e1 * t641 * t649 + 0.3e1 / 0.2e1 * t22 * t1559);
  t1569 = t270 * t283;
  t1571 = -0.4e1 / 0.3e1 * t1453 + t1455 - t1456 + t1462 - 0.4e1 * t270 * t320 + 0.2e1 * t1465 - 0.4e1 * t1467 - 0.8e1 / 0.3e1 * t110 * t719 - t1472 + t1474 - 0.4e1 / 0.3e1 * t1476 - 0.2e1 / 0.3e1 * t25 * t28 * t1536 - 0.2e1 / 0.3e1 * t4 * t1563 * t57 - 0.8e1 / 0.3e1 * t654 * t142 - 0.4e1 * t1569;
  t1572 = my_piecewise3(t2, 0, t1571);
  t1573 = t65 * t65;
  t1575 = 0.1e1 / t67 / t1573;
  t1576 = t326 * t326;
  t1582 = t332 * t332;
  t1587 = t62 * t1555;
  t1590 = my_piecewise5(t13, 0, t9, 0, 0.24e2 * t645 + 0.24e2 * t1587);
  t1594 = my_piecewise3(t66, 0, 0.9e1 / 0.16e2 * t1575 * t1576 - 0.9e1 / 0.4e1 * t724 * t326 * t332 + 0.9e1 / 0.4e1 * t325 * t1582 + 0.3e1 * t728 * t734 + 0.3e1 / 0.2e1 * t67 * t1590);
  t1598 = t739 * t156;
  t1600 = t337 * t342;
  t1601 = t153 * t745;
  t1604 = 0.5e1 / 0.8e1 * t70 * t1459 * t97;
  t1606 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t4 * t1594 * t98 - 0.4e1 / 0.3e1 * t1598 + t1600 - t1601 + t1604);
  tv4rho40 = 0.4e1 * t723 + 0.4e1 * t749 + t5 * (t1572 + t1606);

  if(out->v4rho4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho4[ip*p->dim.v4rho4 + 0] += tv4rho40;

  t1611 = t770 * t115;
  t1612 = t358 * t280;
  t1613 = t1612 / 0.2e1;
  t1614 = t168 * t669;
  t1621 = t168 * t672;
  t1622 = t1621 / 0.2e1;
  t1623 = t168 * t675;
  t1642 = 0.12e2 * t645;
  t1643 = 0.24e2 * t1556;
  t1645 = my_piecewise5(t9, 0, t13, 0, -t1642 + t1643);
  t1649 = my_piecewise3(t19, 0, 0.9e1 / 0.16e2 * t1542 * t164 * t638 - 0.9e1 / 0.8e1 * t637 * t353 * t257 - 0.9e1 / 0.8e1 * t754 * t106 * t265 + 0.9e1 / 0.4e1 * t256 * t765 * t106 + 0.9e1 / 0.4e1 * t757 * t265 + 0.3e1 / 0.4e1 * t349 * t649 + 0.3e1 / 0.2e1 * t22 * t1645);
  t1655 = t358 * t283;
  t1660 = -t1611 + t1613 - t1614 / 0.4e1 - t1453 / 0.3e1 + t1455 / 0.2e1 - 0.3e1 / 0.4e1 * t1456 + t1462 - 0.2e1 * t358 * t320 + t1622 - t1623 - 0.2e1 / 0.3e1 * t168 * t719 - 0.2e1 / 0.3e1 * t4 * t1649 * t57 - 0.2e1 * t770 * t142 - 0.2e1 * t1655 + t1465 - t1467 - 0.3e1 / 0.4e1 * t1472 + t1474 / 0.2e1 - t1476 / 0.3e1 - t1569;
  t1661 = my_piecewise3(t2, 0, t1660);
  t1678 = 0.24e2 * t1587;
  t1680 = my_piecewise5(t13, 0, t9, 0, t1642 + t1678);
  t1684 = my_piecewise3(t66, 0, 0.9e1 / 0.16e2 * t1575 * t174 * t725 - 0.9e1 / 0.8e1 * t724 * t373 * t326 - 0.9e1 / 0.8e1 * t790 * t149 * t332 + 0.9e1 / 0.4e1 * t325 * t800 * t149 + 0.9e1 / 0.4e1 * t793 * t332 + 0.3e1 / 0.4e1 * t369 * t734 + 0.3e1 / 0.2e1 * t67 * t1680);
  t1688 = t805 * t156;
  t1689 = t378 * t342;
  t1690 = t1689 / 0.2e1;
  t1691 = t178 * t745;
  t1698 = t337 * t386;
  t1699 = t153 * t818;
  t1700 = t1699 / 0.2e1;
  t1702 = t70 * t668 * t204;
  t1704 = -0.2e1 / 0.3e1 * t4 * t1684 * t98 - t1688 + t1690 - t1691 / 0.4e1 - t1598 / 0.3e1 + t1600 / 0.2e1 - 0.3e1 / 0.4e1 * t1601 + t1604 - 0.2e1 / 0.3e1 * t739 * t205 - t1698 + t1700 - t1702 / 0.4e1;
  t1705 = my_piecewise3(t61, 0, t1704);
  tv4rho41 = t723 + t749 + 0.3e1 * t789 + 0.3e1 * t822 + t5 * (t1661 + t1705);

  if(out->v4rho4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho4[ip*p->dim.v4rho4 + 1] += tv4rho41;

  t1712 = t839 * t115;
  t1714 = t405 * t280;
  t1729 = t353 * t353;
  t1742 = my_piecewise5(t9, 0, t13, 0, t1643);
  t1746 = my_piecewise3(t19, 0, 0.9e1 / 0.16e2 * t1542 * t395 * t257 - 0.3e1 / 0.2e1 * t754 * t106 * t353 - 0.3e1 / 0.8e1 * t825 * t265 + 0.3e1 / 0.2e1 * t256 * t1729 + 0.3e1 / 0.2e1 * t349 * t765 - 0.3e1 / 0.8e1 * t637 * t400 * t257 + 0.3e1 / 0.2e1 * t256 * t834 * t106 + 0.3e1 / 0.4e1 * t830 * t265 + 0.3e1 / 0.2e1 * t22 * t1742);
  t1752 = t405 * t283;
  t1762 = -0.2e1 / 0.3e1 * t1712 + t1714 / 0.6e1 - 0.2e1 / 0.3e1 * t1611 + 0.2e1 / 0.3e1 * t1612 - t1614 / 0.2e1 + t1455 / 0.6e1 - t1456 / 0.2e1 + t1462 - 0.2e1 / 0.3e1 * t4 * t1746 * t57 - 0.4e1 / 0.3e1 * t839 * t142 - 0.2e1 / 0.3e1 * t1752 - 0.2e1 / 0.3e1 * t405 * t320 + 0.2e1 / 0.3e1 * t1621 - 0.2e1 / 0.3e1 * t1623 - 0.4e1 / 0.3e1 * t1655 + t1465 / 0.3e1 - t1472 / 0.2e1 + t1474 / 0.6e1;
  t1763 = my_piecewise3(t2, 0, t1762);
  t1772 = t373 * t373;
  t1785 = my_piecewise5(t13, 0, t9, 0, t1678);
  t1789 = my_piecewise3(t66, 0, 0.9e1 / 0.16e2 * t1575 * t411 * t326 - 0.3e1 / 0.2e1 * t790 * t149 * t373 - 0.3e1 / 0.8e1 * t851 * t332 + 0.3e1 / 0.2e1 * t325 * t1772 + 0.3e1 / 0.2e1 * t369 * t800 - 0.3e1 / 0.8e1 * t724 * t416 * t326 + 0.3e1 / 0.2e1 * t325 * t860 * t149 + 0.3e1 / 0.4e1 * t856 * t332 + 0.3e1 / 0.2e1 * t67 * t1785);
  t1793 = t865 * t156;
  t1795 = t421 * t342;
  t1802 = t378 * t386;
  t1804 = t178 * t818;
  t1813 = t153 * t879;
  t1816 = t70 * t279 * t461;
  t1818 = -0.2e1 / 0.3e1 * t4 * t1789 * t98 - 0.2e1 / 0.3e1 * t1793 + t1795 / 0.6e1 - 0.2e1 / 0.3e1 * t1688 + 0.2e1 / 0.3e1 * t1689 - t1691 / 0.2e1 - 0.4e1 / 0.3e1 * t805 * t205 - 0.4e1 / 0.3e1 * t1802 + t1804 / 0.3e1 + t1600 / 0.6e1 - t1601 / 0.2e1 + t1604 - 0.2e1 / 0.3e1 * t1698 + 0.2e1 / 0.3e1 * t1699 - t1702 / 0.2e1 - 0.2e1 / 0.3e1 * t337 * t462 - 0.2e1 / 0.3e1 * t1813 + t1816 / 0.6e1;
  t1819 = my_piecewise3(t61, 0, t1818);
  tv4rho42 = 0.2e1 * t789 + 0.2e1 * t822 + 0.2e1 * t850 + 0.2e1 * t883 + t5 * (t1763 + t1819);

  if(out->v4rho4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho4[ip*p->dim.v4rho4 + 2] += tv4rho42;

  t1840 = my_piecewise5(t9, 0, t13, 0, t1642 + t1643);
  t1844 = my_piecewise3(t19, 0, 0.9e1 / 0.16e2 * t1542 * t888 * t106 - 0.9e1 / 0.8e1 * t825 * t353 - 0.9e1 / 0.8e1 * t754 * t400 * t106 + 0.9e1 / 0.4e1 * t757 * t400 + 0.9e1 / 0.4e1 * t349 * t834 + 0.3e1 / 0.4e1 * t256 * t895 * t106 + 0.3e1 / 0.2e1 * t22 * t1840);
  t1848 = t900 * t115;
  t1856 = -0.2e1 / 0.3e1 * t4 * t1844 * t57 - t1848 / 0.3e1 - 0.2e1 / 0.3e1 * t900 * t142 - t1712 + t1714 / 0.2e1 - t1752 + t1613 - 0.3e1 / 0.4e1 * t1614 + t1622 - t1456 / 0.4e1 + t1462 - t1472 / 0.4e1;
  t1857 = my_piecewise3(t2, 0, t1856);
  t1874 = my_piecewise5(t13, 0, t9, 0, -t1642 + t1678);
  t1878 = my_piecewise3(t66, 0, 0.9e1 / 0.16e2 * t1575 * t906 * t149 - 0.9e1 / 0.8e1 * t851 * t373 - 0.9e1 / 0.8e1 * t790 * t416 * t149 + 0.9e1 / 0.4e1 * t793 * t416 + 0.9e1 / 0.4e1 * t369 * t860 + 0.3e1 / 0.4e1 * t325 * t913 * t149 + 0.3e1 / 0.2e1 * t67 * t1874);
  t1882 = t918 * t156;
  t1887 = t421 * t386;
  t1892 = t178 * t879;
  t1899 = t70 * t114 * t969;
  t1901 = -0.2e1 / 0.3e1 * t4 * t1878 * t98 - t1882 / 0.3e1 - t1793 + t1795 / 0.2e1 - 0.2e1 * t865 * t205 - t1887 + t1690 - 0.3e1 / 0.4e1 * t1691 - 0.2e1 * t1802 + t1804 - 0.2e1 * t378 * t462 - t1892 - t1601 / 0.4e1 + t1604 + t1700 - 0.3e1 / 0.4e1 * t1702 - t1813 + t1816 / 0.2e1 - 0.2e1 / 0.3e1 * t153 * t970 - t1899 / 0.3e1;
  t1902 = my_piecewise3(t61, 0, t1901);
  tv4rho43 = 0.3e1 * t850 + 0.3e1 * t883 + t905 + t974 + t5 * (t1857 + t1902);

  if(out->v4rho4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho4[ip*p->dim.v4rho4 + 3] += tv4rho43;

  t1907 = t395 * t395;
  t1912 = t400 * t400;
  t1919 = my_piecewise5(t9, 0, t13, 0, 0.24e2 * t645 + 0.24e2 * t1556);
  t1923 = my_piecewise3(t19, 0, 0.9e1 / 0.16e2 * t1542 * t1907 - 0.9e1 / 0.4e1 * t825 * t400 + 0.9e1 / 0.4e1 * t256 * t1912 + 0.3e1 * t349 * t895 + 0.3e1 / 0.2e1 * t22 * t1919);
  t1929 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t4 * t1923 * t57 - 0.4e1 / 0.3e1 * t1848 + t1714 - t1614 + t1462);
  t1938 = 0.1e1 / t438 / t71;
  t1941 = 0.14851066049790937571e3 * t521 + 0.19060236292676185411e1 * t76 * t1938;
  t1952 = t428 * t428;
  t1954 = 0.1e1 / t83 / t1952;
  t1955 = t431 * t431;
  t1961 = t442 * t442;
  t1966 = t948 * t200;
  t1973 = t448 * t455;
  t1976 = t196 * t960;
  t1983 = t92 / t93 / t1952;
  t1994 = -t182 * t1941 / 0.15e2 + 0.2e1 / 0.5e1 * (0.10057864837953650842e2 * t521 - 0.73720569640165919525e0 * tau[1] * t79) * t94 - 0.2e1 / 0.25e2 * t201 * t1941 + 0.22816e5 / 0.50625e5 * t1954 * t1955 - 0.992e3 / 0.1125e4 * t930 * t431 * t442 + 0.16e2 / 0.75e2 * t430 * t1961 + 0.64e2 / 0.225e3 * t934 * t942 - 0.8e1 / 0.25e2 * t1966 * t190 - 0.12e2 / 0.25e2 * t951 * t442 - 0.8e1 / 0.25e2 * t451 * t942 + 0.72e2 / 0.125e3 * t1973 * t431 - 0.528e3 / 0.625e3 * t1976 * t931 + 0.144e3 / 0.125e3 * t954 * t964 + 0.2112e4 / 0.3125e4 * t1983 * t1955 - 0.792e3 / 0.625e3 * t961 * t431 * t442 + 0.36e2 / 0.125e3 * t456 * t1961 + 0.48e2 / 0.125e3 * t456 * t190 * t942;
  t1998 = t411 * t411;
  t2003 = t416 * t416;
  t2010 = my_piecewise5(t13, 0, t9, 0, -0.24e2 * t645 + 0.24e2 * t1587);
  t2014 = my_piecewise3(t66, 0, 0.9e1 / 0.16e2 * t1575 * t1998 - 0.9e1 / 0.4e1 * t851 * t416 + 0.9e1 / 0.4e1 * t325 * t2003 + 0.3e1 * t369 * t913 + 0.3e1 / 0.2e1 * t67 * t2010);
  t2023 = -0.4e1 / 0.3e1 * t1882 - 0.4e1 * t1887 - 0.4e1 * t1892 - 0.4e1 / 0.3e1 * t1899 - 0.8e1 / 0.3e1 * t178 * t970 - 0.2e1 / 0.3e1 * t70 * t28 * t1994 - 0.2e1 / 0.3e1 * t4 * t2014 * t98 - 0.8e1 / 0.3e1 * t918 * t205 - 0.4e1 * t421 * t462 + t1816 + t1795 + 0.2e1 * t1804 - t1691 - t1702 + t1604;
  t2024 = my_piecewise3(t61, 0, t2023);
  tv4rho44 = 0.4e1 * t905 + 0.4e1 * t974 + t5 * (t1929 + t2024);

  if(out->v4rho4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho4[ip*p->dim.v4rho4 + 4] += tv4rho44;

  t2030 = t270 * t471;
  t2033 = t110 * t984;
  t2035 = t110 * t987;
  t2041 = t25 * t668 * t222 / 0.4e1;
  t2043 = t25 * t279 * t495;
  t2046 = t25 * t114 * t1031;
  t2083 = -0.396e3 / 0.625e3 * t710 * t490 * t300 - 0.396e3 / 0.625e3 * t1518 * t1020 + 0.2112e4 / 0.3125e4 * t1525 * t215 * t680 + 0.80462918703629206734e-2 * t1009 * t713 + 0.36e2 / 0.125e3 * t1515 * t490 + 0.72e2 / 0.125e3 * t703 * t1023 + 0.36e2 / 0.125e3 * t703 * t1026 - 0.396e3 / 0.625e3 * t710 * t480 * t289 + 0.36e2 / 0.125e3 * t314 * t1001 * t127 + 0.36e2 / 0.125e3 * t314 * t480 * t300 + 0.12e2 / 0.125e3 * t314 * t215 * t691 - 0.496e3 / 0.1125e4 * t990 * t713 - 0.496e3 / 0.1125e4 * t679 * t480 * t289 + 0.16e2 / 0.75e2 * t288 * t1001 * t127;
  t2088 = t293 * t137;
  t2104 = -0.24751776749651562618e2 * t37 - 0.42356080650391523138e0 * sigma[0] * t688;
  t2110 = t120 * t313;
  t2113 = t31 * t709;
  t2120 = 0.16e2 / 0.75e2 * t993 * t300 + 0.16e2 / 0.225e3 * t474 * t691 - 0.80462918703629206734e-1 * t2088 * t127 + 0.20115729675907301684e-1 * t1006 * t300 - 0.22350810751008112982e-2 * t485 * t691 - 0.2e1 / 0.25e2 * t1508 * t215 - 0.6e1 / 0.25e2 * t700 * t480 - 0.6e1 / 0.25e2 * t309 * t1001 - 0.2e1 / 0.25e2 * t138 * t2104 + 0.22816e5 / 0.50625e5 * t1496 * t215 * t680 - 0.2413887561108876202e-1 * t2110 * t289 - 0.59006140382661418272e-2 * t2113 * t680 - 0.67052432253024338945e0 * t37 * t53 - t119 * t2104 / 0.15e2;
  t2126 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t654 * t223 - t2030 - 0.2e1 * t270 * t496 + t2033 / 0.2e1 - 0.2e1 * t2035 - 0.2e1 * t110 * t1032 - t2041 + t2043 / 0.2e1 - t2046 - 0.2e1 / 0.3e1 * t25 * t28 * (t2083 + t2120));
  tv4rho3sigma0 = t2126 * t5 + 0.3e1 * t1036;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 0] += tv4rho3sigma0;

  tv4rho3sigma1 = 0.e0;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 1] += tv4rho3sigma1;

  t2131 = t337 * t504;
  t2132 = t153 * t1043;
  t2136 = t70 * t668 * t237 / 0.4e1;
  t2138 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t739 * t238 - t2131 + t2132 / 0.2e1 - t2136);
  tv4rho3sigma2 = t2138 * t5 + 0.3e1 * t1047;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 2] += tv4rho3sigma2;

  t2140 = 0.2e1 * t1058;
  t2144 = 0.2e1 / 0.3e1 * t358 * t471;
  t2147 = t168 * t984;
  t2150 = 0.2e1 / 0.3e1 * t168 * t987;
  t2158 = -0.2e1 / 0.3e1 * t770 * t223 - t2144 - 0.4e1 / 0.3e1 * t358 * t496 + t2147 / 0.6e1 - t2150 - 0.2e1 / 0.3e1 * t168 * t1032 - t2030 / 0.3e1 + t2033 / 0.3e1 - 0.2e1 / 0.3e1 * t2035 - t2041 + t2043 / 0.3e1 - t2046 / 0.3e1;
  t2159 = my_piecewise3(t2, 0, t2158);
  tv4rho3sigma3 = t2159 * t5 + t1036 + t2140;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 3] += tv4rho3sigma3;

  tv4rho3sigma4 = 0.e0;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 4] += tv4rho3sigma4;

  t2161 = 0.2e1 * t1071;
  t2165 = 0.2e1 / 0.3e1 * t378 * t504;
  t2166 = t178 * t1043;
  t2173 = 0.2e1 / 0.3e1 * t153 * t1067;
  t2175 = t70 * t279 * t538;
  t2178 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t805 * t238 - t2165 + t2166 / 0.6e1 - t2131 / 0.3e1 + t2132 / 0.3e1 - t2136 - 0.2e1 / 0.3e1 * t337 * t539 - t2173 + t2175 / 0.6e1);
  tv4rho3sigma5 = t2178 * t5 + t1047 + t2161;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 5] += tv4rho3sigma5;

  t2182 = t405 * t471;
  t2190 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t839 * t223 - t2182 / 0.3e1 - 0.2e1 / 0.3e1 * t405 * t496 - t2144 + t2147 / 0.3e1 - t2150 + t2033 / 0.6e1 - t2041 + t2043 / 0.6e1);
  tv4rho3sigma6 = t2190 * t5 + t1078 + t2140;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 6] += tv4rho3sigma6;

  tv4rho3sigma7 = 0.e0;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 7] += tv4rho3sigma7;

  t2194 = t421 * t504;
  t2199 = t178 * t1067;
  t2206 = t70 * t114 * t1128;
  t2208 = -0.2e1 / 0.3e1 * t865 * t238 - t2194 / 0.3e1 - t2165 + t2166 / 0.3e1 - 0.4e1 / 0.3e1 * t378 * t539 - 0.2e1 / 0.3e1 * t2199 + t2132 / 0.6e1 - t2136 - t2173 + t2175 / 0.3e1 - 0.2e1 / 0.3e1 * t153 * t1129 - t2206 / 0.3e1;
  t2209 = my_piecewise3(t61, 0, t2208);
  tv4rho3sigma8 = t2209 * t5 + t1133 + t2161;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 8] += tv4rho3sigma8;

  t2216 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t900 * t223 - t2182 + t2147 / 0.2e1 - t2041);
  tv4rho3sigma9 = t2216 * t5 + 0.3e1 * t1078;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 9] += tv4rho3sigma9;

  tv4rho3sigma10 = 0.e0;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 10] += tv4rho3sigma10;

  t2261 = t183 * t455;
  t2264 = -0.396e3 / 0.625e3 * t961 * t533 * t442 - 0.396e3 / 0.625e3 * t1976 * t1117 + 0.2112e4 / 0.3125e4 * t1983 * t230 * t931 + 0.36e2 / 0.125e3 * t1973 * t533 + 0.72e2 / 0.125e3 * t954 * t1120 + 0.36e2 / 0.125e3 * t954 * t1123 - 0.396e3 / 0.625e3 * t961 * t523 * t431 + 0.36e2 / 0.125e3 * t456 * t1098 * t190 + 0.36e2 / 0.125e3 * t456 * t523 * t442 + 0.12e2 / 0.125e3 * t456 * t230 * t942 - 0.496e3 / 0.1125e4 * t1087 * t964 + 0.80462918703629206734e-2 * t1106 * t964 + 0.22816e5 / 0.50625e5 * t1954 * t230 * t931 - 0.2413887561108876202e-1 * t2261 * t431;
  t2265 = t73 * t960;
  t2268 = t435 * t200;
  t2284 = -0.24751776749651562618e2 * t79 - 0.42356080650391523138e0 * sigma[2] * t939;
  t2301 = -0.59006140382661418272e-2 * t2265 * t931 - 0.80462918703629206734e-1 * t2268 * t190 + 0.20115729675907301684e-1 * t1103 * t442 - 0.22350810751008112982e-2 * t528 * t942 - 0.2e1 / 0.25e2 * t1966 * t230 - 0.6e1 / 0.25e2 * t951 * t523 - 0.6e1 / 0.25e2 * t451 * t1098 - 0.2e1 / 0.25e2 * t201 * t2284 - 0.496e3 / 0.1125e4 * t930 * t523 * t431 + 0.16e2 / 0.75e2 * t430 * t1098 * t190 + 0.16e2 / 0.75e2 * t1090 * t442 + 0.16e2 / 0.225e3 * t517 * t942 - t182 * t2284 / 0.15e2 - 0.67052432253024338945e0 * t79 * t94;
  t2307 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t918 * t238 - t2194 - 0.2e1 * t421 * t539 + t2166 / 0.2e1 - 0.2e1 * t2199 - 0.2e1 * t178 * t1129 - t2136 + t2175 / 0.2e1 - t2206 - 0.2e1 / 0.3e1 * t70 * t28 * (t2264 + t2301));
  tv4rho3sigma11 = t2307 * t5 + 0.3e1 * t1133;

  if(out->v4rho3sigma != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3sigma[ip*p->dim.v4rho3sigma + 11] += tv4rho3sigma11;

  tv4rho3lapl0 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 0] += tv4rho3lapl0;

  tv4rho3lapl1 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 1] += tv4rho3lapl1;

  tv4rho3lapl2 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 2] += tv4rho3lapl2;

  tv4rho3lapl3 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 3] += tv4rho3lapl3;

  tv4rho3lapl4 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 4] += tv4rho3lapl4;

  tv4rho3lapl5 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 5] += tv4rho3lapl5;

  tv4rho3lapl6 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 6] += tv4rho3lapl6;

  tv4rho3lapl7 = 0.e0;

  if(out->v4rho3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3lapl[ip*p->dim.v4rho3lapl + 7] += tv4rho3lapl7;

  t2310 = t545 * t1147;
  t2312 = t545 * t1151;
  t2319 = 0.34660314570157146405e-3 * t242 * t667 * t44 * t53;
  t2322 = t242 * t278 * t31 * t53;
  t2326 = t242 * t113 * t120 * t53;
  t2332 = t1136 * t549;
  t2339 = t545 * t113;
  t2340 = t2339 * t558;
  t2344 = -0.6932062914031429281e-3 * t2310 - 0.55456503312251434248e-2 * t2312 + 0.16636950993675430275e-1 * t545 * t1158 + t2319 + 0.13864125828062858562e-2 * t2322 + 0.83184754968377151372e-2 * t2326 - 0.22182601324900573699e-1 * t242 * t27 * t293 * t53 + 0.13864125828062858562e-2 * t2332 - 0.55456503312251434248e-2 * t1136 * t553 + 0.9242750552041905708e-3 * t653 * t26 * t244 - 0.55456503312251434248e-3 * t2340 + 0.22182601324900573699e-2 * t1143 * t486;
  t2347 = t242 * t278;
  t2348 = t2347 * t558;
  t2350 = t1154 * t486;
  t2352 = t1154 * t1167;
  t2361 = t1136 * t27;
  t2364 = t1154 * t1164;
  t2368 = t44 * t709;
  t2377 = -0.55456503312251434248e-3 * t1143 * t1167 + 0.13864125828062858562e-3 * t2348 + 0.1109130066245028685e-2 * t2350 - 0.27728251656125717124e-3 * t2352 - 0.33273901987350860549e-2 * t556 * t1007 + 0.1109130066245028685e-2 * t556 * t1012 - 0.18485501104083811416e-3 * t556 * t557 * t691 - 0.55456503312251434248e-3 * t2361 * t558 + 0.33273901987350860549e-3 * t2364 - 0.1330956079494034422e-2 * t556 * t1010 - 0.48801722914781262138e-3 * t556 * t2368 * t680 + 0.66547803974701721097e-3 * t1143 * t1164 + 0.66547803974701721097e-3 * t556 * t1163 * t713;
  t2379 = my_piecewise3(t2, 0, t2344 + t2377);
  tv4rho3tau0 = t2379 * t5 + 0.3e1 * t1171;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 0] += tv4rho3tau0;

  t2385 = t1174 * t568;
  t2387 = t564 * t1180;
  t2392 = 0.34660314570157146405e-3 * t248 * t667 * t86 * t94;
  t2394 = my_piecewise3(t61, 0, 0.9242750552041905708e-3 * t738 * t26 * t250 + 0.13864125828062858562e-2 * t2385 - 0.6932062914031429281e-3 * t2387 + t2392);
  tv4rho3tau1 = t2394 * t5 + 0.3e1 * t1184;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 1] += tv4rho3tau1;

  t2396 = 0.2e1 * t1200;
  t2400 = 0.9242750552041905708e-3 * t1186 * t549;
  t2403 = t1186 * t27;
  t2406 = t574 * t1147;
  t2409 = 0.18485501104083811416e-2 * t574 * t1151;
  t2410 = t574 * t113;
  t2412 = 0.18485501104083811416e-3 * t2410 * t558;
  t2420 = 0.22182601324900573699e-3 * t1193 * t1164 + t2400 - 0.36971002208167622832e-2 * t1186 * t553 - 0.36971002208167622832e-3 * t2403 * t558 - 0.2310687638010476427e-3 * t2406 - t2409 - t2412 + 0.55456503312251434248e-2 * t574 * t1158 + 0.73942004416335245664e-3 * t1193 * t486 - 0.18485501104083811416e-3 * t1193 * t1167 - 0.4621375276020952854e-3 * t2310;
  t2433 = -0.18485501104083811416e-2 * t2312 - 0.18485501104083811416e-3 * t2340 + t2319 + 0.9242750552041905708e-3 * t2322 + 0.9242750552041905708e-4 * t2348 + 0.27728251656125717124e-2 * t2326 + 0.36971002208167622832e-3 * t2350 - 0.9242750552041905708e-4 * t2352 + 0.4621375276020952854e-3 * t2332 + 0.9242750552041905708e-3 * t769 * t26 * t244 + 0.1109130066245028685e-3 * t2364;
  t2435 = my_piecewise3(t2, 0, t2420 + t2433);
  tv4rho3tau2 = t2435 * t5 + t1171 + t2396;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 2] += tv4rho3tau2;

  t2437 = 0.2e1 * t1221;
  t2442 = 0.9242750552041905708e-3 * t1202 * t568;
  t2443 = t580 * t1180;
  t2450 = 0.18485501104083811416e-2 * t564 * t1211;
  t2453 = t248 * t278 * t73 * t94;
  t2455 = t1174 * t27;
  t2458 = t564 * t113;
  t2460 = 0.18485501104083811416e-3 * t2458 * t589;
  t2461 = t248 * t278;
  t2462 = t2461 * t589;
  t2464 = 0.9242750552041905708e-3 * t804 * t26 * t250 + t2442 - 0.2310687638010476427e-3 * t2443 + 0.4621375276020952854e-3 * t2385 - 0.4621375276020952854e-3 * t2387 + t2392 - 0.18485501104083811416e-2 * t1174 * t584 - t2450 + 0.4621375276020952854e-3 * t2453 - 0.18485501104083811416e-3 * t2455 * t589 - t2460 + 0.4621375276020952854e-4 * t2462;
  t2465 = my_piecewise3(t61, 0, t2464);
  tv4rho3tau3 = t2465 * t5 + t1184 + t2437;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 3] += tv4rho3tau3;

  t2470 = t1224 * t549;
  t2474 = t1224 * t27;
  t2481 = 0.9242750552041905708e-3 * t838 * t26 * t244 + 0.4621375276020952854e-3 * t2470 - 0.18485501104083811416e-2 * t1224 * t553 - 0.18485501104083811416e-3 * t2474 * t558 + t2400 - 0.4621375276020952854e-3 * t2406 - t2409 - t2412 - 0.2310687638010476427e-3 * t2310 + t2319 + 0.4621375276020952854e-3 * t2322 + 0.4621375276020952854e-4 * t2348;
  t2482 = my_piecewise3(t2, 0, t2481);
  tv4rho3tau4 = t2482 * t5 + t1229 + t2396;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 4] += tv4rho3tau4;

  t2487 = t1232 * t568;
  t2492 = t580 * t1211;
  t2494 = t1202 * t27;
  t2497 = t580 * t113;
  t2498 = t2497 * t589;
  t2501 = 0.9242750552041905708e-3 * t864 * t26 * t250 + 0.4621375276020952854e-3 * t2487 + t2442 - 0.4621375276020952854e-3 * t2443 - 0.36971002208167622832e-2 * t1202 * t584 - 0.18485501104083811416e-2 * t2492 - 0.36971002208167622832e-3 * t2494 * t589 - 0.18485501104083811416e-3 * t2498 - 0.2310687638010476427e-3 * t2387 + t2392 - t2450;
  t2508 = t248 * t113 * t183 * t94;
  t2512 = t1217 * t529;
  t2516 = t1217 * t1250;
  t2520 = t1217 * t1253;
  t2522 = 0.9242750552041905708e-3 * t2453 - t2460 + 0.9242750552041905708e-4 * t2462 + 0.55456503312251434248e-2 * t564 * t1244 + 0.27728251656125717124e-2 * t2508 + 0.73942004416335245664e-3 * t1214 * t529 + 0.36971002208167622832e-3 * t2512 + 0.22182601324900573699e-3 * t1214 * t1250 + 0.1109130066245028685e-3 * t2516 - 0.18485501104083811416e-3 * t1214 * t1253 - 0.9242750552041905708e-4 * t2520;
  t2524 = my_piecewise3(t61, 0, t2501 + t2522);
  tv4rho3tau5 = t2524 * t5 + t1257 + t2437;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 5] += tv4rho3tau5;

  t2533 = my_piecewise3(t2, 0, 0.9242750552041905708e-3 * t899 * t26 * t244 + 0.13864125828062858562e-2 * t2470 - 0.6932062914031429281e-3 * t2406 + t2319);
  tv4rho3tau6 = t2533 * t5 + 0.3e1 * t1229;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 6] += tv4rho3tau6;

  t2552 = t86 * t960;
  t2558 = 0.13864125828062858562e-2 * t2487 - 0.55456503312251434248e-2 * t2492 + 0.83184754968377151372e-2 * t2508 - 0.22182601324900573699e-1 * t248 * t27 * t435 * t94 + 0.9242750552041905708e-3 * t917 * t26 * t250 - 0.55456503312251434248e-2 * t1232 * t584 + 0.16636950993675430275e-1 * t580 * t1244 + t2392 - 0.6932062914031429281e-3 * t2443 + 0.13864125828062858562e-2 * t2453 - 0.48801722914781262138e-3 * t587 * t2552 * t931 + 0.66547803974701721097e-3 * t1238 * t1250;
  t2559 = t1232 * t27;
  t2583 = -0.55456503312251434248e-3 * t2559 * t589 + 0.22182601324900573699e-2 * t1238 * t529 - 0.55456503312251434248e-3 * t1238 * t1253 - 0.55456503312251434248e-3 * t2498 + 0.1109130066245028685e-2 * t2512 + 0.33273901987350860549e-3 * t2516 - 0.27728251656125717124e-3 * t2520 - 0.33273901987350860549e-2 * t587 * t1104 + 0.1109130066245028685e-2 * t587 * t1109 - 0.18485501104083811416e-3 * t587 * t588 * t942 - 0.1330956079494034422e-2 * t587 * t1107 + 0.13864125828062858562e-3 * t2462 + 0.66547803974701721097e-3 * t587 * t1249 * t964;
  t2585 = my_piecewise3(t61, 0, t2558 + t2583);
  tv4rho3tau7 = t2585 * t5 + 0.3e1 * t1257;

  if(out->v4rho3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho3tau[ip*p->dim.v4rho3tau + 7] += tv4rho3tau7;

  t2590 = t110 * t1261;
  t2596 = t25 * t279 * t606 / 0.6e1;
  t2598 = t25 * t114 * t1295;
  t2637 = -0.528e3 / 0.625e3 * t710 * t490 * t480 - 0.11801228076532283655e-1 * t2113 * t1020 + 0.2112e4 / 0.3125e4 * t1525 * t595 * t289 - 0.26623822123103243117e-3 * t710 * t37 * t289 - 0.14522084794419950791e-2 * t314 * t124 * t127 - 0.32185167481451682694e-1 * t2110 * t490 + 0.10728389160483894231e-1 * t1009 * t1023 + 0.53641945802419471157e-2 * t1009 * t1026 - 0.264e3 / 0.625e3 * t1518 * t1282 + 0.48e2 / 0.125e3 * t703 * t1285 - 0.132e3 / 0.625e3 * t710 * t595 * t300 + 0.24e2 / 0.125e3 * t314 * t215 * t1001 + 0.24203474657366584652e-3 * t703 * t1290 + 0.12101737328683292326e-3 * t314 * t37 * t300 - 0.1984e4 / 0.3375e4 * t990 * t1023;
  t2653 = t480 * t480;
  t2674 = 0.12101737328683292326e-2 * t309 * t124 - 0.4235608065039152314e-2 * t138 * t297 + 0.22816e5 / 0.50625e5 * t1496 * t595 * t289 - 0.18526116404404052448e-3 * t679 * t37 * t289 - 0.10757099847718482067e-2 * t288 * t124 * t127 - 0.53641945802419471156e-1 * t2088 * t215 + 0.24e2 / 0.125e3 * t314 * t2653 + 0.26820972901209735578e-1 * t1006 * t480 - 0.44701621502016225964e-2 * t485 * t1001 + 0.12e2 / 0.125e3 * t1515 * t595 - 0.10084781107236076938e-3 * t700 * t37 - 0.496e3 / 0.3375e4 * t1264 * t300 + 0.32e2 / 0.225e3 * t474 * t1001 + 0.89642498730987350557e-4 * t1269 * t300 + 0.32e2 / 0.225e3 * t288 * t2653 - 0.35296733875326269282e-2 * t119 * t297;
  t2680 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t270 * t607 - 0.2e1 / 0.3e1 * t2590 - 0.4e1 / 0.3e1 * t110 * t1296 + t2596 - 0.2e1 / 0.3e1 * t2598 - 0.2e1 / 0.3e1 * t25 * t28 * (t2637 + t2674));
  tv4rho2sigma20 = t2680 * t5 + 0.2e1 * t1300;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 0] += tv4rho2sigma20;

  tv4rho2sigma21 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 1] += tv4rho2sigma21;

  tv4rho2sigma22 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 2] += tv4rho2sigma22;

  tv4rho2sigma23 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 3] += tv4rho2sigma23;

  tv4rho2sigma24 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 4] += tv4rho2sigma24;

  t2685 = t153 * t1304;
  t2689 = t70 * t279 * t622 / 0.6e1;
  t2691 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t337 * t623 - 0.2e1 / 0.3e1 * t2685 + t2689);
  tv4rho2sigma25 = t2691 * t5 + 0.2e1 * t1308;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 5] += tv4rho2sigma25;

  t2695 = t168 * t1261;
  t2702 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t358 * t607 - t2695 / 0.3e1 - 0.2e1 / 0.3e1 * t168 * t1296 - t2590 / 0.3e1 + t2596 - t2598 / 0.3e1);
  tv4rho2sigma26 = t2702 * t5 + t1300 + t1313;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 6] += tv4rho2sigma26;

  tv4rho2sigma27 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 7] += tv4rho2sigma27;

  tv4rho2sigma28 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 8] += tv4rho2sigma28;

  tv4rho2sigma29 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 9] += tv4rho2sigma29;

  tv4rho2sigma210 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 10] += tv4rho2sigma210;

  t2706 = t178 * t1304;
  t2712 = t70 * t114 * t1348;
  t2715 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t378 * t623 - t2706 / 0.3e1 - t2685 / 0.3e1 + t2689 - 0.2e1 / 0.3e1 * t153 * t1349 - t2712 / 0.3e1);
  tv4rho2sigma211 = t2715 * t5 + t1308 + t1353;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 11] += tv4rho2sigma211;

  t2722 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t405 * t607 - 0.2e1 / 0.3e1 * t2695 + t2596);
  tv4rho2sigma212 = t2722 * t5 + 0.2e1 * t1313;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 12] += tv4rho2sigma212;

  tv4rho2sigma213 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 13] += tv4rho2sigma213;

  tv4rho2sigma214 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 14] += tv4rho2sigma214;

  tv4rho2sigma215 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 15] += tv4rho2sigma215;

  tv4rho2sigma216 = 0.e0;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 16] += tv4rho2sigma216;

  t2767 = -0.14522084794419950791e-2 * t456 * t187 * t190 - 0.1984e4 / 0.3375e4 * t1087 * t1120 - 0.32185167481451682694e-1 * t2261 * t533 + 0.10728389160483894231e-1 * t1106 * t1120 + 0.53641945802419471157e-2 * t1106 * t1123 - 0.264e3 / 0.625e3 * t1976 * t1335 + 0.48e2 / 0.125e3 * t954 * t1338 - 0.132e3 / 0.625e3 * t961 * t611 * t442 + 0.24e2 / 0.125e3 * t456 * t230 * t1098 + 0.24203474657366584652e-3 * t954 * t1343 + 0.12101737328683292326e-3 * t456 * t79 * t442 - 0.11801228076532283655e-1 * t2265 * t1117 + 0.2112e4 / 0.3125e4 * t1983 * t611 * t431 - 0.26623822123103243117e-3 * t961 * t79 * t431 - 0.496e3 / 0.3375e4 * t1317 * t442;
  t2778 = t523 * t523;
  t2805 = 0.32e2 / 0.225e3 * t517 * t1098 + 0.89642498730987350557e-4 * t1322 * t442 + 0.26820972901209735578e-1 * t1103 * t523 - 0.44701621502016225964e-2 * t528 * t1098 + 0.12e2 / 0.125e3 * t1973 * t611 + 0.24e2 / 0.125e3 * t456 * t2778 + 0.12101737328683292326e-2 * t451 * t187 - 0.4235608065039152314e-2 * t201 * t439 + 0.22816e5 / 0.50625e5 * t1954 * t611 * t431 - 0.18526116404404052448e-3 * t930 * t79 * t431 - 0.10757099847718482067e-2 * t430 * t187 * t190 - 0.53641945802419471156e-1 * t2268 * t230 - 0.10084781107236076938e-3 * t951 * t79 - 0.35296733875326269282e-2 * t182 * t439 + 0.32e2 / 0.225e3 * t430 * t2778 - 0.528e3 / 0.625e3 * t961 * t533 * t523;
  t2811 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t421 * t623 - 0.2e1 / 0.3e1 * t2706 - 0.4e1 / 0.3e1 * t178 * t1349 + t2689 - 0.2e1 / 0.3e1 * t2712 - 0.2e1 / 0.3e1 * t70 * t28 * (t2767 + t2805));
  tv4rho2sigma217 = t2811 * t5 + 0.2e1 * t1353;

  if(out->v4rho2sigma2 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigma2[ip*p->dim.v4rho2sigma2 + 17] += tv4rho2sigma217;

  tv4rho2sigmalapl0 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 0] += tv4rho2sigmalapl0;

  tv4rho2sigmalapl1 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 1] += tv4rho2sigmalapl1;

  tv4rho2sigmalapl2 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 2] += tv4rho2sigmalapl2;

  tv4rho2sigmalapl3 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 3] += tv4rho2sigmalapl3;

  tv4rho2sigmalapl4 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 4] += tv4rho2sigmalapl4;

  tv4rho2sigmalapl5 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 5] += tv4rho2sigmalapl5;

  tv4rho2sigmalapl6 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 6] += tv4rho2sigmalapl6;

  tv4rho2sigmalapl7 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 7] += tv4rho2sigmalapl7;

  tv4rho2sigmalapl8 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 8] += tv4rho2sigmalapl8;

  tv4rho2sigmalapl9 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 9] += tv4rho2sigmalapl9;

  tv4rho2sigmalapl10 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 10] += tv4rho2sigmalapl10;

  tv4rho2sigmalapl11 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 11] += tv4rho2sigmalapl11;

  tv4rho2sigmalapl12 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 12] += tv4rho2sigmalapl12;

  tv4rho2sigmalapl13 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 13] += tv4rho2sigmalapl13;

  tv4rho2sigmalapl14 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 14] += tv4rho2sigmalapl14;

  tv4rho2sigmalapl15 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 15] += tv4rho2sigmalapl15;

  tv4rho2sigmalapl16 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 16] += tv4rho2sigmalapl16;

  tv4rho2sigmalapl17 = 0.e0;

  if(out->v4rho2sigmalapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmalapl[ip*p->dim.v4rho2sigmalapl + 17] += tv4rho2sigmalapl17;

  t2818 = t1154 * t1364;
  t2825 = t2339 * t627;
  t2832 = 0.4621375276020952854e-4 * t2347 * t627;
  t2833 = t1154 * t600;
  t2835 = t1154 * t1361;
  t2850 = -0.18485501104083811416e-3 * t2361 * t627 - 0.36971002208167622832e-3 * t1143 * t1364 - 0.18485501104083811416e-3 * t2818 + 0.73942004416335245664e-3 * t556 * t1278 - 0.18485501104083811416e-3 * t556 * t557 * t1001 - 0.18485501104083811416e-3 * t2825 + 0.73942004416335245664e-3 * t1143 * t600 + 0.44365202649801147398e-3 * t1143 * t1361 + t2832 + 0.36971002208167622832e-3 * t2833 + 0.221826013249005737e-3 * t2835 - 0.1109130066245028685e-2 * t556 * t1274 - 0.88730405299602294796e-3 * t556 * t1276 + 0.44365202649801147398e-3 * t556 * t1163 * t1023 + 0.22182601324900573699e-3 * t556 * t1163 * t1026 - 0.48801722914781262138e-3 * t556 * t2368 * t1020;
  t2851 = my_piecewise3(t2, 0, t2850);
  tv4rho2sigmatau0 = t2851 * t5 + 0.2e1 * t1368;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 0] += tv4rho2sigmatau0;

  tv4rho2sigmatau1 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 1] += tv4rho2sigmatau1;

  tv4rho2sigmatau2 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 2] += tv4rho2sigmatau2;

  tv4rho2sigmatau3 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 3] += tv4rho2sigmatau3;

  tv4rho2sigmatau4 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 4] += tv4rho2sigmatau4;

  t2856 = t2458 * t631;
  t2859 = 0.4621375276020952854e-4 * t2461 * t631;
  t2861 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t2455 * t631 - 0.18485501104083811416e-3 * t2856 + t2859);
  tv4rho2sigmatau5 = t2861 * t5 + 0.2e1 * t1375;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 5] += tv4rho2sigmatau5;

  t2865 = t2410 * t627;
  t2878 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t2403 * t627 - 0.9242750552041905708e-4 * t2865 + 0.36971002208167622832e-3 * t1193 * t600 + 0.22182601324900573699e-3 * t1193 * t1361 - 0.18485501104083811416e-3 * t1193 * t1364 - 0.9242750552041905708e-4 * t2825 + t2832 + 0.18485501104083811416e-3 * t2833 + 0.1109130066245028685e-3 * t2835 - 0.9242750552041905708e-4 * t2818);
  tv4rho2sigmatau6 = t2878 * t5 + t1368 + t1380;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 6] += tv4rho2sigmatau6;

  tv4rho2sigmatau7 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 7] += tv4rho2sigmatau7;

  tv4rho2sigmatau8 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 8] += tv4rho2sigmatau8;

  tv4rho2sigmatau9 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 9] += tv4rho2sigmatau9;

  tv4rho2sigmatau10 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 10] += tv4rho2sigmatau10;

  t2882 = t2497 * t631;
  t2887 = t1217 * t616;
  t2891 = t1217 * t1386;
  t2895 = t1217 * t1389;
  t2898 = my_piecewise3(t61, 0, -0.18485501104083811416e-3 * t2494 * t631 - 0.9242750552041905708e-4 * t2882 - 0.9242750552041905708e-4 * t2856 + t2859 + 0.36971002208167622832e-3 * t1214 * t616 + 0.18485501104083811416e-3 * t2887 + 0.22182601324900573699e-3 * t1214 * t1386 + 0.1109130066245028685e-3 * t2891 - 0.18485501104083811416e-3 * t1214 * t1389 - 0.9242750552041905708e-4 * t2895);
  tv4rho2sigmatau11 = t2898 * t5 + t1375 + t1393;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 11] += tv4rho2sigmatau11;

  t2905 = my_piecewise3(t2, 0, -0.18485501104083811416e-3 * t2474 * t627 - 0.18485501104083811416e-3 * t2865 + t2832);
  tv4rho2sigmatau12 = t2905 * t5 + 0.2e1 * t1380;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 12] += tv4rho2sigmatau12;

  tv4rho2sigmatau13 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 13] += tv4rho2sigmatau13;

  tv4rho2sigmatau14 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 14] += tv4rho2sigmatau14;

  tv4rho2sigmatau15 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 15] += tv4rho2sigmatau15;

  tv4rho2sigmatau16 = 0.e0;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 16] += tv4rho2sigmatau16;

  t2938 = -0.18485501104083811416e-3 * t587 * t588 * t1098 - 0.18485501104083811416e-3 * t2559 * t631 - 0.36971002208167622832e-3 * t1238 * t1389 + 0.73942004416335245664e-3 * t587 * t1331 + 0.73942004416335245664e-3 * t1238 * t616 + 0.44365202649801147398e-3 * t1238 * t1386 - 0.1109130066245028685e-2 * t587 * t1327 - 0.88730405299602294796e-3 * t587 * t1329 + 0.44365202649801147398e-3 * t587 * t1249 * t1120 + 0.22182601324900573699e-3 * t587 * t1249 * t1123 - 0.18485501104083811416e-3 * t2882 + 0.36971002208167622832e-3 * t2887 - 0.18485501104083811416e-3 * t2895 + t2859 - 0.48801722914781262138e-3 * t587 * t2552 * t1117 + 0.221826013249005737e-3 * t2891;
  t2939 = my_piecewise3(t61, 0, t2938);
  tv4rho2sigmatau17 = t2939 * t5 + 0.2e1 * t1393;

  if(out->v4rho2sigmatau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2sigmatau[ip*p->dim.v4rho2sigmatau + 17] += tv4rho2sigmatau17;

  tv4rho2lapl20 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 0] += tv4rho2lapl20;

  tv4rho2lapl21 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 1] += tv4rho2lapl21;

  tv4rho2lapl22 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 2] += tv4rho2lapl22;

  tv4rho2lapl23 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 3] += tv4rho2lapl23;

  tv4rho2lapl24 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 4] += tv4rho2lapl24;

  tv4rho2lapl25 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 5] += tv4rho2lapl25;

  tv4rho2lapl26 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 6] += tv4rho2lapl26;

  tv4rho2lapl27 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 7] += tv4rho2lapl27;

  tv4rho2lapl28 = 0.e0;

  if(out->v4rho2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapl2[ip*p->dim.v4rho2lapl2 + 8] += tv4rho2lapl28;

  tv4rho2lapltau0 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 0] += tv4rho2lapltau0;

  tv4rho2lapltau1 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 1] += tv4rho2lapltau1;

  tv4rho2lapltau2 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 2] += tv4rho2lapltau2;

  tv4rho2lapltau3 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 3] += tv4rho2lapltau3;

  tv4rho2lapltau4 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 4] += tv4rho2lapltau4;

  tv4rho2lapltau5 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 5] += tv4rho2lapltau5;

  tv4rho2lapltau6 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 6] += tv4rho2lapltau6;

  tv4rho2lapltau7 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 7] += tv4rho2lapltau7;

  tv4rho2lapltau8 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 8] += tv4rho2lapltau8;

  tv4rho2lapltau9 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 9] += tv4rho2lapltau9;

  tv4rho2lapltau10 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 10] += tv4rho2lapltau10;

  tv4rho2lapltau11 = 0.e0;

  if(out->v4rho2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2lapltau[ip*p->dim.v4rho2lapltau + 11] += tv4rho2lapltau11;

  tv4rho2tau20 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 0] += tv4rho2tau20;

  tv4rho2tau21 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 1] += tv4rho2tau21;

  tv4rho2tau22 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 2] += tv4rho2tau22;

  tv4rho2tau23 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 3] += tv4rho2tau23;

  tv4rho2tau24 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 4] += tv4rho2tau24;

  tv4rho2tau25 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 5] += tv4rho2tau25;

  tv4rho2tau26 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 6] += tv4rho2tau26;

  tv4rho2tau27 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 7] += tv4rho2tau27;

  tv4rho2tau28 = 0.e0;

  if(out->v4rho2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rho2tau2[ip*p->dim.v4rho2tau2 + 8] += tv4rho2tau28;

  t2945 = t25 * t114 * t1409 / 0.3e1;
  t2965 = t688 * t313;
  t2987 = 0.22816e5 / 0.50625e5 * t1496 * t1395 * t127 - 0.496e3 / 0.1125e4 * t1264 * t480 - 0.55578349213212157345e-3 * t990 * t1290 + 0.26892749619296205167e-3 * t993 * t37 - 0.161356497715777231e-2 * t474 * t124 - 0.2413887561108876202e-1 * t2110 * t595 - 0.17701842114798425482e-1 * t2113 * t1282 + 0.16092583740725841347e-1 * t1009 * t1285 + 0.76073523972696768362e-4 * t1480 * t137 + 0.10143136529692902448e-4 * t2965 * t127 - 0.132e3 / 0.625e3 * t1518 * t1395 + 0.2112e4 / 0.3125e4 * t1525 * t1395 * t127 - 0.396e3 / 0.625e3 * t710 * t595 * t480 + 0.36305211986049876976e-3 * t703 * t1406 - 0.79871466369309729347e-3 * t710 * t1406 * t127 + 0.36305211986049876976e-3 * t314 * t480 * t37 - 0.21783127191629926186e-2 * t314 * t215 * t124;
  t2992 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t110 * t1410 - t2945 - 0.2e1 / 0.3e1 * t25 * t28 * t2987);
  tv4rhosigma30 = t2992 * t5 + t1413;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 0] += tv4rhosigma30;

  tv4rhosigma31 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 1] += tv4rhosigma31;

  tv4rhosigma32 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 2] += tv4rhosigma32;

  tv4rhosigma33 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 3] += tv4rhosigma33;

  tv4rhosigma34 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 4] += tv4rhosigma34;

  tv4rhosigma35 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 5] += tv4rhosigma35;

  tv4rhosigma36 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 6] += tv4rhosigma36;

  tv4rhosigma37 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 7] += tv4rhosigma37;

  tv4rhosigma38 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 8] += tv4rhosigma38;

  t2998 = t70 * t114 * t1428 / 0.3e1;
  t3000 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t153 * t1429 - t2998);
  tv4rhosigma39 = t3000 * t5 + t1432;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 9] += tv4rhosigma39;

  t3005 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t168 * t1410 - t2945);
  tv4rhosigma310 = t3005 * t5 + t1413;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 10] += tv4rhosigma310;

  tv4rhosigma311 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 11] += tv4rhosigma311;

  tv4rhosigma312 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 12] += tv4rhosigma312;

  tv4rhosigma313 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 13] += tv4rhosigma313;

  tv4rhosigma314 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 14] += tv4rhosigma314;

  tv4rhosigma315 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 15] += tv4rhosigma315;

  tv4rhosigma316 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 16] += tv4rhosigma316;

  tv4rhosigma317 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 17] += tv4rhosigma317;

  tv4rhosigma318 = 0.e0;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 18] += tv4rhosigma318;

  t3028 = t939 * t455;
  t3050 = 0.22816e5 / 0.50625e5 * t1954 * t1414 * t190 - 0.496e3 / 0.1125e4 * t1317 * t523 - 0.55578349213212157345e-3 * t1087 * t1343 + 0.26892749619296205167e-3 * t1090 * t79 - 0.161356497715777231e-2 * t517 * t187 - 0.2413887561108876202e-1 * t2261 * t611 - 0.17701842114798425482e-1 * t2265 * t1335 + 0.16092583740725841347e-1 * t1106 * t1338 + 0.76073523972696768362e-4 * t1938 * t200 + 0.10143136529692902448e-4 * t3028 * t190 - 0.132e3 / 0.625e3 * t1976 * t1414 + 0.2112e4 / 0.3125e4 * t1983 * t1414 * t190 - 0.396e3 / 0.625e3 * t961 * t611 * t523 + 0.36305211986049876976e-3 * t954 * t1425 - 0.79871466369309729347e-3 * t961 * t1425 * t190 + 0.36305211986049876976e-3 * t456 * t523 * t79 - 0.21783127191629926186e-2 * t456 * t230 * t187;
  t3055 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t178 * t1429 - t2998 - 0.2e1 / 0.3e1 * t70 * t28 * t3050);
  tv4rhosigma319 = t3055 * t5 + t1432;

  if(out->v4rhosigma3 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma3[ip*p->dim.v4rhosigma3 + 19] += tv4rhosigma319;

  tv4rhosigma2lapl0 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 0] += tv4rhosigma2lapl0;

  tv4rhosigma2lapl1 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 1] += tv4rhosigma2lapl1;

  tv4rhosigma2lapl2 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 2] += tv4rhosigma2lapl2;

  tv4rhosigma2lapl3 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 3] += tv4rhosigma2lapl3;

  tv4rhosigma2lapl4 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 4] += tv4rhosigma2lapl4;

  tv4rhosigma2lapl5 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 5] += tv4rhosigma2lapl5;

  tv4rhosigma2lapl6 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 6] += tv4rhosigma2lapl6;

  tv4rhosigma2lapl7 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 7] += tv4rhosigma2lapl7;

  tv4rhosigma2lapl8 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 8] += tv4rhosigma2lapl8;

  tv4rhosigma2lapl9 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 9] += tv4rhosigma2lapl9;

  tv4rhosigma2lapl10 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 10] += tv4rhosigma2lapl10;

  tv4rhosigma2lapl11 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 11] += tv4rhosigma2lapl11;

  tv4rhosigma2lapl12 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 12] += tv4rhosigma2lapl12;

  tv4rhosigma2lapl13 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 13] += tv4rhosigma2lapl13;

  tv4rhosigma2lapl14 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 14] += tv4rhosigma2lapl14;

  tv4rhosigma2lapl15 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 15] += tv4rhosigma2lapl15;

  tv4rhosigma2lapl16 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 16] += tv4rhosigma2lapl16;

  tv4rhosigma2lapl17 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 17] += tv4rhosigma2lapl17;

  tv4rhosigma2lapl18 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 18] += tv4rhosigma2lapl18;

  tv4rhosigma2lapl19 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 19] += tv4rhosigma2lapl19;

  tv4rhosigma2lapl20 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 20] += tv4rhosigma2lapl20;

  tv4rhosigma2lapl21 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 21] += tv4rhosigma2lapl21;

  tv4rhosigma2lapl22 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 22] += tv4rhosigma2lapl22;

  tv4rhosigma2lapl23 = 0.e0;

  if(out->v4rhosigma2lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2lapl[ip*p->dim.v4rhosigma2lapl + 23] += tv4rhosigma2lapl23;

  t3060 = 0.1109130066245028685e-3 * t1154 * t1433;
  t3074 = 0.116513895182660039e-6 * t242 * t113 * t297 * t137;
  t3079 = t297 * t313;
  t3084 = my_piecewise3(t2, 0, 0.22182601324900573699e-3 * t1143 * t1433 + t3060 - 0.44365202649801147398e-3 * t556 * t1400 - 0.48801722914781262138e-3 * t556 * t2368 * t1282 + 0.44365202649801147398e-3 * t556 * t1163 * t1285 - 0.233027790365320078e-6 * t545 * t1437 - t3074 + 0.1864222322922560624e-5 * t242 * t27 * t688 * t137 + 0.2796333484383840936e-6 * t556 * t3079 * t127);
  tv4rhosigma2tau0 = t3084 * t5 + t1441;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 0] += tv4rhosigma2tau0;

  tv4rhosigma2tau1 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 1] += tv4rhosigma2tau1;

  tv4rhosigma2tau2 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 2] += tv4rhosigma2tau2;

  tv4rhosigma2tau3 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 3] += tv4rhosigma2tau3;

  tv4rhosigma2tau4 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 4] += tv4rhosigma2tau4;

  tv4rhosigma2tau5 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 5] += tv4rhosigma2tau5;

  tv4rhosigma2tau6 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 6] += tv4rhosigma2tau6;

  tv4rhosigma2tau7 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 7] += tv4rhosigma2tau7;

  tv4rhosigma2tau8 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 8] += tv4rhosigma2tau8;

  tv4rhosigma2tau9 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 9] += tv4rhosigma2tau9;

  tv4rhosigma2tau10 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 10] += tv4rhosigma2tau10;

  t3089 = 0.1109130066245028685e-3 * t1217 * t1442;
  t3095 = 0.116513895182660039e-6 * t248 * t113 * t439 * t200;
  t3097 = my_piecewise3(t61, 0, 0.22182601324900573699e-3 * t1214 * t1442 + t3089 - 0.233027790365320078e-6 * t564 * t1446 - t3095);
  tv4rhosigma2tau11 = t3097 * t5 + t1450;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 11] += tv4rhosigma2tau11;

  t3104 = my_piecewise3(t2, 0, 0.22182601324900573699e-3 * t1193 * t1433 + t3060 - 0.233027790365320078e-6 * t574 * t1437 - t3074);
  tv4rhosigma2tau12 = t3104 * t5 + t1441;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 12] += tv4rhosigma2tau12;

  tv4rhosigma2tau13 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 13] += tv4rhosigma2tau13;

  tv4rhosigma2tau14 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 14] += tv4rhosigma2tau14;

  tv4rhosigma2tau15 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 15] += tv4rhosigma2tau15;

  tv4rhosigma2tau16 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 16] += tv4rhosigma2tau16;

  tv4rhosigma2tau17 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 17] += tv4rhosigma2tau17;

  tv4rhosigma2tau18 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 18] += tv4rhosigma2tau18;

  tv4rhosigma2tau19 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 19] += tv4rhosigma2tau19;

  tv4rhosigma2tau20 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 20] += tv4rhosigma2tau20;

  tv4rhosigma2tau21 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 21] += tv4rhosigma2tau21;

  tv4rhosigma2tau22 = 0.e0;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 22] += tv4rhosigma2tau22;

  t3122 = t439 * t455;
  t3127 = my_piecewise3(t61, 0, 0.22182601324900573699e-3 * t1238 * t1442 + t3089 - 0.44365202649801147398e-3 * t587 * t1419 - 0.48801722914781262138e-3 * t587 * t2552 * t1335 + 0.44365202649801147398e-3 * t587 * t1249 * t1338 - 0.233027790365320078e-6 * t580 * t1446 - t3095 + 0.1864222322922560624e-5 * t248 * t27 * t939 * t200 + 0.2796333484383840936e-6 * t587 * t3122 * t190);
  tv4rhosigma2tau23 = t3127 * t5 + t1450;

  if(out->v4rhosigma2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigma2tau[ip*p->dim.v4rhosigma2tau + 23] += tv4rhosigma2tau23;

  tv4rhosigmalapl20 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 0] += tv4rhosigmalapl20;

  tv4rhosigmalapl21 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 1] += tv4rhosigmalapl21;

  tv4rhosigmalapl22 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 2] += tv4rhosigmalapl22;

  tv4rhosigmalapl23 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 3] += tv4rhosigmalapl23;

  tv4rhosigmalapl24 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 4] += tv4rhosigmalapl24;

  tv4rhosigmalapl25 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 5] += tv4rhosigmalapl25;

  tv4rhosigmalapl26 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 6] += tv4rhosigmalapl26;

  tv4rhosigmalapl27 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 7] += tv4rhosigmalapl27;

  tv4rhosigmalapl28 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 8] += tv4rhosigmalapl28;

  tv4rhosigmalapl29 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 9] += tv4rhosigmalapl29;

  tv4rhosigmalapl210 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 10] += tv4rhosigmalapl210;

  tv4rhosigmalapl211 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 11] += tv4rhosigmalapl211;

  tv4rhosigmalapl212 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 12] += tv4rhosigmalapl212;

  tv4rhosigmalapl213 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 13] += tv4rhosigmalapl213;

  tv4rhosigmalapl214 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 14] += tv4rhosigmalapl214;

  tv4rhosigmalapl215 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 15] += tv4rhosigmalapl215;

  tv4rhosigmalapl216 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 16] += tv4rhosigmalapl216;

  tv4rhosigmalapl217 = 0.e0;

  if(out->v4rhosigmalapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapl2[ip*p->dim.v4rhosigmalapl2 + 17] += tv4rhosigmalapl217;

  tv4rhosigmalapltau0 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 0] += tv4rhosigmalapltau0;

  tv4rhosigmalapltau1 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 1] += tv4rhosigmalapltau1;

  tv4rhosigmalapltau2 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 2] += tv4rhosigmalapltau2;

  tv4rhosigmalapltau3 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 3] += tv4rhosigmalapltau3;

  tv4rhosigmalapltau4 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 4] += tv4rhosigmalapltau4;

  tv4rhosigmalapltau5 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 5] += tv4rhosigmalapltau5;

  tv4rhosigmalapltau6 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 6] += tv4rhosigmalapltau6;

  tv4rhosigmalapltau7 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 7] += tv4rhosigmalapltau7;

  tv4rhosigmalapltau8 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 8] += tv4rhosigmalapltau8;

  tv4rhosigmalapltau9 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 9] += tv4rhosigmalapltau9;

  tv4rhosigmalapltau10 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 10] += tv4rhosigmalapltau10;

  tv4rhosigmalapltau11 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 11] += tv4rhosigmalapltau11;

  tv4rhosigmalapltau12 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 12] += tv4rhosigmalapltau12;

  tv4rhosigmalapltau13 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 13] += tv4rhosigmalapltau13;

  tv4rhosigmalapltau14 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 14] += tv4rhosigmalapltau14;

  tv4rhosigmalapltau15 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 15] += tv4rhosigmalapltau15;

  tv4rhosigmalapltau16 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 16] += tv4rhosigmalapltau16;

  tv4rhosigmalapltau17 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 17] += tv4rhosigmalapltau17;

  tv4rhosigmalapltau18 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 18] += tv4rhosigmalapltau18;

  tv4rhosigmalapltau19 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 19] += tv4rhosigmalapltau19;

  tv4rhosigmalapltau20 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 20] += tv4rhosigmalapltau20;

  tv4rhosigmalapltau21 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 21] += tv4rhosigmalapltau21;

  tv4rhosigmalapltau22 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 22] += tv4rhosigmalapltau22;

  tv4rhosigmalapltau23 = 0.e0;

  if(out->v4rhosigmalapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmalapltau[ip*p->dim.v4rhosigmalapltau + 23] += tv4rhosigmalapltau23;

  tv4rhosigmatau20 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 0] += tv4rhosigmatau20;

  tv4rhosigmatau21 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 1] += tv4rhosigmatau21;

  tv4rhosigmatau22 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 2] += tv4rhosigmatau22;

  tv4rhosigmatau23 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 3] += tv4rhosigmatau23;

  tv4rhosigmatau24 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 4] += tv4rhosigmatau24;

  tv4rhosigmatau25 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 5] += tv4rhosigmatau25;

  tv4rhosigmatau26 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 6] += tv4rhosigmatau26;

  tv4rhosigmatau27 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 7] += tv4rhosigmatau27;

  tv4rhosigmatau28 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 8] += tv4rhosigmatau28;

  tv4rhosigmatau29 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 9] += tv4rhosigmatau29;

  tv4rhosigmatau210 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 10] += tv4rhosigmatau210;

  tv4rhosigmatau211 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 11] += tv4rhosigmatau211;

  tv4rhosigmatau212 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 12] += tv4rhosigmatau212;

  tv4rhosigmatau213 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 13] += tv4rhosigmatau213;

  tv4rhosigmatau214 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 14] += tv4rhosigmatau214;

  tv4rhosigmatau215 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 15] += tv4rhosigmatau215;

  tv4rhosigmatau216 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 16] += tv4rhosigmatau216;

  tv4rhosigmatau217 = 0.e0;

  if(out->v4rhosigmatau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhosigmatau2[ip*p->dim.v4rhosigmatau2 + 17] += tv4rhosigmatau217;

  tv4rholapl30 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 0] += tv4rholapl30;

  tv4rholapl31 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 1] += tv4rholapl31;

  tv4rholapl32 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 2] += tv4rholapl32;

  tv4rholapl33 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 3] += tv4rholapl33;

  tv4rholapl34 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 4] += tv4rholapl34;

  tv4rholapl35 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 5] += tv4rholapl35;

  tv4rholapl36 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 6] += tv4rholapl36;

  tv4rholapl37 = 0.e0;

  if(out->v4rholapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl3[ip*p->dim.v4rholapl3 + 7] += tv4rholapl37;

  tv4rholapl2tau0 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 0] += tv4rholapl2tau0;

  tv4rholapl2tau1 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 1] += tv4rholapl2tau1;

  tv4rholapl2tau2 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 2] += tv4rholapl2tau2;

  tv4rholapl2tau3 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 3] += tv4rholapl2tau3;

  tv4rholapl2tau4 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 4] += tv4rholapl2tau4;

  tv4rholapl2tau5 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 5] += tv4rholapl2tau5;

  tv4rholapl2tau6 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 6] += tv4rholapl2tau6;

  tv4rholapl2tau7 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 7] += tv4rholapl2tau7;

  tv4rholapl2tau8 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 8] += tv4rholapl2tau8;

  tv4rholapl2tau9 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 9] += tv4rholapl2tau9;

  tv4rholapl2tau10 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 10] += tv4rholapl2tau10;

  tv4rholapl2tau11 = 0.e0;

  if(out->v4rholapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapl2tau[ip*p->dim.v4rholapl2tau + 11] += tv4rholapl2tau11;

  tv4rholapltau20 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 0] += tv4rholapltau20;

  tv4rholapltau21 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 1] += tv4rholapltau21;

  tv4rholapltau22 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 2] += tv4rholapltau22;

  tv4rholapltau23 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 3] += tv4rholapltau23;

  tv4rholapltau24 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 4] += tv4rholapltau24;

  tv4rholapltau25 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 5] += tv4rholapltau25;

  tv4rholapltau26 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 6] += tv4rholapltau26;

  tv4rholapltau27 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 7] += tv4rholapltau27;

  tv4rholapltau28 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 8] += tv4rholapltau28;

  tv4rholapltau29 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 9] += tv4rholapltau29;

  tv4rholapltau210 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 10] += tv4rholapltau210;

  tv4rholapltau211 = 0.e0;

  if(out->v4rholapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rholapltau2[ip*p->dim.v4rholapltau2 + 11] += tv4rholapltau211;

  tv4rhotau30 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 0] += tv4rhotau30;

  tv4rhotau31 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 1] += tv4rhotau31;

  tv4rhotau32 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 2] += tv4rhotau32;

  tv4rhotau33 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 3] += tv4rhotau33;

  tv4rhotau34 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 4] += tv4rhotau34;

  tv4rhotau35 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 5] += tv4rhotau35;

  tv4rhotau36 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 6] += tv4rhotau36;

  tv4rhotau37 = 0.e0;

  if(out->v4rhotau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4rhotau3[ip*p->dim.v4rhotau3 + 7] += tv4rhotau37;

  t3129 = t595 * t595;
  t3135 = 0.1e1 / t296 / t35;
  t3153 = my_piecewise3(t2, 0, -0.2e1 / 0.3e1 * t25 * t28 * (0.22816e5 / 0.50625e5 * t1496 * t3129 - 0.11115669842642431469e-2 * t1264 * t37 + 0.3390093666028857131e-6 * t288 * t3135 - 0.23602456153064567309e-1 * t2113 * t1395 + 0.40572546118771609792e-4 * t2965 * t215 + 0.2112e4 / 0.3125e4 * t1525 * t3129 - 0.15974293273861945869e-2 * t710 * t595 * t37 + 0.45766264491389571269e-6 * t314 * t3135));
  tv4sigma40 = t5 * t3153;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 0] += tv4sigma40;

  tv4sigma41 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 1] += tv4sigma41;

  tv4sigma42 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 2] += tv4sigma42;

  tv4sigma43 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 3] += tv4sigma43;

  tv4sigma44 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 4] += tv4sigma44;

  tv4sigma45 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 5] += tv4sigma45;

  tv4sigma46 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 6] += tv4sigma46;

  tv4sigma47 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 7] += tv4sigma47;

  tv4sigma48 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 8] += tv4sigma48;

  tv4sigma49 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 9] += tv4sigma49;

  tv4sigma410 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 10] += tv4sigma410;

  tv4sigma411 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 11] += tv4sigma411;

  tv4sigma412 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 12] += tv4sigma412;

  tv4sigma413 = 0.e0;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 13] += tv4sigma413;

  t3154 = t611 * t611;
  t3160 = 0.1e1 / t438 / t77;
  t3178 = my_piecewise3(t61, 0, -0.2e1 / 0.3e1 * t70 * t28 * (0.22816e5 / 0.50625e5 * t1954 * t3154 - 0.11115669842642431469e-2 * t1317 * t79 + 0.3390093666028857131e-6 * t430 * t3160 - 0.23602456153064567309e-1 * t2265 * t1414 + 0.40572546118771609792e-4 * t3028 * t230 + 0.2112e4 / 0.3125e4 * t1983 * t3154 - 0.15974293273861945869e-2 * t961 * t611 * t79 + 0.45766264491389571269e-6 * t456 * t3160));
  tv4sigma414 = t5 * t3178;

  if(out->v4sigma4 != NULL && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma4[ip*p->dim.v4sigma4 + 14] += tv4sigma414;

  tv4sigma3lapl0 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 0] += tv4sigma3lapl0;

  tv4sigma3lapl1 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 1] += tv4sigma3lapl1;

  tv4sigma3lapl2 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 2] += tv4sigma3lapl2;

  tv4sigma3lapl3 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 3] += tv4sigma3lapl3;

  tv4sigma3lapl4 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 4] += tv4sigma3lapl4;

  tv4sigma3lapl5 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 5] += tv4sigma3lapl5;

  tv4sigma3lapl6 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 6] += tv4sigma3lapl6;

  tv4sigma3lapl7 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 7] += tv4sigma3lapl7;

  tv4sigma3lapl8 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 8] += tv4sigma3lapl8;

  tv4sigma3lapl9 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 9] += tv4sigma3lapl9;

  tv4sigma3lapl10 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 10] += tv4sigma3lapl10;

  tv4sigma3lapl11 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 11] += tv4sigma3lapl11;

  tv4sigma3lapl12 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 12] += tv4sigma3lapl12;

  tv4sigma3lapl13 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 13] += tv4sigma3lapl13;

  tv4sigma3lapl14 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 14] += tv4sigma3lapl14;

  tv4sigma3lapl15 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 15] += tv4sigma3lapl15;

  tv4sigma3lapl16 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 16] += tv4sigma3lapl16;

  tv4sigma3lapl17 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 17] += tv4sigma3lapl17;

  tv4sigma3lapl18 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 18] += tv4sigma3lapl18;

  tv4sigma3lapl19 = 0.e0;

  if(out->v4sigma3lapl != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3lapl[ip*p->dim.v4sigma3lapl + 19] += tv4sigma3lapl19;

  t3186 = my_piecewise3(t2, 0, -0.48801722914781262138e-3 * t556 * t2368 * t1395 + 0.8389000453151522808e-6 * t556 * t3079 * t215);
  tv4sigma3tau0 = t5 * t3186;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 0] += tv4sigma3tau0;

  tv4sigma3tau1 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 1] += tv4sigma3tau1;

  tv4sigma3tau2 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 2] += tv4sigma3tau2;

  tv4sigma3tau3 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 3] += tv4sigma3tau3;

  tv4sigma3tau4 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 4] += tv4sigma3tau4;

  tv4sigma3tau5 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 5] += tv4sigma3tau5;

  tv4sigma3tau6 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 6] += tv4sigma3tau6;

  tv4sigma3tau7 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 7] += tv4sigma3tau7;

  tv4sigma3tau8 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 8] += tv4sigma3tau8;

  tv4sigma3tau9 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 9] += tv4sigma3tau9;

  tv4sigma3tau10 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 10] += tv4sigma3tau10;

  tv4sigma3tau11 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 11] += tv4sigma3tau11;

  tv4sigma3tau12 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 12] += tv4sigma3tau12;

  tv4sigma3tau13 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 13] += tv4sigma3tau13;

  tv4sigma3tau14 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 14] += tv4sigma3tau14;

  tv4sigma3tau15 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 15] += tv4sigma3tau15;

  tv4sigma3tau16 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 16] += tv4sigma3tau16;

  tv4sigma3tau17 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 17] += tv4sigma3tau17;

  tv4sigma3tau18 = 0.e0;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 18] += tv4sigma3tau18;

  t3194 = my_piecewise3(t61, 0, -0.48801722914781262138e-3 * t587 * t2552 * t1414 + 0.8389000453151522808e-6 * t587 * t3122 * t230);
  tv4sigma3tau19 = t5 * t3194;

  if(out->v4sigma3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma3tau[ip*p->dim.v4sigma3tau + 19] += tv4sigma3tau19;

  tv4sigma2lapl20 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 0] += tv4sigma2lapl20;

  tv4sigma2lapl21 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 1] += tv4sigma2lapl21;

  tv4sigma2lapl22 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 2] += tv4sigma2lapl22;

  tv4sigma2lapl23 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 3] += tv4sigma2lapl23;

  tv4sigma2lapl24 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 4] += tv4sigma2lapl24;

  tv4sigma2lapl25 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 5] += tv4sigma2lapl25;

  tv4sigma2lapl26 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 6] += tv4sigma2lapl26;

  tv4sigma2lapl27 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 7] += tv4sigma2lapl27;

  tv4sigma2lapl28 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 8] += tv4sigma2lapl28;

  tv4sigma2lapl29 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 9] += tv4sigma2lapl29;

  tv4sigma2lapl210 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 10] += tv4sigma2lapl210;

  tv4sigma2lapl211 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 11] += tv4sigma2lapl211;

  tv4sigma2lapl212 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 12] += tv4sigma2lapl212;

  tv4sigma2lapl213 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 13] += tv4sigma2lapl213;

  tv4sigma2lapl214 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 14] += tv4sigma2lapl214;

  tv4sigma2lapl215 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 15] += tv4sigma2lapl215;

  tv4sigma2lapl216 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 16] += tv4sigma2lapl216;

  tv4sigma2lapl217 = 0.e0;

  if(out->v4sigma2lapl2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapl2[ip*p->dim.v4sigma2lapl2 + 17] += tv4sigma2lapl217;

  tv4sigma2lapltau0 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 0] += tv4sigma2lapltau0;

  tv4sigma2lapltau1 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 1] += tv4sigma2lapltau1;

  tv4sigma2lapltau2 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 2] += tv4sigma2lapltau2;

  tv4sigma2lapltau3 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 3] += tv4sigma2lapltau3;

  tv4sigma2lapltau4 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 4] += tv4sigma2lapltau4;

  tv4sigma2lapltau5 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 5] += tv4sigma2lapltau5;

  tv4sigma2lapltau6 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 6] += tv4sigma2lapltau6;

  tv4sigma2lapltau7 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 7] += tv4sigma2lapltau7;

  tv4sigma2lapltau8 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 8] += tv4sigma2lapltau8;

  tv4sigma2lapltau9 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 9] += tv4sigma2lapltau9;

  tv4sigma2lapltau10 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 10] += tv4sigma2lapltau10;

  tv4sigma2lapltau11 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 11] += tv4sigma2lapltau11;

  tv4sigma2lapltau12 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 12] += tv4sigma2lapltau12;

  tv4sigma2lapltau13 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 13] += tv4sigma2lapltau13;

  tv4sigma2lapltau14 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 14] += tv4sigma2lapltau14;

  tv4sigma2lapltau15 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 15] += tv4sigma2lapltau15;

  tv4sigma2lapltau16 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 16] += tv4sigma2lapltau16;

  tv4sigma2lapltau17 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 17] += tv4sigma2lapltau17;

  tv4sigma2lapltau18 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 18] += tv4sigma2lapltau18;

  tv4sigma2lapltau19 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 19] += tv4sigma2lapltau19;

  tv4sigma2lapltau20 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 20] += tv4sigma2lapltau20;

  tv4sigma2lapltau21 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 21] += tv4sigma2lapltau21;

  tv4sigma2lapltau22 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 22] += tv4sigma2lapltau22;

  tv4sigma2lapltau23 = 0.e0;

  if(out->v4sigma2lapltau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2lapltau[ip*p->dim.v4sigma2lapltau + 23] += tv4sigma2lapltau23;

  tv4sigma2tau20 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 0] += tv4sigma2tau20;

  tv4sigma2tau21 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 1] += tv4sigma2tau21;

  tv4sigma2tau22 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 2] += tv4sigma2tau22;

  tv4sigma2tau23 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 3] += tv4sigma2tau23;

  tv4sigma2tau24 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 4] += tv4sigma2tau24;

  tv4sigma2tau25 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 5] += tv4sigma2tau25;

  tv4sigma2tau26 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 6] += tv4sigma2tau26;

  tv4sigma2tau27 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 7] += tv4sigma2tau27;

  tv4sigma2tau28 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 8] += tv4sigma2tau28;

  tv4sigma2tau29 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 9] += tv4sigma2tau29;

  tv4sigma2tau210 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 10] += tv4sigma2tau210;

  tv4sigma2tau211 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 11] += tv4sigma2tau211;

  tv4sigma2tau212 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 12] += tv4sigma2tau212;

  tv4sigma2tau213 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 13] += tv4sigma2tau213;

  tv4sigma2tau214 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 14] += tv4sigma2tau214;

  tv4sigma2tau215 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 15] += tv4sigma2tau215;

  tv4sigma2tau216 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 16] += tv4sigma2tau216;

  tv4sigma2tau217 = 0.e0;

  if(out->v4sigma2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigma2tau2[ip*p->dim.v4sigma2tau2 + 17] += tv4sigma2tau217;

  tv4sigmalapl30 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 0] += tv4sigmalapl30;

  tv4sigmalapl31 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 1] += tv4sigmalapl31;

  tv4sigmalapl32 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 2] += tv4sigmalapl32;

  tv4sigmalapl33 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 3] += tv4sigmalapl33;

  tv4sigmalapl34 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 4] += tv4sigmalapl34;

  tv4sigmalapl35 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 5] += tv4sigmalapl35;

  tv4sigmalapl36 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 6] += tv4sigmalapl36;

  tv4sigmalapl37 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 7] += tv4sigmalapl37;

  tv4sigmalapl38 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 8] += tv4sigmalapl38;

  tv4sigmalapl39 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 9] += tv4sigmalapl39;

  tv4sigmalapl310 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 10] += tv4sigmalapl310;

  tv4sigmalapl311 = 0.e0;

  if(out->v4sigmalapl3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl3[ip*p->dim.v4sigmalapl3 + 11] += tv4sigmalapl311;

  tv4sigmalapl2tau0 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 0] += tv4sigmalapl2tau0;

  tv4sigmalapl2tau1 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 1] += tv4sigmalapl2tau1;

  tv4sigmalapl2tau2 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 2] += tv4sigmalapl2tau2;

  tv4sigmalapl2tau3 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 3] += tv4sigmalapl2tau3;

  tv4sigmalapl2tau4 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 4] += tv4sigmalapl2tau4;

  tv4sigmalapl2tau5 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 5] += tv4sigmalapl2tau5;

  tv4sigmalapl2tau6 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 6] += tv4sigmalapl2tau6;

  tv4sigmalapl2tau7 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 7] += tv4sigmalapl2tau7;

  tv4sigmalapl2tau8 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 8] += tv4sigmalapl2tau8;

  tv4sigmalapl2tau9 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 9] += tv4sigmalapl2tau9;

  tv4sigmalapl2tau10 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 10] += tv4sigmalapl2tau10;

  tv4sigmalapl2tau11 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 11] += tv4sigmalapl2tau11;

  tv4sigmalapl2tau12 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 12] += tv4sigmalapl2tau12;

  tv4sigmalapl2tau13 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 13] += tv4sigmalapl2tau13;

  tv4sigmalapl2tau14 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 14] += tv4sigmalapl2tau14;

  tv4sigmalapl2tau15 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 15] += tv4sigmalapl2tau15;

  tv4sigmalapl2tau16 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 16] += tv4sigmalapl2tau16;

  tv4sigmalapl2tau17 = 0.e0;

  if(out->v4sigmalapl2tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapl2tau[ip*p->dim.v4sigmalapl2tau + 17] += tv4sigmalapl2tau17;

  tv4sigmalapltau20 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 0] += tv4sigmalapltau20;

  tv4sigmalapltau21 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 1] += tv4sigmalapltau21;

  tv4sigmalapltau22 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 2] += tv4sigmalapltau22;

  tv4sigmalapltau23 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 3] += tv4sigmalapltau23;

  tv4sigmalapltau24 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 4] += tv4sigmalapltau24;

  tv4sigmalapltau25 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 5] += tv4sigmalapltau25;

  tv4sigmalapltau26 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 6] += tv4sigmalapltau26;

  tv4sigmalapltau27 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 7] += tv4sigmalapltau27;

  tv4sigmalapltau28 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 8] += tv4sigmalapltau28;

  tv4sigmalapltau29 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 9] += tv4sigmalapltau29;

  tv4sigmalapltau210 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 10] += tv4sigmalapltau210;

  tv4sigmalapltau211 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 11] += tv4sigmalapltau211;

  tv4sigmalapltau212 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 12] += tv4sigmalapltau212;

  tv4sigmalapltau213 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 13] += tv4sigmalapltau213;

  tv4sigmalapltau214 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 14] += tv4sigmalapltau214;

  tv4sigmalapltau215 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 15] += tv4sigmalapltau215;

  tv4sigmalapltau216 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 16] += tv4sigmalapltau216;

  tv4sigmalapltau217 = 0.e0;

  if(out->v4sigmalapltau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmalapltau2[ip*p->dim.v4sigmalapltau2 + 17] += tv4sigmalapltau217;

  tv4sigmatau30 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 0] += tv4sigmatau30;

  tv4sigmatau31 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 1] += tv4sigmatau31;

  tv4sigmatau32 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 2] += tv4sigmatau32;

  tv4sigmatau33 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 3] += tv4sigmatau33;

  tv4sigmatau34 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 4] += tv4sigmatau34;

  tv4sigmatau35 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 5] += tv4sigmatau35;

  tv4sigmatau36 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 6] += tv4sigmatau36;

  tv4sigmatau37 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 7] += tv4sigmatau37;

  tv4sigmatau38 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 8] += tv4sigmatau38;

  tv4sigmatau39 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 9] += tv4sigmatau39;

  tv4sigmatau310 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 10] += tv4sigmatau310;

  tv4sigmatau311 = 0.e0;

  if(out->v4sigmatau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4sigmatau3[ip*p->dim.v4sigmatau3 + 11] += tv4sigmatau311;

  tv4lapl40 = 0.e0;

  if(out->v4lapl4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl4[ip*p->dim.v4lapl4 + 0] += tv4lapl40;

  tv4lapl41 = 0.e0;

  if(out->v4lapl4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl4[ip*p->dim.v4lapl4 + 1] += tv4lapl41;

  tv4lapl42 = 0.e0;

  if(out->v4lapl4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl4[ip*p->dim.v4lapl4 + 2] += tv4lapl42;

  tv4lapl43 = 0.e0;

  if(out->v4lapl4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl4[ip*p->dim.v4lapl4 + 3] += tv4lapl43;

  tv4lapl44 = 0.e0;

  if(out->v4lapl4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl4[ip*p->dim.v4lapl4 + 4] += tv4lapl44;

  tv4lapl3tau0 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 0] += tv4lapl3tau0;

  tv4lapl3tau1 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 1] += tv4lapl3tau1;

  tv4lapl3tau2 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 2] += tv4lapl3tau2;

  tv4lapl3tau3 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 3] += tv4lapl3tau3;

  tv4lapl3tau4 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 4] += tv4lapl3tau4;

  tv4lapl3tau5 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 5] += tv4lapl3tau5;

  tv4lapl3tau6 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 6] += tv4lapl3tau6;

  tv4lapl3tau7 = 0.e0;

  if(out->v4lapl3tau != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl3tau[ip*p->dim.v4lapl3tau + 7] += tv4lapl3tau7;

  tv4lapl2tau20 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 0] += tv4lapl2tau20;

  tv4lapl2tau21 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 1] += tv4lapl2tau21;

  tv4lapl2tau22 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 2] += tv4lapl2tau22;

  tv4lapl2tau23 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 3] += tv4lapl2tau23;

  tv4lapl2tau24 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 4] += tv4lapl2tau24;

  tv4lapl2tau25 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 5] += tv4lapl2tau25;

  tv4lapl2tau26 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 6] += tv4lapl2tau26;

  tv4lapl2tau27 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 7] += tv4lapl2tau27;

  tv4lapl2tau28 = 0.e0;

  if(out->v4lapl2tau2 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapl2tau2[ip*p->dim.v4lapl2tau2 + 8] += tv4lapl2tau28;

  tv4lapltau30 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 0] += tv4lapltau30;

  tv4lapltau31 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 1] += tv4lapltau31;

  tv4lapltau32 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 2] += tv4lapltau32;

  tv4lapltau33 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 3] += tv4lapltau33;

  tv4lapltau34 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 4] += tv4lapltau34;

  tv4lapltau35 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 5] += tv4lapltau35;

  tv4lapltau36 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 6] += tv4lapltau36;

  tv4lapltau37 = 0.e0;

  if(out->v4lapltau3 != NULL && (p->info->flags & XC_FLAGS_NEEDS_LAPLACIAN) && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4lapltau3[ip*p->dim.v4lapltau3 + 7] += tv4lapltau37;

  tv4tau40 = 0.e0;

  if(out->v4tau4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4tau4[ip*p->dim.v4tau4 + 0] += tv4tau40;

  tv4tau41 = 0.e0;

  if(out->v4tau4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4tau4[ip*p->dim.v4tau4 + 1] += tv4tau41;

  tv4tau42 = 0.e0;

  if(out->v4tau4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4tau4[ip*p->dim.v4tau4 + 2] += tv4tau42;

  tv4tau43 = 0.e0;

  if(out->v4tau4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4tau4[ip*p->dim.v4tau4 + 3] += tv4tau43;

  tv4tau44 = 0.e0;

  if(out->v4tau4 != NULL && (p->info->flags & XC_FLAGS_NEEDS_TAU) && (p->info->flags & XC_FLAGS_HAVE_LXC))
    out->v4tau4[ip*p->dim.v4tau4 + 4] += tv4tau44;

}

#endif

