본문 바로가기

Verilog/HDLbits

[HDLBits] Kmap2

1. 문제 및 설명

  •  아래 카르노 맵에 의해 정의된 회로를 구현하시오

 

문제 풀이

 각 원으로 묶인 부분을  나타내면 아래와 같다.

 - 빨강: b'&c'

 - 노랑: a'&d'

 - 주황: b&c&d

 - 파랑: a&b'&d

 

 

2. 모듈 정의

module top_module(
    input a,
    input b,
    input c,
    input d,
    output out  );

 

 

 

3. 답

module top_module(
    input a,
    input b,
    input c,
    input d,
    output out  ); 
    
    assign out = (!b&!c)|(!a&!d)|(b&c&d)|(a&!b&d);

endmodule
 

'Verilog > HDLbits' 카테고리의 다른 글

[HDLBits] Kmap4  (0) 2025.12.15
[HDLBits] Kmap3  (0) 2025.12.15
[HDLBits] Kmap1  (0) 2025.12.10
[HDLBits] Bcdadd100  (0) 2025.12.07
[HDLBits] Adder100i  (0) 2025.12.07