16 bit multiplier verilog code
#1

I need code for 16bit vedic multiplier using urdhva thiryagbhyam.
Reply
#2
16 bit multiplier verilog code

module q_1_2 (input [15:0]x,y, output [31:0]z);

parameter size=256, width=16;
wire [size-1:0]pi,ci,po,co;

genvar i,j;
generate

for (j=0;j<16;j=j+1) assign pi[width*0+j]=0;
for (i=0;i<16;i=i+1) assign ci[width*i+0]=0;
q_1_1 eb0_0 (x[0],y[0],pi[o],ci[0],po[0],co[0]);

for (j=1;j<16;j=j+1) begin
assign ci[width*0+j] = co[width*0+(j-1)];
q_1_1 eb0_j (x[0],y[j],pi[width*0+j],ci[width*0+j],po[width*0+j],co[width*0+j]);
end

for (i=1;i<16;i=i+1) begin
assign pi[width*i+0] = po[width*(i-1)+0];
q_1_1 ebi_0 (x[i],y[0],pi[width*i+0],ci[width*i+0],po[width*i+0],co[width*i+0]);
end

for (i=1;i<16;i=i+1) begin
for (j=1;j<15;j=j+1) begin
assign ci[width*i+j] = co[width*i+(j-1)];
assign pi[width*i+j] = po[width*(i-1)+j];
q_1_1 ebi_j (x[i],y[j],pi[width*i+j],ci[width*i+j],po[width*i+j],co[width*i+j]);
end

assign ci[width*i+15] = co[width*i+14];
assign pi[width*i+15] = co[width*(i-1)+15];
q_1_1 ebi_15 (x[i],y[15],pi[width*i+15],ci[width*i+15],po[width*i+15],co[width*i+15]);
end

for (i=0;i<16;i=i+1) assign z[i] = po[width*i+0];
for (j=1;j<16;j=j+1) assign z[j+15] = po[width*15+j];
assign z[31] = co[width*15+15];

endgenerate
endmodule
Reply

Important Note..!

If you are not satisfied with above reply ,..Please

ASK HERE

So that we will collect data for you and will made reply to the request....OR try below "QUICK REPLY" box to add a reply to this page
Popular Searches: 16 bit multiplier verilog code, verilog 4 bit multiplier, 16 bit linear multiplier verilog code, 32 bit vedic multiplier verilog coderaw date 27 05 16, 4 bit array multiplier verilog, 16 bit by 32 bit multiplier verilog code, verilog code for 4 bit signed baugh wooley multiplier,

[-]
Quick Reply
Message
Type your reply to this message here.

Image Verification
Please enter the text contained within the image into the text box below it. This process is used to prevent automated spam bots.
Image Verification
(case insensitive)

Possibly Related Threads...
Thread Author Replies Views Last Post
  lsb 1 bit algorithm implementation java source code 2 933 11-07-2016, 04:44 PM
Last Post: dhanabhagya
  how to interface lm35 with fpga code in verilog 1 1,074 11-06-2016, 04:04 PM
Last Post: dhanabhagya
  bresenham line algorithm verilog 1 749 11-06-2016, 03:53 PM
Last Post: dhanabhagya
  16 bit kogge stone adder verilog code 1 1,009 08-06-2016, 04:26 PM
Last Post: dhanabhagya
  verilog code for line following robot 1 585 08-06-2016, 04:24 PM
Last Post: dhanabhagya
  future scope of modified booth multiplier 1 701 03-06-2016, 04:29 PM
Last Post: dhanabhagya
  verilog source code for elliptic curve cryptography 1 603 03-06-2016, 04:20 PM
Last Post: dhanabhagya
  verilog code for a water level controller 1 755 31-05-2016, 12:33 PM
Last Post: dhanabhagya
  4x4 multiplier using compressor verilog code 1 651 27-05-2016, 11:19 AM
Last Post: dhanabhagya
  elevator control source code verilog 1 729 25-05-2016, 12:12 PM
Last Post: dhanabhagya

Forum Jump: