Gelöst


Add two different item as shown in example
Add two different item as shown in example x=5; y='ab'; Then output must be'5ab';

fast 10 Jahre vor

Gelöst


Vector Linear sum: (p1-m1)V1+(p2-m2)V2+...(pK-mk)Vk
Calculate the sum of a Vector times coefficients expressed as two strings. Example: Normal representation [ a b c ], [ p1 ...

fast 10 Jahre vor

Beantwortet
Find the longest path in a graph?
Generally this is NP-hard problem. However, for DAGs (directed acyclic graphs) there is one clever way to solve the problem. It ...

fast 10 Jahre vor | 3

Gelöst


chance in percent for minimum K heads when a good coin is tossed N times?
For example, chance is 100% for minimum 0 heads when a coin is tossed 7 times. Chance is 50% for minimum 2 heads when a coin is...

fast 10 Jahre vor

Gelöst


Perimeters/Circumference
Given an array. Determine whether the perimeter is of a circle, triangle or square. Then calculate the perimeter.

fast 10 Jahre vor

Beantwortet
evaluating elements of a vector in a function file
First, the "for" loop stop at first iteration because it enters in one "break" condition. Second, in order to fix it, please gi...

fast 10 Jahre vor | 2

Beantwortet
How do I plot the relationship between two variables in an inseparable function?
(Erroneously canceled my previous answer) Not all s,T verify the equation. To find them use fsolve <https://it.mathworks.com/hel...

fast 10 Jahre vor | 3

Gelöst


Factorial !
Calculate the factorial of a non-negative integer without using the built in function *factorial*

fast 10 Jahre vor

Gelöst


Matrix rotation as per given angle
Given a user defined matrix and angle of rotation, rotate the elements of output matrix as clockwise or anti-clockwise. Angle wi...

fast 10 Jahre vor

Gelöst


Write a code that will follow the equation y = x * (x + x) * x.
If x = 5, y = 5 * (5+5) * 5 = 250

fast 10 Jahre vor

Gelöst


Remove the positive integers.
Given array,x, remove all the positive numbers and display ouput as y. Example x=[1 -2 3 -4] , output is y=[-2 -4].

fast 10 Jahre vor

Gelöst


find the surface area of a cube
given cube side length x, find the surface area of the cube, set it equal to y

fast 10 Jahre vor

Gelöst


ベクトル [1 2 3 4 5 6 7 8 9 10] の作成
MATLABでは,角括弧の中に要素を入れることで、ベクトルを作成できる。 x = [1 2 3 4] また次のようにも書ける(コンマはオプション)。 x = [1, 2, 3, 4] 問題:次のベクトルを出力する関数を作成せよ。...

fast 10 Jahre vor

Gelöst


y equals x divided by 2
function y = x/2

fast 10 Jahre vor

Gelöst


Subtract two positive numbers
Given a and b as a string, return b-a without using string to number conversion functions. a and b must to be a same size and b ...

fast 10 Jahre vor

Beantwortet
for loop and calculaion
Sure it doesn't work. This line d2 = (((P.*b)./(6.*l.*E.*I)).*((l./b).*(x-a).^3)+(l^2 - b.^2).*(x-x.^3)) there are for e...

fast 10 Jahre vor | 3

Gelöst


Sum of diagonals elements of a matrix
Given a matrix, return the sum of all the elements across the diagonals. E.g. A = [1 2 3; 4 5 6; 7 8 9;...

fast 10 Jahre vor

Gelöst


Convert a numerical matrix into a cell array of strings
Given a numerical matrix, output a *cell array of string*. For example: if input = 1:3 output is {'1','2','3'} whic...

fast 10 Jahre vor

Beantwortet
how to make an array with only single numbers from 1 till n
Here it is m=1:14 s=regexprep(num2str(m),' ','')-48

fast 10 Jahre vor | 3

| akzeptiert

Beantwortet
Smoothing images with user-defined masks as vectors.
Use imfilter function: originalRGB = imread('peppers.png'); imshow(originalRGB); %define filter fil = ones(3,5,1);...

fast 10 Jahre vor | 3

Beantwortet
hello, i have equation, but dont know how to solve it, x=argmaxD(epsilon), please help
Given D, then just [~,e]=max(G)

fast 10 Jahre vor | 3

Gelöst


letter yes yes & letter no no
Split a string into two strings, first string has all alphabetic letters, next string has all the rest, keep the order please, o...

fast 10 Jahre vor

Gelöst


Given area find sides
In a right angle triangle given area 'A' one arm=x, another arm=2x then find the value of x. For example, area A=400 then ...

fast 10 Jahre vor

Gelöst


Compute Fibonacci Number
Compute the _n_-th Fibonacci Number f(0) = 0, f(1) = 1, f(2) = 1, f(3) = 2, ... f(42) = 267914296

fast 10 Jahre vor

Beantwortet
How do you create the number as mentioned below?
Here it is m=1:30; n=12; s=regexprep(num2str(m),' ','') s(n)

fast 10 Jahre vor | 3

| akzeptiert

Beantwortet
Challenge: How to interact with MATLAB figure using mouse events?
Also, try this simple version. You can update 5 pixels here, however choose the number in the for loop. I=zeros(20,20); ...

fast 10 Jahre vor | 4

| akzeptiert

Gelöst


Fahrenheit to Celsius converter
Convert Fahrenheit to Celsius degrees.

fast 10 Jahre vor

Beantwortet
Make a plot using value from a certain line of matrix
Herre it is: %define a 10x10 matrix A=rand(10,10); %plot its 5th column with index as x axis plot(A(5,:)); %de...

fast 10 Jahre vor | 3

| akzeptiert

Beantwortet
how I write independent random numbers from a normal distribution, for example between (0,1)?
There is specific matlab function <https://it.mathworks.com/help/matlab/ref/randn.html> For example, create 4x5 matrix of n...

fast 10 Jahre vor | 3

| akzeptiert

Mehr laden