**MEA (Means-Ends Analysis)** is an a approach that puts together aspects of both forward and backward reasoning in that both the condition and action portions of rules are considered when we decide which rules to apply. The logic of the process takes into account the gap between the current situation and the desired goal – where we wish to get to and proposes actions in order to close the gap between the two.

The method uses a set of rules that enable the goal to be achieved iteratively. The rules consist of two parts: rules that are prerequisites and ones that show the changes to be implemented.

MEA works by considering the present position as the current state and the objective as the goal state. The differences between the desired and the goal state are considered and actions are proposed that reduce the ‘gap’ between the initial and desired states.

Since the process is working from the current state towards a goal it is said to be doing forward chaining which implies a search strategy and a procedure that regards goal achievement as success – or if the outcome of a sub-goal is failure a new search is begun (or the process terminates as not possible).

**Consider the following examples.**

- In a travel problem the current state and the goal state are defined by physical locations where we are now and where we have to get to.
- In an assembly problem such as an IKEA flat pack the current state and the goal state are defined by the raw materials lying in a heap along with instructions on the floor and the finished product in your kitchen.

**Aunt Agatha and the invite to tea**

Aunt Agatha lives in Brighton and has invited me to tea this afternoon – she has a lot of money which she may leave to me which is actually a longer term goal for this journey. I am sitting in my office in London and need to decide how to get to Brighton.

Now there are lots of ways to do this: train, car, bus, on foot, private jet or roller blades but I subject myself to the following cost constraints:

- I must arrive at Brighton today within three hours
- The journey must cost no more than $100
- Any distance less than one mile must be walked

To begin this process I consider the available means against my constraints and decide on taking the train via Victoria to Brighton. To do this I need to leave my office and travel to the main station at Victoria which is a new goal.

To get to Victoria I can walk, take a taxi, bus or go by underground. Because of time constraints and cost I decide to take the underground to Victoria – this becomes a new sub goal. The nearest tube station being less than one mile away I walk

On arrival at the station I find the line is down due to a breakdown (goal failure). I can return on foot to get my car to drive to Brighton but this moves me away from my goal on cost and distance. I decide to take the bus to Victoria which becomes a new goal and as the distance is less than one mile I walk to the bus station.

I take the bus to Victoria alight and walk to the station office and purchase a ticket to Brighton. At Brighton I have to get to Agatha’s house – I can use the Bus, Taxi or Walk. As the distance is less than one mile I walk and arrive at Aunt Agatha’s house the end goal.

Just then my cell phone rings with a message and it’s Aunt Agatha, ‘I hope you don’t mind but I forgot I have to be in London today perhaps we can make it next week…’ Arghhhhhhhh!!!

**Some problems for you to solve…**

**Vicars and Tarts**

There are 3 Vicars and 3 Tarts and a boat on one side of a river and the church on the other. How can the 6 of them get across the river for morning prayers in the boat subject to the following constraints?

- There must be at least one person in the boat
- There cannot be more than two people in the boat at any time
- There cannot be more Tarts than Vicars on either bank otherwise the tarts will take advantage the vicars and commit original sin.

**Three coins**

Three coins lie on a table in the order tails, heads, and tails. In precisely three moves make them face either all heads or all tails.