SECION 11

#include<iostream>
#include<math.h>
using namespace std;

int opcion;
int a,b,x,p,q,N,Vo,a,t,v;
double Fx,P,Po,PO,S,Q,PA,Pot,VFi,R,PI=3.1415,rad;
double Funcion (int a);
double Potencia (int p,int q);
double Velocidad final (int l,int m,int n);
double Calor (int X,int Y);

int main()
{
    cout<<"menu \n";
    cout<<"1.Funcion \n";
    cout<<"2.Parabola \n";
    cout<<"3.Potencia \n";
    cout<<"4.POTENCIA \n";
    cout<<"5.Velocidad_Final \n";
    cout<<"6.Calor \n";
    cout<<"elija una opcion";
   
    cin>>opcion;
    switch (opcion)
    {
           case 1:
           {
                cout<<"ingrese el valor de x";cin>>x;
                Fx=pow(x,2)+5;
                cout<<Fx<<endl;
           };break;
         
           case 2:
           {
                for (x=-5,x<=5,x++)
                {
                    P=Parabola(x);
                    cout<<P<<endl;
                }
           };break;
         
           case 3:
           {
                cout<<"ingrese el valor de a";cin>>a;
                cout<<"ingrese el valor de b",cin>>b;
                Po=Potencia(a,b);
                cout<<Po<<endl;
           };break;
         
           case 4:
           {
                cout<<"ingrese el enesimo numero";cin>>N;
                cout<<"ingrese el valor de b";cin>>b;
                a=1;
                while (a<=10)
                {
                      PO=POTENCIA(a,b);
                      cout<<PO<<endl;
                      a++;
                }
           };break;
         
           case 5:
           {
                cout<<"ingrese el valor de Vo";cin>>Vo;
                cout<<"ingrese el valor de a";cin>>a;
                t=10;
                while (t<=17)
                {
                      S=Velocidad_Final (Vo,a,t);
                      cout<<S<<endl;
                      t=t++;
                }
           };break;
         
           case 6:
           {
                for (v=6,v<=13,v++)
                {
                    for (a=9,a<=15,a++)
                    Q=calor(v,a);
                    cout<<Q<<endl;
                }
           };break;
     }//FIN SWITCH
   
}
//ZONA DE FUNCIONES

double funcion (int a)
{
       PA=pow(a,2)+5;
       return PA;
}

double potencia (int p,int q)
{
       Pot=pow(p,q);
       return Pot;
}

double Velocidad_Final (int l,int m,int n)
{
       VFi=l+m*n;
       return VFi;
}

double calor (int X,int Y)
{
       rad=(2*PI*Y)/360;
       R=X*sin(rad);
       return R;
}

No hay comentarios:

Publicar un comentario

mecánica de fluidos e hidráulica

DESCARGAR 😎