You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: amd.rs
    path of file: ./repos/faer-rs/src/sparse/linalg
    
    the code of the file until where you have to start completion: //! Approximate minimum degree ordering.

// AMD, Copyright (c), 1996-2022, Timothy A. Davis,
// Patrick R. Amestoy, and Iain S. Duff.  All Rights Reserved.
//
// Availability:
//
//     http://www.suitesparse.com
//
// -------------------------------------------------------------------------------
// AMD License: BSD 3-clause:
// ------------------------------------------------------
    
pub fn order_req<I: Index>(n: usize, nnz_upper: usize) -> Result<StackReq, SizeOverflow> {
    let n_req = StackReq::try_new::<I>(n)?;
    let nzaat = nnz_upper.checked_mul(2).ok_or(SizeOverflow)?;
    StackReq::try_all_of([
        // len
        n_req,
        // A+A.T plus elbow room
        StackReq::try_new::<I>(nzaat.checked_add(nzaat / 5).ok_or(SizeOverflow)?)?,
        n_req,
        // p_e
        n_req,
        // s_p
        n_req,
        // i_w
        n_req,
        // w
        n_req,
        // nv
        n_req,
        // elen
        n_req,
        // child
        n_req,
        // sibling
        n_req,
        // stack
        n_req,
    ])
}