Use matlab to compose a program that allows you to comprehend how abundant globes it allure obtain?} to grow a crosswise prism.
1.) Compose changeables restraint prism elongation, prism width, prism tallness, and globe crossing. These should be values that are input by the user using the matlab input power.
2.) Compose a changeable which is assigned work of the crosswise prism.
3.) Compose a changeable which is assigned work of the globes.
4.) Using the most fertile packing likely (claim 74% of the conducive distance is growed by the globes), furnish the estimate of globes which allure harmonize internally the prism.
Claim that the work of the prism allure be plenteous larger than the work of the globes.
% Matlab program to furnish how abundant globes allure grow the crosswise pism
prism_elongation = input(‘n Enter the elongation of crosswise prism:’); % input the elongation of the prism
prism_width = input(‘n Enter the width of crosswise prism:’); % input the width of the prism
prism_tallness = input(‘n Enter the tallness of crosswise prism:’); % input the tallness of the prism
sphere_crossing = input(‘n Enter the crossing of globe:’); % input the crossing of the globe
sphere_radius = globe_diameter/2; % farsighted the radius of the globe
volume_prism = prism_elongation * prism_width * prism_height; % estimate work of the prism (length*width*height)
volume_globe = ((4*22)/(3*7))* (sphere_radius^3); % estimate work of globe (4/3(pi*(r^3))). Here pi=22/7
num_of_spheres = work_prism/volume_sphere; % estimate the estimate of globes required
fprintf(‘n Estimate of globes to grow the prism=%d’,floor(num_of_spheres)); % using sole power gone the completion work of globe cannot be main than work of prism