Skip to content

Instantly share code, notes, and snippets.

@andychase
Created July 12, 2015 18:05
Show Gist options
  • Save andychase/e8e56f14fb71812ae003 to your computer and use it in GitHub Desktop.
Save andychase/e8e56f14fb71812ae003 to your computer and use it in GitHub Desktop.
aws_vs_xam
Display the source blob
Display the rendered blob
Raw
{
"metadata": {
"name": "",
"signature": "sha256:f18e1428f0b0fb2e464672fc8be601c325cc2ce480ecc94c9a8ed5febdde7b4a"
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "code",
"collapsed": false,
"input": [],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 29
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import math"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 30
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import sympy"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 31
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"sympy.init_printing()"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 32
},
{
"cell_type": "code",
"collapsed": false,
"input": [],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 32
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"price_device_minute = .17"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 33
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"devices = sympy.Symbol('d')"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 34
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"builds_per_day = 5"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 35
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"monthly_work_days = 5*4"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 36
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"time_per_build = 10 # Minutes"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 37
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"competitor_price = 1000"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 38
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"price_device_minute * devices * builds_per_day * monthly_work_days * time_per_build - competitor_price"
],
"language": "python",
"metadata": {},
"outputs": [
{
"latex": [
"$$170.0 d - 1000$$"
],
"metadata": {},
"output_type": "pyout",
"png": "iVBORw0KGgoAAAANSUhEUgAAAHEAAAASCAYAAABsHjEkAAAABHNCSVQICAgIfAhkiAAAAyFJREFU\nWIXt2E2oVVUUB/Cfvp6h+ZWJUGGBPokKktJqIJTpoJzXrA/EgRhCoEjQpNHTQWAZSg2CHkTgwEYh\n5MQQlIrEelggRZRiyVMHfaBlpa/BOrfOvZ5z3r7vbITg/uGy79nrv/b5773X2XvtzQD/e8yoqZ+D\nT/FAhW0D3sY4fscVXCvZP8e+4v892IXTmMRi7MBEgrY2vrvxNJZiHT5O8ElF09iQrjs3rwsPi4mY\nrLFvL2x1vw0FbwHO4tmS7yv4CrOaBLT07WCrCLDZifwUTDU2qbpz8/7FvTiIMRFpdULfEhE+jJml\n+jXYW3oexXncVKpbhL+wpabtHL4d7MfRRO5USB2bVN25eZUYaxC6t6JuLj4SS00H3+DDCu5JHJ7i\n/W18O/hRDEJujKkfm1TdWXkzKwhTYWtF3Wt4FZeL53lYgTMV3J+wqqH9Nr4dLMcdOJLAzYVU3bl5\nXZ/pdLEGQ/isVHd3Uf5awb+E+bhZ7Fm9mI7vOmzGD1goIvVvHEvpQCak6s7Nu5JjEt8UmWAZ84vy\nzxoBxGBXZVj9+m7CThGZZ3EXTuF4iX8jkKo7N2+i7SSuF9nf9z31V4uyau8YLsqhmjb78V0pjjvP\niwkklp/LbuxSSrru3LzWy+mLIlvrxYUGn1uK8rcaez++o8X/AyXOfbjN9ZO4UiQldWfjXnyBjYlc\n0nXn5rWaxGE8iT0VtgkRQbfWCPhZ/SSm+i7EU/hApNwdrBVR3Hu8GMeDNe/MgVTd1zLzppWddvBI\n0djFCtslEclLK2wj+LKh3VTfEbGcfNLDeQInRAeXNbwnN1J15+a1msSRovyjxn4Qj+pevpYXog70\ncFfovllJ8e1kbeUUfDYe999S+lJjD/Ijtc+5eZXYLz7lOQ2cHQVnU439dvHJP1eqewNf674yekws\nHYf69J0hlshtxfMw3sUv4rixRFxR5UbT2KT2OSuvvCcuwXu4E/cXdafFPd07eL9H8LdiwMYrOgPn\nxP40iofE4XWR2MfKafOE2MS/69N3Es/gdRGZQ+KocQQvYDVertHWL1LHJrXPuXkDDDDAAAO0xz9/\nCS4aPgUSXgAAAABJRU5ErkJggg==\n",
"prompt_number": 39,
"text": [
"170.0\u22c5d - 1000"
]
}
],
"prompt_number": 39
},
{
"cell_type": "heading",
"level": 2,
"metadata": {},
"source": [
"Number of Testing Devices before Xamarin Test Cloud is Cheaper:"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"math.floor(sympy.solve(_)[0])"
],
"language": "python",
"metadata": {},
"outputs": [
{
"latex": [
"$$5$$"
],
"metadata": {},
"output_type": "pyout",
"png": "iVBORw0KGgoAAAANSUhEUgAAAAsAAAASCAYAAACNdSR1AAAABHNCSVQICAgIfAhkiAAAAMxJREFU\nKJHN0TFLQmEUBuDHFIKGFhVcmvwFDW35T/wHQXOLo3/AsSVozTlwCwcbGhoaxHLJTVAIAo0cbLjf\nhevHTW5bL5zh/d5zXt7vHP6AcsQn+MAyaOe4xhMW8fA2qm9cpGIlap5hgDrecIPxb7Ee9mU+2CfG\nKEX8EfeoYoMmrvCaNzzFSYa3MUejSKwyVugVjfoeamd1Q8kfWjnutdjhE885zl+Sy+7gTrKFLE4l\nl+zEzWfo4yjwEm4xwmH6kEULl1jjGC/ohij/BT8UwSaNbxctpgAAAABJRU5ErkJggg==\n",
"prompt_number": 40,
"text": [
"5"
]
}
],
"prompt_number": 40
}
],
"metadata": {}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment