Old Persian cuneiform was the main script for writing the Old Persian language from 525-330 BC. Visually it resembles Sumero-Akkadian cuneiform; most of the letters are arrangements of between two and five horizontal, vertical or angle-shaped wedges. However, there appears to be no derivational relationship between the sound-to-symbol mapping of individual letters in the two scripts, nor has any other script been found which links the forms of the scripts. For this reason, Old Persian cuneiform is generally believed to have been an independent invention.
Old Persian was written from left to right and encoded three vowel ([a/a:], [i/i:] and [u/u:]) and twenty-two consonant sounds using three vowel and thirty-three consonant letters. Vowel length was generally not indicated; the exception to this was a long [a:] vowel. All vowels except for short [a] were written, so the script was essentially an alphabet, with some syllabic properties.
The twenty-two consonant signs were of two types. For thirteen consonant sounds, the following vowel sound was represented by the following vowel sign (or lack thereof). These consonants contained an inherent short 'a' vowel; when this vowel was missing its absence was not indicated in any way. So p = [p] or [pa]. When the letter was followed by an a letter, it indicated a long [a:] vowel: p+a = [pa:] but p+i = [pi] or [pi:] and p+u = [pu] or [pu:]. The remaining nine consonant sounds each had a different shape depending on the quality of the following vowel. Of these, only 'd' and 'm' had three different forms to represent [-a/a:/Ø], [-i/i:] and [-u/u:]. The remaining seven letters only had a two-way distinction, either to distinguish [-u/u:] from [-a/a:/i/i:], or because only two of the three vowels were ever used after that particular consonant.
For those nine signs whose shape already implies the following vowel, the vowel was still written as a separate letter. So the sound [di/i:] was written with two letters di+i. This enabled diphthongs following one of these nine consonants to be easily expressed; da+i represented [dai]. Diphthongs following one of the other thirteen consonants were a little more ambiguous; the letters p+i could represent either [pi/i:] or [pai] because of the possible inherent 'a' vowel.
Some letters were subject to further orthographic rules; n and (before stops) m were not written at the end of a syllable, and h was not written before u or m. The vowel i was generally not written after h.
In addition to the thirty-six phonetic letters, seven ideograms were used to represent common words or divine names, and there was a set of base numbers representing 1, 2, 10, 20, 100. These were added cumulatively with the biggest numbers to the left to represent other numbers, for example 5=2+2+1, 13=10+2+1, 60=20+20+20 etc.