GradePack

    • Home
    • Blog
Skip to content
bg
bg
bg
bg

GradePack

Fill in the following code for the behavioral architecture o…

Fill in the following code for the behavioral architecture of an ALU using the numeric standard library. Write the correct code for each region as specified by the comments around regions. library ieee;use ieee.std_logic_1164.all;use ieee.numeric_std.all;entity example is       generic (width : positive := 4); –width will ALWAYS be even       port (             in1      : in std_logic_vector(width-1 downto 0);             in2      : in std_logic_vector(width-1 downto 0);             sel      : in std_logic_vector(1 downto 0);             out1     : out std_logic_vector(width-1 downto 0);             out2    : out std_logic_vector(width-1 downto 0);             overflow : out std_logic       );end example;architecture BHV of example isbegin                  — REGION 1: Write what goes in the process list below —       process(    )             –variables list – no need to write anything here             variable temp_add  : unsigned(width downto 0);             variable temp_mult : unsigned(2*width-1 downto 0);       begin             — REGION 2: Initialize any signals below —                       case sel is                            –for region 3 compare: if in1 greater than in2 subtract in1 by in2                      –if not add and set the overflow bit as width. set both outputs in out1                    when “00” => — REGION 3: Write code below —                      –for region 4 compare: if in1 is equal to “1111” then ‘and’ in1 and in2 and set the result to out1.                      –Then elsif in2 is equal to “0000” then ‘or’ in1 and in2 and set the result to out2                      — You can assume the width is 4 he and if neither true, set out2 to in1                    when “01” =>                         — REGION 4: Write code below –-                             –multiply: store high bits in out2 and low bits in out1. keep in mind, the width generic                 –will always be even (no need to account for an extra bit on out out1 or out2)                    when “10” =>                         — REGION 5: Write code below –-                                             –create the last when statement that accounts for all other cases and set out1 to 0              — REGION 6: Write code below —             end case;                   end process;end BHV;

Read Details

Which compound or compounds contain both ionic and molecular…

Which compound or compounds contain both ionic and molecular bonds? (i) K3N; (ii) PH3; (iii) NaClO2; (iv) ClO2; (v) AlF3

Read Details

In the reaction shown below, how much of 1.15 M solution of…

In the reaction shown below, how much of 1.15 M solution of AgNO3 is needed to completely react with 0.421 mol of magnesium chloride according to the equation: MgCl2(aq) + 2 AgNO3(aq) → Mg(NO3)2(aq) + 2 AgCl(s)

Read Details

Compounds listed below were mixed with water.  Which solutio…

Compounds listed below were mixed with water.  Which solution(s) will not conduct electricity well? (i) NaCl (ii) NCl3 (iii) KCl (iv) BaCl2 (v) Pb(Cl)2

Read Details

Suppose you approximating the solution of a simple different…

Suppose you approximating the solution of a simple differential equation involving the function , and you appeal to the relation

Read Details

TRUE or FALSE? A  fixed-increment simulation clock is well-s…

TRUE or FALSE? A  fixed-increment simulation clock is well-suited for simulations that model continuous-time systems such as the movement of an approaching weather system.

Read Details

There are 5 random people in a room.  What is the probabilit…

There are 5 random people in a room.  What is the probability that at least two of them share the same birthday?  (Assume 365 days are equally likely.)

Read Details

Suppose that and are i.i.d. random variables. How would y…

Suppose that and are i.i.d. random variables. How would you simulate a discrete uniform random integer between 1 and 12 (e.g., a 12-sided die toss)?

Read Details

Consider the discrete random variable such that

Consider the discrete random variable such that

Read Details

Simplify the following expression. Write your answer with po…

Simplify the following expression. Write your answer with positive exponents. 7x3y4y2x24{“version”:”1.1″,”math”:”7x3y4y2x24″}

Read Details

Posts pagination

Newer posts 1 … 44,051 44,052 44,053 44,054 44,055 … 69,628 Older posts

GradePack

  • Privacy Policy
  • Terms of Service
Top