C Program for Matrix Multiplication (Part 2)

preview_player
Показать описание
C Programming: C Program for Matrix Multiplication (Part 2)
Topics discussed:
1) Matrix multiplication program in C.

Music:
Axol x Alex Skrindo - You [NCS Release]

#CProgrammingByNeso #CProgramming #Arrays #MatrixMultiplicationInC #ArraysInC
Рекомендации по теме
Комментарии
Автор

Seriously u r the life saviour for me at the point of time😇😇😇😇😇😇😇😇😇😇😇😇😇😇

vaishnavijain
Автор

I'm really impressed! Your explanation is very lucid. Thanks a lot.

junephelmacalisang
Автор

I can't appreciate your teaching level by words.🙏🙏

nishantsuthar
Автор

These lectures of c and data structures are teaches as the level of gate question...thanks sir a lot❤️❤️

sukh-e
Автор

Thank u Neso ! the way you explain no one explain it deeply! 🔥🔥

farazahmed
Автор

Understood, thank you for the clear and straight forward explanation, I learned more from this 8min video than I did from my 1hr30m confusing c++ class

SaltyShomudro
Автор

U backed me for my exams. .
Thanks a ton..❤️❤️
Watched nearly 5 tutorials before landing in and thank god I did..❤️❤️

rashmisarur
Автор

#include <stdio.h>
#include <stdlib.h>


int main()
{
/*
The first matrix's rows multiply with the matrix's columns
the first element in the first row multiplies with the first element in
the first column, do it for each iteration, and add them, then put it into
a new 2-dimensional array.

1. Create a 3-dimensional array
2. Create a 2-dimensional array to store the matrix multiplication
3. For now, we'll use 3 by 3 arrays
4. Check if # of rows = # of columns
5. Go through first element in first row to first element in second column
6. Multiply the elements, and when # of rows == # columns iterations then
7. Add all the multiplied values, and store it in the new array
Remember we did matrix addition? Well, this is similar, use the same
logic, except apply it to 3 dimensional arrays so, instead of adding the rows and columns
of one array, we'll multiply the elements in the first array's row to the elements in the
second array's columns.
*/

// int array[2][3][3] = {
// { {1, 2, 3}
// , {1, 2, 1},
// {3, 1, 2} },

// { {1, 2, 3},
// {1, 2, 1},
// {3, 1, 2} }
// };
// int result_array[3][3];
// int result = 0;



/*
On the first array, the row must be one/stay the same, until it mathematically mulitplies
to all three columns of the other array.

Row==1 unless second_array's_columns==3


row = 0, unless there's a ++
iterate over how we're going to remain on row 1, but still iterate the three columns in the code

we may need three-nested for loops, one to keep track of the first array's rows,
second to keep track of the second array's current row and the third to keep
track of the second array's column-number,
*/

int first_arrays_rows = 0;
int column_number = 0;
int second_arrays_rows = 0;
int result_array[3][3];
int result = 0;

int array[2][3][3] = {
{ {1, 2, 3}
, {1, 2, 1},
{3, 1, 2} },

{ {1, 2, 3},
{1, 2, 1},
{3, 1, 2} }
};


for(first_arrays_rows = 0; first_arrays_rows<3; first_arrays_rows++) {
for(second_arrays_rows = 0; second_arrays_rows < 3; second_arrays_rows++) {
for(column_number = 0; column_number < 3; column_number++) {
// printf(" [%d X %d ]", array[0][first_arrays_rows][column_number],
result = result + *

}
// printf("[%d] ", result);
= result;
printf("[%d]",
result = 0;
}
printf("\n");
}



return 0;
}

Dnsx_plus
Автор

God will give you all the good things that you wish for!!! Thank u very much!!!

michaeleluz
Автор

Understood clearly! just by watching it once. I've gone through other's video but theirs' took a lot of effort to understand . Big THANKS for helping me/us with your great explanation.

somalasresthasomala
Автор

This is awesome, I can easily understand everything... This code was complicated for me but now I get everything. Seriously, your technique is lit.

nidhivanshal
Автор

I tried to learn how to make a matrix in c programming from many tutorials, but I did not understand even the logic of teaching, but your teaching has made me completely understand me. Thank you very much you are a great, you also make program tutorial in Hindi.

manojgurung
Автор

Amazing Sir.no words to explain.... Sir your explanation is superb. thanks for helping me in Assignment.

Автор

❤Yeah, now I get it a bit. With Practise I hope I learn more. Thanks.

prasannahd
Автор

what would it be wrong? i did exact;y the same as you did only with different variables and the resultant matrix gives wrong numbers. :c\

luisangelmontiel
Автор

02:15 Sir can you send me the link of the previous lecture (for loop).
I didn't get the logic of the for loop.

TeckTrek-CS
Автор

Thank you sir. Finally found the teacher where I can learn.

saswatapramanick
Автор

sir this was really really helpful....was struggling with the concept of 'k' but u cleared it...thank you!!

LORDGAMINGqwerty
Автор

*_Thank You So Much_*
*_Good Presentation_* ❤‍🔥

TeckTrek-CS
Автор

I felt very confused while hearing this topic from our I'm clear.... really your explanation is awesome 💕

karunasree