How to do function shift in MATLAB?

조회 수: 3 (최근 30일)
H
H 2019년 10월 3일
댓글: Rena Berman 2019년 12월 12일
Hello, I was wondering how can I do the function shinfting in MATLAB?
For example:
Input: f(x) = x+2 (a function) and 5 (the shifting value)
Output: f(x+5) = x+7 (a function)
  댓글 수: 2
Stephen23
Stephen23 2019년 11월 27일
Original question from Google Cache:
"How to do function shift in MATLAB?"
Hello, I was wondering how can I do the function shinfting in MATLAB?
For example:
Input: f(x) = x+2 (a function) and 5 (the shifting value)
Output: f(x+5) = x+7 (a function)
Rena Berman
Rena Berman 2019년 12월 12일
(Answers Dev) Restored edit

댓글을 달려면 로그인하십시오.

답변 (1개)

Shubham Gupta
Shubham Gupta 2019년 10월 3일
Try:
function [ func_up ] = FuncShift( func, shift )
func_up = @(x)(func(x)+shift);
end

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by