Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

can someone help me with this coding , actually I was ask to make a program about milling machine and my output is -Part machining

can someone help me with this coding , actually I was ask to make a program about milling machine and my output is -Part machining time -Total energy consumption -total operation cost -by products or solid waste generation Estimated productivity per day

but i miss "total operation cost" , can u add it in my program, idk how to insert it.

here is my coding;

#include #include

int main() { int a,b,c,d,r,e,f,g,h,t,G,P,q; float y,I,J,k,l,n,m,z,j; float pI=3.142; printf("WELCOME TO MILLING MACHINE "); printf("PLEASE PUT YOUR PLATE ON THIS MACHINE "); printf("SPEED OF MACHINE "); printf("1mm to 2mm: 120mm/s "); printf("3mm to 7mm: 43.3mm/s "); printf("8mm to 10 mm: 18.77mm/s "); printf("PLEASE ENTER THE PART PARAMETERS "); printf("LENGTH OF WORKPIECES(mm): "); scanf("%d",&a); printf("WIDTH OF WORKPIECE(mm): "); scanf("%d",&b); printf("THICKNESS OF WORKPIECE(mm): "); scanf("%d",&c); printf("DISTANCE FROM EDGE TO CUT(mm): "); scanf("%d",&d); printf("HOLE RADIUS(mm): "); scanf("%f",&r); printf("LENGTH OF 1st CUT(mm): "); scanf("%d",&e); printf("DEPTH OF 1st CUT(mm): "); scanf("%d",&f); printf("LENGTH OF 2nd AND 3rd(mm): "); scanf("%d",&g); printf("DEPTH OF 2nd AND 3rd CUT(mm): "); printf("%d",&h); if(c<=3) { y= 3.142*pow(r,2); n=2*3.142*r/120; j=d+r+r; m=2*h; z=a-m; k=b-m; l=2*z+2*k; t=l/120+4*n; } else if(c<=7) { y=3.142*pow(r,2); n=2*3.142*r/43.3; j=d+r+r; m=2*h; z=a-m; k=b-m; l=2*z+2*k; t=l/43.3+4*n; } else if(c<=10) { n=2*3.142*r/18,77; j=d+r+r; m=2*h; z=a-m; k=b-m; l=2*z+2*k; t=l/18.77+4*n; } else { printf("ERROR "); printf("PLEASE TRY AGAIN "); } printf(" MACHINING TIME(s) : %d ",t); G=3.142*pow(r,2)*c; printf("SCRAP GENERATED(kg) : %d ",G); P=t/28800; printf("OUTPUT PER DAY : %d ",P); q=a*b*c-4*G; J=a*b*c/q; printf("MATERIAL EFFICIENCY : %f ",J); printf("ENERGY UTILIZATION(8HOURS) : 3KW"); return 0; }

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro PowerShell For Database Developers

Authors: Bryan P Cafferky

1st Edition

1484205413, 9781484205419

More Books

Students also viewed these Databases questions

Question

Why do HCMSs exist? Do they change over time?

Answered: 1 week ago