A rapid prototyping method for crop models using the discrete element method