72 lines
1.3 KiB
Markdown
72 lines
1.3 KiB
Markdown
---
|
|
id: 5900f52d1000cf542c510040
|
|
challengeType: 5
|
|
title: 'Problem 449: Chocolate covered candy'
|
|
forumTopicId: 302121
|
|
---
|
|
|
|
## Description
|
|
<section id='description'>
|
|
|
|
Phil the confectioner is making a new batch of chocolate covered candy. Each candy centre is shaped like an ellipsoid of revolution defined by the equation: b2x2 + b2y2 + a2z2 = a2b2.
|
|
|
|
|
|
Phil wants to know how much chocolate is needed to cover one candy centre with a uniform coat of chocolate one millimeter thick.
|
|
If a=1 mm and b=1 mm, the amount of chocolate required is
|
|
|
|
283
|
|
π mm3
|
|
<!-- TODO Use MathJax -->
|
|
|
|
If a=2 mm and b=1 mm, the amount of chocolate required is approximately 60.35475635 mm3.
|
|
|
|
|
|
Find the amount of chocolate in mm3 required if a=3 mm and b=1 mm. Give your answer as the number rounded to 8 decimal places behind the decimal point.
|
|
</section>
|
|
|
|
## Instructions
|
|
<section id='instructions'>
|
|
|
|
</section>
|
|
|
|
## Tests
|
|
<section id='tests'>
|
|
|
|
```yml
|
|
tests:
|
|
- text: <code>euler449()</code> should return 103.37870096.
|
|
testString: assert.strictEqual(euler449(), 103.37870096);
|
|
|
|
```
|
|
|
|
</section>
|
|
|
|
## Challenge Seed
|
|
<section id='challengeSeed'>
|
|
|
|
<div id='js-seed'>
|
|
|
|
```js
|
|
function euler449() {
|
|
// Good luck!
|
|
return true;
|
|
}
|
|
|
|
euler449();
|
|
```
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</section>
|
|
|
|
## Solution
|
|
<section id='solution'>
|
|
|
|
```js
|
|
// solution required
|
|
```
|
|
|
|
</section>
|