Plot grraph , srink is problem
    5 visualizzazioni (ultimi 30 giorni)
  
       Mostra commenti meno recenti
    
the following code is plot the graph I want to change the Y axis value so that the box and plot on x -axis does concide , I try it using limit commmand but it just srink the graph 
x=-1000:25:975
u_exact=[-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.25E-08	-9.25E-08	-9.26E-08	-9.27E-08	-9.28E-08	-9.31E-08	-9.36E-08	-9.45E-08	-9.63E-08	-1.00E-07	-1.12E-07	-1.75E-07	-4.18134E+12	-1.77E-07	-1.12E-07	-1.00E-07	-9.63E-08	-9.45E-08	-9.36E-08	-9.31E-08	-9.28E-08	-9.27E-08	-9.26E-08	-9.25E-08	-9.25E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08]
u_RDTM=[-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.25E-08	-9.25E-08	-9.26E-08	-9.27E-08	-9.28E-08	-9.31E-08	-9.36E-08	-9.45E-08	-9.63E-08	-1.00E-07	-1.12E-07	-1.75E-07	-4.18134E+12	-1.77E-07	-1.12E-07	-1.00E-07	-9.63E-08	-9.45E-08	-9.36E-08	-9.31E-08	-9.28E-08	-9.27E-08	-9.26E-08	-9.25E-08	-9.25E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08]
plot(x,u_RDTM,'o',x,u_exact)
xlim([-1844 2054])
ylim([-6950633103752 1818593846248])
0 Commenti
Risposte (1)
  Torsten
      
      
 il 25 Ago 2024
        I don't know what you mean by  "I want to change the Y axis value so that the box and plot on x -axis does concide".
Maybe like this:
x=-1000:25:975;
u_exact=[-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.25E-08	-9.25E-08	-9.26E-08	-9.27E-08	-9.28E-08	-9.31E-08	-9.36E-08	-9.45E-08	-9.63E-08	-1.00E-07	-1.12E-07	-1.75E-07	-4.18134E+12	-1.77E-07	-1.12E-07	-1.00E-07	-9.63E-08	-9.45E-08	-9.36E-08	-9.31E-08	-9.28E-08	-9.27E-08	-9.26E-08	-9.25E-08	-9.25E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08];
u_RDTM=[-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.25E-08	-9.25E-08	-9.26E-08	-9.27E-08	-9.28E-08	-9.31E-08	-9.36E-08	-9.45E-08	-9.63E-08	-1.00E-07	-1.12E-07	-1.75E-07	-4.18134E+12	-1.77E-07	-1.12E-07	-1.00E-07	-9.63E-08	-9.45E-08	-9.36E-08	-9.31E-08	-9.28E-08	-9.27E-08	-9.26E-08	-9.25E-08	-9.25E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08];
semilogy(x,u_RDTM,'o',x,u_exact)
7 Commenti
  DGM
      
      
 il 1 Set 2024
				I didn't know this since I run an older version, but (in some versions newer than R2019b) you can do the following to apply some padding on both x and y.
x=-1000:25:975;
u_exact=[-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.25E-08	-9.25E-08	-9.26E-08	-9.27E-08	-9.28E-08	-9.31E-08	-9.36E-08	-9.45E-08	-9.63E-08	-1.00E-07	-1.12E-07	-1.75E-07	-4.18134E+12	-1.77E-07	-1.12E-07	-1.00E-07	-9.63E-08	-9.45E-08	-9.36E-08	-9.31E-08	-9.28E-08	-9.27E-08	-9.26E-08	-9.25E-08	-9.25E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08];
u_RDTM=[-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.25E-08	-9.25E-08	-9.26E-08	-9.27E-08	-9.28E-08	-9.31E-08	-9.36E-08	-9.45E-08	-9.63E-08	-1.00E-07	-1.12E-07	-1.75E-07	-4.18134E+12	-1.77E-07	-1.12E-07	-1.00E-07	-9.63E-08	-9.45E-08	-9.36E-08	-9.31E-08	-9.28E-08	-9.27E-08	-9.26E-08	-9.25E-08	-9.25E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08	-9.24E-08];
plot(x,u_RDTM,'o',x,u_exact)
axis padded
I'm not sure where this change was made, but it's been five years, so I assume that this is an option for most people, especially students.
Vedere anche
Categorie
				Scopri di più su Graphics Performance in Help Center e File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!






