Answered
hi everyone , can anyone help me to make it , thank you
I suggest you to read about logical indexing: ~(X<15)

7 years ago | 1

| accepted

Answered
Warning: Unable to find explicit solution.
dsolve() is not able to solve the problem so use ode45() instead: k=2.2; vo=0.05; cbo=0.025; Vo=5; cao=0.05; % tspam=0:100...

7 years ago | 0

Answered
関数ハンドルと配列の組み合わせについて
I would do the way as Kazuya does it but as an alternative create comma-separated list and then operate: Example: fh1=@(a,b,c)...

7 years ago | 0

| accepted

Answered
How to get the numbers that do not overlap with another matrix?
setdiff(A,B)

7 years ago | 0

| accepted

Answered
how to copy values from one table to other table
T1=table((1:10).'); T2=table([2, 4, 6, 7, 8].'); outerjoin(T1,T2)

7 years ago | 0

Answered
how to assign an alphabet to a column in matlab
a=[ 0.6164 3.1654 0.5745 2.9883 0.9381 2.1817]; b=repmat(['c1';'c2'],size(a,1)/2,1); % ...

7 years ago | 0

| accepted

Answered
Plotting a range of values from a matrix
Use simple indexing: [A(1:5);B(end-4:-1:end)]

7 years ago | 0

Answered
Convert number to string problem
number = 10; % an example if number>=0 sprintf('The number is : +%d',number) else sprintf('The number is : %d',numb...

7 years ago | 0

| accepted

Answered
solve function of ode45
Try this: There is nothing wrong with your code: dzdt(2)=-(c*z(1) - F + k*z(2))/(M + m); % ^^^---miss...

7 years ago | 0

Answered
Code to run script multiple times
<https://in.mathworks.com/help/matlab/math/parameterizing-functions.html> - *parameterize your function* (by turning your script...

7 years ago | 2

| accepted

Answered
How to insert data in a table in matlab ?
T.Altitude = (10:10:100).' % example T.Azimuth = (1:10).' % just transpose

7 years ago | 0

Answered
Search for Simulink block name
<https://in.mathworks.com/matlabcentral/answers/455228-search-for-simulink-block-name#comment_691620>

7 years ago | 0

| accepted

Answered
how to multiply 2 nd element of the following
<https://in.mathworks.com/help/matlab/math/array-indexing.html> time(2)=time(2)*18.3333

7 years ago | 0

Answered
Matching pair to some reference value
Simply use *ismembertol()*

7 years ago | 0

Answered
How do I plot a horizontal line
Using plot here is pointless when you can directly: yline(.25) xlim([.5,1])

7 years ago | 0

Answered
How do I plot my function that I made? It's piecewise.
Try this: % Logical indexing is the way I would do it but since you requested t=-2:.001:20; plot(t,Y(t)) % ^^^^---funct...

7 years ago | 1

Answered
Writing a for-loop that asks for a vector and evaluates the following function for the elements of the given point.
https://in.mathworks.com/matlabcentral/answers/86837-vector-in-a-piecewise-function - should be a starting point for your homewo...

7 years ago | 0

Answered
Setting threshold on a matrix
m(m(:,3)<.092,:)=[]

7 years ago | 0

| accepted

Answered
how to graph g(t)=1.5 cos(200*pi*t) and f(t)={5,0
t = ... g = ... f = 5 * (t>1 & t<2) ; plot(t,g,t,f)

7 years ago | 0

Answered
How to reshape coordinate geography
Not sure which orientation you want but adapt which one suits you the best from the below: reshape(data.',4,[]).' % this suits ...

7 years ago | 0

Answered
How to recognize if there is in a character a point '.'?
contains(regexp(xx,'.','match'),'.') %or strcmp(regexp(xx,'.','match'),'.') %or cellfun(@(x)x=='.',regexp(xx,'.','match')) ...

7 years ago | 1

| accepted

Answered
Can I solve this 4d integration on matlab , if it is not solvalbe on matlab is there any other way to find the number?
I=@(r2,r1,a,b)1./(r1.^2 +r2.^2-2*r1.*r2.*cos(a-b)-1).^1.5;... I1=@(b)integral3(@(r2,r1,a)I(r2,r1,a,b),.0125,.025,.0325,.06,0,2*...

7 years ago | 1

Answered
Change variable name in a loop
Naming variables is not a good idea so store it as a cell array ( https://in.mathworks.com/matlabcentral/answers/304528-tutorial...

7 years ago | 0

| accepted

Answered
syntax for random number
https://in.mathworks.com/help/matlab/ref/rand.html - see under Topics , you will find lot of resources

7 years ago | 0

Answered
Finding Duplicate rows?
Try this: AA =sort(A,2); U = unique(AA,'rows'); R = cell(size(AA,1),1); for k = 1:size(U,1) R{k}=find(ismember(AA ,U(k...

7 years ago | 0

| accepted

Answered
Why does matlab create a single row when creating a matrix of multiple columns?
[a,b] - you were concatenating two row vectors horizontally which results in a row vector, instead do: c = [a(:) b(:)] %or c...

7 years ago | 0

Answered
simplify symbolic expression coefficients
Use double() or vpa() double([305894193331964780504589990431253575232652692213127/374144419156711147060143317175368453031918731...

7 years ago | 1

Answered
hi everyone , i need help to make this , thank u
No loops needed: C=permute(reshape([A;B].',size(A,2),size(A,1),[]),[2,1,3]) % C(:,:,1) contains A and 2 B

7 years ago | 0

| accepted

Answered
how to solve equation in syms
syms x pi cos(pi+x-x)

7 years ago | 0

| accepted

Answered
Only write floating points and/or avoiding scientific notation when using dlmwrite
Use *dlmwrite()* with *precision* option.

7 years ago | 0

| accepted

Load more