我可以在linux C++編譯器或visual C++ 2010中使用符號C++功能嗎?還一個問題,有時在節目有這樣的頭部代碼gcc或microsoft visual C++中的符號C++
#include <iostream>
#include "symbolicc++.h"
using namespace std;
int main(void)
{
Symbolic x("x");
cout << integrate(x+1, x); // => 1/2*x^(2)+x
Symbolic y("y");
cout << df(y, x); // => 0
cout << df(y[x], x); // => df(y[x],x)
cout << df(exp(cos(y[x])), x); // => -sin(y[x])*df(y[x],x)*e^cos(y[x])
return 0;
}
頭#include "symbolicc++.h"
我曾嘗試
#include " "
,但它不告訴我symbolicC++。h後,該怎麼辦呢,請給我幾個例子
there is such error after compile
symbolic.cpp:2:25: error: symbolicc++.h: No such file or directory
symbolic.cpp: In function ‘int main()’:
symbolic.cpp:7: error: ‘Symbolic’ was not declared in this scope
symbolic.cpp:7: error: expected ‘;’ before ‘x’
symbolic.cpp:8: error: ‘x’ was not declared in this scope
symbolic.cpp:8: error: ‘integrate’ was not declared in this scope
symbolic.cpp:9: error: expected ‘;’ before ‘y’
symbolic.cpp:10: error: ‘y’ was not declared in this scope
symbolic.cpp:10: error: ‘df’ was not declared in this scope
symbolic.cpp:12: error: ‘cos’ was not declared in this scope
symbolic.cpp:12: error: ‘exp’ was not declared in this scope
-1。谷歌+我很幸運能給你實際的答案(這是對的,只要你正確安裝) – 2010-09-06 14:18:46
@Alexandre你認爲爲什麼在這裏發帖?因爲我已經搜索和不理解所以問人們爲什麼downvote?好吧 – user439547 2010-09-06 14:22:56
我可以't downvote,否則我會減少你的標記減少我的標記 – user439547 2010-09-06 14:23:51