8 years, 20 days

## Combining solve and plot commands...

Maple

Hi,

I am struggling with one task involving solve and plot commands. I would appreciate if I could get some help. What I need to do is as follows:

1. Define alpha between 0 and 1.

2. Solve an equation f(x,alpha) =0 for x by taking different values of alpha.

3. Of all values of x obtained in step 2, choose the value of x between 0 and 1 and discard all others. I have technically shown that there will be exactly one value that is acceptable and all other values of x can be discarded.

4. For different values of alpha and correspondingly selected values of x in step 3, plot and display function g(x,alpha) with function value on the vertical axis and alpha on the horizontal axis.

Regards,

Omkar

## Linear fit model...

Maple

Hi,

I am struggling with statistical analysis of a dataset. I would appreciate help from the community. Let me describe what I am looking for.

1. The linear regression model that I am trying to use is Y=b1X1 + b2x2 + e. I am interested in estimating b1 and b2 so that the estimated error is the least.

2. I am trying to randomly select 25 percent of observations from the dataset and estimate b1 and b2.

3. The estimated coefficients are used to predict the Y values for the remainder of the 75 percent of the data and calculate the error. The idea is to use a subset to estimate coefficients, and check for the robustness of the estimates.

4. The process is iterated for say 100 times.

5. Each time, I would like to store the statistical results and export them to an excel file.

For some reason, each time I struggle with one or two steps mentioned above. Could anyone help me with the approach?

Thank you,

Omkar

## Underline in axis labels...

Maple

Hi,

How do I get underlined text -- axis labels and legend -- in plot command? Tried many ways, but could not succeed. I would appreciate any inputs.

Regards,

Omkar

## interrupting solve command...

Hi,
I am having a difficulty is running a loop with solve command. I am using a command solve(f(x,alpha)=0, x) in a loop for alpha = 1 by 1 to 10. For some reasons, for some values of alpha, the solve command does not give any solution and hence the program keeps running on. When I interrupt the program at such instance, the remainder of the program is not complete.

I tried using the try-catch command. I face the same issue.

Is there a way for me to bypass the solve command when it does not find any solution for a particular alpha and continue with the remainder of the program? I can come back and manually obtain the solution for such alpha values where solve command does not provide an answer.

Regards,

Omkar

## solving two bi-variate equations numeric...

Maple

Hi,

I am struggling to obtain solutions for two bi-variate euqations numerically. A command line that I am currently using (for a dummy problem) is as follows:

soln := {solve({f(x,y)=0, g(x,y)=0}, {x,y})};

There are mainly two issues:

1. For some reasons, Maple 2017 takes ages to obtain solutions for certain parameter values. At times, it does not provide any solution which should not happen. I am assuming that this is to do with the "solve" command.

2. Also, I am not sure how to limit search procedure within feasible ranges for variables. In this case, how do I incorporate conditions 0 <= x, y <=1? If I can incorporate these constraints in the "solve" (or any better) command, then I can automatically get rid of complex solutions as they are not relevant for me.

I would appreciate inputs in this regard. Thank you,

Omkar

 1 2 3 Page 2 of 3
﻿