add adhesive tape weigth

master
sp9unb 2022-10-13 11:20:48 +02:00
rodzic 63a91f9040
commit 35ab5bee1c
1 zmienionych plików z 16 dodań i 11 usunięć

Wyświetl plik

@ -30,7 +30,7 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 14,
"id": "6ea87a15-f571-4611-8487-5b7556e2ef45",
"metadata": {
"extensions": {
@ -68,7 +68,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 15,
"id": "d075a994-76bb-46f7-bdfb-cc6ef449dc43",
"metadata": {
"extensions": {
@ -107,7 +107,7 @@
},
{
"cell_type": "code",
"execution_count": 9,
"execution_count": 19,
"id": "2f3b63fd-d5ea-40b6-a2f9-b31c84cfef36",
"metadata": {
"extensions": {
@ -129,7 +129,7 @@
{
"data": {
"application/vnd.jupyter.widget-view+json": {
"model_id": "3f07d16568084521b394d029bb354e83",
"model_id": "77a162e2f4de4b5fa24baba1400ed00b",
"version_major": 2,
"version_minor": 0
},
@ -137,18 +137,17 @@
"VBox(children=(FloatSlider(value=2.0, description='Width [m]:', layout=Layout(width='500px'), max=5.0, min=0.1…"
]
},
"execution_count": 9,
"execution_count": 19,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"def f(width,height,depth,airTemp,hotAirTemp,coatDens):\n",
"def f(width,height,depth,airTemp,hotAirTemp,coatDens,tapeDens):\n",
" \n",
" \n",
" out=widgets.Output(layout={'margin': '10px 10px 10px 20px'}) \n",
" with out: \n",
" print(\"\\n\")\n",
" # Volume\n",
" volume = width * height * depth\n",
" print( \"Volume: {:.2f} [m3]\".format(volume)) \n",
@ -158,6 +157,11 @@
" # Coating density (protective film for painting): 300g / 4x5m = 15g/m2 \n",
" coatingWeight = coatDens * area\n",
" print( \"Coating weight: {:.2f} [g]\".format(coatingWeight)) \n",
" # adhesive tape density : average 2g/m \n",
" tapeLength = 2 * width + 4 * height\n",
" tapeWeight = tapeDens * tapeLength\n",
" print( \"Adh.tape length: {:.2f} [m]\".format(tapeLength)) \n",
" print( \"Adh.tape weight: {:.2f} [g]\".format(tapeWeight)) \n",
" # Lift per volume g/m3 \n",
" # airDens = dens_temp_func( airTemp )\n",
" # hotAirDens = dens_temp_func( hotAirTemp ) \n",
@ -169,13 +173,12 @@
" totalLiftForce = lift * volume\n",
" print( \"Total lift force: {:.2f} [g]\".format(totalLiftForce)) \n",
" # Free lift force totalLiftForce - coatingWeight \n",
" freeLiftForce = totalLiftForce - coatingWeight\n",
" freeLiftForce = totalLiftForce - coatingWeight - tapeWeight\n",
" if freeLiftForce < 0:\n",
" color = 'red'\n",
" else:\n",
" color = None\n",
" print( \"Free lift force:\", colored(\"{:.2f} [g]\".format(freeLiftForce),color)) \n",
" print(\"\\n\")\n",
"\n",
" \n",
" box = Mesh(geometry=BoxBufferGeometry(\n",
@ -218,6 +221,7 @@
"airTemp=widgets.FloatSlider(min=-40, max=35, step=1.0, value=10.0, description='Air temp.[°C]:',readout_format='.0f',layout=layout,style=style) \n",
"hotAirTemp=widgets.FloatSlider(min=-40, max=55, step=1.0, value=35.0, description='Hot air temp.[°C]:',readout_format='.0f',layout=layout,style=style)\n",
"coatDens=widgets.FloatSlider(min=1, max=50, step=1.0, value=15.0, description='Coating density [g/m2]:',readout_format='.0f',layout=layout,style=style) \n",
"tapeDens=widgets.FloatSlider(min=1, max=20, step=1.0, value=2.0, description='Adh. tape density [g/m]:',readout_format='.0f',layout=layout,style=style) \n",
"\n",
"\n",
"w = widgets.interactive_output(f, {\n",
@ -226,12 +230,13 @@
" 'depth' : depth,\n",
" 'airTemp' : airTemp,\n",
" 'hotAirTemp' : hotAirTemp,\n",
" 'coatDens' : coatDens\n",
" 'coatDens' : coatDens,\n",
" 'tapeDens' : tapeDens\n",
" }\n",
" )\n",
"\n",
"\n",
"widgets.VBox([width, height, depth, airTemp, hotAirTemp, coatDens, w])\n"
"widgets.VBox([width, height, depth, airTemp, hotAirTemp, coatDens, tapeDens, w])\n"
]
},
{