Wikipedia page Power symbol mistakenly showed the astronomical symbol of the moon (see right) instead of the IEEE 1621 standard crescent moon symbol. This standardized symbol, called “Sleep” refers to the Sleep mode (also Stand By or Suspend), the low power mode for electronic devices.
The easily accessible consultant report of the standard is a little bit cryptic about the form and size of the proposed symbol (Appendix VI.3.):
Fortunately, abstract of the referred standard IEC 40630 revealed the size of the square, too: exactly 75 mm. Using this data and a ruler, it was possible to measure the diameter of the outer circle, too: it is 6 cm. The standard specifies the ratio of the outer curve of the moon shape: a half circle; the width of the shape: 1/4 diameter of the circle (1.5 cm); and “tilt” of the moon: just for fun, it is equal to the earth’s angle of inclination (at the time of writing of the standard, it was 23.45 degrees). The only question was the specification of the inner curve of the moon shape. After some investigation it was found that it is arc of a circle, not an ellipse. We can calculate its radius (r2) and position based on the following illustration:
Radius of the first circle (r1) is 3 cm. Using the Pythagorean theorem, r22 = (r2–r1/2)2+r12 = (r2–1.5)2 + 9 = r22 – 3r2 + 2.25 + 9, so r2 = 11.25/3 = 3.75. The following LibreLogo program draws the filled moon using a black, 6 cm circle, and a white, 7.5 cm circle:
PENUP LEFT 23.45° FILLCOLOR “BLACK” CIRCLE 6cm RIGHT 90 FORWARD 2.25cm FILLCOLOR “WHITE” CIRCLE 7.5cm
For a better cropping in the SVG version, we can draw only a black semicircle, and – using the law of sines for the calculation – only the requested white circular segment of the second circle:
PICTURE “power_sleep_black_cropped.svg” [ PENUP LEFT 23.45° FILLCOLOR “BLACK” ELLIPSE [6cm, 6cm, 6h, 12h] RIGHT 90 FORWARD 2.25cm LEFT 90 FILLCOLOR “WHITE” ELLIPSE [7.5cm, 7.5cm, 6h+36.8°, 12h-36.8°, 2] ]
Apply the following steps to convert the black and white circular segments to a single moon shape:
1. Open the exported SVG file in LibreOffice Draw.
2. Select and remove the bad black background rectangle.
3. Press Ctrl-A to select the black and white circular segments.
4. Select Modify » Shapes » Subtract to subtract the white circular segment from the black semicircle.
5. Export as SVG.
Drawing white (empty) sleep symbols is a little bit trickier. We have to draw the circular segments with the (double of the) requested line width for the inner moon shape (see the screenshot), (moreover, in enlarged version to reduce the rounding errors of the Draw canvas and the following clipboard operation), and subtract this smaller moon shape from the big one. Steps:
1. Change the Writer paper size to 100×100 cm, and run the following LibreLogo code:
TO moon color bgcolor HOME LEFT 23.45° PENCOLOR color PENSIZE 4cm FILLCOLOR bgcolor ELLIPSE [60cm, 60cm, 6h, 12h] PENUP RIGHT 90 FORWARD 22.5cm LEFT 90 PENDOWN FILLCOLOR “WHITE” ELLIPSE [75cm, 75cm, 6h+36.8°, 12h-36.8°, 2] END PICTURE [ moon “INVISIBLE” “BLACK” moon “ORANGE” “INVISIBLE” ]
2. Copy the picture to a 100×100 cm Draw canvas, select Modify » Ungroup and Modify » Shapes » Subtract to create the inner moon shape.
3. Press Ctrl-C to copy the inner moon shape to the clipboard, and press Ctrl-Z to restore the image.
4. Remove the two shapes with orange outlines.
Press Ctrl-V to insert the inner moon shape (you can change its filling color to check it, see on the attached screenshot).
5. Press Ctrl-A and select Modify » Shapes » Subtract to create the empty moon shape.
6. Resize it with Format » Position and Size…, move it to the left upper corner, resize the canvas (or copy the moon shape to the previous, but empty SVG file), and export it as a new SVG file.
IEC 40630 has got two preferred line widths, 2 mm and 4 mm, also the filled moon is an official version of the symbol, and sometimes it is useful to use not only the fully cropped versions of these symbols, but the versions cropped only to the 6 cm (invisible) circle, that is why Wikimedia Commons has got six new sleep symbols (see the image gallery of one of them).