MatLAB | Mathematica | MathCAD | Maple Answers

Questions: 245

Answers by our Experts: 142

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

Write MATLAB scripts for the following:

a) To accept two numbers from the user; Display all prime numbers between
these two numbers.

b)To accept two numbers from the user and display perfect numbers
between these two numbers.

c) To display Armstrong numbers from 100 to 999 inclusive.
Design an algorithm that will prompt for and receive the time expressed in 2400 format (e.g. 2305 hours), convert it to 12 hour format (eg 11.05 p.m.) and display the new time to the screen. Your program is to repeat the processing until a sentinel time of 9999 is entered.
Design a program that will read a file of employee records containing employee
number, employee name, hourly pay rate, regular hours worked and overtime hours
worked. The company pays its employees weekly, according to the following rules:
regular pay = regular hours worked x hourly rate of pay
overtime pay = overtime hours worked x hourly rate of pay x 1.5
total pay = regular pay + overtime pay
Your program is to read the input data on each employee’s record and compute and
print the employee’s total pay, on the weekly payroll report. All input data and
calculated amounts are to appear on the report. A total payroll amount and average
payroll amount is to appear at the end of the report.
Design an algorithm to accept income from the user; compute the income tax to be
paid and display on the screen. Income tax is based on the following table available
at this link: http://iras.gov.sg/irasHome/page04.aspx?id=1190 (Note: Choose
Resident Individuals)
Need help on this short and supposedly simple problem for MATLAB.

Suppose there is a square matrix: A = [2 1 2 1; 2 2 1 1; 2 1 2 1; 1 2 2 2].

Where:
2 = blocked (cant go there)
1 = can move there

What can I write on MATLAB that can allow me to choose a two spots in the given matrix and locate these spots as start and finish. And then when matlab runs, it will show me how to move from the start to the finish position, showing the co-ordinates as it goes through.
hi:
I wrote a code to solve an ODE using Runge-Kutta 4th order, but unfortunately it doesn't work properly.
i need your help please:
clc;
clear all;
% initial values
gamma = 1.4;
P1 = 101325; % Pa
T1 = 298; % K
Rho1 = 1.225; % kg/m3
tol = -(1e-6); % convergence criteria for Vtheta
Vtheta0 = -10; % fake value to initiate the while loop
delta_theta = 0.5; % angle marching
% inputs
M1 = input('Free stream Mach number=');
theta_c = input('cone angle in degree=');
theta_s = input('initial guess for shock angle in degree=');

while (Vtheta0 <= -tol) || (Vtheta0 >= tol)

% checking the correct input for beta
if (theta_s <= asind(1/M1))
theta_c = 0.0;
Mc = M1;
disp(' !!!!! theta_s > theta_s_max !!!!! ');
return;
end

% calculating the parametrs before shock
Mn1 = M1 * sind (theta_s);
Mu1 = M1 * cosd (theta_s);
P2 = P1 * (1 + (2 * gamma * (Mn1 ^ 2 - 1) / (gamma + 1)));
Rho2 = Rho1 * ((gamma + 1) * Mn1 ^ 2 / (2+((gamma - 1) * Mu1 ^ 2)));
T2 = T1 * P2 * Rho1 / (P1 * Rho2);
theta = atand (
9. What is the resultant temperature when 100 g of steam at 100° C is passed through 500 g of ice at -20° C. the specific heat of water is 0.5 cal g-1° C-1.
12. The speed of a motor boat with respect to water is v = 14 m/s. The speed of water with respect to the banks is 6 m/s. When the boat began travelling upstream, a buoy was dropped from it. A buoy is a body that can float in water. The boat travelled 6.3 km upstream (with respect to banks), turned about and caught up with the buoy. Find the time T lapsed between dropping the buoy and catching up with it again.
what is the physical significance of Ising model in computation physics?
hi.... i have a problem in my code in matlab
i plot my diagram (ECG ) that i get info from database in this site:http://www.physionet.org/ with
now i have ECG diagram in matlab but i want to find value and position of max and min OF ALL OF WAVE ....but with this code i found just one min and one max and i dont know how i can write a loop or for to search and find whole Min and Max of wave with their values in axes y ... in medical field i mean find R-peaks in EKG
thanks alot and my code


x = load ('C:\ekg\example_ecg.txt');
y = x ( : , 2);
h = plot (y );
x = get(h,'XData'); % Get the plotted data
y = get(h,'YData');
imin = find(min(y) == y);% Find the index of the min and max
imax = find(max(y) == y);

text(x(imin),y(imin),[' Min ',num2str(y(imin))],...
'VerticalAlignment','middle',...
'HorizontalAlignment','left',...
'FontSize',7)
text(x(imax),y(imax),['Max ',num2str(y(imax))],...
'VerticalAlignment','bottom',...
'HorizontalAlignment','right',...
'FontSize',7)
LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS