SimReal / Python / Matlab: Programming - Exercise - Mathematics - Numbers |
SimReal - Python - Matlab |
001 Sum / Product / Power Program an application that compute the sum, product and power of two real numbers a and b: sum = a + b product = a * b power = abThe output should be the following (with the example of a = 3 and b = 4): Number1 = 3 Number2 = 4 Sum = 7 Product = 12 Power = 81 |
SimReal - Python - Matlab |
002 Complex Program an application that compute the sum and product of two complex numbers c1 and c2: The output should be the following (with the example of c1 = 3 + 1i and c2 = -2 + 2i): Number1 = 3 + 1i Number2 = -2 + 2i Sum = 1 + 3i Product = -8 + 4i |
SimReal - Python - Matlab |
003 Complex Numbers to Control a Piston Construct an application that use complex numbers to control a piston. The arm connected to origin rotates with constant angular velocity. The arm connected to the piston should have a variable height h. Draw the graph of the position and speed of the piston. The velocity of the piston should be shown by a vector. First, try this experiment in practice. Then try to make a mathematical model of the piston. |