Nanoparticle distribution

Hello.

I am trying to distribute nanoparticles by volume. I use the function G4VPVParameterisation ().

As a result, it was possible to distribute nanoparticles along the X and Y coordinates, I can’t distribute the nanoparticles of the Z coordinates.

Can someone help me?

: G4VPVParameterisation()
{
for (auto copyNo=0; copyNo<kNofEmCells; copyNo++) {
auto column = copyNo / kNofEmRows ;
auto row = copyNo % kNofEmRows;

// регулировать расположение точек по Х и У
fXCell[copyNo] = (column-1)1mm -1.*mm;
fYCell[copyNo] = (row-1)1mm - 1.*mm;}}

//…oooOO0OOooo…oooOO0OOooo…oooOO0OOooo…oooOO0OOooo…

AgParameterisation::~AgParameterisation()
{}
//…oooOO0OOooo…oooOO0OOooo…oooOO0OOooo…oooOO0OOooo…
void AgParameterisation::ComputeTransformation(
const G4int copyNo,G4VPhysicalVolume *physVol) const

{physVol->SetTranslation(G4ThreeVector(fXCell[copyNo],fYCell[copyNo],0));}

// copy Au
// задаем размеры наночастицы
G4Sphere *nAu2 = new G4Sphere(“nAu2”,
0 * cm,
0.1 * mm,
0. * deg,
360. * deg,
0. * deg,
360. * deg);

G4LogicalVolume *LnAu2= new G4LogicalVolume(nAu, Mat(“G4_Au”), “nAu”);

G4VPVParameterisation* AuParam = new AuParameterisation();
new G4PVParameterised(“cellPhysical”,LnAu,LDetPhBox,
kYAxis,kNofEmCells,AuParam);