Making extra parameters optional

Two points:

  1. Your rule isn’t particularly specific. For numeric matches you should be specific about it and specify a) digits and b) how many digits. Year would be ([0-9]{4}), month/day would be ([0-9]{1,2}).

  2. You can’t do it with one rule. Add three separate rules instead.

    add_rewrite_rule( 'whats-on/([0-9]{4})/?$', 'index.php?page_id=71&event_year=$matches[1]','top');
    add_rewrite_rule( 'whats-on/([0-9]{4})/([0-9]{1,2})/?$', 'index.php?page_id=71&event_year=$matches[1]&event_month=$matches[2]','top');
    add_rewrite_rule( 'whats-on/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$', 'index.php?page_id=71&event_year=$matches[1]&event_month=$matches[2]&event_day=$matches[3]','top');