eulumdat-quiz 0.6.0

Photometric knowledge quiz engine for lighting professionals
Documentation
use crate::{Category, Difficulty, Question};

pub fn questions() -> Vec<Question> {
    vec![
        Question {
            id: 14001,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Beginner,
            text: "What does a polar diagram show?".into(),
            options: vec![
                "Color temperature distribution".into(),
                "Luminous intensity distribution in a single plane".into(),
                "Energy consumption over time".into(),
                "Lamp lifetime curve".into(),
            ],
            correct_index: 1,
            explanation: "A polar diagram shows the luminous intensity distribution of a luminaire in a specific C-plane, plotted on polar (angular) coordinates.".into(),
            reference: Some("CIE 102:1993".into()),
        },
        Question {
            id: 14002,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Beginner,
            text: "In a standard polar diagram, where is 0° (nadir)?".into(),
            options: vec!["At the top".into(), "At the bottom".into(), "On the right".into(), "On the left".into()],
            correct_index: 1,
            explanation: "In the standard convention, 0° (nadir/straight down) is at the bottom of the polar diagram, and 180° (zenith) is at the top.".into(),
            reference: Some("CIE 102:1993".into()),
        },
        Question {
            id: 14003,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Intermediate,
            text: "What does a cartesian (rectangular) photometric diagram plot?".into(),
            options: vec![
                "Intensity vs gamma angle in rectangular coordinates".into(),
                "C-plane vs gamma angle".into(),
                "Illuminance vs distance".into(),
                "Power consumption vs time".into(),
            ],
            correct_index: 0,
            explanation: "A cartesian diagram plots intensity (Y-axis) against gamma angle (X-axis) in rectangular coordinates, with one curve per C-plane.".into(),
            reference: Some("CIE 102:1993".into()),
        },
        Question {
            id: 14004,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Intermediate,
            text: "What does a photometric heatmap visualize?".into(),
            options: vec![
                "Temperature distribution of the luminaire".into(),
                "Intensity values across all C-planes and gamma angles as a color grid".into(),
                "Power consumption patterns".into(),
                "Daylight penetration into a room".into(),
            ],
            correct_index: 1,
            explanation: "A photometric heatmap displays intensity values as colors on a 2D grid with C-planes on one axis and gamma angles on the other, giving a complete overview of the light distribution.".into(),
            reference: None,
        },
        Question {
            id: 14005,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Intermediate,
            text: "What does a cone diagram illustrate?".into(),
            options: vec![
                "The physical shape of the luminaire".into(),
                "Beam and field angles as projected cones showing the illuminated area on a surface".into(),
                "The cone of vision of the human eye".into(),
                "Reflector geometry inside the luminaire".into(),
            ],
            correct_index: 1,
            explanation: "A cone diagram shows the beam and field angle cones projected from the luminaire to a target surface, illustrating the illuminated area diameter at a given mounting height.".into(),
            reference: None,
        },
        Question {
            id: 14006,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Expert,
            text: "What does a butterfly (3D) diagram show?".into(),
            options: vec![
                "The luminaire viewed from above".into(),
                "Intensity distribution in multiple C-planes simultaneously, creating a 3D shape".into(),
                "The spectral distribution of the light".into(),
                "The luminaire's mechanical drawing".into(),
            ],
            correct_index: 1,
            explanation: "A butterfly diagram overlays intensity distributions from multiple C-planes in a 3D perspective, showing the complete spatial light distribution. Named for its butterfly-wing appearance in many luminaires.".into(),
            reference: None,
        },
        Question {
            id: 14007,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Expert,
            text: "What is an isolux diagram?".into(),
            options: vec![
                "A diagram showing equal-intensity lines on the luminaire surface".into(),
                "A contour map showing lines of equal illuminance on a target surface".into(),
                "A diagram of isolated lighting zones".into(),
                "A graph comparing luminaire models".into(),
            ],
            correct_index: 1,
            explanation: "An isolux diagram is a contour map showing lines of equal illuminance (lux) on a horizontal or vertical surface, useful for evaluating lighting uniformity.".into(),
            reference: Some("CIE 102:1993".into()),
        },
        Question {
            id: 14008,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Beginner,
            text: "Why are two C-planes typically shown in a polar diagram?".into(),
            options: vec![
                "One for indoor, one for outdoor".into(),
                "C0-C180 (lengthwise) and C90-C270 (crosswise) to show both axes of the distribution".into(),
                "One for beam angle, one for field angle".into(),
                "One for lumens, one for candelas".into(),
            ],
            correct_index: 1,
            explanation: "The C0-C180 plane shows the longitudinal (front-back) distribution and C90-C270 shows the transverse (side-to-side) distribution, giving a complete picture for asymmetric luminaires.".into(),
            reference: Some("CIE 102:1993".into()),
        },
        Question {
            id: 14009,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Intermediate,
            text: "What does the radial distance from center represent in a polar diagram?".into(),
            options: vec!["Angle".into(), "Luminous intensity".into(), "Distance from luminaire".into(), "Illuminance".into()],
            correct_index: 1,
            explanation: "In a polar diagram, the radial distance from center represents luminous intensity (cd or cd/klm). The angular position represents the gamma angle.".into(),
            reference: Some("CIE 102:1993".into()),
        },
        Question {
            id: 14010,
            category: Category::DiagramTypes,
            difficulty: Difficulty::Expert,
            text: "What type of distribution creates a 'batwing' pattern in a cartesian diagram?".into(),
            options: vec![
                "A narrow spot light".into(),
                "A distribution with minimum intensity at nadir and peaks at off-axis angles".into(),
                "A perfectly uniform omnidirectional source".into(),
                "An uplight luminaire".into(),
            ],
            correct_index: 1,
            explanation: "A batwing distribution has reduced intensity at nadir (0°) with peaks at wider angles (e.g., 30-45°), creating a W-shape in cartesian view. This provides better uniformity on work surfaces.".into(),
            reference: None,
        },
    ]
}