Z-Car

The Rolls-Royce Merlin – Could it be the best piston engine ever?

The RAF fighters which resisted the German invasion in 1940 during the Battle of Britain, were all equipped with the same engine, the Rolls-Royce Merlin.  This same engine also powered the majority of the bombers of RAF Bomber Command, and some of the best fighters of the 8th USAAF.   Named after a bird of prey, like all piston engines that Rolls-Royce produced, the Merlin is a unique engine for several reasons.

  • Unlike other engines, which changed relatively little during the war, between 1939 and 1945, no fewer than 52 different versions of the Merlin were produced
  • Powered a wide variety of aircraft, including both fighters and bombers.  These included the Spitfire, Hurricane, Boulton Paul Defiant, Avro Lancaster, De Havilland Mosquito, Handley Page Halifax, Armstrong-Whitworth Whitley, and the P-51 Mustang.  The Merlin even replaced the Hercules II version of the Bristol Beaufighter and the Pegasus in version II of Wellington.
  • The Merlin transforms two of the most important aircraft of World War II.  From the poor performing Manchester was born the transformed Merlin powered Lancaster, the legendary aircraft of Bomber Command.  The P-51 Mustang became one of the best fighters in WWII once the under-powered Allison’s were replaced with the Merlin.  With the new found extended range, it became the only fighter to effectively protect the 8th USAF B-17 deep into enemy territory.
  • Finally, it is the only engine to be built in large numbers simultaneously on both sides of the Atlantic during WWII.

The Birth of the Merlin

The Merlin is a conventional engine, derived from relatively older power trains, as engineers and technicians at Rolls-Royce simply evolved the Merlin from existing proven designs. The Merlin was born into a family of  V12 engines whose origin dates back at Rolls-Royce to the First World War.  As mentioned, they all  bear the names of birds of prey, when studying reciprocating engines from Rolls Royce, you also get a lesson in  ornithology.   Rolls entry into aeronautical engines begins with the Eagle in 1915.  The V-12 Eagle propels the Short Bomber (1916), the Vickers Vimy (1917), the Handley Page O/100 (1916), the Handley Page V/1500 (1918), and fighters like the AIRCO DH.4 (1917).  The Eagle is also mounted in the U.S. aircraft (Fairey F.17).  The Eagle was rated between  250 and 375 hp in its various versions, which for the time was a considerable amount of power, and advantage that the water-cooled engines had over the air-cooled engines of the day.   During this time period the Americans, British and French prefer the V-12 engines from  Rolls Royce, Hispano-Suiza, Renault, and Liberty.  The Germans and Italians are loyal to the 6-cylinder Mercedes, Fiat and Isotta-Fraschini.

After the war, Rolls-Royce began, like all its competitors, the race for power, while remaining faithful to the formula of V-12 liquid cooling.  Advances in design, metallurgy, and fuel allow for an increase in the speed (RPM) and compression ratio of the engine.  In 10 years, the compression ratio increases by 50% (it goes from 4: 1-6: 1) and the rotational speed from approximately 1800 to 2400 rpm. In 1927, the Kestrel 21.25 liter engine is released, which soon powers the Hawker biplanes (Audax, Fury, Hart) in the early 1930s.  The Kestrel develops 745 hp, double the power of the engines produced at the end of WWI.  In order to compensate for lower density air at higher altitudes, the Kestrel gets a mechanical compressor, the super-charger, the first turbocharged engine Rolls-Royce produces.  With the gasoline at that time rated at 87 octane, it allowed for a boost pressure of 5.6PSI.

The Kestrel turns out to be a great engine, with innovations such as the use of ethylene glycol for cooling which reduces the size of the radiators.  Interestingly, Messerschmidt, which still awaits the Daimler-Benz V12 engine, will acquire a Kestrel to test the first version of the BF 109 in 1935.  However, the displacement of the Kestrel is a bit inadequate for the next generation of fighters will require, such as Britain’s future Spitfire.

The Kestrel was followed in 1929 by the Buzzard (36.7 liters), which was named Type R in its competition form. It is with the 2300 hp R-type aircraft that race Supermarine S6 allows England to win for the third consecutive time in the 1931 Schneider Cup and beat the world speed record at 407MPH.  However, the Type R is a racing engine, whose performance can only be sustained for a short period of time.

To fill the existing hole in the range between Kestrel and Buzzard, Rolls began to privately develop a new V12 called the PV 12 (Private Venture 12).  In October 1934, the Air Ministry officially orders the PV12 into production and it is given the name Merlin.  For the next 10 years, Rolls-Royce will continue to develop the Merlin, to make it ever more powerful and versatile.

The Merlin I and II : In July 1934, Rolls releases the first pre-production Merlin A, which like many motors, has a bore (137 mm) which is slightly less compared to the stroke (152 mm), a feature that promotes low-end torque. The Merlin is estimated at 790 hp at 2500 rpm at an altitude of 12,000 feet, already outstanding performance for a block that weighs less than 1322 pounds dry (no oil or coolant).  At the same time (Feb 1935), another version (Merlin B) is produced with a redesigned combustion chamber and 4 valves per cylinder, it reached 960 hp at 11,000 feet. The changes follow through F, to be released in small numbers with the name of Merlin I. The Merlin G (called Merlin II production) is the first type for mass production, it reached 1030 hp at 3000 rpm and 16,250 feet. Compared to the type A, the Merlin type G has gained 30% in power, while the weight has increased by 220 pounds. The Merlin II has a single-speed super-charger, and with 87-octane fuel limit has a boost pressure up to 5.6PSI, and in 1939 with the introduction of 100 octane fuel, this was increased to 11.2PSI, improving power at high-altitude.

The X Merlin : The Merlin X represented a milestone in the evolution of Merlin with the introduction of a two-speed compressor.  Driven by the engine, the supercharger requires power to compress the incoming air.  Therefore, it is important that the power required to compress the air does not exceed the power gained.  The two-speed compressor would allow a lower pressure when the engine was at low to medium altitude, and only use maximum pressure at high altitude.  With the adoption of this compressor Rolls-Royce significantly improves the performance of the Merlin.

Series 60 and Beyond : For the 60 series, the Merlin receives a two-stage compressor. Rather than resorting to turbocharging, which Rolls Royce has no experience, and requires special alloys, Sir Stanley Hooker (Merlin Head Engineer) prefers to mount a two-stage compressor.  This again allows efficient low altitude performance, while increasing high altitude performance.  The ultimate development of this technology will lead to the series 100, which develops over 2000 hp at sea level, and retains a power of 1000 hp at 12,000 ft, with a boost pressure of  2.8PSI.  With the two-stage compressor, Rolls-Royce has the Merlin which is the envy of American turbocharged engines.

The Merlin in Action

Almost all British aircraft, fighters or bombers, were, during the war, equipped with the Merlin. With its V configuration, Merlin offered a reduced frontal area, which was perfect for swift fighters.  Two of these mythical Battle of Britain fighters were the Spitfire and Hurricane. The first Spitfire and Hurricane used the Merlin II. Although designed for fighters, the Merlin also powers almost all British bombers, first the twin-engine bombers (Stirling, Whitley, Mosquito) and then the four-engined Lancaster and Halifax.  The Merlin power plant is also installed in two American fighters, the Curtis P-40 in limited numbers, and the P-51 Mustang almost excusively.


Bell P-39N Airacobra – Little Sir Echo – Small Fry

Bell P-39 Airacobra - Little Sir Echo

This is P-39N-5 “Little Sir Echo / Small Fry” Serial Number 42-19027 which served with the USAAF 5th Air Force (AF), 71st Tactical Reconnaissance Group (TRG), 82nd Tactical Reconnaissance Squadron (TRS), from June 1943 to July 16, 1944. It was abandoned at Tadji, Papua New Guinea, a Japanese airfield that was liberated by the US Army on April 26, 1944. Tadji became a major Allied air depot for American and Australian forces, and the resting place for this P-39 for the next thirty years. It is now on static display at the Planes of Fame Museum in Chino, CA.

This specific P-39 was delivered to the US Army on April 28, 1943, and sent to the Pacific in May. Lyndall W. Tate was assigned to this aircraft. Lyndall was born Oct 20, 1920 in Texas, and passed away Sept 15, 2008. He served over 28 years in the military. If anyone else has any further information on Lyndall, please let us know more about this hero. The aircraft was recovered from Tadji in a 1974 salvage operation funded by David Talichet’s Yesterday’s Air Force (MARC). It currently is on static display at the Planes of Fame museum. It still supports its original markings of Olive Drab over Neutral Grey with White New Guinea theatre markings on tail unit, wing leading edges and spinner (thin White band on nose). In addition it features an interesting shark mouth on the center drop-tank.

The Bell P-39 was one of the US’s main-line fighters when war first broke out in the Pacific at the beginning of World War II. It was unique at the time for having a tricycle undercarriage and a mid-mounted engine located behind the pilot. This arrangement was due to the proposed installation of a powerful 30 mm cannon in the nose. Ultimately, the P-39 was unable to achieve the same performance of later US and European fighters, mainly due to a lack of a turbo-supercharged engine which greatly limited the P-39’s ceiling and speed. However, its low-altitude performance, mid-mounted engine, and armor plating allowed it to become a great ground-support aircraft, most notably used by the Soviet Air Force. In the end, the Bell P-39 became Bell’s most successful fixed-wing aircraft that they ever produced.


Top My.CNF Optimizations for Innodb

worried-girl-computer

These are the four parameters which will have the most affect on the performance of MySQL 5.1x and Innodb.   If you are suffering from poor performance, try changing the following settings.  Remember, each individual situation will vary, and in many cases, the actual design of your queries will have more to do with your overall performance than any system tuning tricks.  The best tool I have found to capture, review, and analyse query performance for MySQL is Jet Profiler for MySQL.  If you need help optimizing your queries, let us know.

innodb_buffer_pool_size =8G
Set this to ~80% of free server memory.  For example, if you have a dedicated MySQL server with 10G, set to 8G

innodb_flush_log_at_trx_commit =0
Setting this to 0 will have a huge performance improvement, however your data is at somewhat more if you have a hardware failure

sync_binlog =0
Setting this to 0 will have a huge performance improvement, however your data is at somewhat more if you have a hardware failure

innodb_flush_method=O_DIRECT
On many systems, this will provide a performance improvement.  However, this can actually have a negative affect, so make sure you test appropriately.

How to increase MySQL performance when loading a Dump File

GirlComputer

In MYSQL, as well as most database engines, restoring a backup, or importing from an existing dump file can take a long time depending on the number of indexes and primary keys you have on each table. You can speed this process up dramatically by modifying your original dump file by surrounding it with the following:

SET AUTOCOMMIT = 0;
SET FOREIGN_KEY_CHECKS=0;

.. your dump file ..

SET FOREIGN_KEY_CHECKS = 1;
COMMIT;
SET AUTOCOMMIT = 1;

This will force MySQL to not commit until all rows have been loaded, as well as skip all foreign keys checks. Only skip these checks if you are 100% sure that no constraint is violated. This will usually be the case when dumping from one table and inserting into another.


MySQL – Should you put an index on a Boolean field to help query performance?

blonde working on computer

I am often asked if it makes sense to place an index on a Boolean field in order to improve query performance.  In general, because a boolean value can only have three values (True, False, Null), this low cardinality would suggest that adding an index will not help performance, as the query optimizer will still usually perform a table-scan if you have an even distribution of values within your DB.

One situation in which an index on a boolean field (or other low cardinality field) might be useful is if there are relatively few of one of the values, for example 5 True values in a table of millions of records and you are searching for those few values on a regular basis.

However, you might index a boolean value on a combination of fields. Indexing on a single Boolean might be pointless, because there’s only 2 (or 3) values.  However, indexing on 16 boolean values has the potential of  2^16 values.  It might help to make a combined index but you should understand how the combined index can and cannot be used and be aware that the order of the columns matters.

In general, you should always profile your system to see if there are queries that are too slow and consider adding another index to handle those queries. Sometimes a single combined index can be used for multiple queries and others time you will need to make an index for each type of query. Remember that adding indexes slows down modifications to the data so it is possible to have too many indexes. There is always a  trade-off when creating multiple indexes.


MySQL – Best way to speed up Slave replication

hot-woman

The number one thing that you can do to speed up Slave Replication is to set innodb_flush_log_at_trx_commit=0 in your my.cnf file. This will make the transactions less recoverable on your Slave in case of a crash, however with a Slave this is usually an acceptable risk. This setting prevents MySQL from forcing a fsync after every transaction, allowing transactions to be batched up and all fsynced in one operation. When using slower HD RAID’s, this is a huge performance benefit.

Setting sync_binlog=0 will also prove to be beneficial, but also at some level of additional risk.