At the begining i mentioned that red spheres was: 6 x 1 = 6
In my first post I questioned only 18x1/6 ! The rest was correct.
There are in total 21 blue spheres since there is 1 in the centre of each base and 6 around the edges for each base, based on the image I attached for Nickel Arsenide. How do I possibly reach that number with "8x1/8 + 4x1/4"? Since that only accounts for 12 spheres.
Your first crystallographic scheme (hexagonal prism contain 3 unit cells). The second scheme for NiAs is for 1 unit cell and calculations should be different. To 3 unit cells belong 6 As and 6 Ni; to 1 unit cell belongs 2 Ni and 2 As
summation of 21 blue spheres right?
from 21 blue spheres
1 belongs completely to hexagonal prism
2 are splited into 2 prisms
6 are splited into 3 prisms
12 are splited into 6 prisms. These give 6 blue spheres in 1 hexagonal prism.
In (my) scheme for 1 unit cell you have z position for these spheres 0, 1/2 and 1 (default not showed).
From these spheres that of positions 0 and 1, each sphere belongs to 8 unit cells, and that of positions 1/2 belongs to 4 unit cells. Sum is 8x1/8+4x1/4.
In my summation for correct unit cell of NiAs
Summation of atoms
As 8x1/8 + 4x1/4=2
Ni 2x1=2
there is an error - As and Ni should be interchanged (ie Ni=8x1/8+ 4x1/2 and As 2x1) My fault.