1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
galina1969 [7]
3 years ago
10

Try using the inv command to find the inverse of the matrix Notice the strange output. Include your command and the output in yo

ur write-up. Now enter the following matrix A into MATLAB: >> A = [4 9; 5 11] Define B to be its inverse in MATLAB. Then run the commands >> A*B >> B*A to check that it satisfies the definition of inverse. Include your commands and their output in your write-up. (Note that MATLAB may give you entries like -0.0000 in your results. This still counts as 0 for our purposes.) Enter the following column vector x: >> x = [5; 10] Use the following command to multiply A by x: >> y = A*x As usual, include your input and output in your write-up. Without entering anything into MATLAB, what do you think you'll get if you multiply B by y? Explain your answer. Use MATLAB to check your answer to the last question, and include your input and output in your document.
Computers and Technology
1 answer:
denpristay [2]3 years ago
3 0

Answer:

a)

inv([1 1; 100 100])

warning: matrix singular to machine precision

warning: called from ATest at line 1 column1

ans =

Inf Intf

Inf Inf

b)

A = [4, 9; 5, 11]

B = inv(A)

A*B

B*A

4. 9

5 11

-11.0000 9.0000

5.0000 4.0000

ans . 00000 -0.00000

0 . 00000 1.00000

ans 1.00000 0.00000

0.00000 1.00000

c)

x = [5; 10]

y = A*x

x = [5; 10]

y=

110 135"

d)

B * y is

5.0000

10.0000

e)

B * y

ans 5.0000

10.0000

You might be interested in
In order to consolidate your theoretical knowledge into technique and skills with practical and applicational value, you will us
Arisa [49]

Answer:

Check the explanation

Explanation:

Lasso: R example

To run Lasso Regression you can re-use the glmnet() function, but with the alpha parameter set to 1.

# Perform 10-fold cross-validation to select lambda --------------------------- lambdas_to_try <- 10^seq(-3, 5, length.out = 100) # Setting alpha = 1 implements lasso regression lasso_cv <- cv.glmnet(X, y, alpha = 1, lambda = lambdas_to_try, standardize = TRUE, nfolds = 10) # Plot cross-validation results plot(lasso_cv)

Best cross-validated lambda lambda_cv <- lasso_cv$lambda.min # Fit final model, get its sum of squared residuals and multiple R-squared model_cv <- glmnet(X, y, alpha = 1, lambda = lambda_cv, standardize = TRUE) y_hat_cv <- predict(model_cv, X) ssr_cv <- t(y - y_hat_cv) %*% (y - y_hat_cv) rsq_lasso_cv <- cor(y, y_hat_cv)^2 # See how increasing lambda shrinks the coefficients -------------------------- # Each line shows coefficients for one variables, for different lambdas. # The higher the lambda, the more the coefficients are shrinked towards zero. res <- glmnet(X, y, alpha = 1, lambda = lambdas_to_try, standardize = FALSE) plot(res, xvar = "lambda") legend("bottomright", lwd = 1, col = 1:6, legend = colnames(X), cex = .7)

Kindly check the Image below.

5 0
3 years ago
¿que lenguaje de programacion usan los operadores matematicos?​
kolbaska11 [484]

Answer:

Matlab / GNU Octave. MATLAB (laboratorio de matrices) es un entorno informático numérico multiparadigma y un lenguaje de programación de cuarta generación.

Explanation:

8 0
3 years ago
Read 2 more answers
Match each word to its correct meaning.
MrMuchimi

Answer:

1. active listening             8. an online journal

2. barrier            1. a strategy for showing other people you are interested in what they are saying and that you understand what they are saying and how they feel about it

3. blog          2. anything that interferes with a message being sent or received

4. communication    5. guidelines for courteous electronic communication

5. netiquette         7. the person who creates or composes a message and delivers it either orally or in writing

6. receiver        9.. a personal belief that one should work hard and do a good job

7. sender             3. an online database of Web pages that can be created or edited by anyone (with permission)

8. wiki            6. the person who receives a message

9. work ethic          4. an exchange of information

Explanation:

The answer is as mentioned above. And these are important words from subject Professional Communication. And like when we talk of an exchange of information, we mean communication. And similarly, other words means as being mentioned above.  

5 0
3 years ago
Array Challenge Have the function ArrayChallenge (arr) take the array of numbers stored in arr and return the string true if any
vampirchik [111]

Answer:

The code is given as follows,

Explanation:

Code:

#include <stdio.h>

#include <string.h>  

int n; //to store size of array  

char* ArrayChallenge(int arr[]) //function returns string true or false

{

  int i, j;

  int sum = 0;

  for(i = 0; i < n; i++)

  {

      sum = sum + arr[i]; //count sum

  }  

  for(i = 0; i < n; i++)

  {

      for(j = i+1; j < n; j++) //loop for every two elements in array

      {

          if(arr[i]*arr[j] > 2*sum) //check if proudct of two elements > 2 times sum

          {

              printf("\n%d x %d = %d, 2xSum = %d\n", arr[i], arr[j], arr[i]*arr[j], 2*sum);

              return "true"; //If proudct of two elements > 2 times sum. return true

          }

      }

  }

  return "false"; // If proudct of two elements < 2 times sum. return false

}  

int main()

{  

  printf("\nEnter size of array: ");

  scanf("%d", &n); //read size of array

  int A[n]; //array of size n

  printf("\nEnter array elements: ");

  int i;

  for(i = 0; i < n; i++)

  {

      scanf("%d", &A[i]); //read array from stdin

  }

  printf("%s\n",ArrayChallenge(A)); //ccall function and print answer

 

  return 0;

}

6 0
3 years ago
Compute the monthly cost of gas.
aalyn [17]

Answer:

Attached excel file containing formula for monthly cost of gas.

Explanation:

To find mileage note down readings at the star of month and at end of month.

Subtract end of month reading from start this will give you number of miles in month. Now as per mentioned in question, divide number of miles by average mpg and multiply by the price of a gallon of gas.

Here is your monthly cost of gas.

Download xlsx
6 0
3 years ago
Other questions:
  • Which type of electronic community displays discussions on different topics in threads?
    8·1 answer
  • as measuring the current, the shunt resistance of a galvanometer is needed to be zero. so why don't we put a wire parallel to th
    9·1 answer
  • A program runs from start to finish, producing unexpected results, though no error message is received. What most likely occurre
    15·1 answer
  • For java
    7·1 answer
  • Accenture has partnered with a global construction company that specializes in building skyscrapers. The company wants better ma
    12·1 answer
  • Functionality testing is primarily used with ____________. firewall protection software development hardening servers server tes
    8·1 answer
  • The first real computer was an abacus?
    13·1 answer
  • During the data transmission there are chances that the data bits in the frame might get corrupted. This will require the sender
    8·1 answer
  • Write a program that removes all non-alphabetic characters from the given input.
    7·1 answer
  • the php function that is executed is a connection to a database cannot be made is the____ function. die | isset| end | connect.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!