multiply by three
Given the variable x as your input, multiply it by 3 and put the result equal to y.
Examples:
Input x = 2
Output y is ...
3年弱 前
解決済み
Calculate the centroid of a triangle
Info: https://en.wikipedia.org/wiki/Centroid
Example
Input:
x = [0 0 1]; % x-coordinate
y = [0 1 0]; % y-coordinat...
3年弱 前
解決済み
Unit conversion
Convert x degree Celsius to y degree Fahrenheit.
3年弱 前
解決済み
Create a vector
Create a vector from 0 to n by intervals of 2.
3年弱 前
解決済み
Reverse the vector
Reverse the vector elements.
Example:
Input x = [1,2,3,4,5,6,7,8,9]
Output y = [9,8,7,6,5,4,3,2,1]
3年弱 前
解決済み
Vector creation
Create a vector using square brackets going from 1 to the given value x in steps on 1.
Hint: use increment.
3年弱 前
解決済み
Side of a rhombus
If a rhombus has diagonals of length x and x+1, then what is the length of its side, y?
<<https://imgur.com/x6hT6mm.png>>
...
3年弱 前
解決済み
Area of an Isoceles Triangle
An isosceles triangle has equal sides of length x and a base of length y. Find the area, A, of the triangle.
<<https://imgur...
Side of an equilateral triangle
If an equilateral triangle has area A, then what is the length of each of its sides, x?
<<https://i.imgur.com/jlZDHhq.png>>
...
3年弱 前
解決済み
Dimensions of a rectangle
The longer side of a rectangle is three times the length of the shorter side. If the length of the diagonal is x, find the width...
Pizza!
Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.]
Non-scor...
3年弱 前
解決済み
Convert from Fahrenheit to Celsius
Given an input vector |F| containing temperature values in Fahrenheit, return an output vector |C| that contains the values in C...
3年弱 前
解決済み
Length of the hypotenuse
Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle.
<<https://i.imgu...
3年弱 前
解決済み
Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so:
x = [1 2 3 4]
Commas are optional, s...