MATLAB 2D Graph of Total Charge vs. Voltage

Status
Not open for further replies.

dzafar

Member level 4
Joined
Jan 17, 2017
Messages
76
Helped
1
Reputation
2
Reaction score
1
Trophy points
8
Activity points
690
Hello,

I am new to MATLAB. I am trying to plot a 2D graph showing total charge (in pC) vs. Voltage (in V) ranging from 1 to 10V. Below is my attempt which gives an empty window.

Code:
q_tot = 7.062*10^(-12);
Voltage = [1:1:10];
figure(1);
plot(q_tot, Voltage);
title('Q vs. V');
xlabel('x[m]');
ylabel('y[m]');
grid on;

Can someone please help.

Thanks
 
Last edited:

You are not defining any relation between Charge and Voltage, both are independent vectors. It is missing the function that correlates both, something of the kind q_tot = f(Voltage) where "f" denotes the algebraic function where the above parameter 7.062*10^(-12) is included.
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…