ENG_MAP An Engine Map class.

Overview

The eng_map class is a class for doing convenient pre- and post-processing of ADVISOR style engine maps (i.e., lookup tables). The eng_map class is used from the MATLAB command line. Detailed help can be obtained by typing:

help eng_map % for help on eng_map

help eng_map\method_name % for help on a specific method name. e.g., help eng_map\plot

methods eng_map % lists all of the available methods for the eng_map class

All of the eng_map class is available to the user (open source) in the @eng_map directory in <ADVISOR root directory>\gui\@eng_map. For more information on matlab classes, please consult the MATLAB documentation. Listed below are various constructors for the eng_map class demonstrating how you might instantiate an eng_map object.

Constructor 1:

em = ENG_MAP(shaft_speed,… % [rad/s]

shaft_brake_trq,… % [Nm]

Brake_Specific_Fuel_Consumption_matrix ,… % [g/kWh] indexed vertically by speed, and horizontally by trq

fuel_LHV,… % [J/g], lower heating value of the fuel

max_trq); %[Nm], the maximum torque corresponding to the shaft_speed vector

creates an eng_map object

Constructor 2:

em = ENG_MAP(’fuel_consumption’,…% dummy flag to indicate fuel consumption will be given instead of BSFC

shaft_speed,… % [rad/s]

shaft_brake_trq,… % [Nm]

Fuel_Consumption_matrix ,… % [g/s] indexed vertically by speed, and horizontally by trq

fuel_LHV,… % [J/g], lower heating value of the fuel

max_trq); %[Nm], the maximum torque corresponding to the shaft_speed vector

Constructor 3:

em = ENG_MAP(’fc_file_name’) % the fc_file_name is the name of an ADVISOR fc file

Constructor 4:

em = ENG_MAP(em_object) % creates a new eng_map object from an existing one

creates an eng_map object

Constructor 5:

em = ENG_MAP(’dummyFlagOne’,…% dummy flag to indicate fuel consumption will be given instead of BSFC

‘dummyFlagTwo’,…

shaft_speed,… % [rad/s]

shaft_brake_trq,… % [Nm]

eff_matrix ,… % [–,decimal between 0 and 1] indexed vertically by speed, and horizontally by trq

fuel_LHV,… % [J/g], lower heating value of the fuel

max_trq); %[Nm], the maximum torque corresponding to the shaft_speed vector

METHODS AVAILABLE FOR THIS CLASS: 

(type methods eng_map for the most up-to-date listing)

Example: Creating a New Engine from BSFC Information at Max. Torque

Engine OEM’s will often make available performance data that contains such information as maximum torque curves for their engine model by shaft speed. If one is lucky, the brake-specific fuel consumption (or fuel rate) will also be given along this maximum curve. However, rarely is the entire efficiency map provided.

One quick and dirty way to make an engine efficiency map using only this limited information is to use the eng_map class. The eng_map class has a method called buildNewMap that is a scaling function. eng_map.buildNewMap uses an existing engine map and scales efficiency at constant shaft speeds to match that of the efficiency at max torque provided by the user. Let’s take an example.

Let’s say a user has the following information available along the max torque curve for an engine and let us assume the fuel lower heating value is 43 MJ/kg:

Engine Data
gine Speed (rad/s [rpm]) En gine Max. Torque (Nm) BS FC (g/kWh)
125.7 [1200] 1690 196
146.6 [1400] 1650 195
167.6 [1600] 1540 196
188.5 [1800] 1380 197
209.4 [2000] 1220 199

Let’s use the FC_CI330.m file in ADVISOR as the base engine to work off of with the above data. To make an eng_map class based off of the FC_CI330.m file, we need only call constructor 3:

> em205=eng_map(’FC_CI205’)

Now that we have this map, let’s plot it to look at it:

> plot(em205)

You should now see a custom drawn efficiency map figure. Now let’s scale the 205 kW map to fit our information at max. torque. We’ll specify our new map to have torque evaluated every 50 Nm from 50 up to 1700 Nm. Fuel lower heating value will be taken as 43000 J/g:

> emNew=buildNewMap(em205, [125.7, 146.6, 167.6, 188.5, 209.4], [50:50:1700], [196, 195, 196, 197, 199], …
   [1690, 1650, 1540, 1380, 1220], 43000);

We can now plot our new map:

> plot(emNew)

If we like our results, we can save them to an m-file and begin creating an ADVISOR engine m-file:

> saveToFile(emNew, ‘fc_testEngine.m’)

Remember, if you ever need help, just type

‘help eng_map\{method name}’ or ‘methods eng_map’

Let’s compare how our scaling algorithm did versus just scaling the 205 kW engine by Torque:

> em205a=scaleTrq(em205,1700/1200) % scale the torque values of the engine

> em205a=set(em205a, ‘maxTorque’,get(em205a, ‘maxTorque’).*1700/1200) % scale the max torque curve of the 205 kW engine

> plot(diffMap(emNew, em205a)) % plot the difference between the two engines


Return to ADVISOR Documentation


Last revised: [01-April-2002] mpo
Created: [01-April-2002] mpo