Materiales
FACULTAD DE INGENIERIA
ESCUELA DE INGENIERIA MECATRONICA
PRIMERTEST DE MECANICA DE FLUIDOS Y TRANSFERENCIA DE CALOR
|APELLIDOS Y NOMBRE |FIRMA |NOTA |
||201020675 | |
|| | |
|Chávez Padilla Juan José Patricio | ||
COMPLETAR EN LOS ESPACIOS EN BLANCO:
1) Se desea graficar la función [pic] con [pic] , [pic], escriba los comandos en MATLAB correspondientes:
>> x=0:pi/100:4*pi;
>>a=log(abs(cos(x))+1);
>> b=(x^pi)+abs((pi^exp(1)).*sin(x));
??? Error using ==> ^
Matrix must be square.
>> b=(x.^pi)+abs((pi^exp(1)).*sin(x));
>> y=a./(b.^(1/pi));
Warning: Divide by zero.
(Type "warning offMATLAB:divideByZero" to suppress this warning.)
>> plot(x,y)
[pic]
2) Escriba el comando mas abreviado para generar la siguiente matriz:
[pic]
>> clear
>>h1=[1:5;10:-1:6;11:15;20:-1:16;21:25];
>> h2=2.^[1:2:9];
>> h3=h2';
>> H=[h1,h3];
>> H=[h1,h3]
H =
1 2 3 4 5 2
10 9 8 7 6 8
11 12 13 14 15 3220 19 18 17 16 128
21 22 23 24 25 512
3) Escriba un comando MATLAB que genere a partir de la matriz H del ejemplo anterior, la siguiente matriz:
[pic]
>>h1=[1:5;10:-1:6;11:15;20:-1:16;21:25];
>> h2=2.^[1:2:9];
>> h3=h2';
>> H=[h1,h3];
>> G=[H(2:5,2),H(2:5,4),H(2:5,6)]
G =
9 7 8
12 14 32
19 17 128
22...
Regístrate para leer el documento completo.