def checking_stack(stack, database='<STR_LIT>'):
for _keys in stack:<EOL><INDENT>_elements = stack[_keys]['<STR_LIT>']<EOL>for _element in _elements:<EOL><INDENT>if not is_element_in_database(element=_element, database=database):<EOL><INDENT>raise ValueError("<STR_LIT>".format(_element))<EOL><DEDENT><DEDENT>_thickness = stack[_keys]['<STR_LIT>']['<STR_LIT:value>']<EOL>if not isinstance(_thickness, numbers.Number):<EOL><INDENT>raise ValueError("<STR_LIT>".format(_thickness))<EOL><DEDENT>_stoichiometric_ratio = stack[_keys]['<STR_LIT>']<EOL>if len(_stoichiometric_ratio) != len(_elements):<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT><DEDENT>return True<EOL>
This method makes sure that all the elements from the various stacks are
    in the database and that the thickness has the correct format (float)

    Parameters:
    ==========
    stack: dictionary that defines the various stacks
    database: string (default is 'ENDF_VII') name of database

    Raises:
    ======
    ValueError if one of the element in one of the stack can not be found 
    ValueError if thickness is not a float
    ValueError if elements and stoichiometric ratio arrays do not have the same size

    Return:
    ======
    True: for testing purpose only