S&E Modules

Computations with Synergetics volume modules

"""
From David Koski's paper:

Revisiting R.B. Fuller's S & E Modules

--------
The concentric hierarchy can be described in terms of 
phi-scaled S modules: 

Tetrahedron:  21S +  5s3 =  5S3 + 1S = 1S6 + 1S3 
Cube       :  72S + 15s3 = 15S3 + 3S = 3S6 + 3S3 
Octahedron :  84S + 20s3 = 20S3 + 4S = 4S6 + 4S3 
Rh Triac   : 105S + 25s3 = 25s3 + 5S = 5S6 + 5S3 (volume = 5) 
Rh Dodec   : 126S + 30s3 = 30S3 + 6S = 6S6 + 6S3
--------

On-line:  http://coffeeshopsnet.blogspot.com/2017/06/koski-paper.html
"""
from math import sqrt as rt2

φ  = (rt2(5)+1)/2      # golden ratio
S3 = rt2(9/8)          # not to be confused with Smod

Smod = (φ **-5)/2      # home base Smod
smod3 = Smod  * φ**-3  # small s, phi down
Smod3 = Smod  * φ**3   # capital s, phi up
Smod6 = Smod3 * φ**3   # phi up yet again

cubocta = 20
SuperRT = S3 * cubocta

Emod3 = SuperRT / 120          # Emod phi up
Emod = (rt2(2)/8) * (φ ** -3)  # home base Emod
emod3 = Emod * φ ** -3         # Emod phi down

S_factor = Smod / Emod

print("Volume of SuperRT : {:10.6f}".format(SuperRT))
print("Volume of Cubocta : {:10.6f}".format(cubocta))
# print("Volume of Icosa   : {:10.6f}".format(20 * 1/S_factor))
# print("Volume of Icosa   : {:10.6f}".format(420 * Emod + 100 * emod3))
print("Volume of Icosa   : {:10.6f}".format(100*Emod3 + 20*Emod))
print("Volume of Octa    : {:10.6f}".format(4*Smod6 + 4*Smod3))
print("Volume of Cube    : {:10.6f}".format(3*Smod6 + 3*Smod3))
print("Volume of Tetra   : {:10.6f}".format(5*Smod3 + Smod))


print("Emod3             : {:10.6f}".format(Emod3)) 
print("Emod              : {:10.6f}".format(Emod)) 
print("emod3             : {:10.6f}".format(emod3)) 

# DEMO 2
print("-" * 20)

SmallVE = 20 * 1/8  # half D edges (=R)
SkewIcosa = SmallVE * S_factor * S_factor
Octa = 4
Smod_check = (Octa - SkewIcosa)/24
print("Smod              : {:10.6f}".format(Smod))
print("Smod              : {:10.6f}".format(Smod_check))