Skip to main content
added 15 characters in body
Source Link
rhermans
  • 37.4k
  • 4
  • 61
  • 152

Change [_t] to [t_], pi to Pi

$Assumptions = {d >= 1, Element[d, Integers], Element[x, Vectors[d]]};
unitSphereVolume = Pi^(d/2)/Gamma[d/2 + 1];

epan[t_] = 
  Piecewise[{{(d + 2)/(2*unitSphereVolume) (1 - Dot[t, t]), 
     Dot[t, t] < 1}}, 0];

EV[t_] = Refine[D[t*epan[t], t], Element[t, Vectors[d]]];
V[t_] = Refine[EV[t^2] - (EV[t])^2, Element[t, Vectors[d]]];
FunctionExpand[V[x]]
FullSimplify@PiecewiseExpand@V[x]

Mathematica graphicsMathematica graphics

Change [_t] to [t_], pi to Pi

$Assumptions = {d >= 1, Element[d, Integers], Element[x, Vectors[d]]};
unitSphereVolume = Pi^(d/2)/Gamma[d/2 + 1];

epan[t_] = 
  Piecewise[{{(d + 2)/(2*unitSphereVolume) (1 - Dot[t, t]), 
     Dot[t, t] < 1}}, 0];

EV[t_] = Refine[D[t*epan[t], t], Element[t, Vectors[d]]];
V[t_] = Refine[EV[t^2] - (EV[t])^2, Element[t, Vectors[d]]];
FunctionExpand[V[x]]

Mathematica graphics

Change [_t] to [t_], pi to Pi

$Assumptions = {d >= 1, Element[d, Integers], Element[x, Vectors[d]]};
unitSphereVolume = Pi^(d/2)/Gamma[d/2 + 1];

epan[t_] = 
  Piecewise[{{(d + 2)/(2*unitSphereVolume) (1 - Dot[t, t]), 
     Dot[t, t] < 1}}, 0];

EV[t_] = Refine[D[t*epan[t], t], Element[t, Vectors[d]]];
V[t_] = Refine[EV[t^2] - (EV[t])^2, Element[t, Vectors[d]]];

FullSimplify@PiecewiseExpand@V[x]

Mathematica graphics

Source Link
rhermans
  • 37.4k
  • 4
  • 61
  • 152

Change [_t] to [t_], pi to Pi

$Assumptions = {d >= 1, Element[d, Integers], Element[x, Vectors[d]]};
unitSphereVolume = Pi^(d/2)/Gamma[d/2 + 1];

epan[t_] = 
  Piecewise[{{(d + 2)/(2*unitSphereVolume) (1 - Dot[t, t]), 
     Dot[t, t] < 1}}, 0];

EV[t_] = Refine[D[t*epan[t], t], Element[t, Vectors[d]]];
V[t_] = Refine[EV[t^2] - (EV[t])^2, Element[t, Vectors[d]]];
FunctionExpand[V[x]]

Mathematica graphics