• [X, Y, Z] = meshgrid(x, y, z) Misol.
  • 4. Maxsus matritsalar COMPAN
  • C = 0 7 -6 1 0 0 0 1 0 Mos keluvchi funksiyalar: PO LY, POLYVAL, POLYVALM. HADAMARD
  • Misol: c = [1 2 3]; H = hankel(c) H = 1 2 3 1 2 0
  • R = sprandsym(n, alpha, rcond, kind)




    Download 232,03 Kb.
    bet7/8
    Sana27.05.2024
    Hajmi232,03 Kb.
    #255039
    1   2   3   4   5   6   7   8
    Bog'liq
    Matlab tizimida matritsalar ustida arifmetik amallar bajarish

    R = sprandsym(n, alpha, rcond, kind)
    CROSS - vector ko’paytmani hosil qiladi.
    Sintaksisi:
    c = cross(a, b)
    KRON - tenzorli ko’paytmani hosil qilish.
    Sintaksisi:
    K = kron(X, Y)
    LINSPACE -teng munosabatli tugunlar chiziqli massivini hosil qilish.
    Sintaksisi:
    x = linspace(x1, x2)
    x = linspace(x1, x2, n)
    LOGSPACE - logarifmik to’rli tugunlarni hosil qiladi.
    Sintaksisi:
    x = logspace(d1, d2)
    x = logspace(d1, d2, n)
    MESHGRID - ikki o’lchamli va uch o’lchamli to’rlar tugunlarini hosil qiladi.
    Sintaksisi:
    [X, Y] = meshgrid(x, y)
    [X, Y] = meshgrid(x)
    [X, Y, Z] = meshgrid(x, y, z)
    Misol. Funksiyani -2 < x < 2, -2 < y < 2 sohada hisoblash uchun quyidagi amallar ketma-ketligi bajariladi:
    >> [X, Y] = meshgrid (-2:.2:2, -2:.2:2);
    >> Z = X.*exp (-X.^2 - Y.^2);
    >> mesh (Z).
    Mos keluvchi funksiyalar: SURF, SLICE.

    4. Maxsus matritsalar

    COMPAN - xarakterestik ko’phadni matrisa ko’rinishida ifodalaydi.
    Sintaksisi: C = compan(p).
    Misol. (x-1)(x-2)(x-3) = x3 - 7x + 6 polinomi koiffetsentalaridan tuzilgan vektor
    p = [1 0 -7 6] yordamchi massiv quyidagicha bo’ladi:
    C = compan(p)
    C = 0 7 -6
    1 0 0
    0 1 0
    Mos keluvchi funksiyalar: PO LY, POLYVAL, POLYVALM.
    HADAMARD - Adamar matritsasini (Hadamard matrix) hosil qiladi.
    Sintaksisi: H = hadamard(n).
    HANKEL - Hankel matritsasini (Hankel matrix) hosil qiladi.
    Sintaksisi: H = hankel(c)
    H = hankel(c, r)
    Misol: c = [1 2 3];
    H = hankel(c)
    H = 1 2 3
    1 2 0

    Download 232,03 Kb.
    1   2   3   4   5   6   7   8




    Download 232,03 Kb.

    Bosh sahifa
    Aloqalar

        Bosh sahifa



    R = sprandsym(n, alpha, rcond, kind)

    Download 232,03 Kb.