How to use the Elements module to make $form['element'] = array( '#type' => 'number' );
Have a quick look at the code of the elements module.

The number field is defined like this:

  $types['numberfield'] = array(
    '#input' =&gt; TRUE,
    '#step' =&gt; 1,
    '#process' =&gt; array('ajax_process_form'),
    '#element_validate' =&gt; array('elements_validate_number'),
    '#theme' =&gt; 'numberfield',
    '#theme_wrappers' =&gt; array('form_element'),
  );


So you should use '#type' =&gt; 'numberfield' instead.