pub fn tridag(
    a: &[f64],
    b: &[f64],
    c: &[f64],
    r: &[f64],
    u: &mut [f64],
    n: usize
)