Skip to content

Creating a UnitQuaternion from a Rotation3 of NaNs hangs forever #1509

@joelsa

Description

@joelsa

MCVE to reproduce:

use std::f64::NAN;
use nalgebra::{UnitQuaternion, Rotation3};

fn main() {
    let r_br: nalgebra::Matrix3<f64> = nalgebra::Matrix3::new(
        NAN, NAN, NAN,
        NAN, NAN, NAN,
        NAN, NAN, NAN,
    );

    let q =
            UnitQuaternion::from_rotation_matrix(&Rotation3::from_matrix(&r_br)).into_inner();
    println!("q: {q}");
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions