Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~10.4K People Reached
Favorite Forums
Favorite Tags
Member Avatar for ALosh99

I have four ordinary differential equation written in mathmatica : Simplify[DSolve[{y1'[x] == -0.162y1[x], y2'[x]=-0.148 y2[x]+ 0.055y1[x],y3'[x]==-0.134 y3[x]+ 0.033y1[x]+ 0.039y2[x],y4'[x]==-0.125y4[x]+0.021 y1[x]+0.025y2[x]+ 0.043y3[x], y1[0] == 100,y2[0]==4.76,y3[0]==69.7,y4[0]==0}, {y1[x], y2[x],y3[x],y4[x]}, x]] I am trying to write them in python I have try the following : def n1(y,x): s1 = 0.162131 dydx = -s1 * …

0
235
Member Avatar for ALosh99

I am trying to calculate some thing called directional derivatives of a vector b (which defined in attached file as an example) to calculate the directional derivatives of the vector b . the result of the example is also in the attached file. I serached in goolge to find how …

Member Avatar for ALosh99
0
1K
Member Avatar for ALosh99

How can I calculate the average weight in python for two columns (x,y) data file, between 8<r< 9. in python I have tried this put it dose not work with my np.average(X,Y, weights=[8,9]) I have calculated the average weight which is 12.14, now I am trying to use this weight …

Member Avatar for vaishali_2
0
300
Member Avatar for ALosh99

I have two array data files. I want to add weight function to these two array which I ploted see attached file. what I am trying to do now is use the weight function below, for two data set and select the points between 8<r <9 in each data then …

Member Avatar for ALosh99
0
140
Member Avatar for ALosh99

I want to shift my plot to the right by fixed value , I have npy file contain 7 columns, I plot the histogram for the column number 7 as below: plt.figure() plt.hist(x[7],bins=800,color='y',histtype='step',linewidth=2,stacked=True) plt.show() I am trying to shift my plot to the right with fix value but I could …

Member Avatar for ALosh99
0
1K
Member Avatar for ALosh99

I want to define a function like this: n_H = 0.9 # constant . x = np.array([16.7, 16.5, 16.1, 15, 13.5,14.2, 14.9, 13.7])# example to test D = np.array([0, 1, 4, 7, 16, 31, 64, 127]) Sec_nucli = [] x = [] D = [] Sec_nucli[i]= n_H *D[i]* x[i] where …

Member Avatar for ALosh99
0
354
Member Avatar for ALosh99

I have this point in (x,y) : ([27.266378342786531], [1.9505463431334713]) Now I want to use this point(I have many points,I want to know how can I use this point first ) to put it in the function below insted of x :(I have tried to make an array put i don't …

Member Avatar for Gribouillis
0
164
Member Avatar for ALosh99

I am trying to plot the picewise function below: rho0 = 3*10e-11 Rd = 3.15 Rc = 7 def Density(rho0, r, Rc, Rd): if r < Rc : return rho0 elif r> Rc : return rho0*np.exp(-(r-Rc)/Rd) r = np.linspace(0,20, 1000) y= Density(rho0, r, Rc, Rd) plt.plot(r, y) plt.show() I am …

Member Avatar for ALosh99
0
869
Member Avatar for ALosh99

Hello, I'm trying to plot this function with using this values: Rh = 9.8 H0 = 0.063 def Thickness_H(H0, r, Rh): return float(H0)*np.exp(float(r)/float(Rh)) r = np.linspace(0,1, 10) x =Thickness_H(H0, r, Rh) plt.plot(r, x) plt.show() I'm trying to defind r like what i know but this dose not work, I'm getting …

Member Avatar for ALosh99
0
308
Member Avatar for ALosh99

I am trying to define a function in c++, I wrote it in main function. I am getting an error : a function-definition is not allowed here before ‘{’ token}I have defined it as following : float distance(float x, float y, float pitch) { float r; //local variable r = …

Member Avatar for ALosh99
0
242
Member Avatar for ALosh99

I am trying to define the archimedean spiral: when im trying to define the inclination angle (incl) of the tangent vector to the orbit ( i.e: tan(incl)) im getting an error :"'numpy.ufunc' object does not support item assignment". the same error when I want to calculate cos(incl), and sin(incl). Any …

Member Avatar for Gribouillis
0
4K
Member Avatar for ALosh99

How can we insert two independent random number to two equations (x,y) contain two parts like this: x = a* randomnumber1 + b* randomnumber2 y = c* randomnumber1 + d* randomnumber2 these two random number should be independent. Thank inadvance.

Member Avatar for ALosh99
0
260
Member Avatar for ALosh99

I plot the archimedaen spirlas for one branch, how can I plot more than one branches starting from the original, my code that I have written : n= 1000 a= 2. # will turn the spiral v= 1 omega = 0.1 r0 = v/omega T=100 N=10000 t=np.linspace(0,T,N+1) r= v*t theta …

0
118
Member Avatar for ALosh99

Hello, I am trying to write two equations, each element in the equation is an arry , double XDiffusion (int D,int D11, int x, int s) { float DeltaX; return DeltaX; } double YDiffusion (int D,int D11, int x, int s) { float DeltaY; return DeltaY; } int main() { …

Member Avatar for ALosh99
0
608