Program design for comprehensive curve element calculation