Saturday, March 10, 2018

mathematics - Find the word with the highest normalized product of letter-prime values where A=2, B=3, C=5, ..., Z=101


Which word has the highest normalized score according to the following:



  • Assign each individual letter A..Z of an (English) word a value corresponding to the n'th prime (see table below).

  • Take the product of its letter values.

  • Normalization: Take the log10 of that product, and divide by the wordlength.

  • (See Python example code below)

  • Please state the wordlength along with its score



Examples:



  • SYZYGY = 1.83686.. (6 letters)

  • WOW = 1.83675.. (3 letters)

  • SYZYGIUM = 1.73403.. (8 letters)

  • WOODWORKING = 1.56381.. (11 letters)


(The normalization is to prefer everyday English words over IUPAC chemical names or 'Pneumonoultramicroscopicsilicovolcanoconiosis').


Letter values A:2 B:3 C:5 D:7 E:11 F:13 G:17 H:19 I:23 J:29 K:31 L:37 M:41 N:43 O:47 P:53 Q:59 R:61 S:67 T:71 U:73 V:79 W:83 X:89 Y:97 Z:101


Some Python example code:



import string
from math import log10

primes = { letter_prime[0]:letter_prime[1] for letter_prime in zip(string.ascii_uppercase, [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101])}
{'A': 2, 'B': 3, 'C': 5, 'D': 7, 'E': 11, 'F': 13, 'G': 17, 'H': 19, 'I': 23, 'J': 29, 'K': 31, 'L': 37, 'M': 41, 'N': 43, 'O': 47, 'P': 53, 'Q': 59, 'R': 61, 'S': 67, 'T': 71, 'U': 73, 'V': 79, 'W': 83, 'X': 89, 'Y': 97, 'Z': 101}

def letter_prime_score(word):
prod = 1
for letter in word:
prod *= primes[letter]

return log10(prod) / len(word)

letter_prime_score('SYZYGY')
1.8368600501100796

letter_prime_score('WOW')
1.8367513475626218

letter_prime_score('SYZYGIUM')
1.734027889906502


letter_prime_score('WOODWORKING')
1.5638076854903682

Answer



The word that I got was ZYZZYVA, a valid Scrabble word, and a type of snouted beetle, most famous for being the final word in the dictionary. The total points are 1013×972×79×2, which is equal to 1.5316681×1012. If we normalize this by taking the logarithm and dividing by the number of letters in the word, we get log1.5316681×101271.74073781098.


In comparison, SYZYGIUM results in log7451146790488981.73402788991.


WOODWORKING results in log159178548575947607111.56380768549.


PNEUMONOULTRAMICROSCOPICSILICOVOLCANOCONIOSIS results in log2.09×1065451.45155880636.


Update On the other hand, my first suggestion punished long words as much as it favoured small words. Therefore:


1 letter: I results in log2311.36172783602.

2 letter: XU results in log73×8921.90635643338.
Note: This word found by @Herb Wolfe! Go upvote their answer!! :D
3 letter: ZZZ results in log103030132.00432137378.
Note: Check the link for ZZZ, it's in the Merriam Scrabble Dictionary!
4 letter: ZIZZ results in log2369692341.84367298934.
Note: Apparently ZIZZ is in the Merrriam Scrabble Dictionary too!
5 letter: ZZYZX results in log869471013951.98785102165.
6 letter: ZYZZYX results in log86277508770161.98931626609.
Note: This word found by @peaceoutside! Go upvote their answer!! :D
7 letter: ZYZZYVA results in log1.5316681×101271.74073781098.

8 letter: ZYZZYZUS results in log4.7887992×101581.96002832831.


No comments:

Post a Comment

classical mechanics - Moment of a force about a given axis (Torque) - Scalar or vectorial?

I am studying Statics and saw that: The moment of a force about a given axis (or Torque) is defined by the equation: $M_X = (\vec r \times \...