CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Main CFD Forum (https://www.cfd-online.com/Forums/main/)
-   -   CFD by anderson, chp 10.... supersonic flow over flat plate (https://www.cfd-online.com/Forums/main/74130-cfd-anderson-chp-10-supersonic-flow-over-flat-plate.html)

varunjain89 March 25, 2010 06:22

CFD by anderson, chp 10.... supersonic flow over flat plate
 
hi all

i'm trying to write C code for supersonic flow over flat plate. i'm reffereing CFD by JD anderson chp 10. i have a few doubts hope u can help.

firstly when i'm calculating vector E at plate surface and vector F at inflow, what should be the values of txy, txx, tyy, qx and qy, should i consider. should i take all of them to be zero...???

and after prdictor step, when calculating txy, then in one of the terms we need to calculate central difference, so our expression is something like....
U(i+1,j)-U(i-1,j) but we dont have values for U(i+1,j) at time step t+dt, right...??? so am i suppose to use the values calculated at previous time step.... coz that is the only way... jz needed to confirm..

thanks once again

varun :)

Bajji December 20, 2011 04:30

Full code
 
Hi,

Sorry for the late reply.

I am posting the full code in the attachment, in C. All functions are named as in Anderson. Takes 70 seconds. No input files. All parameters are defined in preprocessor part..

Has been verified using the temperature profile at the trailing edge. Hope this helps.

Enjoy.

Bajji December 20, 2011 04:33

1 Attachment(s)
Ooops. Didn't upload.
Here should be the code. :D

ivan_CFD February 16, 2012 10:39

Thanks for the code :)

shirazbj March 29, 2013 07:26

thanks for c code.

shirazbj April 3, 2013 08:39

1 Attachment(s)
Quote:

Originally Posted by Bajji (Post 336435)
Ooops. Didn't upload.
Here should be the code. :D

there is one little error in the code, see attached pic.

The second Redx should be Redy.

Bajji April 29, 2013 00:20

Thank you
 
Hi Cean,
Thanks for pointing out the error! I don know how the plots came out fine after the mess up :( :confused:. Thanks again:)

tienthanh_bk2901 May 3, 2013 03:49

thank you so much

soroosh.alahdin@gmail.com August 14, 2013 12:37

would you please send me a copy?
 
my email address is my username, if you decided to help, ofcourse.

archeoptyrx August 14, 2013 16:34

Quote:

Originally Posted by Bajji (Post 336435)
Ooops. Didn't upload.
Here should be the code. :D

Mr.Balaji ,

I tried compiling the code u gave without making any change in it .

I just gave me errors . if possible take a look at this

Code:

main.c: In function ‘main’:
main.c:145:13: warning: passing argument 4 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 5 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 6 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 7 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 8 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 9 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 10 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 11 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 12 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c: At top level:
main.c:443:6: warning: conflicting types for ‘verbose_mac’ [enabled by default]
main.c:140:13: note: previous implicit declaration of ‘verbose_mac’ was here
main.c:1175:6: warning: conflicting types for ‘u2fp’ [enabled by default]
main.c:318:5: note: previous implicit declaration of ‘u2fp’ was here
/tmp/ccbyCj1V.o: In function `mac':
main.c:(.text+0xbe8): undefined reference to `pow'
main.c:(.text+0xe9c): undefined reference to `sqrt'
main.c:(.text+0xf68): undefined reference to `sqrt'
/tmp/ccbyCj1V.o: In function `verbose_mac':
main.c:(.text+0x19d2): undefined reference to `pow'
main.c:(.text+0x1aca): undefined reference to `sqrt'
main.c:(.text+0x1b96): undefined reference to `sqrt'
/tmp/ccbyCj1V.o: In function `fp2u':
main.c:(.text+0x2b45): undefined reference to `pow'
main.c:(.text+0x2b86): undefined reference to `pow'
/tmp/ccbyCj1V.o: In function `fp2e':
main.c:(.text+0x2cc9): undefined reference to `pow'
main.c:(.text+0x2e9a): undefined reference to `pow'
main.c:(.text+0x2ee1): undefined reference to `pow'
/tmp/ccbyCj1V.o:main.c:(.text+0x31eb): more undefined references to `pow' follow
collect2: error: ld returned 1 exit status
sudharsan@ubuntu:~/Desktop$ gcc -lm main.c
main.c: In function ‘main’:
main.c:145:13: warning: passing argument 4 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 5 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 6 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 7 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 8 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 9 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 10 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 11 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c:145:13: warning: passing argument 12 of ‘mac’ from incompatible pointer type [enabled by default]
main.c:69:6: note: expected ‘float *’ but argument is of type ‘float (*)[70][70]’
main.c: At top level:
main.c:443:6: warning: conflicting types for ‘verbose_mac’ [enabled by default]
main.c:140:13: note: previous implicit declaration of ‘verbose_mac’ was here
main.c:1175:6: warning: conflicting types for ‘u2fp’ [enabled by default]
main.c:318:5: note: previous implicit declaration of ‘u2fp’ was here
/tmp/ccnpPswn.o: In function `mac':
main.c:(.text+0xbe8): undefined reference to `pow'
main.c:(.text+0xe9c): undefined reference to `sqrt'
main.c:(.text+0xf68): undefined reference to `sqrt'
/tmp/ccnpPswn.o: In function `verbose_mac':
main.c:(.text+0x19d2): undefined reference to `pow'
main.c:(.text+0x1aca): undefined reference to `sqrt'
main.c:(.text+0x1b96): undefined reference to `sqrt'
/tmp/ccnpPswn.o: In function `fp2u':
main.c:(.text+0x2b45): undefined reference to `pow'
main.c:(.text+0x2b86): undefined reference to `pow'
/tmp/ccnpPswn.o: In function `fp2e':
main.c:(.text+0x2cc9): undefined reference to `pow'
main.c:(.text+0x2e9a): undefined reference to `pow'
main.c:(.text+0x2ee1): undefined reference to `pow'
/tmp/ccnpPswn.o:main.c:(.text+0x31eb): more undefined references to `pow' follow
collect2: error: ld returned 1 exit status


Bajji August 15, 2013 09:49

math library?
 
Hi,

Please google on "Linking math library while compiling c++ codes" .

You basically add -lm option to your compile line so that the GCC can find power and absolute functions that are used in the code.

PS: I had the same error few years ago :):D

Hope it helps

Bajji August 15, 2013 09:51

Code is there!
 
Hi,

The code is already posted here! Just run the main.c.

Quote:

Originally Posted by Bajji (Post 336435)
Ooops. Didn't upload.
Here should be the code. :D

:):):)

archeoptyrx August 20, 2013 23:02

Quote:

Originally Posted by Bajji (Post 445959)
Hi,

Please google on "Linking math library while compiling c++ codes" .

You basically add -lm option to your compile line so that the GCC can find power and absolute functions that are used in the code.

PS: I had the same error few years ago :):D

Hope it helps


IT worked Mr.Balaji . How do i obtain the plots ? . Do i need to use any other software to plot ? .

Thanks in advance

Bajji August 20, 2013 23:37

Plotting the output
 
Hi ,

Glad it helped you. You can use gnuplot for plotting results. A very small script will let you automate the plotting wonderfully. Its highly recommended for 2D plots.

Quick way to get things done is to copy the pressure and temperature matrices into Matlab and do surface plots. This is how I did it long back.:D

enjoy!

archeoptyrx August 20, 2013 23:44

Quote:

Originally Posted by Bajji (Post 447016)
Hi ,

Glad it helped you. You can use gnuplot for plotting results. A very small script will let you automate the plotting wonderfully. Its highly recommended for 2D plots.

Quick way to get things done is to copy the pressure and temperature matrices into Matlab and do surface plots. This is how I did it long back.:D

enjoy!


Thank you Mr.Balaji .

I got the u_profile via gnuplot . I myself tried writing the entire thing in matlab . it did gave me results after 15000 iterations . But the results are slightly over predicted . Can you help me with this ? I am not a good programmer .

shirazbj August 21, 2013 02:47

Quote:

Originally Posted by archeoptyrx (Post 447013)
IT worked Mr.Balaji . How do i obtain the plots ? . Do i need to use any other software to plot ? .

Thanks in advance

Hi, I made one exe file under win7@32. It outputs some plots while simulating. You can press D,T,P,V,R key to switch between Desity,Temperature,Presssure, Vector and residual plot. At the end, it also outputs GMSH's pos files. You could view it with GMSH.

You could download it from here:
https://sites.google.com/site/gmsh2s...edirects=0&d=1

Enjoy.

cpchung January 24, 2015 22:43

Quote:

Originally Posted by Bajji (Post 336435)
Ooops. Didn't upload.
Here should be the code. :D

I encountered the following error~~~

Could you point out what is the problem?
I use visual studio 2010 to compile it

1> Touching "Debug\navierStokes_anderson.unsuccessfulbuild ".
1>ClCompile:
1> main.cpp
1>d:\cfd\navierstokes_anderson\main.cpp(106): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(107): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(142): error C3861: 'verbose_mac': identifier not found
1>d:\cfd\navierstokes_anderson\main.cpp(147): error C2664: 'mac' : cannot convert parameter 4 from 'float [5][70][90]' to 'float *'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>d:\cfd\navierstokes_anderson\main.cpp(211): warning C4305: '=' : truncation from 'double' to 'float'
1>d:\cfd\navierstokes_anderson\main.cpp(217): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(218): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(221): warning C4305: '=' : truncation from 'double' to 'float'
1>d:\cfd\navierstokes_anderson\main.cpp(227): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(228): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(231): warning C4305: '=' : truncation from 'double' to 'float'
1>d:\cfd\navierstokes_anderson\main.cpp(265): warning C4305: 'initializing' : truncation from 'double' to 'float'
1>d:\cfd\navierstokes_anderson\main.cpp(269): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(270): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(271): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(299): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(300): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(301): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(309): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(320): error C3861: 'u2fp': identifier not found
1>d:\cfd\navierstokes_anderson\main.cpp(328): error C3861: 'u2fp': identifier not found
1>d:\cfd\navierstokes_anderson\main.cpp(450): warning C4305: 'initializing' : truncation from 'double' to 'float'
1>d:\cfd\navierstokes_anderson\main.cpp(454): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(482): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(483): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(484): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(491): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(615): error C3861: 'u2fp': identifier not found
1>d:\cfd\navierstokes_anderson\main.cpp(681): error C3861: 'u2fp': identifier not found
1>d:\cfd\navierstokes_anderson\main.cpp(717): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(732): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(749): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(761): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(769): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(773): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(777): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(781): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(785): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(793): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(797): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(801): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(806): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(810): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(828): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(836): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(840): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(844): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(848): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(852): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(860): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(864): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(868): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(874): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(878): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(896): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(903): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(907): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(911): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(917): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(921): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(931): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(935): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(939): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(944): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(948): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(955): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(959): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(963): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(967): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(971): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(979): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(983): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(987): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(993): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(997): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1014): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1015): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1021): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1025): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1032): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1036): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1052): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1053): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1060): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1064): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1073): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1077): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1099): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1100): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1101): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1102): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1124): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1125): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1126): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1127): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1164): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1165): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1166): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1167): warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
1>d:\cfd\navierstokes_anderson\main.cpp(1188): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:00.16
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

ivan_CFD February 11, 2015 09:47

Matlab code
 
Hi,

I have uploaded a Matlab code that solves the original problem in Anderson's book. It can be downloaded from MathWorks here: http://www.mathworks.com/matlabcentr...r-a-flat-plate

Hope this helps!!

ashitsme May 11, 2018 07:31

Quote:

Originally Posted by archeoptyrx (Post 447013)
IT worked Mr.Balaji . How do i obtain the plots ? . Do i need to use any other software to plot ? .

Thanks in advance

i am new at the programming can u provide me the complete code with final correction.its very urgent.


All times are GMT -4. The time now is 01:34.