• 제목/요약/키워드: Functional Languages

검색결과 62건 처리시간 0.024초

함수형 언어의 패턴 매칭 기능과 제약에 관한 연구 (Pattern Matching and Its Restrictions in Functional Languages)

  • 권기항;주예찬;신현삼
    • 한국정보처리학회논문지
    • /
    • 제6권5호
    • /
    • pp.1291-1295
    • /
    • 1999
  • Modern functional languages provide some forms of pattern matching capability in them. However, these forms are on an ad-hoc basis and vary from languages to languages, making the user hard to understand the feature. To overcome this problem, we present a systematic approach to adding pattern matching to functional language. We extend to the core functional language with pattern matching capability and illustrate several examples of the language. We also discuss how to extend the pattern matching capability to higher-order terms.

  • PDF

지연 함수형 프로그래밍 언어의 항 개서 의미 (Term Rewriting Semantics of Lazy Functional Programming Languages)

  • 변석우
    • 한국정보과학회논문지:시스템및이론
    • /
    • 제35권3호
    • /
    • pp.141-149
    • /
    • 2008
  • 대부분의 함수형 프로그래밍 언어에서는 '위에서 아래쪽, 왼쪽에서 오른쪽 방향으로' 패턴 매칭(pattern matching)을 한다는 전략에 따라, 모호한(ambiguous) 특성을 갖는 룰의 정의를 허용하고 있다. 이 방법은 함수형 프로그래머에게 디폴트 룰을 정의할 수 있게 하는 직관적인 편리함을 제공하지만, 한편으로 모호한 룰 때문에 함수형 언어의 의미는 불명확해 질 수 있다. 좀 더 구체적으로, 함수형 언어가 갖는 대표적인 특성인 등식 추론(equational reasoning) 원리의 적용을 불가능하게 할 수 있으며, 함수형 언어를 람다 계산법으로 변환하는 데 있어서도 정형적인 방법이 아닌 임시방편적인(ad hoc) 방법에 의존할 수밖에 없게 한다. 본 연구에서는 지연(lazy) 함수형 언어의 패턴 매칭의 의미를 순수 선언적 특성을 갖는 항 개서 시스템(Term Rewriting Systems)의 분리성(separability) 이론과 연관시키고, 분리성 이론에 따라 지연 함수형 언어가 람다 계산법으로 변환될 수 있음을 보인다.

기초적인 프로그래밍 교육을 위한 컴퓨터 언어의 특성 및 개발 환경의 임상적 비교 분석 (Clinical Comparative Analysis of Characteristics of Computer Programming Languages and their Development Environments for Basic Programming Education)

  • 강대기
    • 공학교육연구
    • /
    • 제15권3호
    • /
    • pp.66-71
    • /
    • 2012
  • In this paper, we try to explore basic factors that defines easy-to-learn programming language and easy-to-learn development environments for novice students who have not been exposed to computer programming language education. For these purpose, we investigate and analyze computer programming languages that are widely used in industrial environments, and present the summary and analyzed results. From the experimental results, most novice programmers understand computer programming languages in terms of procedural programming languages rather than in terms of functional programming languages or object oriented programming languages. Furthermore, we have found that, for effective education of basic level programming languages, factors of development environments are much more important than factors of programming paradigms that the computer programming languages are based on.

상태를 갖는 명령형 함수언어의 설계 (A design of the imperative functional language with state)

  • 주형석
    • 한국컴퓨터산업학회논문지
    • /
    • 제2권10호
    • /
    • pp.1261-1268
    • /
    • 2001
  • 함수언어는 여러 가지 유용한 특징에도 불구하고 상태를 나타내기 위한 효율적인 방법을 제공하지 못하고있다. 함수언어의 표현력을 높이기 위해서는 함수언어의 의미를 위배함이 없이 상태를 명시적으로 나타내기 위한 방법이 요구된다. 이 연구에서는 순수 함수언어의 성질을 위배함이 없이 상태를 표현하기 위한 명령형 함수언어 $\lambda$st-계산을 설계하였고 제안된 명령형 함수언어를 감축하기 위한 알고리즘을 구성하였다. $\lambda$-계산에 명시적인 상태 구성자를 확장한 $\lambda$st-계산 모델은 상태의 합성 개념을 도입하고 감축규칙을 간략화 함으로써 구문구조의 표현력을 향상시켰다.

  • PDF

다중스레드 구조를 위한 함수형 언어의 중첩루프 펼침 (Unfolding Nested Loops of Functional Languages for Multithreaded Architectures)

  • 하상호
    • 한국정보과학회논문지:소프트웨어및응용
    • /
    • 제29권11호
    • /
    • pp.826-836
    • /
    • 2002
  • Id 언어와 같은 함수형 언어의 중천루프에 포함된 미세한 수준의 대규모 병렬성을 다중스레드 구조상에서 이용하려면 프로세서뿐만 아니라, 이름공간을 위한 상당히 말은 기억공간 등의 자원이 추가로 요구된다. 이러한 병렬성을 포함하는 중첩루프론 시스템 자원 제한 없이 무분별하게 펼쳐서 실행하려고 한다면, 실행도중 기억공간의 자원의 고갈로 인하여 프로그램의 실행이 중단될 수 있다. 또한, 루프의 펼침에 따른 부담으로 인하여 프로세서의 수에 비해서 루프를 지나치게 많이 펼치는 경우에, 병렬 수행의 효과가 상당히 떨어질 수 있다. 본 논문에서는 함수형 언어의 중첩루프를 다중스레드 구조상에서 효과적으로 펼쳐서 실행할 수 있는 알고리즘을 제안하고 분석한다. 제안된 알고리즘의 특성은 주어진 중첩루프를 펼칠 시점에 프로세서 수와 기억공간의 현재 사용 가능한 시스템 자원 양에 제한하여 안전하면서도 가능한 최적으로 펼친다는데 있다.

어휘기능문법(Lexical-Functional Grammar)에 근거한 한-영 양방향 기계 번역기의 언어학적 구성 (Linguistic design of a bidirectional Korean-English machine translation system based on Lexical-Functional Grammar)

  • 김정렬
    • 한국언어정보학회지:언어와정보
    • /
    • 제3권1호
    • /
    • pp.65-82
    • /
    • 1999
  • The interests in Machine Translation(MT) have gotten revitalized lately with the rapid expansion of internet users. MT technology has gone through several different stages of development, but the longest surviving methods usually maintains the following characteristics: the expand ability and flexibility based on proved linguistic formalism, the transfer method of translation, the continued efforts of systematic updates being made into the system. This paper introduces one such system, L&H Korean-English bidirectional MT system. This system uses Lexical-Functional Grammar as its linguistic framework. It also adopts the transfer method of MT and has been around on the market for over 10 years for other language pairs. Currently, the system covers over 10 different languages including Chinese, Japanese and Arabic, in addition to European languages. This paper will review the system in its core and discuss related tools and resources be ing used to enhance the quality of translation.

  • PDF

Feasibility Study Of Functional Programming In Scala Language By Implementing An Interpreter

  • Sugwoo, Byun
    • 한국컴퓨터정보학회논문지
    • /
    • 제28권2호
    • /
    • pp.111-119
    • /
    • 2023
  • 본 논문에서는 스칼라 언어의 함수형 프로그래밍 기능의 타당성에 대해서 검토한다. 주된 관심사는 스칼라가 어느 정도까지 람다 식, 고차 함수, 제너릭 타입, 대수적 타입, 모나드 등 함수형 프로그래밍의 주요 특성을 표현할 수 있는 가에 있다. 이 목적을 위하여 명령형 프로그래밍 언어의 인터프리터를 구현한다. 동일한 함수형 프로그래밍 기법을 적용하여 인터프리터를 하스켈과 스칼라로 구현한 다음, 이 두 버전의 구현을 비교 분석한다. 명령형 프로그래밍 언어의 추상 구문트리는 스칼라의 제너릭스를 갖는 대수적 타입과 enum 클래스로서 표현되고, 명령형 프로그래밍의 상태 변환은 상태 모나드를 이용하여 구현된다. 또한 스칼라의 새로운 기능인 extension과 given도 사용된다.

Parallel Machine에 있어서의 Functional, Declarative 언어의 Algorithm (Algorithm for Functional and Declarative Language in Parallel Machine)

  • 김진수
    • 자연과학논문집
    • /
    • 제5권2호
    • /
    • pp.39-43
    • /
    • 1992
  • 사용자의 관점에서 볼때는 compiler가 parallelism을 발견할 수 있게 하는것이 매우 요구되지만, 아무리 잘 만들어진 compiler 라 할지라도 conditional, functional 또는 I/O statement 등 프로그램내에 존재하는 많은 parallelism을 인식 하기가 결코 쉬운 일이 아니다. 경우에 따라서는 compiler의 parallelism 결정이 곤란할경우 사용자에게 feedback 시키는 경우가 종종 있다. 이런 입장에서 프로그래머는 parallelism을 바로 전달하기 위해서 프로그램의 일부를 재구성 시킬 필요가 자주 발생한다. 그러한 관점에서 Functional, Declarative 언어의 잇점이 있다고 할 수 있고, 그러기 위해서는 paralled machine에 적합한 Algorithm 이 필요하다. 그러나, 이미 사용중인 Algorithm이 Parallel Machine에 부적절 하다는 것을 의미 하는것은 아니다. 본 연구에서는, Fortran을 이용하여 Parallel Algorithm을 구현 시키기위한 Declarative 언어에 있어서 Array 및 Matrix 를 다루기위한 Abstraction 방법을 제시 하고자 한다.

  • PDF

A Survey of Automatic Code Generation from Natural Language

  • Shin, Jiho;Nam, Jaechang
    • Journal of Information Processing Systems
    • /
    • 제17권3호
    • /
    • pp.537-555
    • /
    • 2021
  • Many researchers have carried out studies related to programming languages since the beginning of computer science. Besides programming with traditional programming languages (i.e., procedural, object-oriented, functional programming language, etc.), a new paradigm of programming is being carried out. It is programming with natural language. By programming with natural language, we expect that it will free our expressiveness in contrast to programming languages which have strong constraints in syntax. This paper surveys the approaches that generate source code automatically from a natural language description. We also categorize the approaches by their forms of input and output. Finally, we analyze the current trend of approaches and suggest the future direction of this research domain to improve automatic code generation with natural language. From the analysis, we state that researchers should work on customizing language models in the domain of source code and explore better representations of source code such as embedding techniques and pre-trained models which have been proved to work well on natural language processing tasks.

계층화된 테스트벤치를 이용한 검증 환경 구현 (Implementation of a Verification Environment using Layered Testbench)

  • 오영진;송기용
    • 융합신호처리학회논문지
    • /
    • 제12권2호
    • /
    • pp.145-149
    • /
    • 2011
  • 최근 시스템의 규모가 커지고 복잡해지면서, 시스템 수준에서의 기능 검증방법론이 중요해지고 있다. 기능블록의 검증을 위해서는 주로 BFM(bus functional model)이 사용되며, 기능 검증에 대한 부담이 증가할수록 올바른 검증환경 구성의 중요성은 더욱 증가한다. SystemVerilog는 Verilog HDL의 확장으로 하드웨어 설계언어의 특징과 검증언어의 특징을 동시에 갖는다. 동일한 언어로 설계기술, 기능 시뮬레이션 그리고 검증을 진행할 수 있다는 것은 시스템개발에서 큰 이점을 갖는다. 본 논문에서는 SystemVerilog를 이용하여 AMBA 버스와 기능블록으로 구성된 DUT를 설계하고, 계층적 테스트벤치를 이용한 검증환경에서 DUT의 가능을 검증한다. 기능 블록은 Adaptive FIR 필터와 Booth's 곱셈기를 사용한다. 이를 통하여 검증환경이 DUT와 연결되는 인터페이스의 부분적인 변경을 통하여 다른 하드웨어의 기능을 검증하는데 재사용되는 이점을 가지고 있음을 확인한다.