# README

## Overview

This MATLAB script analyzes rover wheel design configurations starting from a FEM results table (Excel file).

It reads the simulation data, cleans the table, applies project constraints, ranks the feasible designs, identifies the Pareto front, and selects three representative configurations.

---

## What the script does

The script performs the following steps:

1. Reads an Excel table containing FEM simulation results
2. Maps the original column names to a standardized internal format
3. Cleans invalid or unwanted rows
4. Analyzes the data in one of two modes:
   - `row`: each row is treated as an independent configuration
   - `design_worst_case`: rows belonging to the same design are aggregated into a worst-case summary
5. Applies design constraints on:
   - maximum stress
   - vertical deflection
   - mass
   - stiffness
   - durability index
6. Keeps only feasible configurations
7. Computes a weighted score for ranking
8. Identifies the Pareto-optimal solutions
9. Selects three significant cases:
   - best overall configuration
   - most critical feasible configuration
   - lightest distinct feasible configuration
10. Produces comparison plots

---

## Required input

- An Excel file containing the wheel simulation results  
  Example:
  - `TAB_tweel_final.xlsx`

You must set:

- `fileName`
- `sheetName`

at the beginning of the script.

---

## Main constraints

The script uses user-defined project limits, including:

- allowable stress
- required safety factor
- maximum vertical deflection
- optional mass limit
- optional minimum stiffness
- durability threshold

These values can be edited in the **USER INPUT** section.

---

## Ranking method

A weighted score is computed using:

- stress
- deflection
- mass
- stiffness
- durability

Lower score means a better configuration.

---

## Output

The script provides:

- feasible/non-feasible filtering
- weighted ranking
- Pareto front identification
- three selected representative cases
- plots of:
  - mass vs stress
  - Pareto front in deflection vs stress space
  - 3D objective space

---

## Notes

- The script reads `.xlsx` input data but does not export `.csv` or `.xlsx` files.
- The local helper functions at the end of the script handle:
  - column name matching
  - numeric conversion
  - normalization
  - Pareto filtering
  - row selection

---

## Purpose

This script is intended to support design selection for rover wheels by combining structural performance, feasibility checks, weighted ranking, and Pareto analysis.