4.3.1 Matrix Chain Multiplication (Program) - Dynamic Programming

Поділитися
Вставка
  • Опубліковано 7 лис 2024

КОМЕНТАРІ • 147

  • @minhazmuktadir1194
    @minhazmuktadir1194 3 роки тому +34

    Compared to others making similar videos, he's quite elaborate even though slow. For beginners, it is perfect.

  • @sharda16april
    @sharda16april 7 місяців тому +10

    One of the best teacher. Thank you Sir. God bless you and your family always.

  • @mdkamrankhan4032
    @mdkamrankhan4032 5 років тому +42

    Thank you Sir for taking the hardship for making all of these well-explained Video Lectures. You deserve a lot of Respect for your hard work. Thank you!!

  • @nikhilmahato5771
    @nikhilmahato5771 6 років тому +13

    One can understand completely matrix chain multiplication with these two videos Outstanding... awesome.

  • @MrPollitogatito
    @MrPollitogatito 3 роки тому +7

    We had this same exact example in class and I understand where the 88 and 104 came from now. Thank you!

  • @Hussainsaddam-c1v
    @Hussainsaddam-c1v 4 місяці тому +1

    best teacher i have ever found on earth , love you sir always❤❤❤❤❤❤❤❤❤❤

  • @jaatharsh
    @jaatharsh 4 роки тому +1

    jump to 16:49 those who are here just for Print Algo.
    Abdul Bari sir you are one of the most awesome teachers I have learned from, thanks for publishing excellent quality videos.

  • @PhantomAnonymous-ie1pi
    @PhantomAnonymous-ie1pi 5 місяців тому

    This channel deserves the most subscribers because these video lectures are among the best channels for CS

  • @Toopa88
    @Toopa88 5 років тому +5

    I think it would be better to set "m[i][j]" to -1 before the 3rd loop and then check if(q < m[i][j] || m[i][j] == -1)
    Theoretically it would be best to set "m[i][j]" to infinite but practically -1 is easier to use.

  • @sandeepmandrawadkar9133
    @sandeepmandrawadkar9133 5 років тому +10

    Sir, your explanation is awesome. most simplest, yet highly effective. hats off to you Sir!!!

  • @harishch769
    @harishch769 6 років тому +5

    sir the code u have has bug because of 2 way recursion while printing u gave cout

  • @308_akashsharma2
    @308_akashsharma2 3 роки тому +1

    super easy program!! this topiic takes my long time to understand and u make it so easy to understand. thanks alot sir!!

  • @annafebland4460
    @annafebland4460 Рік тому +2

    Thank you for the video sir! But can you please put the code in the description?

  • @krutikabarad4241
    @krutikabarad4241 3 місяці тому

    pretty easy compared to the code of multistage graph, thank you for explaining it so well

  • @aishwaryaverma7129
    @aishwaryaverma7129 4 роки тому +8

    Nice explanation Sir!! But the code is not present in the description box can you pls add it?

  • @Abhishek-ys2io
    @Abhishek-ys2io 3 роки тому +2

    Sir, your voice is pleasing.

  • @kalpitvisavadiya926
    @kalpitvisavadiya926 4 роки тому +5

    Sir Iska source code description me nahi hai.

  • @sadekujjamansaju2245
    @sadekujjamansaju2245 3 роки тому +11

    very good explanation. but one minor issue
    k should start from i instead 1.
    for(k = i; k

    • @shauryavardhan9206
      @shauryavardhan9206 2 роки тому +1

      Please look carefully in the code... it is ' i ' not 1. :)
      Thanks.

    • @yourtube3214
      @yourtube3214 2 роки тому +3

      @@shauryavardhan9206 as per said by Abdul sir in the description there is the piece of code but I couldn't find it...can anyone Please send the code in comment reply section here ?

  • @RaviKumar-vk6ib
    @RaviKumar-vk6ib 4 роки тому

    sir you are awesome ...far better than tushar roy...you are my online guru and goto person for algorithms...very much thankful

  • @solidstatedevices
    @solidstatedevices 5 років тому +1

    Best explanation So far on youtube

  • @saurabh.gupta22
    @saurabh.gupta22 5 місяців тому

    This man is genius ❤

  • @bhavyanayyer3391
    @bhavyanayyer3391 3 роки тому +1

    in the program there should be k = I thanks sir u r amazing

  • @abhishekkumargupta3043
    @abhishekkumargupta3043 5 років тому +3

    as Simple as it can get. Thanks for this explanation!!

  • @sgupta308
    @sgupta308 10 місяців тому

    thanks for the course. Sir you have mentioned, code is in description. Not able to see any link for code.

  • @manishsakariya4595
    @manishsakariya4595 5 років тому +1

    k loop should start from i and should end at j-1. please update if possible

  • @ardhidattatreyavarma5337
    @ardhidattatreyavarma5337 2 роки тому +2

    Holy cow the code is beautiful

  • @subramaniyanvg6367
    @subramaniyanvg6367 Рік тому

    Sir truly super. One issue i don't find program in description any idea where I can get?

  • @BrahmanG-kl1yl
    @BrahmanG-kl1yl 5 місяців тому

    How to find which value of 'q' is minimum

  • @Quelledine
    @Quelledine 6 років тому +6

    Amazing videos and explaination! Thank you, sir!

  • @anshulgoyal2682
    @anshulgoyal2682 4 роки тому

    Sir I think this can also be done by a recursive method, I mean whichever cost is found to be min. In the beginning should just be multiplied and then again recursively called for (n-i) no. of arrays where (i) is no. of times multiplication has already been done...
    And Thank you it was because of binge watching ur videos that I was able to think towards this approach...

  • @aarthikeerthi149
    @aarthikeerthi149 6 років тому +3

    Sir, its a nice video to understand "Ordering matrix multiplication" , but in exam how they ask question? to solve "Ordering matrix multiplication"...

  • @harishch769
    @harishch769 6 років тому +3

    sir plz create advanced data sructures like fenwick splay trees and more

  • @alvxlopez
    @alvxlopez 4 роки тому

    Thanks for all the video on matrix chain multiplication, very helpful.

  • @adityalaata
    @adityalaata 6 років тому +2

    the sequence print can be resolved by
    if(s[l][h]==0)
    {
    if(l==(n-1)&&h==(n-1)){cout

    • @adityalaata
      @adityalaata 6 років тому +1

      #include
      using namespace std;
      void inorder(int s[][5],int l,int h,int n)
      {
      if(s[l][h]!=0)
      {
      cout

    • @adityalaata
      @adityalaata 6 років тому

      Thank you Sir.Your efforts are really very helpful and we are benefitting from your way of teaching.Looking forward to many more videos on your channel.

    • @adityalaata
      @adityalaata 6 років тому

      Abdul Bari
      Reduction problems in NPC or approximation algorithms
      Convex hull
      Red black trees
      Or any other topic you think is interesting or important

  • @JRAllen-nv8vy
    @JRAllen-nv8vy Рік тому

    This is fantastic. Thank you for the explanation and examples.

  • @shraddhadwivedi3101
    @shraddhadwivedi3101 Рік тому

    where is code ,as u said it is in description but in description there is udemy course link

  • @sabamaheen528
    @sabamaheen528 Рік тому +1

    Thank you soo much sir..very well explained 🤍

  • @yunyi1900
    @yunyi1900 4 роки тому +1

    Thank you for the teaching. I knowed it finally! Thank you!

  • @nannubedi7773
    @nannubedi7773 4 роки тому +1

    why is min = 32767 initially??

  • @akshitk6818
    @akshitk6818 2 роки тому

    Very helpful video! Thank you so much Abdul Sir!

  • @sourabhsingh5941
    @sourabhsingh5941 2 роки тому

    There is no code in the description

  • @anuragdhote8902
    @anuragdhote8902 2 роки тому

    where I can find the Inorder Traversal Code?

  • @samriddhijain1651
    @samriddhijain1651 3 роки тому

    How is this inorder traversal?

  • @metallitaITA
    @metallitaITA 3 роки тому +1

    can I ask why we assign that "magic number" to min?

  • @kainatkhan4497
    @kainatkhan4497 6 років тому +6

    sir plz explain algorithms of edge finding for images

    • @anant8884
      @anant8884 5 років тому +2

      that is a typical algorithm and different from this. Andrew Ng has a video on edge detection for images. Watch it.

  • @v.karthikraju5616
    @v.karthikraju5616 5 років тому +1

    Perfect explanation in an intuitive way...Thanks a lot sir

  • @gopabharti8377
    @gopabharti8377 4 роки тому

    Sir the link in the description is not working...please provide proper link...so that I can understand and learn it

  • @jarinjui4277
    @jarinjui4277 5 років тому +1

    Thanks sir. you'r video so helpful for me....

  • @pranavbalaji7864
    @pranavbalaji7864 2 роки тому

    Sir code is not available in the desc. Requesting you to kindly upload it.

  • @kainathussain6973
    @kainathussain6973 2 роки тому

    sir where is the program its not in the description

  • @sanjaykapilesh5426
    @sanjaykapilesh5426 5 років тому +3

    why is there a line of code that says min=32767 ??

    • @changguiqian7794
      @changguiqian7794 5 років тому +2

      i have the same questions

    • @nakshathranazer6446
      @nakshathranazer6446 4 роки тому

      @@changguiqian7794 Maybe for just initialising,to begin comparing

    • @umairalvi7382
      @umairalvi7382 3 роки тому +1

      See what i is doing in loop.
      It is keeping track of row in which we want to compute the value.
      Say i=1,j=2
      Now q will contain 120
      120

  • @Smashkartzz
    @Smashkartzz Рік тому

    Code kha s milega ye description m ???

  • @mohammedadel8948
    @mohammedadel8948 2 роки тому

    Thank you for your hard work.

  • @jannatulmawasornale4215
    @jannatulmawasornale4215 4 роки тому +2

    where is the code?

  • @navneetpal8046
    @navneetpal8046 5 років тому +1

    Sir parenthesis find out karna ka algorithm ki link de do....the link in the description is not working

  • @angadrajsingh4311
    @angadrajsingh4311 5 років тому +1

    Sir the link is not opening to the code

  • @naimulislam8488
    @naimulislam8488 2 роки тому

    where is the code
    its not in the description

  • @joydeeprony89
    @joydeeprony89 5 років тому +1

    seems like the program link is not working.

  • @nam_blink
    @nam_blink 6 років тому +4

    shouldn't the k loop start from i ?

  • @pankajkumarprasad1489
    @pankajkumarprasad1489 4 роки тому +2

    Sir there is no code in the description

    • @nannubedi7773
      @nannubedi7773 4 роки тому

      exactly no code... Has sir put it anywhere else bro?

  • @debaratighatak2211
    @debaratighatak2211 3 роки тому

    Thank you so much sir, the explanation is so amazing!

  • @bhanushreechauhan9792
    @bhanushreechauhan9792 3 роки тому

    Can u make video on matrix multiplication with variable order with random fixed point and floating point value . Plz explain it ,I need

  • @cakelickinginstrument5312
    @cakelickinginstrument5312 4 роки тому

    why min= 32767 is written in the code

  • @Arpit_Arora
    @Arpit_Arora 4 роки тому

    Salute hai sir aapko

  • @pratikmoharana4165
    @pratikmoharana4165 2 роки тому

    Sir why min=32767???

  • @priyatuts3115
    @priyatuts3115 3 роки тому +1

    Why min=32767

  • @thrilleracaste400
    @thrilleracaste400 2 роки тому

    Best playlist!

  • @hamzasaber880
    @hamzasaber880 5 років тому

    Anyone who didn't understand how the S matrix is filled, please check the next video to fully understand it

  • @rajeshmohanty8090
    @rajeshmohanty8090 5 років тому

    mind blowing explanation,sir

  • @muhammadnazeel463
    @muhammadnazeel463 5 років тому +1

    Sir even this code is compile in turbo c++

    • @MohdSalman-hm3zc
      @MohdSalman-hm3zc 3 роки тому

      where is code

    • @muhammadnazeel463
      @muhammadnazeel463 3 роки тому

      @@MohdSalman-hm3zc follow the brocode channel in which they explain algorithm with code very deeply

  • @boredsatan4435
    @boredsatan4435 10 місяців тому

    ty sir i am algo now

  • @moransanjay505
    @moransanjay505 3 роки тому

    Thank you for explanation!

  • @hackstreet781
    @hackstreet781 3 роки тому +37

    I hate dynamic programing

  • @vinaybora617
    @vinaybora617 3 роки тому +1

    Awesome! tutorial

  • @jadsakr9867
    @jadsakr9867 4 роки тому

    the link is wrong i think, I can't find the code. please help

  • @snehel1586
    @snehel1586 2 роки тому

    hwo can we use the S table to actually parenthesize our matrices correctly? Can someone help bcoz i'm finding it difficult to code it out?

    • @studyacc
      @studyacc 2 роки тому

      Follow this algorithm:
      if i == j
      print “A”i
      else print “(”
      PRINT-OPTIMAL-PARENS(s, i, s[i, j])
      PRINT-OPTIMAL-PARENS(s, s[i,j] + 1, j)
      print “)”

  • @monishakirthu5248
    @monishakirthu5248 5 років тому

    thank you sir ........ nyz video

  • @frobeniusfg
    @frobeniusfg 4 роки тому

    144 < 158 in m[1][4] calculation

  • @robinkumar9021
    @robinkumar9021 5 років тому

    nice explanation vp!

  • @endgame3842
    @endgame3842 3 роки тому

    Where is code

  • @ssnprakash
    @ssnprakash Рік тому

    where is the code can anyone send it to me?

  • @Riffu_Rafan
    @Riffu_Rafan 6 років тому

    Nice explanation

  • @azharuddinkhan117
    @azharuddinkhan117 6 років тому

    Thank you So much sir,
    Because of you I am gaining some valuable knowledge.

  • @sultanatasnimjahan5114
    @sultanatasnimjahan5114 5 років тому

    If i code it in codeblocks.ans is-142.. but why!😥

  • @Sayan_Sinha
    @Sayan_Sinha Рік тому

    Why min=32767?

    • @NotFlame
      @NotFlame Рік тому

      Can by any value, we are just taking a very big value to find minimum

  • @rugvedbongale7651
    @rugvedbongale7651 4 роки тому

    You are the best!!!

  • @SurajMaity
    @SurajMaity 3 роки тому

    really great.

  • @Rk1818_
    @Rk1818_ 4 роки тому

    you are a legend

  • @harshdeep6281
    @harshdeep6281 6 років тому +1

    Thank you sir!

  • @bipul2138
    @bipul2138 5 років тому

    very helpful

  • @srivathsanv9116
    @srivathsanv9116 3 роки тому

    where is the source code?

  • @adnanalkarfan2277
    @adnanalkarfan2277 3 роки тому

    Given a set of non-negative distinct integers, and a value m, determine if there is a subset of the given set with sum divisible by m.
    Input Constraints
    Size of set i.e., n

  • @ashiq4750
    @ashiq4750 5 років тому

    the code download link is not working sir..!
    can you give it on the comment please..?

    • @ashiq4750
      @ashiq4750 5 років тому

      Abdul Bari sir can you give the code here please?

  • @VeeruSingh-ww4nr
    @VeeruSingh-ww4nr 4 роки тому

    Thank You Sir

  • @naimulislam8488
    @naimulislam8488 2 роки тому

    everyone there is a mistake in the code
    k should start from i not 1

  • @MijanurRahman-jo1st
    @MijanurRahman-jo1st 6 років тому

    Thanks for the code.

  • @AnitShrestha
    @AnitShrestha 5 років тому

    Thank you!

  • @sonya8505
    @sonya8505 5 років тому

    thank you so much!

  • @shoaibakhtar9194
    @shoaibakhtar9194 5 років тому

    thnx sir

  • @sharmisthachakraborty256
    @sharmisthachakraborty256 5 років тому

    Thank u sir