How to create nice-looking nuclei in TikZ?
Clash Royale CLAN TAG#URR8PPP
up vote
29
down vote
favorite
In the responses to Draw Bohr atomic model with electron shells in TeX?, there are nice drawings of atoms. However, the nuclei don't look very appealing or realistic.
I was wondering: Can anyone think of an algorithm to (semi-)automatically (for example in a randomized fashion) create large nuclei that look more realistic as for example the in the image attached?
It seems to be key that the balls are sufficiently spaced and that the spherical look requires more centered balls to be on top. Both requirements are not met with my code:
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 1,...,200
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:-r) circle (5pt);
endtikzpicture
enddocument
The result is:
tikz-pgf random
add a comment |Â
up vote
29
down vote
favorite
In the responses to Draw Bohr atomic model with electron shells in TeX?, there are nice drawings of atoms. However, the nuclei don't look very appealing or realistic.
I was wondering: Can anyone think of an algorithm to (semi-)automatically (for example in a randomized fashion) create large nuclei that look more realistic as for example the in the image attached?
It seems to be key that the balls are sufficiently spaced and that the spherical look requires more centered balls to be on top. Both requirements are not met with my code:
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 1,...,200
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:-r) circle (5pt);
endtikzpicture
enddocument
The result is:
tikz-pgf random
1
"More realistic" doesn't really make sense here. It's a quantum-mechanical object, and the wavefunctions all overlap.
– Ben Crowell
Sep 1 at 19:44
1
Agreed, at least in terms of physics. What I was shooting for was spheres somehow bunched together to form a bigger sphere...
– FlorianL
Sep 1 at 19:54
add a comment |Â
up vote
29
down vote
favorite
up vote
29
down vote
favorite
In the responses to Draw Bohr atomic model with electron shells in TeX?, there are nice drawings of atoms. However, the nuclei don't look very appealing or realistic.
I was wondering: Can anyone think of an algorithm to (semi-)automatically (for example in a randomized fashion) create large nuclei that look more realistic as for example the in the image attached?
It seems to be key that the balls are sufficiently spaced and that the spherical look requires more centered balls to be on top. Both requirements are not met with my code:
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 1,...,200
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:-r) circle (5pt);
endtikzpicture
enddocument
The result is:
tikz-pgf random
In the responses to Draw Bohr atomic model with electron shells in TeX?, there are nice drawings of atoms. However, the nuclei don't look very appealing or realistic.
I was wondering: Can anyone think of an algorithm to (semi-)automatically (for example in a randomized fashion) create large nuclei that look more realistic as for example the in the image attached?
It seems to be key that the balls are sufficiently spaced and that the spherical look requires more centered balls to be on top. Both requirements are not met with my code:
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 1,...,200
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:-r) circle (5pt);
endtikzpicture
enddocument
The result is:
tikz-pgf random
edited Aug 31 at 20:33


Milo
5,53321345
5,53321345
asked Aug 31 at 18:22


FlorianL
6731511
6731511
1
"More realistic" doesn't really make sense here. It's a quantum-mechanical object, and the wavefunctions all overlap.
– Ben Crowell
Sep 1 at 19:44
1
Agreed, at least in terms of physics. What I was shooting for was spheres somehow bunched together to form a bigger sphere...
– FlorianL
Sep 1 at 19:54
add a comment |Â
1
"More realistic" doesn't really make sense here. It's a quantum-mechanical object, and the wavefunctions all overlap.
– Ben Crowell
Sep 1 at 19:44
1
Agreed, at least in terms of physics. What I was shooting for was spheres somehow bunched together to form a bigger sphere...
– FlorianL
Sep 1 at 19:54
1
1
"More realistic" doesn't really make sense here. It's a quantum-mechanical object, and the wavefunctions all overlap.
– Ben Crowell
Sep 1 at 19:44
"More realistic" doesn't really make sense here. It's a quantum-mechanical object, and the wavefunctions all overlap.
– Ben Crowell
Sep 1 at 19:44
1
1
Agreed, at least in terms of physics. What I was shooting for was spheres somehow bunched together to form a bigger sphere...
– FlorianL
Sep 1 at 19:54
Agreed, at least in terms of physics. What I was shooting for was spheres somehow bunched together to form a bigger sphere...
– FlorianL
Sep 1 at 19:54
add a comment |Â
3 Answers
3
active
oldest
votes
up vote
37
down vote
accepted
Here is a proposal that makes the nucleus look more like a compact ball. It works by building up circular rings starting from the outside in. By adjusting the number of protons/neutrons in each ring and its distance from the center, you can create a ball effect.
documentclassstandalone
usepackagetikz
usepackage[version=4]mhchem
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
pgfmathsetseed1
foreach A/R in 25/1,12/0.9,15/0.8,20/0.7,12/0.5,7/0.3,1/0
pgfmathsetmacroS360/A
foreach B in 0,S,...,360
pgfmathrandomitemCcolor
shade[ball color=C] (B+A:R) circle (5pt);
node at (-1,1.3) ce^226_88Ra;
endtikzpicture
enddocument
3
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
add a comment |Â
up vote
13
down vote
Based on your code, I first draw protons/neutrons following a circular pattern three times, at radius 1, 0.5 and 0.2. I also draw random protons/neutrons in between.
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 0,10,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:1) circle (5pt);
foreach a in 0,20,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.5) circle (5pt);
foreach a in 1,...,350
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:r) circle (5pt);
foreach a in 0,60,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.2) circle (5pt);
endtikzpicture
enddocument
The results is:
add a comment |Â
up vote
7
down vote
Here is another version in which the spheres are put on the root lattice of A_3 and allowed to wiggle a bit. More explanations can be found here.
documentclass[tikz,border=3.14mm]standalone
usepackagetikz-3dplot
usetikzlibrary3d
tikzsetdeclare function=posx(x,y,z)=x-y/2;
posy(x,y,z)=y/sqrt(2);
posz(x,y,z)=-y/2+z;
newsaveboxProton
newsaveboxNeutron
sboxProtontikzshade[ball color=red] circle(0.85/sqrt(2));
sboxNeutrontikzshade[ball color=gray!20] circle(0.85/sqrt(2));
begindocument
xdefLst-1, 0, 2, -2, -1, 1,
0, 0, 2, -1, -1, 1,
-2, -2, 0, -1, 1, 2,
-2, 0, 1, 1, 0, 2, 0, -1, 1,
-1, -2, 0, -2, -3, -1,
0, 1, 2, -1, 0, 1,
-2, -1, 0, 1, -1, 1,
0, -2, 0, -1, -3, -1,
1, 1, 2, 0, 0, 1, -1, -1, 0,
-2, -2, -1, 0, 2, 2,
-1, 1, 1, 2, 1, 2, -2, 0, 0,
1, 0, 1, 0, -1, 0,
-1, -2, -1, -2, -3, -2,
1, 2, 2, 0, 1, 1, -1, 0, 0,
2, 0, 1, -2, -1, -1,
1, -1, 0, 0, -2, -1,
-1, -3, -2, 2, 2, 2,
1, 1, 1, 0, 0, 0,
-1, -1, -1, -2, -2, -2,
1, 3, 2, 0, 2, 1, -1, 1, 0,
2, 1, 1, -2, 0, -1, 1, 0, 0,
0, -1, -1, -1, -2, -2,
2, 3, 2, 1, 2, 1, 0, 1, 0,
-1, 0, -1, 2, 0, 0,
-2, -1, -2, 1, -1, -1,
0, -2, -2, 2, 2, 1, 1, 1, 0,
0, 0, -1, -1, -1, -2,
1, 3, 1, 0, 2, 0, -1, 1, -1,
2, 1, 0, 1, 0, -1,
0, -1, -2, 2, 3, 1, 1, 2, 0,
0, 1, -1, -1, 0, -2,
2, 0, -1, 1, -1, -2,
2, 2, 0, 1, 1, -1, 0, 0, -2,
2, 1, -1, 1, 0, -2
tdplotsetmaincoords-90+109.471-90+70
foreach X in 1,...,10
begintikzpicture
path[use as bounding box] (-3.5,-3.5) rectangle (3.5,3.5);
draw (0,0) circle (1); % /sqrt(2)
beginscope[tdplot_main_coords]
draw[-latex] (0,0,0) coordinate (O) -- (1,0,0) node[right]$alpha_1$;
draw[-latex] (O) -- (-1/2,1/sqrt(2),-1/2) node[right]$alpha_2$;
draw[-latex] (O) -- (0,0,1) node[right]$alpha_3$;
draw[red,-latex] (O) -- (1/2,1/sqrt(2),1/2) node[right]$-theta$;
foreach Z in Lst
pgfmathsetmacromyxZ[0]
pgfmathsetmacromyyZ[1]
pgfmathsetmacromyzZ[2]
pgfmathsetmacromydeltax0.1*(rnd-0.5)
pgfmathsetmacromydeltay0.1*(rnd-0.5)
pgfmathsetmacromydeltaz0.1*(rnd-0.5)
pgfmathtruncatemacromycolint(2*rnd)
ifnummycol=1
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxNeutron;
else
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxProton;
fi
endscope
endtikzpicture
enddocument
Just for fun: more nuclei. And no, it does not look like sphere, but like a set of sphere which are packed with maximum density. This is of course not the same as demanding that the nuclei should fill out a sphere. The latter might translate in the requirement that the sum of distances gets minimized or something like that, which obviously is not the same requirement as maximal packing. I do not know if there is a simple algorithm that minimizes the sum of distances while making sure the spheres do not overlap.
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
1
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
1
@FlorianL Well, you could define your own version:tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.
– marmot
Sep 1 at 20:57
 |Â
show 3 more comments
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
37
down vote
accepted
Here is a proposal that makes the nucleus look more like a compact ball. It works by building up circular rings starting from the outside in. By adjusting the number of protons/neutrons in each ring and its distance from the center, you can create a ball effect.
documentclassstandalone
usepackagetikz
usepackage[version=4]mhchem
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
pgfmathsetseed1
foreach A/R in 25/1,12/0.9,15/0.8,20/0.7,12/0.5,7/0.3,1/0
pgfmathsetmacroS360/A
foreach B in 0,S,...,360
pgfmathrandomitemCcolor
shade[ball color=C] (B+A:R) circle (5pt);
node at (-1,1.3) ce^226_88Ra;
endtikzpicture
enddocument
3
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
add a comment |Â
up vote
37
down vote
accepted
Here is a proposal that makes the nucleus look more like a compact ball. It works by building up circular rings starting from the outside in. By adjusting the number of protons/neutrons in each ring and its distance from the center, you can create a ball effect.
documentclassstandalone
usepackagetikz
usepackage[version=4]mhchem
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
pgfmathsetseed1
foreach A/R in 25/1,12/0.9,15/0.8,20/0.7,12/0.5,7/0.3,1/0
pgfmathsetmacroS360/A
foreach B in 0,S,...,360
pgfmathrandomitemCcolor
shade[ball color=C] (B+A:R) circle (5pt);
node at (-1,1.3) ce^226_88Ra;
endtikzpicture
enddocument
3
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
add a comment |Â
up vote
37
down vote
accepted
up vote
37
down vote
accepted
Here is a proposal that makes the nucleus look more like a compact ball. It works by building up circular rings starting from the outside in. By adjusting the number of protons/neutrons in each ring and its distance from the center, you can create a ball effect.
documentclassstandalone
usepackagetikz
usepackage[version=4]mhchem
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
pgfmathsetseed1
foreach A/R in 25/1,12/0.9,15/0.8,20/0.7,12/0.5,7/0.3,1/0
pgfmathsetmacroS360/A
foreach B in 0,S,...,360
pgfmathrandomitemCcolor
shade[ball color=C] (B+A:R) circle (5pt);
node at (-1,1.3) ce^226_88Ra;
endtikzpicture
enddocument
Here is a proposal that makes the nucleus look more like a compact ball. It works by building up circular rings starting from the outside in. By adjusting the number of protons/neutrons in each ring and its distance from the center, you can create a ball effect.
documentclassstandalone
usepackagetikz
usepackage[version=4]mhchem
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
pgfmathsetseed1
foreach A/R in 25/1,12/0.9,15/0.8,20/0.7,12/0.5,7/0.3,1/0
pgfmathsetmacroS360/A
foreach B in 0,S,...,360
pgfmathrandomitemCcolor
shade[ball color=C] (B+A:R) circle (5pt);
node at (-1,1.3) ce^226_88Ra;
endtikzpicture
enddocument
edited Aug 31 at 22:27
answered Aug 31 at 20:12


Milo
5,53321345
5,53321345
3
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
add a comment |Â
3
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
3
3
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
+1, again excellent work.
– Sebastiano
Sep 1 at 1:40
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
Excellent, thanks!
– FlorianL
Sep 1 at 19:41
add a comment |Â
up vote
13
down vote
Based on your code, I first draw protons/neutrons following a circular pattern three times, at radius 1, 0.5 and 0.2. I also draw random protons/neutrons in between.
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 0,10,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:1) circle (5pt);
foreach a in 0,20,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.5) circle (5pt);
foreach a in 1,...,350
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:r) circle (5pt);
foreach a in 0,60,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.2) circle (5pt);
endtikzpicture
enddocument
The results is:
add a comment |Â
up vote
13
down vote
Based on your code, I first draw protons/neutrons following a circular pattern three times, at radius 1, 0.5 and 0.2. I also draw random protons/neutrons in between.
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 0,10,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:1) circle (5pt);
foreach a in 0,20,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.5) circle (5pt);
foreach a in 1,...,350
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:r) circle (5pt);
foreach a in 0,60,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.2) circle (5pt);
endtikzpicture
enddocument
The results is:
add a comment |Â
up vote
13
down vote
up vote
13
down vote
Based on your code, I first draw protons/neutrons following a circular pattern three times, at radius 1, 0.5 and 0.2. I also draw random protons/neutrons in between.
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 0,10,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:1) circle (5pt);
foreach a in 0,20,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.5) circle (5pt);
foreach a in 1,...,350
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:r) circle (5pt);
foreach a in 0,60,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.2) circle (5pt);
endtikzpicture
enddocument
The results is:
Based on your code, I first draw protons/neutrons following a circular pattern three times, at radius 1, 0.5 and 0.2. I also draw random protons/neutrons in between.
documentclassstandalone
usepackagetikz
begindocument
begintikzpicture
path (-2,-2) rectangle (2,2);
pgfmathdeclarerandomlistcolorredwhite
foreach a in 0,10,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:1) circle (5pt);
foreach a in 0,20,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.5) circle (5pt);
foreach a in 1,...,350
pgfmathsetmacrorrnd
pgfmathsetmacroarandom(0,360)
pgfmathrandomitemccolor
shade[ball color=c] (a:r) circle (5pt);
foreach a in 0,60,...,360
pgfmathrandomitemccolor
shade[ball color=c] (a:0.2) circle (5pt);
endtikzpicture
enddocument
The results is:
edited Sep 1 at 6:30


current_user
2,514428
2,514428
answered Aug 31 at 19:29


Ignacio Correa
583111
583111
add a comment |Â
add a comment |Â
up vote
7
down vote
Here is another version in which the spheres are put on the root lattice of A_3 and allowed to wiggle a bit. More explanations can be found here.
documentclass[tikz,border=3.14mm]standalone
usepackagetikz-3dplot
usetikzlibrary3d
tikzsetdeclare function=posx(x,y,z)=x-y/2;
posy(x,y,z)=y/sqrt(2);
posz(x,y,z)=-y/2+z;
newsaveboxProton
newsaveboxNeutron
sboxProtontikzshade[ball color=red] circle(0.85/sqrt(2));
sboxNeutrontikzshade[ball color=gray!20] circle(0.85/sqrt(2));
begindocument
xdefLst-1, 0, 2, -2, -1, 1,
0, 0, 2, -1, -1, 1,
-2, -2, 0, -1, 1, 2,
-2, 0, 1, 1, 0, 2, 0, -1, 1,
-1, -2, 0, -2, -3, -1,
0, 1, 2, -1, 0, 1,
-2, -1, 0, 1, -1, 1,
0, -2, 0, -1, -3, -1,
1, 1, 2, 0, 0, 1, -1, -1, 0,
-2, -2, -1, 0, 2, 2,
-1, 1, 1, 2, 1, 2, -2, 0, 0,
1, 0, 1, 0, -1, 0,
-1, -2, -1, -2, -3, -2,
1, 2, 2, 0, 1, 1, -1, 0, 0,
2, 0, 1, -2, -1, -1,
1, -1, 0, 0, -2, -1,
-1, -3, -2, 2, 2, 2,
1, 1, 1, 0, 0, 0,
-1, -1, -1, -2, -2, -2,
1, 3, 2, 0, 2, 1, -1, 1, 0,
2, 1, 1, -2, 0, -1, 1, 0, 0,
0, -1, -1, -1, -2, -2,
2, 3, 2, 1, 2, 1, 0, 1, 0,
-1, 0, -1, 2, 0, 0,
-2, -1, -2, 1, -1, -1,
0, -2, -2, 2, 2, 1, 1, 1, 0,
0, 0, -1, -1, -1, -2,
1, 3, 1, 0, 2, 0, -1, 1, -1,
2, 1, 0, 1, 0, -1,
0, -1, -2, 2, 3, 1, 1, 2, 0,
0, 1, -1, -1, 0, -2,
2, 0, -1, 1, -1, -2,
2, 2, 0, 1, 1, -1, 0, 0, -2,
2, 1, -1, 1, 0, -2
tdplotsetmaincoords-90+109.471-90+70
foreach X in 1,...,10
begintikzpicture
path[use as bounding box] (-3.5,-3.5) rectangle (3.5,3.5);
draw (0,0) circle (1); % /sqrt(2)
beginscope[tdplot_main_coords]
draw[-latex] (0,0,0) coordinate (O) -- (1,0,0) node[right]$alpha_1$;
draw[-latex] (O) -- (-1/2,1/sqrt(2),-1/2) node[right]$alpha_2$;
draw[-latex] (O) -- (0,0,1) node[right]$alpha_3$;
draw[red,-latex] (O) -- (1/2,1/sqrt(2),1/2) node[right]$-theta$;
foreach Z in Lst
pgfmathsetmacromyxZ[0]
pgfmathsetmacromyyZ[1]
pgfmathsetmacromyzZ[2]
pgfmathsetmacromydeltax0.1*(rnd-0.5)
pgfmathsetmacromydeltay0.1*(rnd-0.5)
pgfmathsetmacromydeltaz0.1*(rnd-0.5)
pgfmathtruncatemacromycolint(2*rnd)
ifnummycol=1
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxNeutron;
else
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxProton;
fi
endscope
endtikzpicture
enddocument
Just for fun: more nuclei. And no, it does not look like sphere, but like a set of sphere which are packed with maximum density. This is of course not the same as demanding that the nuclei should fill out a sphere. The latter might translate in the requirement that the sum of distances gets minimized or something like that, which obviously is not the same requirement as maximal packing. I do not know if there is a simple algorithm that minimizes the sum of distances while making sure the spheres do not overlap.
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
1
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
1
@FlorianL Well, you could define your own version:tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.
– marmot
Sep 1 at 20:57
 |Â
show 3 more comments
up vote
7
down vote
Here is another version in which the spheres are put on the root lattice of A_3 and allowed to wiggle a bit. More explanations can be found here.
documentclass[tikz,border=3.14mm]standalone
usepackagetikz-3dplot
usetikzlibrary3d
tikzsetdeclare function=posx(x,y,z)=x-y/2;
posy(x,y,z)=y/sqrt(2);
posz(x,y,z)=-y/2+z;
newsaveboxProton
newsaveboxNeutron
sboxProtontikzshade[ball color=red] circle(0.85/sqrt(2));
sboxNeutrontikzshade[ball color=gray!20] circle(0.85/sqrt(2));
begindocument
xdefLst-1, 0, 2, -2, -1, 1,
0, 0, 2, -1, -1, 1,
-2, -2, 0, -1, 1, 2,
-2, 0, 1, 1, 0, 2, 0, -1, 1,
-1, -2, 0, -2, -3, -1,
0, 1, 2, -1, 0, 1,
-2, -1, 0, 1, -1, 1,
0, -2, 0, -1, -3, -1,
1, 1, 2, 0, 0, 1, -1, -1, 0,
-2, -2, -1, 0, 2, 2,
-1, 1, 1, 2, 1, 2, -2, 0, 0,
1, 0, 1, 0, -1, 0,
-1, -2, -1, -2, -3, -2,
1, 2, 2, 0, 1, 1, -1, 0, 0,
2, 0, 1, -2, -1, -1,
1, -1, 0, 0, -2, -1,
-1, -3, -2, 2, 2, 2,
1, 1, 1, 0, 0, 0,
-1, -1, -1, -2, -2, -2,
1, 3, 2, 0, 2, 1, -1, 1, 0,
2, 1, 1, -2, 0, -1, 1, 0, 0,
0, -1, -1, -1, -2, -2,
2, 3, 2, 1, 2, 1, 0, 1, 0,
-1, 0, -1, 2, 0, 0,
-2, -1, -2, 1, -1, -1,
0, -2, -2, 2, 2, 1, 1, 1, 0,
0, 0, -1, -1, -1, -2,
1, 3, 1, 0, 2, 0, -1, 1, -1,
2, 1, 0, 1, 0, -1,
0, -1, -2, 2, 3, 1, 1, 2, 0,
0, 1, -1, -1, 0, -2,
2, 0, -1, 1, -1, -2,
2, 2, 0, 1, 1, -1, 0, 0, -2,
2, 1, -1, 1, 0, -2
tdplotsetmaincoords-90+109.471-90+70
foreach X in 1,...,10
begintikzpicture
path[use as bounding box] (-3.5,-3.5) rectangle (3.5,3.5);
draw (0,0) circle (1); % /sqrt(2)
beginscope[tdplot_main_coords]
draw[-latex] (0,0,0) coordinate (O) -- (1,0,0) node[right]$alpha_1$;
draw[-latex] (O) -- (-1/2,1/sqrt(2),-1/2) node[right]$alpha_2$;
draw[-latex] (O) -- (0,0,1) node[right]$alpha_3$;
draw[red,-latex] (O) -- (1/2,1/sqrt(2),1/2) node[right]$-theta$;
foreach Z in Lst
pgfmathsetmacromyxZ[0]
pgfmathsetmacromyyZ[1]
pgfmathsetmacromyzZ[2]
pgfmathsetmacromydeltax0.1*(rnd-0.5)
pgfmathsetmacromydeltay0.1*(rnd-0.5)
pgfmathsetmacromydeltaz0.1*(rnd-0.5)
pgfmathtruncatemacromycolint(2*rnd)
ifnummycol=1
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxNeutron;
else
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxProton;
fi
endscope
endtikzpicture
enddocument
Just for fun: more nuclei. And no, it does not look like sphere, but like a set of sphere which are packed with maximum density. This is of course not the same as demanding that the nuclei should fill out a sphere. The latter might translate in the requirement that the sum of distances gets minimized or something like that, which obviously is not the same requirement as maximal packing. I do not know if there is a simple algorithm that minimizes the sum of distances while making sure the spheres do not overlap.
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
1
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
1
@FlorianL Well, you could define your own version:tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.
– marmot
Sep 1 at 20:57
 |Â
show 3 more comments
up vote
7
down vote
up vote
7
down vote
Here is another version in which the spheres are put on the root lattice of A_3 and allowed to wiggle a bit. More explanations can be found here.
documentclass[tikz,border=3.14mm]standalone
usepackagetikz-3dplot
usetikzlibrary3d
tikzsetdeclare function=posx(x,y,z)=x-y/2;
posy(x,y,z)=y/sqrt(2);
posz(x,y,z)=-y/2+z;
newsaveboxProton
newsaveboxNeutron
sboxProtontikzshade[ball color=red] circle(0.85/sqrt(2));
sboxNeutrontikzshade[ball color=gray!20] circle(0.85/sqrt(2));
begindocument
xdefLst-1, 0, 2, -2, -1, 1,
0, 0, 2, -1, -1, 1,
-2, -2, 0, -1, 1, 2,
-2, 0, 1, 1, 0, 2, 0, -1, 1,
-1, -2, 0, -2, -3, -1,
0, 1, 2, -1, 0, 1,
-2, -1, 0, 1, -1, 1,
0, -2, 0, -1, -3, -1,
1, 1, 2, 0, 0, 1, -1, -1, 0,
-2, -2, -1, 0, 2, 2,
-1, 1, 1, 2, 1, 2, -2, 0, 0,
1, 0, 1, 0, -1, 0,
-1, -2, -1, -2, -3, -2,
1, 2, 2, 0, 1, 1, -1, 0, 0,
2, 0, 1, -2, -1, -1,
1, -1, 0, 0, -2, -1,
-1, -3, -2, 2, 2, 2,
1, 1, 1, 0, 0, 0,
-1, -1, -1, -2, -2, -2,
1, 3, 2, 0, 2, 1, -1, 1, 0,
2, 1, 1, -2, 0, -1, 1, 0, 0,
0, -1, -1, -1, -2, -2,
2, 3, 2, 1, 2, 1, 0, 1, 0,
-1, 0, -1, 2, 0, 0,
-2, -1, -2, 1, -1, -1,
0, -2, -2, 2, 2, 1, 1, 1, 0,
0, 0, -1, -1, -1, -2,
1, 3, 1, 0, 2, 0, -1, 1, -1,
2, 1, 0, 1, 0, -1,
0, -1, -2, 2, 3, 1, 1, 2, 0,
0, 1, -1, -1, 0, -2,
2, 0, -1, 1, -1, -2,
2, 2, 0, 1, 1, -1, 0, 0, -2,
2, 1, -1, 1, 0, -2
tdplotsetmaincoords-90+109.471-90+70
foreach X in 1,...,10
begintikzpicture
path[use as bounding box] (-3.5,-3.5) rectangle (3.5,3.5);
draw (0,0) circle (1); % /sqrt(2)
beginscope[tdplot_main_coords]
draw[-latex] (0,0,0) coordinate (O) -- (1,0,0) node[right]$alpha_1$;
draw[-latex] (O) -- (-1/2,1/sqrt(2),-1/2) node[right]$alpha_2$;
draw[-latex] (O) -- (0,0,1) node[right]$alpha_3$;
draw[red,-latex] (O) -- (1/2,1/sqrt(2),1/2) node[right]$-theta$;
foreach Z in Lst
pgfmathsetmacromyxZ[0]
pgfmathsetmacromyyZ[1]
pgfmathsetmacromyzZ[2]
pgfmathsetmacromydeltax0.1*(rnd-0.5)
pgfmathsetmacromydeltay0.1*(rnd-0.5)
pgfmathsetmacromydeltaz0.1*(rnd-0.5)
pgfmathtruncatemacromycolint(2*rnd)
ifnummycol=1
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxNeutron;
else
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxProton;
fi
endscope
endtikzpicture
enddocument
Just for fun: more nuclei. And no, it does not look like sphere, but like a set of sphere which are packed with maximum density. This is of course not the same as demanding that the nuclei should fill out a sphere. The latter might translate in the requirement that the sum of distances gets minimized or something like that, which obviously is not the same requirement as maximal packing. I do not know if there is a simple algorithm that minimizes the sum of distances while making sure the spheres do not overlap.
Here is another version in which the spheres are put on the root lattice of A_3 and allowed to wiggle a bit. More explanations can be found here.
documentclass[tikz,border=3.14mm]standalone
usepackagetikz-3dplot
usetikzlibrary3d
tikzsetdeclare function=posx(x,y,z)=x-y/2;
posy(x,y,z)=y/sqrt(2);
posz(x,y,z)=-y/2+z;
newsaveboxProton
newsaveboxNeutron
sboxProtontikzshade[ball color=red] circle(0.85/sqrt(2));
sboxNeutrontikzshade[ball color=gray!20] circle(0.85/sqrt(2));
begindocument
xdefLst-1, 0, 2, -2, -1, 1,
0, 0, 2, -1, -1, 1,
-2, -2, 0, -1, 1, 2,
-2, 0, 1, 1, 0, 2, 0, -1, 1,
-1, -2, 0, -2, -3, -1,
0, 1, 2, -1, 0, 1,
-2, -1, 0, 1, -1, 1,
0, -2, 0, -1, -3, -1,
1, 1, 2, 0, 0, 1, -1, -1, 0,
-2, -2, -1, 0, 2, 2,
-1, 1, 1, 2, 1, 2, -2, 0, 0,
1, 0, 1, 0, -1, 0,
-1, -2, -1, -2, -3, -2,
1, 2, 2, 0, 1, 1, -1, 0, 0,
2, 0, 1, -2, -1, -1,
1, -1, 0, 0, -2, -1,
-1, -3, -2, 2, 2, 2,
1, 1, 1, 0, 0, 0,
-1, -1, -1, -2, -2, -2,
1, 3, 2, 0, 2, 1, -1, 1, 0,
2, 1, 1, -2, 0, -1, 1, 0, 0,
0, -1, -1, -1, -2, -2,
2, 3, 2, 1, 2, 1, 0, 1, 0,
-1, 0, -1, 2, 0, 0,
-2, -1, -2, 1, -1, -1,
0, -2, -2, 2, 2, 1, 1, 1, 0,
0, 0, -1, -1, -1, -2,
1, 3, 1, 0, 2, 0, -1, 1, -1,
2, 1, 0, 1, 0, -1,
0, -1, -2, 2, 3, 1, 1, 2, 0,
0, 1, -1, -1, 0, -2,
2, 0, -1, 1, -1, -2,
2, 2, 0, 1, 1, -1, 0, 0, -2,
2, 1, -1, 1, 0, -2
tdplotsetmaincoords-90+109.471-90+70
foreach X in 1,...,10
begintikzpicture
path[use as bounding box] (-3.5,-3.5) rectangle (3.5,3.5);
draw (0,0) circle (1); % /sqrt(2)
beginscope[tdplot_main_coords]
draw[-latex] (0,0,0) coordinate (O) -- (1,0,0) node[right]$alpha_1$;
draw[-latex] (O) -- (-1/2,1/sqrt(2),-1/2) node[right]$alpha_2$;
draw[-latex] (O) -- (0,0,1) node[right]$alpha_3$;
draw[red,-latex] (O) -- (1/2,1/sqrt(2),1/2) node[right]$-theta$;
foreach Z in Lst
pgfmathsetmacromyxZ[0]
pgfmathsetmacromyyZ[1]
pgfmathsetmacromyzZ[2]
pgfmathsetmacromydeltax0.1*(rnd-0.5)
pgfmathsetmacromydeltay0.1*(rnd-0.5)
pgfmathsetmacromydeltaz0.1*(rnd-0.5)
pgfmathtruncatemacromycolint(2*rnd)
ifnummycol=1
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxNeutron;
else
node at (posx(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posy(myx+mydeltax,myy+mydeltay,myz+mydeltaz),
posz(myx+mydeltax,myy+mydeltay,myz+mydeltaz)) useboxProton;
fi
endscope
endtikzpicture
enddocument
Just for fun: more nuclei. And no, it does not look like sphere, but like a set of sphere which are packed with maximum density. This is of course not the same as demanding that the nuclei should fill out a sphere. The latter might translate in the requirement that the sum of distances gets minimized or something like that, which obviously is not the same requirement as maximal packing. I do not know if there is a simple algorithm that minimizes the sum of distances while making sure the spheres do not overlap.
edited Sep 1 at 16:45
answered Sep 1 at 15:41


marmot
56.2k461122
56.2k461122
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
1
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
1
@FlorianL Well, you could define your own version:tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.
– marmot
Sep 1 at 20:57
 |Â
show 3 more comments
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
1
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
1
@FlorianL Well, you could define your own version:tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.
– marmot
Sep 1 at 20:57
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
+1, but somehow this looks not exactly spherical…
– TeXnician
Sep 1 at 15:56
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
@TeXnician It might be that I did something wrong but they are not supposed to look spherical. More precisely, they will approach a sphere in the limit of infinitely many spheres. Just do a 2D example and pack two circles. Does that look like a bigger circle? Definitely not. Same for any finite amount of circles. You will arrange them on a hexagonal lattice and put them as close as possible to a center, but the emerging shape is never a precise circle as long as you have a finite number of circles. This here is the 3D version of that (I hope).
– marmot
Sep 1 at 16:02
1
1
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
Yes, I understand the approach which is interesting, I just understood the OP to reproduce a "spherical look", but who knows how realistic either of these representations is :)
– TeXnician
Sep 1 at 16:06
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
@TeXnician Well, in reality nuclei are not spheres, and the interactions between them cannot be described by a spherical potential, rather there are the dominant strong interactions plus a bit of electromagnetic interactions. This lattice packing allows you to partly understand why there are these magical numbers. And I think that this approach comes close to the OP's version if I increase the number of spheres. Just fill a hexagonal lattice with a huge number of circles around a center, and it will approach a circle. If the number of circles is smaller, it will have "edges".
– marmot
Sep 1 at 16:09
1
1
@FlorianL Well, you could define your own version:
tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.– marmot
Sep 1 at 20:57
@FlorianL Well, you could define your own version:
tikzsetdeclare function=Veclen(x,y,z)=sqrt(x*x+y*y+z*z);
. However, I am not sure if my result is more physical. Apart from the fact that nuclei are not spheres, my procedure produces something that has only discrete rotational symmetries, but I don't see a reason why a nucleus should have some preferred axes. I think all of these are just cartoons, and among the proposals so far, IMHO Milo's nice answer is the winner. It is nicer and TeX only.– marmot
Sep 1 at 20:57
 |Â
show 3 more comments
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f448733%2fhow-to-create-nice-looking-nuclei-in-tikz%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
1
"More realistic" doesn't really make sense here. It's a quantum-mechanical object, and the wavefunctions all overlap.
– Ben Crowell
Sep 1 at 19:44
1
Agreed, at least in terms of physics. What I was shooting for was spheres somehow bunched together to form a bigger sphere...
– FlorianL
Sep 1 at 19:54