Undefined function using int function?

조회 수: 2 (최근 30일)
fabian Maritato
fabian Maritato 2017년 3월 27일
댓글: Joshua 2017년 3월 27일
Hi, I've been trying to figure out how to use the int function to solve the area, but every time i use it and says ' Undefined function 'int' for input arguments of type 'double'. My version of MATLAB does not have the symbolic toolbox so I can not use syms x etc.
This is the equation I am working with, and here is my code I've generated so far;
close all
clc
N = 2; % No. of axles
Pnf = (2.5+2.05) * 9.81; % Weight of the point load in newtons
PnR = 2.05*9.81; %if the cart was split into two, 50% weight distrubition on the axles
Weight = 4.1*9.81; % Weight of cart when empty
n = 1;
Nn = N .* n;
e = cumsum(n);
en = cumsum(Nn);
tt = (Pnf .* e) + (PnR .* e);
GVW = tt/9.81
% Now find a way to generate the Area of the callibrated data.
% The influence area, A, of a truck passing by... which is a result from
% the response wave.
% Distance between the axles, xn
xx = 3; % Distance to where the point load is, half the span of slot 4
xn = 0.6
Ap = GVW .* e;
aaaa = int((xx - xn),-Inf,Inf)
I am not entirely sure this has been the correct method or approach, would like to get some feedback please. Thank you.
  댓글 수: 2
KSSV
KSSV 2017년 3월 27일
Read the documentation of int it accepts variables as inputs. You are giving double as inputs.
Joshua
Joshua 2017년 3월 27일
Since you don't have symbolic functions, you might be able to use anonymous functions and the integral command as a work around. It would look something like this:
xn=0.6;
func=@(x) x-xn
integral(func,-inf,inf)
Not really sure I understand the summation portion of the problem though.

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

답변 (0개)

카테고리

Help CenterFile Exchange에서 Calculus에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by