friction_map_interface
FrictionMapInterface
Created by: Leonhard Hermansdorfer
Documentation: This class loads the friction map (_tpamap.csv) and the corresponding data (_tpadata.json) and provides an interface to fetch friction data for a requested position on the race track.
Naming of map and data file has to be consistent! Everything replaced by '*' has to be identical in
order to load correct data to a given map.
The following data must be available for the friction map: tpa_map: csv-file containing the map information (x,y-coordinates of each grid cell; '_tpamap.csv' located in inputs folder) tpa_data: json-file containing specific data for each grid cell (e.g. coefficient of friction); '_tpadata.json' located in inputs folder)
get_friction_singlepos(positions)
This function returns the friction value mue for a given position.
Inputs: positions: x,y coordinate(s) in meters from origin for position of requested friction value(s) [[x_0, y_0], [x_1, y_1], ...] (multiple coordinate points allowed)
Outputs: mue_singlepos: array with coefficient of friction for requested positions (same number) [[mue_0], [mue_1], [mue_2], ...]]