practica1lab.html

practica1lab.html - Contents • Ejercicio 33%Practica de...

  • No School
  • AA 1
  • 23

This preview shows page 1 - 8 out of 23 pages.

Contents Ejercicio 33 %%%Practica de laboratorio %%%%EJERCICIO 1%% %Realizar las siguientes operaciones a = sqrt(5) b = cos(pi) c = log(2) d = 124312 - 5478*3 e = 17^0.4 f = 711/143 g = 1/(2*3) h = (5+3)/(9-1) i = exp(2)/3 j =(2^3)-(4/(5+3)) k= (5^pi+2)/(4-log(3)) l = ((5+6)*(7/3)-2^2)/(2/3)*3/(3*6) a = 2.2361 b = -1 c = 0.6931 d = 107878 e = 3.1058 f = 4.9720 g = 0.1667 h = 1 i = 2.4630
Image of page 1

Subscribe to view the full document.

j = 7.5000 k = 54.7988 l = 5.4167 %Ejercicio 2 x = 1/3; y = x/(x^2-1)^3 y = -0.4746 %Ejercicio 3 %Calcular el area de un triangulo syms x b = 12*x; h = 2*x+5; x = sqrt(2); A = (b*h)/2 A1 = eval(A) x = sqrt(3); A2 = eval(A) x = 1.75; A3 = eval(A) A = 6*x*(2*x + 5) A1 = 66.4264 A2 = 87.9615 A3 = 89.2500 %%Ejercicio 4 %Syntax %taylor(f, x, <order>, <mode>) %taylor(f, x = x0, <order>, <mode>) %taylor(f, x, <AbsoluteOrder = order>) %taylor(f, x = x0, <AbsoluteOrder = order>) %taylor(f, x, <RelativeOrder = order>) %taylor(f, x = x0, <RelativeOrder = order>) %Estas son las diferentes manera de utilizar la funcion
Image of page 2
%Ejercicio 5 %Las funciones relacionados con sqrt son nthroot | realsqrt | sqrtm %Ejercicio 6 %a) format rat a1 = (1/3) + (5/7) a2 = (1 + 3/5)^3 %b) format long b1 = (1/3) + (5/7) b2 = (1 + 3/5)^3 a1 = 22/21 a2 = 512/125 b1 = 1.047619047619048 b2 = 4.096000000000001 %Ejercicio 7 %a) a = mod(89,18) b = mod(a,2) %Vemos que el residuo no es primo, ya que para que sea primo, el residuo de %su division entre 2 debe ser 0, pero en este caso es 1 %b) b = lcm(65,6) b2 = factor(b) %c) c= gcd(14,35) d = gcd(21,91) c1 = gcd(c,d) %Ejercicio 8 %Calculando raices y=x^2-4*x + 13; y1= [1 -4 13]; r= roots(y1); x1 = r(1) x2 = r(2) %Calcular a = cos(x1) + sin(x2) b = abs(x1 + x2) c = real (x1/x2) d = conj(x1) e = conj(x2) f = angle(x1)-angle(x2) a = 17 b =
Image of page 3

Subscribe to view the full document.

1 b = 390 b2 = 2 3 5 13 c = 7 d = 7 c1 = 7 x1 = 2.000000000000000 + 3.000000000000000i x2 = 2.000000000000000 - 3.000000000000000i a = 4.964873455942623 - 4.940320933788772i b = 4 c = -0.384615384615385 d = 2.000000000000000 - 3.000000000000000i e = 2.000000000000000 + 3.000000000000000i f = 1.965587446494658
Image of page 4
%%Ejercicio 9 %Parte a z = 4+2i; z2 = conj (z); zr = z*z2 %Parte b z3 = imag(z^3) zr = 20 z3 = 88 %Ejercicio 10 %definir variables simbolicas syms t w x y g(x) f(x) h(w,y) f(x) = exp(x)-x*sin(x+1) f(-1) g(x)=asin(exp(x)/x)-1 g(-0.5) h(w,y) =tan(w+y)-w/y h(0,1) h(2*t,t) f(x) = exp(x) - x*sin(x + 1) ans = exp(-1) g(x) = asin(exp(x)/x) - 1 ans = - asin(2*exp(-1/2)) - 1 h(w, y) = tan(w + y) - w/y ans = tan(1) ans = tan(3*t) - 2 %Ejercicio 11 %Enlistar las variables who
Image of page 5

Subscribe to view the full document.

%Definir de forma anonima f = @(x,y) 2*x + 3*y - 1 %evaluar f(0,1) f(1+t,0) -f(1,0) Your variables are: A A3 a2 b c e h k t x1 y1 z3 A1 a a33 b1 c1 f i l w x2 z zr A2 a1 ans b2 d g j r x y z2 f = function_handle with value: @(x,y)2*x+3*y-1 ans = 2 ans = 2*t + 1 ans = -1 %Ejercicio 12 %Las palabras no reservadas que podemos utilizar son %test, Test, Resultado_1, ZzaAbC ,Sin %Ejercicio 13 l = 8 g = 9.8 f=2*pi*sqrt(l/g) %%Ejercicio 14 %Calculo de poblacion clear %a) syms r P0 K t P = (K*P0*exp(r*t))/(K+P0*(exp(r*t)-1)) r = 1.2; P0 = 1000000; K = 1500000; t= 5; Pa = vpa(eval(P)) %b) t = 5/0; Pb = eval(P) l = 8 g = 9.800000000000001 f =
Image of page 6
5.676907580454914 P = (K*P0*exp(r*t))/(K + P0*(exp(r*t) - 1)) Pa = 1498143.2370950463227927684783936 Pb = NaN %Ejercico 15 %Realizar las siguientes operaciones a = [2, 3, 5, 8, 9] %La b no se puede realizar c = sin(a)
Image of page 7

Subscribe to view the full document.

Image of page 8

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern