• WriteLine
  • Integral(Fredgolm) tenglamani momentlar usuli bilan sonli yechishni c# dasturlash tilidagi kodi




    Download 219,8 Kb.
    bet7/8
    Sana27.05.2024
    Hajmi219,8 Kb.
    #254584
    1   2   3   4   5   6   7   8
    Bog'liq
    Valijoonova Shahlo kurs ishi sonli usullardan

    2.2.Integral(Fredgolm) tenglamani momentlar usuli bilan sonli yechishni c# dasturlash tilidagi kodi
    using System;

    class Program


    {
    static void Main()
    {
    // Define the kernel function
    Func<double, double, double> kernel = (x, t) => Math.Exp(-x * t);

    // Define the limits of integration


    double a = 0;
    double b = 1;

    // Define the number of moments and the step size


    int numMoments = 10;
    double h = (b - a) / numMoments;

    // Initialize the moments array


    double[] moments = new double[numMoments];

    // Calculate the moments


    for (int i = 0; i < numMoments; i++)
    {
    double xi = a + (i + 0.5) * h;
    for (int j = 0; j < numMoments; j++)
    {
    double xj = a + (j + 0.5) * h;
    moments[i] += kernel(xi, xj);
    }
    moments[i] *= h;
    }

    // Define the function to be approximated


    Func<double, double> f = x => Math.Sin(x);

    // Calculate the approximate solution


    double solution = 0;
    for (int i = 0; i < numMoments; i++)
    {
    solution += moments[i] * f(a + (i + 0.5) * h);
    }
    solution *= h;

    // Print the result


    Console.WriteLine("Tahminiy yechim: " + solution);
    Console.ReadKey(true);
    }
    }



    XULOSA
    Mazkur kurs ishidan asosiy maqsad--Integral(Fredgolm) tenglamani momentlar usuli bilan sonli yechish mukammal o’rganib, ular orqali turli xil dasturlar tuzishni takomillashtirib keying ish faolyatimga poydevor qurishdir.
    Ushu kurs ishda men Integral(Fredgolm) tenglamani momentlar usuli bilan sonli yechish o’rganishga harakat qildim. Algoritmlar, ulardan foydalanishni va ishlab chiqilgan algoritmlar yordamida dasturlar tuzishni o’rgandim.
    Zamonaviy matematik paketlarning imkoniyatlari, qo`llanish sohalari, mathcad, maple dasturi haqida ham keng yoritib berilgan. Jumladan aniq integralni hisoblash, egri chiziqlar bilan ajratilgan sohaning yuzi, ikki karrali integrallarni hisoblash figuraning hajmi topish, murakkab ko'rinishdagi integrallarni son qiymatini topishda turli xil metodlardan foydalanish, yuqori tartibli integrallarning son qiymatini hisoblash Mathcad tizimi misollar bilan tushuntirilgan.
    Integral tenglamalarni sonli usullar: to’g’ri to’rtburchaklar, trapetsiyalar, formulalari haqida ma’lumotlar berilgan, integral va integral tenglamalar sonli usullarda hisoblangan, Mathcad dasturida ham to’g’ri to’rtburchaklar, trapetsiyalar, formulalari yordamida hisoblashlar keltirilgan. Integral tenglamalarni hisoblash algoritmlari tuzilgan.
    Bu kurs ishimni tayyorlash jarayonida men o’zim uchun bilgan bilmaganlarimni o’rgandim, va men o’rganishim kerak bo’lgan qirralari ko’pligini angladim. Endi kelajakda bu o’rganganlarim o’zimning mehnat faolyatimda juda katta samara beradi va asqotadi.

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




    Download 219,8 Kb.

    Bosh sahifa
    Aloqalar

        Bosh sahifa



    Integral(Fredgolm) tenglamani momentlar usuli bilan sonli yechishni c# dasturlash tilidagi kodi

    Download 219,8 Kb.